Пример #1
0
 /**
  * 好租精选
  * @param $record
  * @return bool|mixed
  */
 private function noticeChoiceSolrAjkAPI($record)
 {
     //14-精选推广,15-取消精选推广,16-取消精选排队
     if ($record['type'] == 14 || $record['type'] == Const_ProLogType::LOG_CHOICE_NOFITY_SOLR_UP) {
         $flag = 1;
     } elseif ($record['type'] == 15 || $record['type'] == 16 || $record['type'] == Const_ProLogType::LOG_CHOICE_NOFITY_SOLR_DOWN) {
         $flag = 2;
     } else {
         $this->setLog('不需要做solr处理' . __METHOD__);
         return false;
     }
     //根据计划id查询计划信息
     $PlanInfo = Model_Plan_EsfAjkPropSpread::getPlanInfoByIdEx($record['planId']);
     if ($PlanInfo) {
         $offer = $PlanInfo['offer'];
         $commsHpratioA = $PlanInfo['commsHpratioA'];
         $commsHpratio = $PlanInfo['commsHpratio'];
         $spreadstartdate = $PlanInfo['spreadstartdate'];
         $spreadenddate = $PlanInfo['spreadenddate'];
         $planid = $PlanInfo['id'];
     } else {
         $offer = 0;
         $commsHpratioA = 0;
         $commsHpratio = 0;
         $spreadstartdate = 0;
         $spreadenddate = 0;
         $planid = $record['planId'];
     }
     $res = Bll_Combo_NoticeSolrUpDown::noticeChoiceSolrAjkAPI($record['cityId'], $record['brokerId'], $record['houseId'], $flag, $offer, $commsHpratioA, $commsHpratio, $spreadstartdate, $spreadenddate, $planid, Bll_Combo_NoticeSolrUpDown::HLSFromChoiceUpDown, strtotime($record['addDate']), date('Ymd', strtotime($record['addDate'])) . $record['id']);
     $this->setLog('通知solr res: ' . json_encode($res));
     return $res;
 }