Beispiel #1
0
 public function __construct()
 {
     parent::__construct();
     $this->job = Auto_order_job_Model::get_instance();
     $this->log = Auto_order_log_Model::get_instance();
     //$this->plan = Auto_order_plan_Model::get_instance();
     $this->plans_basic_obj = Plans_basicService::get_instance();
     $this->jczq_obj = Plans_jczqService::get_instance();
     $this->jclq_obj = Plans_jclqService::get_instance();
     $this->sfc_obj = Plans_sfcService::get_instance();
     $this->bjdc_obj = Plans_bjdcService::get_instance();
     $this->errorDesc = Kohana::config('errorcode.error');
 }
Beispiel #2
0
 public function bonus_plan($ordernum)
 {
     $result = Plans_basicService::get_instance()->get_by_ordernum($ordernum);
     if (empty($result)) {
         return FALSE;
     }
     if ($result['status'] != 4) {
         return FALSE;
     }
     switch ($result['ticket_type']) {
         case 1:
             //$flag = Plans_jczqService::get_instance()->bonus_plan($result['order_num']);
             $flag = Plans_jczqService::get_instance()->bonus_plan_virtual($result['order_num']);
             break;
         case 2:
             $flag = Plans_sfcService::get_instance()->bonus_plan($result['order_num']);
             break;
         case 6:
             $flag = Plans_jclqService::get_instance()->bonus_plan($result['order_num']);
             break;
         case 7:
             $flag = Plans_bjdcService::get_instance()->bonus_plan($result['order_num']);
             break;
     }
 }