Commit 52338581 by 朱继来

外部引用订单详情页

parent e53021e8
......@@ -804,9 +804,15 @@ Class OrderController extends Controller
}
}
// 详情页
// 订单详情页面
public function details(Request $request, $id)
{
return $this->templateData($request, $id, 'detail');
}
// 详情页
public function templateData(Request $request, $id, $view_id)
{
$data = $this->orderDetail($request, $id);
if ($request->input('tags') == 'self') {
......@@ -821,7 +827,13 @@ Class OrderController extends Controller
}
}
return view('detail', $data);
return view($view_id, $data);
}
// 外部引用
public function detailsPage(Request $request, $id)
{
return $this->templateData($request, $id, 'page');
}
// 调价
......
......@@ -36,7 +36,8 @@ Route::group(['middleware' => 'web'], function () {
Route::get('/erp_order', 'OrderController@erpOrder');
Route::get('/export', 'OrderController@export');
Route::get('/details/{id}', 'OrderController@details');
Route::get('/details/{id}', 'OrderController@details');
Route::get('/page/details/{id}', 'OrderController@detailsPage');
Route::get('/change/{id}', 'OrderController@changeOrder');
Route::match(['get', 'post'], '/sendSales/{id?}', 'OrderController@sendSales');
Route::post('/ajaxdeletegoods', 'OrderController@ajaxdeletegoods');
......
......@@ -3,7 +3,6 @@
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>订单管理后台 | 订单详情</title>
<script>document.domain="{{ Config::get('website.domain') }}";</script>
......@@ -14,7 +13,7 @@
<body class="">
<div id="wrapper">
<!-- layouts.navigation -->
<?php $isPage = false; ?>
@include('layouts.navigation')
<div id="page-wrapper" class="gray-bg">
......
<div class="page-content order-details">
@if (!$isPage)
<ul class="nav nav-tabs">
@if (isset($_REQUEST['tags']) && $_REQUEST['tags'] == 'erp')
<li><a href="{{URL('erp_order')}}">ERP订单</a></li>
......@@ -9,6 +10,8 @@
@endif
<li class="active"><a href="javascript:;">订单详情</a></li>
</ul>
@endif
<?php
$route = \Route::current()->getActionName();
$action_name = explode('@', $route)[1];
......@@ -171,6 +174,7 @@
<tr class="caption">
<th colspan="7" style="text-align: center; background: #f9f9f9;">
收货信息
@if (!$isPage)
<!-- 订单状态小于5 且 更新地址权限存在 显示按钮 -->
@if (!isset($_REQUEST['tags']))
@if (in_array($order_info['status'], array(1, 2, 3, 4)) && in_array('update_address', $userPerms))
......@@ -183,6 +187,7 @@
@elseif (isset($_REQUEST['tags']) && $_REQUEST['tags'] == 'erp')
<a href="/changeShipping/{{$order_info['order_id']}}?tags={{$_REQUEST['tags']}}" class="btn btn-success btn-sm changeBtn">更改收货地址</a>
@endif
@endif
</th>
</tr>
<tr>
......@@ -234,6 +239,7 @@
<tr class="caption">
<th colspan="3" style="text-align: center; background: #f9f9f9;">
发票信息
@if (!$isPage)
<!-- 发票状态小于2(已发货)且更改权限存在 显示按钮 -->
@if (!isset($_REQUEST['tags']))
@if($order_info['status'] < 10 && $order_invoice_info['invoice_status'] < 2 && in_array('update_invoice', $userPerms))
......@@ -246,6 +252,7 @@
@elseif (isset($_REQUEST['tags']) && $_REQUEST['tags'] == 'erp')
<a href="/changeInvoice/{{$order_info['order_id']}}?tags={{$_REQUEST['tags']}}" class="btn btn-success btn-sm changeBtn">更改发票</a>
@endif
@endif
</th>
</tr>
......@@ -469,7 +476,8 @@
</div>
</div>
@if (!$isPage)
@if ($action_name == 'sendSales')
<!--推送业务员-->
@include('detail.sendSales')
......@@ -610,8 +618,11 @@
</table>
</div>
@endif
@endif
</div>
<script>
$.lie.order.details();
</script>
\ No newline at end of file
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>订单管理后台 | 订单详情</title>
<!-- <script>document.domain="{{ Config::get('website.domain') }}";</script> -->
<script>window.isPage = true; </script>
@include('orderlist.css')
@include('orderlist.js')
</head>
<body class="" style="background-color:#FFF;">
<?php $isPage = true; ?>
@include('detail.content')
</body>
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