Commit d1dbf09b authored by hujun's avatar hujun

time

parent 68f54806
...@@ -751,21 +751,15 @@ class OfficeBargain extends Basic ...@@ -751,21 +751,15 @@ class OfficeBargain extends Basic
$content = ''; $content = '';
if ($data['agent_id'] != $this->params['agent_id']) { if ($data['agent_id'] != $this->params['agent_id']) {
$agent_id[0] = $data['agent_id']; if ($data['agent_id'] != $this->params['agent_id']) {
$agent_id[1] = $this->params['agent_id']; $redis = new RedisCacheService();
$m_agent = new AAgents(); $old_agent = $redis->getRedisCache(2, $data['agent_id']);
$agent_data = $m_agent->getAgentById('id,name,phone,district_id,store_id', [ 'in_id' => $agent_id ]); $this->totalOfficialReceiptsV2($old_agent['id'], $old_agent['district_id'], $old_agent['store_id'], $data['create_time'], $data['income_time']);
$content .= '【分佣方:' . $old_agent['name'] . '-' . $old_agent['phone'].'】';
foreach ($agent_data as $v) {
if ($v['id'] == $data['agent_id']) { $new_agent = $redis->getRedisCache(2, $this->params['agent_id']);
$this->totalOfficialReceiptsV2($v['id'], $v['district_id'], $v['store_id'], $data['create_time'], $data['income_time']); $this->totalOfficialReceiptsV2($new_agent['id'], $new_agent['district_id'], $new_agent['store_id'], $data['create_time'], $data['income_time']);
$content .= '【分佣方:' . $v['name'] . '-' . $v['phone'].'】'; $content .= '【修改为:' . $new_agent['name'] . '-' . $new_agent['phone'] . '】';
}
if ($v['id'] == $this->params['agent_id']) {
$this->totalOfficialReceiptsV2($v['id'], $v['district_id'], $v['store_id'], $data['create_time'], $data['income_time']);
$content .= '【修改为:' . $v['name'] . '-' . $v['phone'] . '】';
}
} }
} }
......
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