Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
semour
/
semour_admin
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
132bbc35
authored
Dec 05, 2022
by
宁成龙
Browse files
Options
_('Browse Files')
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
6cc891c6
7ed37a19
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
20 additions
and
12 deletions
app/Admin/Controllers/Api/OrderApiController.php
app/Admin/Controllers/OrderController.php
app/Admin/Service/OrderService.php
public/assets/images/excel-logo.png
resources/lang/en/inquiry.php
resources/lang/en/order.php
resources/lang/en/scm-user.php
resources/lang/zh_CN/menu.php
resources/lang/zh_CN/order.php
app/Admin/Controllers/Api/OrderApiController.php
View file @
132bbc35
...
@@ -27,7 +27,7 @@ class OrderApiController extends BaseController
...
@@ -27,7 +27,7 @@ class OrderApiController extends BaseController
$params
=
$request
->
all
();
$params
=
$request
->
all
();
$type
=
arrayGet
(
$params
,
"type"
);
$type
=
arrayGet
(
$params
,
"type"
);
$order_id
=
69
;
$order_id
=
203
;
$orderAddressList
=
OrderService
::
getOrderAddress
(
$order_id
);
$orderAddressList
=
OrderService
::
getOrderAddress
(
$order_id
);
$orderAddressList
=
arrayChangeKeyByField
(
$orderAddressList
,
"order_address_type"
);
$orderAddressList
=
arrayChangeKeyByField
(
$orderAddressList
,
"order_address_type"
);
// dump($orderAddressList);
// dump($orderAddressList);
...
...
app/Admin/Controllers/OrderController.php
View file @
132bbc35
...
@@ -57,7 +57,7 @@ class OrderController extends AdminController
...
@@ -57,7 +57,7 @@ class OrderController extends AdminController
$grid
->
fixColumns
(
1
,
2
);
//固定列
$grid
->
fixColumns
(
1
,
2
);
//固定列
// $grid->showColumnSelector();//开启字段选择器功能
// $grid->showColumnSelector();//开启字段选择器功能
// 在 display 回调中使用
// 在 display 回调中使用
$grid
->
column
(
'序号'
)
->
display
(
function
()
{
$grid
->
column
(
'序号'
,
admin_trans
(
'order.labels.序号'
)
)
->
display
(
function
()
{
return
$this
->
_index
+
1
;
return
$this
->
_index
+
1
;
});
});
$grid
->
column
(
'order_id'
,
"ID"
);
$grid
->
column
(
'order_id'
,
"ID"
);
...
@@ -74,7 +74,7 @@ class OrderController extends AdminController
...
@@ -74,7 +74,7 @@ class OrderController extends AdminController
});
});
$grid
->
column
(
'scmUser.name'
,
admin_trans
(
'scm-user.fields.name'
));
$grid
->
column
(
'scmUser.name'
,
admin_trans
(
'scm-user.fields.name'
));
$grid
->
column
(
'order_price'
,
"应付金额"
)
->
display
(
function
(
$order_price
)
{
$grid
->
column
(
'order_price'
,
admin_trans
(
'order.labels.应付金额'
)
)
->
display
(
function
(
$order_price
)
{
$otherAmount
=
0
;
$otherAmount
=
0
;
foreach
(
$order_price
->
toArray
()
as
$key
=>
$val
){
foreach
(
$order_price
->
toArray
()
as
$key
=>
$val
){
if
(
in_array
(
$val
[
"price_type"
],[
3
,
5
])){
if
(
in_array
(
$val
[
"price_type"
],[
3
,
5
])){
...
@@ -103,7 +103,7 @@ class OrderController extends AdminController
...
@@ -103,7 +103,7 @@ class OrderController extends AdminController
});
});
$grid
->
fixColumns
(
1
,
-
1
);
$grid
->
showFilter
();
$grid
->
showFilter
();
...
@@ -133,10 +133,12 @@ class OrderController extends AdminController
...
@@ -133,10 +133,12 @@ class OrderController extends AdminController
new
OrderReverseAuditAction
(),
new
OrderReverseAuditAction
(),
new
OrderEditSatusAction
(),
new
OrderEditSatusAction
(),
]);
]);
$grid
->
disableCreateButton
();
$grid
->
setActionClass
(
Grid\Displayers\Actions
::
class
);
$grid
->
setActionClass
(
Grid\Displayers\Actions
::
class
);
$grid
->
actions
(
function
(
Grid\Displayers\Actions
$actions
)
{
$grid
->
actions
(
function
(
Grid\Displayers\Actions
$actions
)
{
$actions
->
disableDelete
();
$actions
->
disableDelete
();
$actions
->
disableEdit
();
$actions
->
disableEdit
();
$actions
->
disableQuickEdit
();
$actions
->
disableQuickEdit
();
...
...
app/Admin/Service/OrderService.php
View file @
132bbc35
...
@@ -47,7 +47,7 @@ class OrderService extends BaseService
...
@@ -47,7 +47,7 @@ class OrderService extends BaseService
}
}
}
}
$orderList
[
"order_items"
]
=
$orderItems
;
$orderList
[
"order_items"
]
=
$orderItems
;
$orderList
[
"total_amount"
]
=
$orderList
[
"order_amount"
]
+
$orderList
[
"payServiceFee"
]
+
$orderList
[
"carriage"
]
+
$orderList
[
"carriage"
]
;
$orderList
[
"total_amount"
]
=
$orderList
[
"order_amount"
]
+
$orderList
[
"payServiceFee"
]
+
$orderList
[
"carriage"
];
//支付手续费
//支付手续费
$orderList
[
"payServiceFee_format"
]
=
decimal_number_format
(
$orderList
[
"payServiceFee"
],
DIGITS_TWO
,
2
);
$orderList
[
"payServiceFee_format"
]
=
decimal_number_format
(
$orderList
[
"payServiceFee"
],
DIGITS_TWO
,
2
);
//运费
//运费
...
...
public/assets/images/excel-logo.png
0 → 100644
View file @
132bbc35
16.4 KB
resources/lang/en/inquiry.php
View file @
132bbc35
...
@@ -7,6 +7,7 @@ return [
...
@@ -7,6 +7,7 @@ return [
'handle'
=>
'Handle'
,
'handle'
=>
'Handle'
,
'inquiry_handle_status_wrong'
=>
'Only pending inquiry can be handle'
,
'inquiry_handle_status_wrong'
=>
'Only pending inquiry can be handle'
,
],
],
'fields'
=>
[
'fields'
=>
[
'inquiry_id'
=>
'Id'
,
'inquiry_id'
=>
'Id'
,
'sales_name'
=>
'Sales Name'
,
'sales_name'
=>
'Sales Name'
,
...
...
resources/lang/en/order.php
View file @
132bbc35
...
@@ -11,6 +11,8 @@ return [
...
@@ -11,6 +11,8 @@ return [
'审核成功'
=>
'Successful audit'
,
'审核成功'
=>
'Successful audit'
,
'是否确认反审核'
=>
'Whether to confirm counteraudit'
,
'是否确认反审核'
=>
'Whether to confirm counteraudit'
,
'待确认'
=>
'To be confirmed'
,
'待确认'
=>
'To be confirmed'
,
'序号'
=>
'number'
,
'应付金额'
=>
'Amount payable'
,
],
],
'fields'
=>
[
'fields'
=>
[
...
...
resources/lang/en/scm-user.php
View file @
132bbc35
...
@@ -5,13 +5,13 @@ return [
...
@@ -5,13 +5,13 @@ return [
'scm-user'
=>
'ScmUser'
,
'scm-user'
=>
'ScmUser'
,
],
],
'fields'
=>
[
'fields'
=>
[
'name'
=>
'
用户名
'
,
'name'
=>
'
User name
'
,
'user_sn'
=>
'
客户编码
'
,
'user_sn'
=>
'
Customer code
'
,
'email'
=>
'
邮箱
'
,
'email'
=>
'
email
'
,
'email_verified_at'
=>
'
邮箱校验时间
'
,
'email_verified_at'
=>
'
Email verification time
'
,
'password'
=>
'
密码
'
,
'password'
=>
'
password
'
,
'phone'
=>
'
手机号码
'
,
'phone'
=>
'
Mobile phone Number
'
,
'remember_token'
=>
'
记住登陆
token'
,
'remember_token'
=>
'
Remember to log in the
token'
,
'account_properties'
=>
'账号属性,1是个人,2是企业'
,
'account_properties'
=>
'账号属性,1是个人,2是企业'
,
'status'
=>
'状态,1是正常,-1是禁用'
,
'status'
=>
'状态,1是正常,-1是禁用'
,
'company_name'
=>
'公司名称'
,
'company_name'
=>
'公司名称'
,
...
...
resources/lang/zh_CN/menu.php
View file @
132bbc35
...
@@ -15,6 +15,7 @@ return [
...
@@ -15,6 +15,7 @@ return [
'icons'
=>
'图标'
,
'icons'
=>
'图标'
,
'userAddress'
=>
'用户地址'
,
'userAddress'
=>
'用户地址'
,
'inquiry'
=>
'询价管理'
,
'inquiry'
=>
'询价管理'
,
'order'
=>
'订单管理'
,
'task'
=>
'任务管理'
,
'task'
=>
'任务管理'
,
'country'
=>
'地区管理'
,
'country'
=>
'地区管理'
,
],
],
...
...
resources/lang/zh_CN/order.php
View file @
132bbc35
...
@@ -11,6 +11,8 @@ return [
...
@@ -11,6 +11,8 @@ return [
'审核成功'
=>
'是否确认审核'
,
'审核成功'
=>
'是否确认审核'
,
'是否确认反审核'
=>
'是否确认审核'
,
'是否确认反审核'
=>
'是否确认审核'
,
'待确认'
=>
'待确认'
,
'待确认'
=>
'待确认'
,
'序号'
=>
'序号'
,
'应付金额'
=>
'应付金额'
,
],
],
'fields'
=>
[
'fields'
=>
[
...
...
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