|
@@ -97,26 +97,26 @@ class Buy extends Core
|
|
|
$this->data['price'] += $this->data['list'][$k]['price'] * $n;
|
|
|
$this->data['name'][] = $this->data['list'][$k]['name'];
|
|
|
}
|
|
|
- $this->data['method'] =array();
|
|
|
+ $this->data['wallet'] =array();
|
|
|
if($method == 1){
|
|
|
- $this->data['method']['method'] = $method;
|
|
|
+ $this->data['wallet']['method'] = $method;
|
|
|
if($this->shop && $this->shop['price']){
|
|
|
if($this->shop['price'] >= $this->data['price']){
|
|
|
- $this->data['method']['type'] = 1;
|
|
|
+ $this->data['wallet']['type'] = 1;
|
|
|
|
|
|
- $this->data['method']['price'] = $this->data['price'];
|
|
|
+ $this->data['wallet']['price'] = $this->data['price'];
|
|
|
$this->data['price'] = 0;
|
|
|
|
|
|
- $this->data['method']['yue'] = $this->shop['price'] - $this->data['price'];
|
|
|
+ $this->data['wallet']['yue'] = $this->shop['price'] - $this->data['price'];
|
|
|
} else {
|
|
|
- $this->data['method']['type'] = 2;
|
|
|
- $this->data['method']['price'] = $this->shop['price'];
|
|
|
+ $this->data['wallet']['type'] = 2;
|
|
|
+ $this->data['wallet']['price'] = $this->shop['price'];
|
|
|
$this->data['price'] = $this->data['price'] - $this->shop['price'];
|
|
|
- $this->data['method']['yue'] = 0;
|
|
|
+ $this->data['wallet']['yue'] = 0;
|
|
|
}
|
|
|
}
|
|
|
}else{
|
|
|
- $this->data['method'] = false;
|
|
|
+ $this->data['wallet'] = false;
|
|
|
}
|
|
|
|
|
|
$this->data['name'] = implode(',', $this->data['name']);
|
|
@@ -131,7 +131,7 @@ class Buy extends Core
|
|
|
|
|
|
$this->goods();
|
|
|
|
|
|
- $pay = Dever::load('mshop/lib/buy')->set(1,1)->action($this->passport_uid, 1, $this->shop_id, $this->data['name'], $this->data['num'], $this->data['list'], $this->data['price'], $info, $refer, $this->shop['area'],$this->data['method']);
|
|
|
+ $pay = Dever::load('mshop/lib/buy')->set(1,1)->action($this->passport_uid, 1, $this->shop_id, $this->data['name'], $this->data['num'], $this->data['list'], $this->data['price'], $info, $refer, $this->shop['area'],$this->data['wallet']);
|
|
|
return $pay;
|
|
|
}
|
|
|
|