17 require_once SQ_INCLUDE_PATH.
'/package_manager.inc';
41 $this->_full_path = SQ_PACKAGES_PATH.
'/trim';
57 if ($GLOBALS[
'SQ_SYSTEM']->am->installed(
'cron_job_update_trim_record')) {
58 return Array(
'cron_job_update_trim_record');
74 $cron_manager = $GLOBALS[
'SQ_SYSTEM']->am->getSystemAsset(
'cron_manager');
75 if (is_null($cron_manager)) {
76 trigger_error(
'Couldn\'t get cron manager, couldn\'t create Update Trim Record cron job', E_USER_WARNING);
81 $GLOBALS[
'SQ_SYSTEM']->am->includeAsset(
'cron_job_update_trim_record');
84 $root_user = $GLOBALS[
'SQ_SYSTEM']->am->getSystemAsset(
'root_user');
85 if (!$cron_manager->addJob($cron_job, $root_user, SQ_LINK_TYPE_2)) {
86 trigger_error(
'Update Trim Record Cron Job NOT CREATED', E_USER_ERROR);
88 pre_echo(
'Update Trim Record Cron Job Id: '.$cron_job->id);
90 $GLOBALS[
'SQ_SYSTEM']->am->registerSystemAsset(
'cron_job_update_trim_record', $cron_job->id);