diff --git a/app/common/dao/store/product/ProductAttrDao.php b/app/common/dao/store/product/ProductAttrDao.php index 5cfc9cd8..54c05cb7 100755 --- a/app/common/dao/store/product/ProductAttrDao.php +++ b/app/common/dao/store/product/ProductAttrDao.php @@ -41,9 +41,6 @@ class ProductAttrDao extends BaseDao */ public function insert(array $data) { - foreach ($data as &$item) { - $item['profit_rate'] = bcdiv(bcsub($item['price'], $item['procure_price'], 2), $item['price'], 2) * 100; - } return ($this->getModel()::getDB())->insertAll($data); } diff --git a/app/common/repositories/system/merchant/MerchantIntentionRepository.php b/app/common/repositories/system/merchant/MerchantIntentionRepository.php index c8024cbe..780473e6 100755 --- a/app/common/repositories/system/merchant/MerchantIntentionRepository.php +++ b/app/common/repositories/system/merchant/MerchantIntentionRepository.php @@ -201,7 +201,7 @@ class MerchantIntentionRepository extends BaseRepository if ($intention['type'] == 2) { $merId = MerchantIntention::where('uid', $intention['uid'])->where('status', 1)->value('mer_id'); if (!empty($merId)) { - Merchant::where('mer_id', $merId)->update(['business_status' => 2]); + Merchant::where('mer_id', $merId)->update(['business_status' => 2, 'mer_settlement_agree_status' => 1]); } } if (!empty($smsData)) {