Commit e14087c0 authored by hujun's avatar hujun

审核消息

parent a068d544
......@@ -451,10 +451,12 @@ class PushMessageService
$this->pushAgentAllDeviceId($v['addressee_id'], $title, $v['message'], $type, $id, $is_forbidden,$v['house_id'], $v['order_id']);
$update_data['status'] = 1;
$update_data['send_time'] = date('Y-m-d H:i:s');
$m_push->updateData($update_data, [ 'id' => $v['id'] ]);
$id_array[] = $v['id'];
}
$update_data['status'] = 1;
$update_data['send_time'] = date('Y-m-d H:i:s');
$m_push->updateData($update_data, [ 'id' => ['in', $id_array] ]);
}
return ;
}
......@@ -610,4 +612,23 @@ class PushMessageService
$this->record(6, 0, [$agent_id], $operation_id, $record_data);
return true;
}
/**
*
*/
public function pushCheckRecord() {
$m_push = new MPushCheckMessage();
$field = 'id,addressee_id,type,message,house_id,user_id,order_id,title';
$where['status'] = $id = $is_forbidden = 0;
$push_data = $m_push->getDateLimit($field, $where, 100);
foreach ($push_data['data'] as $k => $v) {
$this->pushAgentAllDeviceId($v['addressee_id'], $v['title'], $v['message'], $v['type'], $id, $is_forbidden, $v['house_id'], $v['order_id']);
$id_array[] = $v['id'];
}
$update_data['status'] = 1;
$update_data['send_time'] = date('Y-m-d H:i:s');
$m_push->updateData($update_data, [ 'id' =>['in', $id_array] ]);
}
}
\ No newline at end of file
......@@ -21,6 +21,7 @@ class PushMessageTask
//经纪人
$push = new PushMessageService();
$push->pushRecord();
$push->pushCheckRecord();
//客户
$push = new PushClientService();
......
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