Commit 2a6cf80f authored by hujun's avatar hujun

收信息人

parent 47d43522
......@@ -43,6 +43,7 @@ class PushMessageService
public function pushReportMessage($house_id, $agent_id, $type, $operation_id)
{
try {
$agent_id_arr = [];
$house_agent = new GHousesToAgents();
$agent = new AAgents();
$house = new GHouses();
......@@ -52,15 +53,15 @@ class PushMessageService
$agent_name = $agent->getAgentsStoreById([ 'a.id' => $agent_id ], 'name,store_name');
$house_data = $house->getHouseDetail('internal_title', [ 'id' => $house_id ]);
$order_id = $m_report->getReportOrder('b.id',['a.report_agent_id'=>$agent_id]);
foreach ($data as $k => $v) {
$content = "【{$agent_name['store_name']}】店【{$agent_name['name']}】约带看【{$house_data['internal_title']}】商铺";
// $this->pushAgentAllDeviceId($v['id'], '报备', $content);
$save['message'] = $content;
$save['order_id'] = $order_id['id'];
$save['house_id'] = $house_id;
$this->record(7, 0, [$agent_id], $operation_id, $save);
foreach ($data as $k => $v) {
// $this->pushAgentAllDeviceId($v['id'], '报备', $content);
$agent_id_arr[] = $v['id'];
}
$this->record(7, $house_id, $agent_id_arr, $operation_id, $save);
$result = true;
} catch (\Exception $e) {
$result = false;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment