Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
朱继来
/
后台订单管理
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
a4d2db41
authored
Dec 10, 2018
by
朱继来
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
temp
parent
1d16214e
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
37 additions
and
19 deletions
app/Http/Controllers/OrderController.php
public/js/order.js
resources/views/detail/changeOrder.blade.php
resources/views/detail/content.blade.php
resources/views/orderlist/content.blade.php
resources/views/selfOrder/content.blade.php
app/Http/Controllers/OrderController.php
View file @
a4d2db41
...
...
@@ -260,12 +260,18 @@ function isChangeInvoice($order_sn)
}
}
//
自营线下订单
function
getOrderExtend
(
$order_id
)
//
订单扩展表
function
getOrderExtend
(
$order_id
,
$field
=
"*"
,
$where
=
array
()
)
{
$
extend
=
DB
::
connection
(
'order'
)
->
table
(
'lie_order_extend'
)
->
where
([
'order_id'
=>
$order_id
,
'order_type'
=>
3
])
->
select
(
'temp_id'
)
->
first
()
;
$
map
[
'order_id'
]
=
$order_id
;
return
$extend
?
true
:
false
;
if
(
!
empty
(
$where
))
{
$map
=
array_merge
(
$map
,
$where
);
}
$extend
=
DB
::
connection
(
'order'
)
->
table
(
'lie_order_extend'
)
->
where
(
$map
)
->
select
(
$field
)
->
first
();
return
$extend
;
}
Class
OrderController
extends
Controller
...
...
public/js/order.js
View file @
a4d2db41
...
...
@@ -1265,8 +1265,8 @@
$
(
'.checkOrder'
).
click
(
function
(){
var
is_newClient
=
$
(
'input[name=is_newClient]:checked'
).
val
();
var
client_source
=
$
(
'input[name=client_source]:checked'
).
val
();
var
order_status
=
$
(
'input[name=order_status]:checked'
).
val
();
var
pay_type
=
$
(
'input[name=order_pay_type]:checked'
).
val
();
// 订单付款类型
var
order_status
=
$
(
'input[name=order_status]:checked'
).
val
()
?
$
(
'input[name=order_status]:checked'
).
val
()
:
2
;
var
pay_type
=
$
(
'input[name=order_pay_type]:checked'
).
val
()
?
$
(
'input[name=order_pay_type]:checked'
).
val
()
:
1
;
// 订单付款类型
var
reason
=
$
(
'input[name=reason]:checked'
).
val
();
var
payTime
=
$
(
'.payTime'
).
val
();
var
payTimeOther
=
$
(
'.payTimeOther'
).
val
();
...
...
resources/views/detail/changeOrder.blade.php
View file @
a4d2db41
...
...
@@ -43,6 +43,7 @@
@endif
<!-- 审核 -->
@if ($order_info['order_goods_type'] == 1)
<p>
审核
</p>
<table
class=
"table table-bordered table-hover check-table"
>
<tr>
...
...
@@ -82,6 +83,8 @@
</table>
<hr/>
@endif
<!-- 调价 -->
<p>
调价
</p>
<table
class=
"table table-bordered table-hover order-change-table"
>
...
...
resources/views/detail/content.blade.php
View file @
a4d2db41
...
...
@@ -410,7 +410,7 @@
<th>
供应商
</th>
<?php
if
(
$action_name
==
'changeOrder'
&&
count
(
$order_items_info
)
>
1
&&
$order_info
[
'status'
]
==
1
)
{
if
(
$action_name
==
'changeOrder'
&&
count
(
$order_items_info
)
>
1
&&
in_array
(
$order_info
[
'status'
],
[
1
,
2
])
)
{
echo
'<th>操作</th>'
;
}
?>
...
...
@@ -443,7 +443,7 @@
<td>
{{$v['delivery_time']}}
</td>
<td>
{{$v['supplier_name']}}
</td>
@if ($action_name == 'changeOrder'
&&
count($order_items_info) > 1
&&
$order_info['status'] == 1
)
@if ($action_name == 'changeOrder'
&&
count($order_items_info) > 1
&&
in_array($order_info['status'], [1, 2])
)
<td><a
class=
"btn btn-danger deletegoods"
href=
"javascript:;"
data-id=
"{{$v['rec_id']}}"
>
删除
</a></td>
@endif
</tr>
...
...
@@ -606,20 +606,20 @@
@elseif (isset($_REQUEST['tags'])
&&
$_REQUEST['tags'] == 'self'
&&
$action_name != 'changeOrder')
<p
style=
"padding-left: 5px;"
>
操作
</p>
<div
class=
"tabs-box"
>
@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>
@endif
<!-- 判断状态和权限 $extend-自营线下订单 -->
@if ($order_info['status'] == 1
&&
in_array('add_offline_audit', $userPerms)
&&
$extend)
<
a
class=
"btn btn-success self-check"
data-id=
"{{$order_info['order_id']}}"
>
内部订单审核
</a
>
<
!-- <a class="btn btn-success self-check" data-id="{{$order_info['order_id']}}">内部订单审核</a> --
>
@endif
<!-- 订单审单 -->
@if (in_array($order_info['status'], [1, 2])
&&
in_array('self_check_order', $userPerms)
&&
!$extend
)
@if (in_array($order_info['status'], [1, 2])
&&
in_array('self_check_order', $userPerms))
<a
class=
"btn btn-info"
href=
"/change/{{$order_info['order_id']}}?tags=self"
>
人工审单
</a>
@endif
@if (in_array($order_info['status'], [1, 2, 3, 4])
&&
!$extend
&&
in_array('self_order_cancel', $userPerms))
<a
class=
"btn btn-danger self_cancel"
href=
"javascript:;"
data-id=
"{{$order_info['order_id']}}"
>
取消订单
</a>
@endif
@if ($order_info['status'] == 2
&&
in_array('self_check_pay', $userPerms))
<a
href=
"/self_check_pay/{{$order_info['order_id']}}?tags=self"
class=
"btn btn-success"
>
对账
</a>
@endif
...
...
resources/views/orderlist/content.blade.php
View file @
a4d2db41
...
...
@@ -340,9 +340,13 @@
<td
class=
"table-list-content"
>
<p
class=
"show-title"
title=
"{{App\Http\Controllers\getCompanyName($v['user_id'])}}"
>
{{App\Http\Controllers\getCompanyName($v['user_id'])}}
</p>
</td>
<td
class=
"table-list-title"
>
Adtag或其它
</td>
<td
class=
"table-list-content"
colspan=
"3"
>
<p
class=
"show-title"
title=
"
<?php
echo
App\Http\Controllers\handleOrderSource
(
$v
[
'order_source'
]);
?>
"
>
<?php
echo
App\Http\Controllers\handleOrderSource
(
$v
[
'order_source'
]);
?>
</p>
<td
class=
"table-list-title"
>
是否新订单
</td>
<td
class=
"table-list-content"
>
<?php
$is_new_order
=
App\Http\Controllers\getOrderExtend
(
$v
[
'order_id'
],
'is_new'
);
echo
$is_new_order
->
is_new
?
'是'
:
'否'
;
?>
</td>
</tr>
@if ($v['order_pay_type'] == 2)
...
...
@@ -433,6 +437,12 @@
<td
class=
"table-list-title"
>
发货状态
</td>
<td
class=
"table-list-content"
>
{{$shippingStatus}}
</td>
</tr>
<tr>
<td
class=
"table-list-title"
>
Adtag或其它
</td>
<td
class=
"table-list-content"
colspan=
"3"
>
<p
class=
"show-title"
title=
"
<?php
echo
App\Http\Controllers\handleOrderSource
(
$v
[
'order_source'
]);
?>
"
>
<?php
echo
App\Http\Controllers\handleOrderSource
(
$v
[
'order_source'
]);
?>
</p>
</td>
</tr>
</table>
</td>
</tr>
...
...
resources/views/selfOrder/content.blade.php
View file @
a4d2db41
...
...
@@ -276,8 +276,7 @@
<div
class=
"btn-group btn-group-xs"
>
<a
class=
"btn btn-primary"
href=
"/details/{{$v['order_id']}}?tags=self"
target=
"_blank"
>
详情
</a>
<?php
$extend
=
App\Http\Controllers\getOrderExtend
(
$v
[
'order_id'
]);
?>
@if (in_array('self_check_order', $userPerms)
&&
in_array($v['status'], [1, 2])
&&
!$extend)
@if (in_array('self_check_order', $userPerms)
&&
in_array($v['status'], [1, 2]))
<a
class=
"btn btn-success"
href=
"/change/{{$v['order_id']}}?tags=self"
target=
"_blank"
>
人工审单
</a>
@endif
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment