12 private const STEP_ROWS_LIMIT = 100;
18 $limit = self::STEP_ROWS_LIMIT;
22 $idCondition =
$lastId > 0 ?
" AND tu.ID < {$lastId} " :
'';
25 select tu.ID from b_bp_task_user tu
26 where tu.USER_ID = {$userId} {$idCondition} order by tu.ID DESC LIMIT {$limit}
30 $ids = array_column($queryRows,
'ID');
34 return self::FINISH_EXECUTION;
39 $idsSql = implode(
',', $ids);
43 INSERT INTO b_bp_workflow_user
44 (USER_ID, WORKFLOW_ID, IS_AUTHOR, WORKFLOW_STATUS, TASK_STATUS, MODIFIED)
46 select tu.USER_ID, t.WORKFLOW_ID, 0,
case when wi.id is
null then 1
else 0 end,
47 case when tu.STATUS =
'0' then 2
else 1 end,
48 case when tu.DATE_UPDATE is
null then now()
else tu.DATE_UPDATE end
49 from b_bp_task_user tu
50 inner join b_bp_task t on (t.ID = tu.TASK_ID)
51 left join b_bp_workflow_instance wi on (t.WORKFLOW_ID = wi.ID)
52 where tu.ID IN ({$idsSql})
54 ON DUPLICATE KEY UPDATE WORKFLOW_STATUS = VALUES(WORKFLOW_STATUS), TASK_STATUS = VALUES(TASK_STATUS), MODIFIED = VALUES(MODIFIED)
58 return self::CONTINUE_EXECUTION;
61 public static function bindUser(
int $userId): void
setOuterParams(array $outerParams)
hidden mSiteList<?=htmlspecialcharsbx(serialize( $siteList))?><?=htmlspecialcharsbx( $siteList[ $j]["ID"])?> _Propery<? if(((COption::GetOptionString( $module_id, "different_set", "N")=="Y") &&( $j !=0))||(COption::GetOptionString( $module_id, "different_set", "N")=="N")) echo "display: none;"?> top adm detail content cell l top adm detail content cell r heading center center ID left