Commit a3a57461 by 朱继来

调整自营推送

parent 1cbc5fef
......@@ -837,26 +837,30 @@ Class OrderController extends Controller
$tags = $request->input('tags', '');
// 联营
$joint_manager = $perm->getRoleUsers($request, '经理');
$joint_kefu = $perm->getRoleUsers($request, '客服');
$sale_list = $perm->getRoleUsers($request, '交易员');
$test = $perm->getRoleUsers($request, '测试');
$self_manager = $self_kefu = '';
if ($tags && $tags == 'self') {
$manager = $perm->getRoleUsers($request, '自营客服主管');
$test = $perm->getRoleUsers($request, '测试');
$sale_list = '';
$assistant = $perm->getRoleUsers($request, '自营客服主管助理');
$kefu = $perm->getRoleUsers($request, '自营客服');
$kefu = array_merge($assistant, $kefu);
} else {
$manager = $perm->getRoleUsers($request, '经理');
$test = $perm->getRoleUsers($request, '测试');
$sale_list = $perm->getRoleUsers($request, '交易员');
$kefu = $perm->getRoleUsers($request, '客服');
}
$self_manager = $perm->getRoleUsers($request, '自营客服主管');
$self_assistant = $perm->getRoleUsers($request, '自营客服主管助理');
$self_kefu = $perm->getRoleUsers($request, '自营客服');
$self_kefu = array_merge($self_assistant, $self_kefu);
}
$info['manager'] = $this->filterLeave($manager);
$info['test'] = $this->filterLeave($test);
$info['sale_list'] = $this->filterLeave($sale_list);
$info['kefu'] = $this->filterLeave($kefu);
$info['joint_manager'] = $this->filterLeave($joint_manager);
$info['joint_kefu'] = $this->filterLeave($joint_kefu);
$info['sale_list'] = $this->filterLeave($sale_list);
$info['test'] = $this->filterLeave($test);
$info['self_manager'] = $this->filterLeave($self_manager);
$info['self_kefu'] = $this->filterLeave($self_kefu);
$info['sale_id'] = $request->user->userId;
$info['role'] = $perm->getUserRole($request);
$info['role'] = $perm->getUserRole($request);
return view('detail', $info);
}
......
......@@ -9,16 +9,13 @@
<input type="hidden" name="order_id" value="{{$order_info['order_id']}}">
<table class="table table-bordered table-hover check-table" style="min-height:150px;">
@if (!empty($manager))
@if (!empty($joint_manager))
<tr>
@if ($order_info['order_goods_type'] == 1)
<td class="check-table-title" width="10%">经理:</td>
@else
<td class="check-table-title" width="10%">客服主管:</td>
@endif
<td class="check-table-title" width="10%">经理:</td>
<td>
<ul>
@foreach ($manager as $k => $v)
@foreach ($joint_manager as $k => $v)
@if ($v->userId == $order_info['sale_id'])
<li><label><input type="radio" name="sale_id" value="{{$v->userId}}" checked /><span>{{$v->name}}</span></label></li>
@else
......@@ -30,6 +27,23 @@
</tr>
@endif
@if (!empty($joint_kefu))
<tr>
<td class="check-table-title">联营客服:</td>
<td>
<ul>
@foreach ($joint_kefu as $key => $vo)
@if ($vo->userId == $order_info['sale_id'])
<li><label><input type="radio" name="sale_id" value="{{$vo->userId}}" checked /><span>{{$vo->name}}</span></label></li>
@else
<li><label><input type="radio" name="sale_id" value="{{$vo->userId}}"/><span>{{$vo->name}}</span></label></li>
@endif
@endforeach
</ul>
</td>
</tr>
@endif
@if (!empty($sale_list))
<tr>
<td class="check-table-title">交易员:</td>
......@@ -46,13 +60,31 @@
</td>
</tr>
@endif
@if (!empty($self_manager))
<tr>
<td class="check-table-title" width="10%">自营客服主管:</td>
<td>
<ul>
@foreach ($self_manager as $k => $v)
@if ($v->userId == $order_info['sale_id'])
<li><label><input type="radio" name="sale_id" value="{{$v->userId}}" checked /><span>{{$v->name}}</span></label></li>
@else
<li><label><input type="radio" name="sale_id" value="{{$v->userId}}"/><span>{{$v->name}}</span></label></li>
@endif
@endforeach
</ul>
</td>
</tr>
@endif
@if (!empty($kefu))
@if (!empty($self_kefu))
<tr>
<td class="check-table-title">客服:</td>
<td class="check-table-title">自营客服:</td>
<td>
<ul>
@foreach ($kefu as $key => $vo)
@foreach ($self_kefu as $key => $vo)
@if ($vo->userId == $order_info['sale_id'])
<li><label><input type="radio" name="sale_id" value="{{$vo->userId}}" checked /><span>{{$vo->name}}</span></label></li>
@else
......
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