Commit 6b916b4e by 朱继来

调整查询商品

parent 36b82f1a
......@@ -310,6 +310,11 @@ Class AddOrderController extends Controller
if ($request->isMethod('post')) {
$url = Config('website.search-skuid');
$data['id'] = $request->input('sku_id');
$user_id = $request->input('user_id', 0);
if ($user_id) {
$data['uid'] = $user_id;
}
$data['k1'] = time();
$data['k2'] = md5(md5($data['k1']).'fh6y5t4rr351d2c3bryi');
......
......@@ -252,6 +252,7 @@
// 获取SKU信息
$('.get-sku').click(function() {
var sku_id = $(this).siblings('.search-sku').val();
var user_id = $('.user_id').val() || 0;
if (!sku_id) {
layer.msg('请输入SKU_ID');
......@@ -266,7 +267,7 @@
$.ajax({
url: '/ajax/getSku',
type: 'post',
data: {sku_id : sku_id.trim()},
data: {sku_id : sku_id.trim(), user_id: user_id},
dataType: 'json',
success: function (resp) { console.log(resp)
if (resp.errcode != 0) {
......
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