Commit 2075783b by 朱继来

调整添加购物车来源

parent 95927ba7
...@@ -398,14 +398,17 @@ Class AddOrderController extends Controller ...@@ -398,14 +398,17 @@ Class AddOrderController extends Controller
public function addCart(Request $request) public function addCart(Request $request)
{ {
if ($request->isMethod('post')) { if ($request->isMethod('post')) {
$data['uid'] = $request->input('uid'); $data['uid'] = $request->input('uid');
$data['id'] = $request->input('id'); $data['id'] = $request->input('id');
$data['num'] = $request->input('num'); $data['num'] = $request->input('num');
$data['buy'] = $request->input('buy'); $data['buy'] = $request->input('buy');
$data['delivery_place'] = $request->input('delivery_place'); $data['delivery_place'] = $request->input('delivery_place');
$data['type'] = 2; // 后台添加标记 $data['type'] = 2; // 后台添加标记
$data['pf'] = 4;
$add_type = $request->input('add_type', 1); // 1-后台订单添加,2-询价订单添加
$data['pf'] = $add_type == 1 ? 4 : 8;
$data['k1'] = time(); $data['k1'] = time();
$data['k2'] = md5(md5($data['k1']).'fh6y5t4rr351d2c3bryi'); $data['k2'] = md5(md5($data['k1']).'fh6y5t4rr351d2c3bryi');
......
...@@ -563,6 +563,7 @@ layui.config({ ...@@ -563,6 +563,7 @@ layui.config({
num: goods_min_num, num: goods_min_num,
buy: -1, buy: -1,
delivery_place: delivery_place, delivery_place: delivery_place,
add_type: 2,
} }
$.ajax({ $.ajax({
......
...@@ -509,6 +509,7 @@ ...@@ -509,6 +509,7 @@
num: goods_min_num, num: goods_min_num,
buy: -1, buy: -1,
delivery_place: delivery_place, delivery_place: delivery_place,
add_type: 1,
} }
$.ajax({ $.ajax({
......
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