Commit 21c5fd1a authored by hujun's avatar hujun

成交报告详情修改

parent 61025ec9
...@@ -209,10 +209,12 @@ class Finance extends Basic ...@@ -209,10 +209,12 @@ class Finance extends Basic
$m_fee = new OFee(); $m_fee = new OFee();
$update_data = []; $update_data = [];
//实收佣金
if (count($this->params['practical_fee']) > 5) { if (count($this->params['practical_fee']) > 5) {
return $this->response('101', '实收佣金数量超过限制'); return $this->response('101', '实收佣金数量超过限制');
} }
//应收总佣金
if (!empty($this->params['commission'])) { if (!empty($this->params['commission'])) {
$update_data['commission'] = $this->params['commission']; $update_data['commission'] = $this->params['commission'];
} }
...@@ -221,9 +223,20 @@ class Finance extends Basic ...@@ -221,9 +223,20 @@ class Finance extends Basic
$update_data['content'] = $this->params['content']; $update_data['content'] = $this->params['content'];
} }
//是否开业
if (isset($this->params['is_open'])) {
$update_data['is_open'] = $this->params['is_open'];
}
//成交类型 10出租 20 增佣 30 代理 40 好处费
if (!empty($this->params['trade_type'])) {
$update_data['trade_type'] = $this->params['trade_type'];
}
$data['data'] = $m_bargain->updateBargainById($this->params['id'], $update_data); $data['data'] = $m_bargain->updateBargainById($this->params['id'], $update_data);
if ($data['data'] == 1) { if ($data['data'] == 1) {
//新增实收佣金 array 5
$m_fee->addFee($this->params['practical_fee'], $this->params['id'], 0, $this->userId); $m_fee->addFee($this->params['practical_fee'], $this->params['id'], 0, $this->userId);
} else { } else {
$data['code'] = 101; $data['code'] = 101;
......
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