The line of one staff member in the staff page (fl_staff_row): their name and SteamID, whether they are on the server, and a button that demotes them to user after a confirmation. Assign the member with set_member. Derives from fl_base_panel.

Summary

Methods

demote()client
Asks the player to confirm and then asks the server to demote the member of this row.
Returns the staff member this row stands for.
Init()client
Creates the labels of the row and the button that demotes the member.
Draws the row through the theme's PaintRow hook, unless the active theme draws it in its PaintAdminRow hook.
Puts the name on the left, and the status and the demote button on the right.
Sets whether the row is drawn with a darker background, which the page does for every other row.
Sets the staff member this row stands for and fills in their name and status.

Methods

Asks the player to confirm and then asks the server to demote the member of this row.

Returns the staff member this row stands for.

Returns

  • Map member, or nil if it has not been set yet

Creates the labels of the row and the button that demotes the member.

Draws the row through the theme's PaintRow hook, unless the active theme draws it in its PaintAdminRow hook.

Parameters

  • w Number panel width
  • h Number panel height

PANEL:PerformLayout(w, h)

client plugins/admin/plugin/views/cl_staff_list.lua:180

Puts the name on the left, and the status and the demote button on the right.

Parameters

  • w Number panel width
  • h Number panel height

Sets whether the row is drawn with a darker background, which the page does for every other row.

Parameters

  • dark Boolean

PANEL:set_member(member)

client plugins/admin/plugin/views/cl_staff_list.lua:205

Sets the staff member this row stands for and fills in their name and status.

Parameters

  • member Map member with the steam_id, name, role and online fields

Defined in