Commit 6403f6f1 by mushishixian

附加费问题修改

parent 540471c1
Showing with 4 additions and 3 deletions
...@@ -10,8 +10,10 @@ class SupplierExtraFeeService ...@@ -10,8 +10,10 @@ class SupplierExtraFeeService
public function saveSupplierExtraFee($extraFee) public function saveSupplierExtraFee($extraFee)
{ {
$supplierExtendFee = []; $supplierExtendFee = [];
$model = new SupplierExtendModel();
$cache = $model->getExtendExtra($extraFee['supplier_code'], $extraFee['supplier_id']);
if (empty($extraFee['cn']['max']) && empty($extraFee['cn']['price']) if (empty($extraFee['cn']['max']) && empty($extraFee['cn']['price'])
&& empty($extraFee['hk']['max']) && empty($extraFee['hk']['price'])) { && empty($extraFee['hk']['max']) && empty($extraFee['hk']['price'])&&empty($cache)) {
return true; return true;
} }
if (!empty($extraFee['cn'])) { if (!empty($extraFee['cn'])) {
...@@ -23,8 +25,7 @@ class SupplierExtraFeeService ...@@ -23,8 +25,7 @@ class SupplierExtraFeeService
if (empty($supplierExtendFee)) { if (empty($supplierExtendFee)) {
return true; return true;
} }
$model = new SupplierExtendModel();
$cache = $model->getExtendExtra($extraFee['supplier_code'], $extraFee['supplier_id']);
$extraFee['charge_content'] = json_encode($supplierExtendFee); $extraFee['charge_content'] = json_encode($supplierExtendFee);
$supplierCode = $extraFee['supplier_code']; $supplierCode = $extraFee['supplier_code'];
......
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 sign in to comment