Commit fc990db3 by 朱继来

联营批量导入添加标准品牌

parent 66042ee6
...@@ -754,6 +754,7 @@ Class AddOrderController extends Controller ...@@ -754,6 +754,7 @@ Class AddOrderController extends Controller
// 推送到API // 推送到API
$data['data'] = $excel; $data['data'] = $excel;
$data['operator_id'] = $request->user->userId; $data['operator_id'] = $request->user->userId;
$data['operator_name'] = $request->user->name;
$data['type'] = 3; // 后台批量添加标记 $data['type'] = 3; // 后台批量添加标记
$data['uid'] = $request->input('user_id'); $data['uid'] = $request->input('user_id');
$data['delivery_place'] = $request->input('delivery_place'); $data['delivery_place'] = $request->input('delivery_place');
...@@ -825,6 +826,11 @@ Class AddOrderController extends Controller ...@@ -825,6 +826,11 @@ Class AddOrderController extends Controller
return; return;
} }
if ($type == 1 && !$val['standard_brand_name']) {
$err[] = '第'.$key.'行,标准品牌不能为空';
return;
}
if ($val['num'] <= 0) { if ($val['num'] <= 0) {
$err[] = '第'.$key.'行,商品数量等于或小于0'; $err[] = '第'.$key.'行,商品数量等于或小于0';
return; return;
......
...@@ -53,14 +53,15 @@ ...@@ -53,14 +53,15 @@
'joint_map' => [ 'joint_map' => [
0 => 'goods_name', 0 => 'goods_name',
1 => 'brand_name', 1 => 'brand_name',
2 => 'num', 2 => 'standard_brand_name',
3 => 'goods_price', 3 => 'num',
4 => 'delivery_time', 4 => 'goods_price',
5 => 'supplier_name', 5 => 'delivery_time',
6 => 'id', 6 => 'supplier_name',
7 => 'buyer_id', 7 => 'id',
8 => 'remarks', 8 => 'buyer_id',
9 => 'batch', 9 => 'remarks',
10 => 'batch',
], ],
'self_map' => [ 'self_map' => [
......
...@@ -650,7 +650,7 @@ ...@@ -650,7 +650,7 @@
}, },
}) })
layer.msg('批量导入中...', {icon: 16, time: 0, shade: 0.3}); // layer.msg('批量导入中...', {icon: 16, time: 0, shade: 0.3});
}) })
form.find('input[type="file"]').trigger('click'); form.find('input[type="file"]').trigger('click');
......
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