PHP Class DbaController, vanilla

Inheritance: extends DashboardController
Show file Open project: vanilla/vanilla

Public Properties

Property Type Description
$Form Gdn_Form
$Model DBAModel

Public Methods

Method Description
counts ( boolean $Table = false, boolean $Column = false, boolean $From = false, boolean $To = false, boolean $Max = false ) Recalculate counters.
fixInsertUserID ( boolean | string $Table = false ) Scan a table for invalid InsertUserID values and update with SystemUserID
fixPermissions ( ) Set Member-like permissions on all roles with missing permissions.
fixUrlCodes ( $Table, $Column )
fixUserRole ( ) Look for users with an invalid role and apply the role specified to those users.
initialize ( ) Runs before every call to this controller.
rebuildCategoryTree ( ) Fix the category tree after an import that only gives a sort & parent.
resetPermissions ( ) Reset all role permissions based on role type.

Protected Methods

Method Description
_setJob ( string $Name ) Set a job.

Method Details

_setJob() protected method

Set a job.
protected _setJob ( string $Name )
$Name string

counts() public method

Recalculate counters.
public counts ( boolean $Table = false, boolean $Column = false, boolean $From = false, boolean $To = false, boolean $Max = false )
$Table boolean
$Column boolean
$From boolean
$To boolean
$Max boolean

fixInsertUserID() public method

Scan a table for invalid InsertUserID values and update with SystemUserID
public fixInsertUserID ( boolean | string $Table = false )
$Table boolean | string The name of the table to fix InsertUserID in.

fixPermissions() public method

Useful for after an import that didn't include permissions but did include a whole lotta roles you don't want to edit manually.
public fixPermissions ( )

fixUrlCodes() public method

public fixUrlCodes ( $Table, $Column )
$Table
$Column

fixUserRole() public method

Look for users with an invalid role and apply the role specified to those users.
public fixUserRole ( )

initialize() public method

Runs before every call to this controller.
public initialize ( )

rebuildCategoryTree() public method

Fix the category tree after an import that only gives a sort & parent.
public rebuildCategoryTree ( )

resetPermissions() public method

Reset all role permissions based on role type.
public resetPermissions ( )

Property Details

$Form public property

public Gdn_Form $Form
return Gdn_Form

$Model public property

public DBAModel $Model
return DBAModel