Files
WrenchBoradWeb/www-api/app/Controllers/WrenchCrons.php
T
CHIEFSOFT\ameye 716d4a8d35 cron ret
2023-11-25 21:43:21 -05:00

52 lines
1.7 KiB
PHP

<?php
namespace App\Controllers;
define('WRB_CRONJOB_JOBDUE_REMINDER',771);
define('WRB_CRONJOB_JOBDUE_PAYMENTS',772);
define('WRB_CRONJOB_SIGNUP_ALERT', 773);
define('WRB_CRONJOB_PASTDUE_ALERT',774);
define('WRB_CRONJOB_OFFER_REFUND_ALERT',775);
define('WRB_CRONJOB_PENDOFFER_ALERT',776);
class WrenchCrons extends BaseController
{
public function apigate(){
$in["action"] =WRB_JOB_CRONJOB;
$wrenchboard = new \App\Models\BackendModel();
$in['call_action'] = WRB_CRONJOB_SIGNUP_ALERT;
$in['one_limit'] = 3;
$ret['WRB_CRONJOB_SIGNUP_ALERT'] = $wrenchboard->wrenchboard_api($in, $out);
$in['call_action'] = WRB_CRONJOB_JOBDUE_REMINDER;
$in['one_limit'] = 3;
$ret['WRB_CRONJOB_JOBDUE_REMINDER'] = $wrenchboard->wrenchboard_api($in, $out);
$in['call_action'] = WRB_CRONJOB_PENDOFFER_ALERT;
$in['one_limit'] = 3;
$ret['WRB_CRONJOB_PENDOFFER_ALERT'] = $wrenchboard->wrenchboard_api($in, $out);
$in['call_action'] = WRB_CRONJOB_JOBDUE_PAYMENTS;
$in['one_limit'] = 3;
$ret['WRB_CRONJOB_JOBDUE_PAYMENTS'] = $wrenchboard->wrenchboard_api($in, $out);
$in['call_action'] = WRB_CRONJOB_PASTDUE_ALERT;
$in['one_limit'] = 3;
$ret['WRB_CRONJOB_PASTDUE_ALERT'] = $wrenchboard->wrenchboard_api($in, $out);
$in['call_action'] = WRB_CRONJOB_OFFER_REFUND_ALERT;
$in['one_limit'] = 1;
$ret['WRB_CRONJOB_OFFER_REFUND_ALERT'] = $wrenchboard->wrenchboard_api($in, $out);
// $out['internal_return'] = $ret;
$out = $ret;
log_message('critical', "WrenchCrons ===> 0001");
//$response = []; //json_decode($complete, true);
return $this->response->setJson($out);
}
}