Adding Labor to Service Desk
addLabor
Creates a labor record for a specified Service Desk action with automatic rate calculation.
bool $this->addLabor(
int $sd,
int $sda,
int $workgroup,
int $worker,
string $date,
int $hours,
bool|int $billable = true,
?int $workflow = null,
?float $flatrate = null
);
Parameters:
$sd (int): Service Desk RECID
$sda (int): Service Desk Action RECID
$workgroup (int): Workgroup RECID
$worker (int): Worker contact RECID
$date (string): Work date (if null, uses current date)
$hours (int): Hours worked
$billable (bool|int): Whether the labor is billable (default: true)
$workflow (?int): Optional workflow RECID
$flaterate (?float): Optional flat rate amount
Returns
bool - True on success, false on failure