|
@@ -258,28 +258,28 @@ Class Option_account{
|
|
$audit = Dever::param('audit',$data);
|
|
$audit = Dever::param('audit',$data);
|
|
$num = Dever::param('num',$data);
|
|
$num = Dever::param('num',$data);
|
|
$info = Dever::db('agent/option_account')->find($id);
|
|
$info = Dever::db('agent/option_account')->find($id);
|
|
- if (!$info) {
|
|
|
|
- if ($price <= $zh_price){
|
|
|
|
- $zj_price = $price;
|
|
|
|
- } elseif ($price > $zh_price) {
|
|
|
|
- $zj_price = $price - $zh_price;
|
|
|
|
- }
|
|
|
|
- $w['where_id'] = $id;
|
|
|
|
- $w['zj_price'] = $zj_price;
|
|
|
|
- // print_R($w);die;
|
|
|
|
- Dever::db('agent/option_account')->update($w);
|
|
|
|
- }
|
|
|
|
- if (!$info['zj_price'] || $info['zj_price'] <=0) {
|
|
|
|
- if ($info['price'] <= $info['zh_price']) {
|
|
|
|
- $zj_price = $info['price'];
|
|
|
|
- } elseif ($info['price'] > $info['zh_price']) {
|
|
|
|
- $zj_price = $info['price'] - $info['zh_price'];
|
|
|
|
- }
|
|
|
|
- $w['where_id'] = $info['id'];
|
|
|
|
- $w['zj_price'] = $zj_price;
|
|
|
|
- // print_R($w);die;
|
|
|
|
- Dever::db('agent/option_account')->update($w);
|
|
|
|
- }
|
|
|
|
|
|
+ // if (!$info) {
|
|
|
|
+ // if ($price <= $zh_price){
|
|
|
|
+ // $zj_price = $price;
|
|
|
|
+ // } elseif ($price > $zh_price) {
|
|
|
|
+ // $zj_price = $price - $zh_price;
|
|
|
|
+ // }
|
|
|
|
+ // $w['where_id'] = $id;
|
|
|
|
+ // $w['zj_price'] = $zj_price;
|
|
|
|
+ // // print_R($w);die;
|
|
|
|
+ // Dever::db('agent/option_account')->update($w);
|
|
|
|
+ // }
|
|
|
|
+ // if (!$info['zj_price'] || $info['zj_price'] <=0) {
|
|
|
|
+ // if ($info['price'] <= $info['zh_price']) {
|
|
|
|
+ // $zj_price = $info['price'];
|
|
|
|
+ // } elseif ($info['price'] > $info['zh_price']) {
|
|
|
|
+ // $zj_price = $info['price'] - $info['zh_price'];
|
|
|
|
+ // }
|
|
|
|
+ // $w['where_id'] = $info['id'];
|
|
|
|
+ // $w['zj_price'] = $zj_price;
|
|
|
|
+ // // print_R($w);die;
|
|
|
|
+ // Dever::db('agent/option_account')->update($w);
|
|
|
|
+ // }
|
|
if($audit){
|
|
if($audit){
|
|
if ($audit == 1) {
|
|
if ($audit == 1) {
|
|
$where['where_id'] = $id;
|
|
$where['where_id'] = $id;
|