Merge branch 'dev' of https://gitea.lihaink.cn/mkm/multi-store into dev
This commit is contained in:
commit
393659cdf5
@ -15,8 +15,9 @@ class DemoLogic extends BaseLogic
|
||||
$arr = Db::name('ceshi_two')->select();
|
||||
foreach ($arr as $k => $v) {
|
||||
//门店供货、商户、零售
|
||||
$res = Db::name('store_product')->where('id', $v['product_id'])->update(['purchase' => $v['price'], 'cost' => bcadd($v['price1'], 0, 2), 'vip_price' => bcadd($v['price1'], 0, 2), 'price' => bcadd($v['price6'], 0, 2)]);
|
||||
$res = Db::name('store_product')->where('id', $v['product_id'])->update(['purchase' => $v['price'], 'cost' => bcadd($v['price1'], 0, 2), 'vip_price' => bcadd($v['price10'], 0, 2), 'price' => bcadd($v['price6'], 0, 2)]);
|
||||
if ($res) {
|
||||
Db::name('store_branch_product')->where('product_id', $v['product_id'])->update(['purchase' => $v['price'], 'cost' => bcadd($v['price1'], 0, 2), 'vip_price' => bcadd($v['price10'], 0, 2), 'price' => bcadd($v['price6'], 0, 2)]);
|
||||
Db::name('ceshi_two')->where('product_id', $v['product_id'])->update(['status' => 1]);
|
||||
}
|
||||
//种养殖
|
||||
|
Loading…
x
Reference in New Issue
Block a user