Updater
in package
Class that update structure and data to database.
Table of Contents
- addRoleToPicklist() : void
- Function used to change picklist type field (uitype 16) to field with permissions based on role (uitype 15).
- batchDelete() : array<string|int, int>
- Batch insert rows.
- batchInsert() : array<string|int, int>
- Batch insert rows.
- batchUpdate() : array<string|int, int>
- Batch update rows.
- cron() : array<string|int, mixed>
- Function to add and remove cron.
- removeRoleToPicklist() : void
- Function used to change picklist type field (uitype 15 to 16).
Methods
addRoleToPicklist()
Function used to change picklist type field (uitype 16) to field with permissions based on role (uitype 15).
public
static addRoleToPicklist(array<string|int, mixed> $fields) : void
$fields = [ 'fieldName', 'osstimecontrol_status', ];
Parameters
- $fields : array<string|int, mixed>
Return values
void —batchDelete()
Batch insert rows.
public
static batchDelete(array<string|int, mixed> $rows) : array<string|int, int>
$rows = [ ['vtiger_cvcolumnlist', ['cvid' => 43]], ];
Parameters
- $rows : array<string|int, mixed>
Tags
Return values
array<string|int, int> —batchInsert()
Batch insert rows.
public
static batchInsert(array<string|int, mixed> $rows) : array<string|int, int>
$rows = [ ['vtiger_cvcolumnlist', ['cvid' => 43, 'columnindex' => 5, 'columnname' => 'cc'], ], ];
Parameters
- $rows : array<string|int, mixed>
Tags
Return values
array<string|int, int> —batchUpdate()
Batch update rows.
public
static batchUpdate(array<string|int, mixed> $rows) : array<string|int, int>
$rows = [ ['table name', [ update ], [ condition ], ['u_#__squotes_invfield', ['colspan' => 25], ['id' => 1]], ];
Parameters
- $rows : array<string|int, mixed>
Tags
Return values
array<string|int, int> —cron()
Function to add and remove cron.
public
static cron(array<string|int, string> $crons) : array<string|int, mixed>
$crons = [ ['type' => 'add', 'data' => ['LBL_BROWSING_HISTORY', 'cron/BrowsingHistory.php', 86400, NULL, NULL, 1, NULL, 29, NULL]], ['type' => 'remove', 'data' => ['LBL_BATCH_PROCESSES']], ];
Parameters
- $crons : array<string|int, string>
Return values
array<string|int, mixed> —removeRoleToPicklist()
Function used to change picklist type field (uitype 15 to 16).
public
static removeRoleToPicklist(array<string|int, string> $fields) : void
Parameters
- $fields : array<string|int, string>
-
List of field names