...
|
...
|
@@ -118,21 +118,21 @@ class Bcoupon extends Backend |
|
|
//无门槛
|
|
|
if($params['coupon_type'] == 0){
|
|
|
//减少券,去掉满减金额,折扣字段,
|
|
|
unset($params['full_reduce']);
|
|
|
unset($params['discount']);
|
|
|
$params['full_reduce'] = 0;
|
|
|
$params['discount'] = 0;
|
|
|
}else{
|
|
|
//折扣券,去掉满减金额,减少金额字段,
|
|
|
unset($params['full_reduce']);
|
|
|
unset($params['reduce']);
|
|
|
$params['full_reduce'] = 0;
|
|
|
$params['reduce'] = 0;
|
|
|
}
|
|
|
}else{
|
|
|
//有门槛
|
|
|
if($params['coupon_type'] == 0){
|
|
|
//减少券,去掉折扣字段,
|
|
|
unset($params['discount']);
|
|
|
$params['discount'] = 0;
|
|
|
}else{
|
|
|
//折扣券,去掉减少金额字段,
|
|
|
unset($params['reduce']);
|
|
|
$params['reduce'] = 0;
|
|
|
}
|
|
|
}
|
|
|
$result = $this->model->allowField(true)->save($params);
|
...
|
...
|
@@ -192,21 +192,21 @@ class Bcoupon extends Backend |
|
|
//无门槛
|
|
|
if($params['coupon_type'] == 0){
|
|
|
//减少券,去掉满减金额,折扣字段,
|
|
|
unset($params['full_reduce']);
|
|
|
unset($params['discount']);
|
|
|
$params['full_reduce'] = 0;
|
|
|
$params['discount'] = 0;
|
|
|
}else{
|
|
|
//折扣券,去掉满减金额,减少金额字段,
|
|
|
unset($params['full_reduce']);
|
|
|
unset($params['reduce']);
|
|
|
$params['full_reduce'] = 0;
|
|
|
$params['reduce'] = 0;
|
|
|
}
|
|
|
}else{
|
|
|
//有门槛
|
|
|
if($params['coupon_type'] == 0){
|
|
|
//减少券,去掉折扣字段,
|
|
|
unset($params['discount']);
|
|
|
$params['discount'] = 0;
|
|
|
}else{
|
|
|
//折扣券,去掉减少金额字段,
|
|
|
unset($params['reduce']);
|
|
|
$params['reduce'] = 0;
|
|
|
}
|
|
|
}
|
|
|
$result = $row->allowField(true)->save($params);
|
...
|
...
|
|