Example #1
0
 public function handle_request_internal()
 {
     if ($this->_params['demon']) {
         goto demon;
     }
     $brokerId = $this->_params['brokerId'];
     $houseId = $this->_params['propId'];
     $budget = $this->_params['budget'];
     $bll = new BLL_Choice_EsfAPPAPIChoice();
     if (($data = $bll->startChoice($brokerId, $houseId, $budget)) === false) {
         return array('status' => Const_APIStatus::RETURN_CODE_ERROR, 'errcode' => $bll->errorCode, 'message' => $bll->errorMsg);
     }
     return array('status' => Const_APIStatus::RETURN_CODE_OK, 'data' => $data);
     demon:
     return array('status' => Const_APIStatus::RETURN_CODE_OK, 'data' => array('status' => bll_choice_EsfAPPAPIChoice::START_CHOICE_TO_ONLINE, 'statusMsg' => bll_choice_EsfAPPAPIChoice::START_CHOICE_TO_ONLINE_MSG));
 }