Commit 450b32c7 by 朱继来

Merge branch 'master' of http://119.23.72.7/zhujilai/Order into zjl_merge_20200821

parents 45f8bb28 5b3edca0
...@@ -1665,6 +1665,7 @@ Class OrderController extends Controller ...@@ -1665,6 +1665,7 @@ Class OrderController extends Controller
public function ajaxCancel(Request $request) public function ajaxCancel(Request $request)
{ {
if ($request->isMethod('post')) { if ($request->isMethod('post')) {
$data['user_id'] = $request->input('user_id', 0);
$data['order_id'] = $request->input('order_id', 0); $data['order_id'] = $request->input('order_id', 0);
$data['cancel_reason'] = $request->input('cancel_reason', ''); $data['cancel_reason'] = $request->input('cancel_reason', '');
$data['type'] = $request->input('type', 2); // 2.取消订单,3.审核不通过,4-填写取消原因 $data['type'] = $request->input('type', 2); // 2.取消订单,3.审核不通过,4-填写取消原因
......
...@@ -301,8 +301,8 @@ class WebController extends Controller ...@@ -301,8 +301,8 @@ class WebController extends Controller
if (!$user_id) return redirect('/web/selfSampleList'); if (!$user_id) return redirect('/web/selfSampleList');
$data['title'] = '自营样片领取和邀约记录'; $data['title'] = '领取和邀约记录';
$data['paths'] = [["title" => '自营订单', "href" => '#'], ["title" => '自营订单领取列表', "href" => '/web/selfSampleList'], ["title" => '自营样片领取和邀约记录', "href" => '#']]; $data['paths'] = [["title" => '自营订单', "href" => '#'], ["title" => '自营订单领取列表', "href" => '/web/selfSampleList'], ["title" => '领取和邀约记录', "href" => '#']];
$data['user_id'] = $user_id; $data['user_id'] = $user_id;
$UserMainModel = new UserMainModel; $UserMainModel = new UserMainModel;
......
...@@ -26,11 +26,12 @@ class UserSampleApplyModel extends Model ...@@ -26,11 +26,12 @@ class UserSampleApplyModel extends Model
{ {
$page = $request->input('page', 1); $page = $request->input('page', 1);
$limit = $request->input('limit', 10); $limit = $request->input('limit', 10);
$field = ['a.apply_id', 'a.user_id', 'a.account', 'a.order_id', 'order_sn', 'a.goods_id', 'a.goods_name', 'a.apply_num', 'a.quota', 'a.create_time']; $field = ['a.apply_id', 'a.user_id', 'a.account', 'a.order_id', 'order_sn', 'a.goods_id', 'a.goods_name', 'a.apply_num', 'a.quota', 'a.type', 'a.create_time'];
$map['account'] = $request->input('account', ''); // 用户账户 $map['account'] = $request->input('account', ''); // 用户账户
$map['goods_name'] = $request->input('goods_name', ''); // 商品名称 $map['goods_name'] = $request->input('goods_name', ''); // 商品名称
$map['order_sn'] = $request->input('order_sn', ''); // 订单号 $map['order_sn'] = $request->input('order_sn', ''); // 订单号
$map['type'] = $request->input('type', ''); // 活动名称
$map['begin_time'] = $request->input('begin_time', '') ? strtotime($request->input('begin_time')) : ''; $map['begin_time'] = $request->input('begin_time', '') ? strtotime($request->input('begin_time')) : '';
$map['end_time'] = $request->input('end_time', '') ? strtotime($request->input('end_time')) + 86399 : ''; $map['end_time'] = $request->input('end_time', '') ? strtotime($request->input('end_time')) + 86399 : '';
...@@ -55,6 +56,11 @@ class UserSampleApplyModel extends Model ...@@ -55,6 +56,11 @@ class UserSampleApplyModel extends Model
$query->where('a.order_sn', '=', $map['order_sn']); $query->where('a.order_sn', '=', $map['order_sn']);
} }
})->where(function($query) use ($map) { })->where(function($query) use ($map) {
// 活动名称
if ($map['type']) {
$query->where('a.type', '=', $map['type']);
}
})->where(function($query) use ($map) {
// 创建时间 // 创建时间
if(!empty($map['begin_time']) && !empty($map['end_time'])) { if(!empty($map['begin_time']) && !empty($map['end_time'])) {
$query->whereBetween('a.create_time', [$map['begin_time'], $map['end_time']]); $query->whereBetween('a.create_time', [$map['begin_time'], $map['end_time']]);
...@@ -97,8 +103,10 @@ class UserSampleApplyModel extends Model ...@@ -97,8 +103,10 @@ class UserSampleApplyModel extends Model
$UserSampleInviteModel = new UserSampleInviteModel; $UserSampleInviteModel = new UserSampleInviteModel;
$UserInfoModel = new UserInfoModel; $UserInfoModel = new UserInfoModel;
foreach ($data as &$v) { foreach ($data as &$v) {
$v['type_val'] = $v['type'] == 1 ? '样片' : '工具尺';
$v['work_function'] = $UserInfoModel->getWorkFunction($v['user_id']); $v['work_function'] = $UserInfoModel->getWorkFunction($v['user_id']);
$v['invite_count'] = $UserSampleInviteModel->getUserInviteCount($v['user_id']); $v['sample_invite_count'] = $UserSampleInviteModel->getUserInviteCount($v['user_id']);
$v['ruler_invite_count'] = $UserSampleInviteModel->getUserInviteCount($v['user_id'], 2);
$v['apply_num_total'] = $this->getSampleApplySum($v['user_id']); // 获取指定用户申请的样片总数 $v['apply_num_total'] = $this->getSampleApplySum($v['user_id']); // 获取指定用户申请的样片总数
$v['quota_total'] = $this->getSampleApplySum($v['user_id'], 'quota'); // 获取指定用户申请的样片消耗总人数 $v['quota_total'] = $this->getSampleApplySum($v['user_id'], 'quota'); // 获取指定用户申请的样片消耗总人数
// $v['quota_total'] = $this->getUsedCount($v['user_id']); // // $v['quota_total'] = $this->getUsedCount($v['user_id']); //
...@@ -126,7 +134,7 @@ class UserSampleApplyModel extends Model ...@@ -126,7 +134,7 @@ class UserSampleApplyModel extends Model
$page = $request->input('page', 1); $page = $request->input('page', 1);
$limit = $request->input('limit', 10); $limit = $request->input('limit', 10);
$field = ['apply_id', 'user_id', 'account', 'order_id', 'order_sn', 'goods_id', 'goods_name', 'apply_num', 'quota', 'is_expire', 'create_time']; $field = ['apply_id', 'user_id', 'account', 'order_id', 'order_sn', 'goods_id', 'goods_name', 'apply_num', 'quota', 'is_expire', 'type', 'create_time'];
$list = $this->where('user_id', $user_id) $list = $this->where('user_id', $user_id)
->select($field) ->select($field)
...@@ -147,6 +155,8 @@ class UserSampleApplyModel extends Model ...@@ -147,6 +155,8 @@ class UserSampleApplyModel extends Model
$OrderModel = new OrderModel(); $OrderModel = new OrderModel();
foreach ($data as &$v) { foreach ($data as &$v) {
$v['type_val'] = $v['type'] == 1 ? '样片' : '工具尺';
$order = $OrderModel->where('order_id', $v['order_id'])->select('status')->first(); $order = $OrderModel->where('order_id', $v['order_id'])->select('status')->first();
if (!$order) continue; if (!$order) continue;
......
...@@ -28,7 +28,7 @@ class UserSampleInviteModel extends Model ...@@ -28,7 +28,7 @@ class UserSampleInviteModel extends Model
$page = $request->input('page', 1); $page = $request->input('page', 1);
$limit = $request->input('limit', 10); $limit = $request->input('limit', 10);
$field = ['invite_id', 'user_id', 'account', 'invitee_uid', 'invitee_mobile', 'is_expire', 'create_time']; $field = ['invite_id', 'user_id', 'account', 'invitee_uid', 'invitee_mobile', 'is_expire', 'type', 'create_time'];
$list = $this->where('user_id', $user_id) $list = $this->where('user_id', $user_id)
->select($field) ->select($field)
...@@ -36,13 +36,32 @@ class UserSampleInviteModel extends Model ...@@ -36,13 +36,32 @@ class UserSampleInviteModel extends Model
->orderBy('invite_id', 'asc') ->orderBy('invite_id', 'asc')
->paginate($limit, ['*'], 'page', $page)->toArray(); ->paginate($limit, ['*'], 'page', $page)->toArray();
$list['data'] = $this->handleData($list['data']);
return [0, '获取成功', $list['data'], $list['total']]; return [0, '获取成功', $list['data'], $list['total']];
} }
public function handleData($data)
{
if (!$data) return false;
$OrderModel = new OrderModel();
foreach ($data as &$v) {
$v['type_val'] = $v['type'] == 1 ? '样片' : '工具尺';
}
return $data;
}
// 获取指定用户邀约人数 // 获取指定用户邀约人数
public function getUserInviteCount($user_id) public function getUserInviteCount($user_id, $type=1)
{ {
return $this->where('user_id', $user_id)->where('is_expire', 1)->count(); $map = [];
$map['user_id'] = $user_id;
$map['type'] = $type;
return $this->where($map)->where('is_expire', 1)->count();
} }
// 获取用户邀约列表 // 获取用户邀约列表
......
...@@ -780,7 +780,7 @@ ...@@ -780,7 +780,7 @@
return false; return false;
} }
var en_reg = /^[a-zA-Z0-9\.\s\,\(\)]+$/; var en_reg = /^[a-zA-Z0-9\.\-\s\,\(\)]+$/;
if(!en_reg.test(customer_en)){ if(!en_reg.test(customer_en)){
layer.msg('请填写全英文名称'); layer.msg('请填写全英文名称');
return false; return false;
......
...@@ -101,7 +101,7 @@ ...@@ -101,7 +101,7 @@
var price = parseFloat($(this).find('.price').val()) || 0; var price = parseFloat($(this).find('.price').val()) || 0;
if (supplier.hasOwnProperty(sup)) { // 判断当前key是否存在于数组中 if (supplier.hasOwnProperty(sup)) { // 判断当前key是否存在于数组中
supplier[sup] += parseFloat(num * price).toFixed(2); supplier[sup] = (parseFloat(supplier[sup]) + parseFloat(num * price)).toFixed(2);
} else { } else {
supplier[sup] = parseFloat(num * price).toFixed(2); supplier[sup] = parseFloat(num * price).toFixed(2);
} }
...@@ -443,6 +443,9 @@ ...@@ -443,6 +443,9 @@
var goods_name = $(this).find('.change_goods_name').val(); var goods_name = $(this).find('.change_goods_name').val();
var buyer_id = $(this).find('.change_buyer_id').selectpicker('val'); var buyer_id = $(this).find('.change_buyer_id').selectpicker('val');
var batch = $(this).find('.change_batch').val(); var batch = $(this).find('.change_batch').val();
var status = $(this).find('.change_status').val();
if (status == -1) return true;
if (goods_number == '' || goods_number == 0) { if (goods_number == '' || goods_number == 0) {
change_goods_number = true; change_goods_number = true;
...@@ -454,7 +457,7 @@ ...@@ -454,7 +457,7 @@
change_str += goods_name+'单价不能为0或空 '; change_str += goods_name+'单价不能为0或空 ';
} }
if (order_goods_type == 1 && buyer_id == null) { if (order_goods_type == 1 && (buyer_id == null || buyer_id == '')) {
change_buyer_id = true; change_buyer_id = true;
change_str += goods_name+'采购员不能为空 '; change_str += goods_name+'采购员不能为空 ';
} }
......
...@@ -94,6 +94,11 @@ ...@@ -94,6 +94,11 @@
var data = eval('('+resp.data+')'); var data = eval('('+resp.data+')');
var order_item = data.item; // 当前新增商品信息 var order_item = data.item; // 当前新增商品信息
var sup = order_item.canal ? order_item.supplier_id+'.'+order_item.canal : order_item.supplier_id; var sup = order_item.canal ? order_item.supplier_id+'.'+order_item.canal : order_item.supplier_id;
var buyers_option = '';
for (var i = 0; i < buyers.length; i++) {
buyers_option += '<option value="'+buyers[i].userId+'">'+buyers[i].name+'</option>';
}
html += '<tr data-sup="'+sup+'" data-brand_name="'+order_item.brand_name+'">\ html += '<tr data-sup="'+sup+'" data-brand_name="'+order_item.brand_name+'">\
<td>'+curr_no+'</td>\ <td>'+curr_no+'</td>\
...@@ -134,6 +139,14 @@ ...@@ -134,6 +139,14 @@
<input class="price only_number" name="change_info['+curr_no+'][goods_price]" data-price="'+order_item.goods_price+'" value="'+order_item.goods_price+'">\ <input class="price only_number" name="change_info['+curr_no+'][goods_price]" data-price="'+order_item.goods_price+'" value="'+order_item.goods_price+'">\
</td>\ </td>\
<td>\ <td>\
<select id="buyer_id_'+curr_no+'" class="form-control change_buyer_id selectpicker" name="change_info['+curr_no+'][buyer_id]" data-live-search="true" data-size="5" title="请选择采购员">\
<option value="">请选择采购员</option>'+buyers_option+'\
</select>\
</td>\
<td>\
<input type="text" class="form-control change_batch" name="change_info['+curr_no+'][batch]" value="">\
</td>\
<td>\
<input class="change_status" type="hidden" name="change_info['+curr_no+'][status]" value="1">\ <input class="change_status" type="hidden" name="change_info['+curr_no+'][status]" value="1">\
<span class="change_status_val">正常<i style="color:green;">(新增)</i></span>\ <span class="change_status_val">正常<i style="color:green;">(新增)</i></span>\
</td>\ </td>\
...@@ -147,6 +160,7 @@ ...@@ -147,6 +160,7 @@
$('.order-change-table').find('tbody').append(html); $('.order-change-table').find('tbody').append(html);
$('.order-change-table').find('tbody input').trigger('blur'); // 自动触发 $('.order-change-table').find('tbody input').trigger('blur'); // 自动触发
$('.change_buyer_id').selectpicker();
// 添加附加费 // 添加附加费
var extend_fee_items = data.extend_fee_items; var extend_fee_items = data.extend_fee_items;
...@@ -287,6 +301,15 @@ ...@@ -287,6 +301,15 @@
}) })
var curr_no = goods_len + 1; // 当前添加行序号 var curr_no = goods_len + 1; // 当前添加行序号
var buyers_option = '';
for (var i = 0; i < buyers.length; i++) {
if (add_buyer_id == buyers[i].userId) {
buyers_option += '<option value="'+buyers[i].userId+'" selected>'+buyers[i].name+'</option>';
} else {
buyers_option += '<option value="'+buyers[i].userId+'">'+buyers[i].name+'</option>';
}
}
html += '<tr data-brand_name="'+add_brand_name+'">\ html += '<tr data-brand_name="'+add_brand_name+'">\
<td>'+curr_no+'</td>\ <td>'+curr_no+'</td>\
...@@ -313,6 +336,14 @@ ...@@ -313,6 +336,14 @@
<input class="price only_number" name="change_info['+curr_no+'][goods_price]" data-price="'+add_goods_price+'" value="'+add_goods_price+'">\ <input class="price only_number" name="change_info['+curr_no+'][goods_price]" data-price="'+add_goods_price+'" value="'+add_goods_price+'">\
</td>\ </td>\
<td>\ <td>\
<select id="buyer_id_'+curr_no+'" class="form-control change_buyer_id selectpicker" name="change_info['+curr_no+'][buyer_id]" data-live-search="true" data-size="5" title="请选择采购员">\
<option value="">请选择采购员</option>'+buyers_option+'\
</select>\
</td>\
<td>\
<input type="text" class="form-control change_batch" name="change_info['+curr_no+'][batch]" value="'+add_batch+'">\
</td>\
<td>\
<input class="change_status" type="hidden" name="change_info['+curr_no+'][status]" value="1">\ <input class="change_status" type="hidden" name="change_info['+curr_no+'][status]" value="1">\
<span class="change_status_val">正常<i style="color:green;">(新增)</i></span>\ <span class="change_status_val">正常<i style="color:green;">(新增)</i></span>\
</td>\ </td>\
...@@ -324,14 +355,13 @@ ...@@ -324,14 +355,13 @@
<input type="hidden" name="change_info['+curr_no+'][goods_id]" value="'+add_goods_id+'" />\ <input type="hidden" name="change_info['+curr_no+'][goods_id]" value="'+add_goods_id+'" />\
<input type="hidden" name="change_info['+curr_no+'][brand_name]" value="'+add_brand_name+'" />\ <input type="hidden" name="change_info['+curr_no+'][brand_name]" value="'+add_brand_name+'" />\
<input type="hidden" name="change_info['+curr_no+'][delivery_time]" value="'+add_delivery_time+'" />\ <input type="hidden" name="change_info['+curr_no+'][delivery_time]" value="'+add_delivery_time+'" />\
<input type="hidden" name="change_info['+curr_no+'][buyer_id]" value="'+add_buyer_id+'" />\
<input type="hidden" name="change_info['+curr_no+'][batch]" value="'+add_batch+'" />\
<input type="hidden" name="change_info['+curr_no+'][remarks]" value="'+add_remarks+'" />\ <input type="hidden" name="change_info['+curr_no+'][remarks]" value="'+add_remarks+'" />\
</td>\ </td>\
</tr>'; </tr>';
$('.order-change-table').find('tbody').append(html); $('.order-change-table').find('tbody').append(html);
$('.order-change-table').find('tbody input').trigger('blur'); // 自动触发 $('.order-change-table').find('tbody input').trigger('blur'); // 自动触发
$('.change_buyer_id').selectpicker();
layer.close(index); layer.close(index);
} else { } else {
......
...@@ -556,6 +556,7 @@ ...@@ -556,6 +556,7 @@
// 填写订单取消原因 // 填写订单取消原因
$('.input-cancel-reason').click(function(){ $('.input-cancel-reason').click(function(){
var self = $(this); var self = $(this);
var user_id = self.data('uid');
var order_id = self.data('oid'); var order_id = self.data('oid');
var type = self.data('type'); var type = self.data('type');
var title = ''; var title = '';
...@@ -670,7 +671,7 @@ ...@@ -670,7 +671,7 @@
$.ajax({ $.ajax({
url:'/ajaxCancel', url:'/ajaxCancel',
data: {order_id: order_id, cancel_reason: cancel_reason, type: type}, data: {user_id: user_id, order_id: order_id, cancel_reason: cancel_reason, type: type},
type:'post', type:'post',
dataType: 'json', dataType: 'json',
success:function(resp){ success:function(resp){
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
// 填写订单取消原因 // 填写订单取消原因
$('.input-cancel-reason').click(function(){ $('.input-cancel-reason').click(function(){
var self = $(this); var self = $(this);
var user_id = self.data('uid');
var order_id = self.data('oid'); var order_id = self.data('oid');
var type = self.data('type'); var type = self.data('type');
var title = ''; var title = '';
...@@ -122,7 +123,7 @@ ...@@ -122,7 +123,7 @@
$.ajax({ $.ajax({
url:'/ajaxCancel', url:'/ajaxCancel',
data: {order_id: order_id, cancel_reason: cancel_reason, type: type}, data: {user_id: user_id, order_id: order_id, cancel_reason: cancel_reason, type: type},
type:'post', type:'post',
dataType: 'json', dataType: 'json',
success:function(resp){ success:function(resp){
......
...@@ -22,8 +22,10 @@ layui.use(['form', 'table', 'laydate'], function(){ ...@@ -22,8 +22,10 @@ layui.use(['form', 'table', 'laydate'], function(){
{title: '序号', type: 'numbers', fixed: 'left', width: 80} {title: '序号', type: 'numbers', fixed: 'left', width: 80}
,{field: 'user_id', title: '用户ID', width: 100} ,{field: 'user_id', title: '用户ID', width: 100}
,{field: 'account', title: '用户账户', width: 150} ,{field: 'account', title: '用户账户', width: 150}
,{field: 'work_function', title: '用户职务', width: 150} ,{field: 'type_val', title: '活动名称', width: 100}
,{field: 'invite_count', title: '邀请人数', width: 100} ,{field: 'work_function', title: '用户职务', width: 120}
,{field: 'sample_invite_count', title: '样片邀请人数', width: 130}
,{field: 'ruler_invite_count', title: '工具尺邀请人数', width: 130}
,{field: 'apply_num_total', title: '已申请样片数', width: 120} ,{field: 'apply_num_total', title: '已申请样片数', width: 120}
,{field: 'apply_count', title: '剩余有效人数', width: 120} ,{field: 'apply_count', title: '剩余有效人数', width: 120}
,{field: 'quota_total', title: '总消耗人数', width: 120} ,{field: 'quota_total', title: '总消耗人数', width: 120}
......
...@@ -16,13 +16,14 @@ layui.use(['table'], function(){ ...@@ -16,13 +16,14 @@ layui.use(['table'], function(){
{title: '序号', type: 'numbers', fixed: 'left', width: 80} {title: '序号', type: 'numbers', fixed: 'left', width: 80}
,{field: 'user_id', title: '用户ID', width: 120} ,{field: 'user_id', title: '用户ID', width: 120}
,{field: 'account', title: '用户账户', width: 200} ,{field: 'account', title: '用户账户', width: 200}
,{field: 'type_val', title: '活动名称', width: 100}
,{field: 'order_id', title: '订单ID', width: 120} ,{field: 'order_id', title: '订单ID', width: 120}
,{field: 'order_sn', title: '订单编号', width: 200} ,{field: 'order_sn', title: '订单编号', width: 200}
,{field: 'order_status', title: '订单状态', width: 100} ,{field: 'order_status', title: '订单状态', width: 100}
,{field: 'goods_id', title: '样片ID', width: 120} ,{field: 'goods_id', title: '商品ID', width: 120}
,{field: 'goods_name', title: '样片名称', width: 300} ,{field: 'goods_name', title: '商品名称', width: 300}
,{field: 'apply_num', title: '领取数量', width: 120} ,{field: 'apply_num', title: '领取数量', width: 120}
,{field: 'quota', title: '样片消耗人数', width: 120} ,{field: 'quota', title: '消耗人数', width: 120}
,{field: 'is_expire', title: '是否过期', templet: '#is_expire', width: 120} ,{field: 'is_expire', title: '是否过期', templet: '#is_expire', width: 120}
,{field: 'create_time', title: '领取时间', width: 215} ,{field: 'create_time', title: '领取时间', width: 215}
]] ]]
...@@ -45,6 +46,7 @@ layui.use(['table'], function(){ ...@@ -45,6 +46,7 @@ layui.use(['table'], function(){
{title: '序号', type: 'numbers', fixed: 'left', width: 80} {title: '序号', type: 'numbers', fixed: 'left', width: 80}
,{field: 'user_id', title: '用户ID'} ,{field: 'user_id', title: '用户ID'}
,{field: 'account', title: '用户账户'} ,{field: 'account', title: '用户账户'}
,{field: 'type_val', title: '活动名称', width: 100}
,{field: 'invitee_uid', title: '受邀人ID'} ,{field: 'invitee_uid', title: '受邀人ID'}
,{field: 'invitee_mobile', title: '受邀人手机号码'} ,{field: 'invitee_mobile', title: '受邀人手机号码'}
,{field: 'is_expire', title: '是否过期', templet: '#is_expire', width: 120} ,{field: 'is_expire', title: '是否过期', templet: '#is_expire', width: 120}
......
...@@ -258,7 +258,7 @@ ...@@ -258,7 +258,7 @@
<div class="form-group"> <div class="form-group">
<label class="col-sm-2 control-label"><i class="text-danger">*</i> 终端中文名称:</label> <label class="col-sm-2 control-label"><i class="text-danger">*</i> 终端中文名称:</label>
<div class="col-sm-10"> <div class="col-sm-10">
<input type="text" class="form-control customer_cn" name="customer_cn" value="" autocomplete="off" disabled="disabled"> <input type="text" class="form-control customer_cn" name="customer_cn" value="" autocomplete="off">
</div> </div>
</div> </div>
</div> </div>
......
...@@ -367,12 +367,12 @@ ...@@ -367,12 +367,12 @@
</tr> </tr>
@endif @endif
@if ($order_info['order_goods_type'] == 2) @if (($order_info['order_goods_type'] == 1 && $order_price_info['shipping_price']) || $order_info['order_goods_type'] == 2)
<tr> <tr>
<th>运费</th> <th>运费</th>
<td> <td>
<span>{{$currency}}</span> <span>{{$currency}}</span>
<input class="only_number freight_fee" type="text" name="freight_fee" value="{{ $order_price_info['shipping_price'] ? $order_price_info['shipping_price'] : 0 }}"> <input class="only_number freight_fee" type="text" name="freight_fee" value="{{ $order_price_info['shipping_price'] }}">
</td> </td>
</tr> </tr>
@endif @endif
...@@ -553,6 +553,7 @@ ...@@ -553,6 +553,7 @@
var discount_amount = "{{ $order_price_info['discount_amount'] ? $order_price_info['discount_amount'] : 0 }}"; // 优惠券金额 var discount_amount = "{{ $order_price_info['discount_amount'] ? $order_price_info['discount_amount'] : 0 }}"; // 优惠券金额
var pay_preferential = "{{ $order_price_info['pay_preferential'] ? $order_price_info['pay_preferential'] : 0 }}"; // 支付优惠(钱包) var pay_preferential = "{{ $order_price_info['pay_preferential'] ? $order_price_info['pay_preferential'] : 0 }}"; // 支付优惠(钱包)
var new_client_price = "{{ $order_price_info['new_client_price'] }}"; var new_client_price = "{{ $order_price_info['new_client_price'] }}";
var buyers = eval('{!! isset($buyers) ? json_encode($buyers) : '' !!}'); // 采购员集合
// 明细数目 // 明细数目
var item_count = "{{ count($order_items_info) }}"; var item_count = "{{ count($order_items_info) }}";
......
...@@ -153,7 +153,7 @@ ...@@ -153,7 +153,7 @@
<div class="tabs-box"> <div class="tabs-box">
@if (in_array($order_info['status'], [1, 2, 3, 4]) && in_array('cancel_order', $userPerms)) @if (in_array($order_info['status'], [1, 2, 3, 4]) && in_array('cancel_order', $userPerms))
<!-- <a href="{{URL('cancelPay', ['order_id'=>$order_info['order_id']])}}" class="btn btn-danger">取消订单</a> --> <!-- <a href="{{URL('cancelPay', ['order_id'=>$order_info['order_id']])}}" class="btn btn-danger">取消订单</a> -->
<a class="btn btn-danger input-cancel-reason" href="javascript:;" data-oid="{{$order_info['order_id']}}" data-type="2">取消订单</a> <a class="btn btn-danger input-cancel-reason" href="javascript:;" data-oid="{{$order_info['order_id']}}" data-uid="{{$order_info['user_id']}}" data-type="2">取消订单</a>
@endif @endif
@if (in_array('check_order', $userPerms) && $order_info['sale_id']) @if (in_array('check_order', $userPerms) && $order_info['sale_id'])
...@@ -221,7 +221,7 @@ ...@@ -221,7 +221,7 @@
<div class="tabs-box"> <div class="tabs-box">
@if (in_array($order_info['status'], [1, 2, 3, 4]) && in_array('self_order_cancel', $userPerms)) @if (in_array($order_info['status'], [1, 2, 3, 4]) && in_array('self_order_cancel', $userPerms))
<!-- <a class="btn btn-danger self_cancel" href="javascript:;" data-id="{{$order_info['order_id']}}">取消订单</a> --> <!-- <a class="btn btn-danger self_cancel" href="javascript:;" data-id="{{$order_info['order_id']}}">取消订单</a> -->
<a class="btn btn-danger input-cancel-reason" href="javascript:;" data-oid="{{$order_info['order_id']}}" data-type="2">取消订单</a> <a class="btn btn-danger input-cancel-reason" href="javascript:;" data-oid="{{$order_info['order_id']}}" data-uid="{{$order_info['user_id']}}" data-type="2">取消订单</a>
@endif @endif
<!-- 判断状态和权限 $extend-自营线下订单 --> <!-- 判断状态和权限 $extend-自营线下订单 -->
......
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
<table class="table table-bordered"> <table class="table table-bordered">
<tr class="caption"> <tr class="caption">
<th colspan="4" style="text-align: center; background: #f9f9f9;">合同乙方信息 <th colspan="4" style="text-align: center; background: #f9f9f9;">合同乙方信息
<?php if ($order_info['status'] == 1) { ?> <?php if (in_array($order_info['status'], [1, 2])) { ?>
<a href="javascript:;" class="btn btn-success btn-sm changeBtn contract_info_edit">编辑</a> <a href="javascript:;" class="btn btn-success btn-sm changeBtn contract_info_edit">编辑</a>
<?php } ?> <?php } ?>
</th> </th>
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
<script src="/js/details.js?v=<?= time() ?>"></script> <script src="/js/details.js?v=<?= time() ?>"></script>
<script src="/js/order_audit.js?v=<?= time() ?>"></script> <script src="/js/order_audit.js?v=<?= time() ?>"></script>
<script src="/js/order_track.js"></script> <script src="/js/order_track.js"></script>
<script src="/js/order_cancel.js"></script> <script src="/js/order_cancel.js?v=<?= time() ?>"></script>
<script src="/js/order_send_email.js"></script> <script src="/js/order_send_email.js"></script>
<script src="/js/refund.js?v=<?= time() ?>"></script> <script src="/js/refund.js?v=<?= time() ?>"></script>
......
...@@ -389,7 +389,7 @@ ...@@ -389,7 +389,7 @@
?> ?>
@if ($v['status'] == -1 && !$v['cancel_reason']) @if ($v['status'] == -1 && !$v['cancel_reason'])
<a class="btn btn-danger input-cancel-reason" href="javascript:;" data-oid="{{$v['order_id']}}" data-type="4">填写取消原因</a> <a class="btn btn-danger input-cancel-reason" href="javascript:;" data-oid="{{$v['order_id']}}" data-uid="{{$v['user_id']}}" data-type="4">填写取消原因</a>
@endif @endif
</div> </div>
</td> </td>
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
<script src="/js/list.js?v=<?= time() ?>"></script> <script src="/js/list.js?v=<?= time() ?>"></script>
<script src="/js/order_audit.js?v=<?= time() ?>"></script> <script src="/js/order_audit.js?v=<?= time() ?>"></script>
<script src="/js/order_track.js"></script> <script src="/js/order_track.js"></script>
<script src="/js/order_cancel.js"></script> <script src="/js/order_cancel.js?v=<?= time() ?>"></script>
<script src="/js/order_send_email.js"></script> <script src="/js/order_send_email.js"></script>
<script src="/js/refund.js?v=<?= time() ?>"></script> <script src="/js/refund.js?v=<?= time() ?>"></script>
...@@ -394,7 +394,7 @@ ...@@ -394,7 +394,7 @@
@endif @endif
@if ($v['status'] == -1 && !$v['cancel_reason']) @if ($v['status'] == -1 && !$v['cancel_reason'])
<a class="btn btn-danger input-cancel-reason" href="javascript:;" data-oid="{{$v['order_id']}}" data-type="4">填写取消原因</a> <a class="btn btn-danger input-cancel-reason" href="javascript:;" data-oid="{{$v['order_id']}}" data-uid="{{$v['user_id']}}" data-type="4">填写取消原因</a>
@endif @endif
</div> </div>
</td> </td>
......
...@@ -28,15 +28,18 @@ ...@@ -28,15 +28,18 @@
@include('layouts.navigation') @include('layouts.navigation')
<div id="page-wrapper" class="gray-bg"> <div id="page-wrapper" class="gray-bg">
@include('layouts.header') @include('layouts.header')
<div class="layui-col-md6 layui-col-space12" style="margin: 10px;width: 100%;height: 100%;padding-right: 20px">
<div class="layui-card"> <div class="row">
<div class="layui-card-body" style="padding-top: 20px; padding-bottom: 30px;"> <div class="col-lg-12">
<div class="ibox float-e-margins ibox-content" style="margin: 15px">
<div class="row mapping-rows" style="overflow:visible;margin: 10px">
@include("web.$id") @include("web.$id")
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div>
@include('table.js') @include('table.js')
<script src="/js/layui/layui.js"></script> <script src="/js/layui/layui.js"></script>
<script src="/js/web/common.js"></script> <script src="/js/web/common.js"></script>
......
...@@ -22,6 +22,17 @@ ...@@ -22,6 +22,17 @@
</div> </div>
<div class="layui-inline"> <div class="layui-inline">
<label class="layui-form-label">活动名称</label>
<div class="layui-input-inline">
<select name="type" lay-verify="" lay-search>
<option value=""></option>
<option value="1">样片</option>
<option value="2">工具尺</option>
</select>
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">领取时间</label> <label class="layui-form-label">领取时间</label>
<div class="layui-input-inline"> <div class="layui-input-inline">
<input type="text" name="begin_time" value="" autocomplete="off" placeholder="选择开始时间" class="layui-input" id="begin_time" readonly> <input type="text" name="begin_time" value="" autocomplete="off" placeholder="选择开始时间" class="layui-input" id="begin_time" readonly>
......
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