Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
merchant-manage-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ui
merchant-manage-ui
Commits
91599ce3
Commit
91599ce3
authored
Aug 24, 2022
by
李腾
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 修复订单查询售后字段展示&服务订单不展示物流信息
parent
b065c34d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
51 additions
and
19 deletions
+51
-19
index.jsx
...s/orderManage/queryOrder/components/DetailModal/index.jsx
+28
-16
const.js
src/pages/orderManage/queryOrder/const.js
+6
-0
index.jsx
src/pages/orderManage/queryOrder/index.jsx
+13
-3
index.less
src/pages/orderManage/queryOrder/index.less
+4
-0
No files found.
src/pages/orderManage/queryOrder/components/DetailModal/index.jsx
View file @
91599ce3
import
React
,
{
useState
,
useEffect
,
forwardRef
,
useImperativeHandle
}
from
'
react
'
;
import
{
Modal
,
Table
}
from
'
antd
'
;
import
{
queryOrderDetail
}
from
'
../../service
'
;
// import { queryOrderDetail } from '../../service';
import
{
COUPON_CODE_STATUS
}
from
'
../../const
'
;
import
style
from
'
./index.less
'
;
const
DetailModal
=
(
props
,
ref
)
=>
{
...
...
@@ -16,13 +17,13 @@ const DetailModal = (props, ref) => {
},
};
const
getDetail
=
async
orderNo
=>
{
const
params
=
{
orderNo
,
};
const
res
=
await
queryOrderDetail
(
params
);
console
.
log
(
res
);
};
//
const getDetail = async orderNo => {
//
const params = {
//
orderNo,
//
};
//
const res = await queryOrderDetail(params);
//
console.log(res);
//
};
/** @module 基本信息 */
const
[
baseInfo
,
setBaseInfo
]
=
useState
({});
...
...
@@ -44,11 +45,15 @@ const DetailModal = (props, ref) => {
},
{
title
:
'
小计
'
,
dataIndex
:
'
skuName
'
,
dataIndex
:
'
subTotal
'
,
render
:
(
value
,
record
)
=>
{
const
{
supplyPrice
,
count
}
=
record
;
return
(
supplyPrice
*
count
).
toFixed
(
2
);
},
},
{
title
:
'
售后状态
'
,
dataIndex
:
'
afterServiceStatus
'
,
dataIndex
:
'
afterServiceStatus
Desc
'
,
},
];
...
...
@@ -57,23 +62,30 @@ const DetailModal = (props, ref) => {
const
couponColumns
=
[
{
title
:
'
券码
'
,
render
:
(
_
,
record
,
index
)
=>
`券码
${
index
+
1
}
`
,
render
:
(
value
,
record
,
index
)
=>
`券码
${
index
+
1
}
`
,
},
{
title
:
'
有效期
'
,
dataIndex
:
'
price
'
,
dataIndex
:
'
useStartTime
'
,
render
:
(
value
,
record
)
=>
{
const
{
useEndTime
}
=
record
;
return
`
${
value
}
-
${
useEndTime
}
`
;
},
},
{
title
:
'
核销时间
'
,
dataIndex
:
'
count
'
,
dataIndex
:
'
useTime
'
,
render
:
value
=>
value
||
'
-
'
,
},
{
title
:
'
核销人
'
,
dataIndex
:
'
skuName
'
,
dataIndex
:
'
usedByShopName
'
,
render
:
value
=>
value
||
'
-
'
,
},
{
title
:
'
状态
'
,
dataIndex
:
'
afterStatus
'
,
dataIndex
:
'
codeStatus
'
,
render
:
value
=>
COUPON_CODE_STATUS
[
value
],
},
];
...
...
@@ -102,7 +114,7 @@ const DetailModal = (props, ref) => {
payTime
,
});
getDetail
(
orderNo
);
//
getDetail(orderNo);
};
useImperativeHandle
(
ref
,
()
=>
({
...
...
src/pages/orderManage/queryOrder/const.js
View file @
91599ce3
...
...
@@ -73,3 +73,9 @@ export const ORDER_STATUS = [
name
:
'
已关闭
'
,
},
];
export
const
COUPON_CODE_STATUS
=
{
1
:
'
待核销
'
,
2
:
'
已核销
'
,
3
:
'
已取消
'
,
};
src/pages/orderManage/queryOrder/index.jsx
View file @
91599ce3
...
...
@@ -268,9 +268,15 @@ const OrderList = ref => {
width
:
150
,
},
{
title
:
'
售后
状态
'
,
dataIndex
:
'
afterS
tatus
'
,
title
:
'
售后
'
,
dataIndex
:
'
afterS
erviceStatusDesc
'
,
width
:
200
,
render
:
({
value
,
subRecord
})
=>
(
<>
<
div
>
{
value
}
</
div
>
<
div
className=
{
style
.
blue
}
>
{
subRecord
.
afterServiceNo
}
</
div
>
</>
),
},
{
title
:
'
操作
'
,
...
...
@@ -279,13 +285,17 @@ const OrderList = ref => {
width
:
100
,
render
:
({
value
,
record
,
index
,
subRecord
,
subIndex
})
=>
{
let
text
=
''
;
if
([
12
,
14
].
includes
(
record
.
orderStatus
))
{
text
=
'
发货
'
;
}
if
([
13
].
includes
(
record
.
orderStatus
))
{
text
=
'
修改物流
'
;
}
console
.
log
(
text
);
// 服务订单不展示发货/修改物流
if
(
record
.
productType
===
4
)
{
return
<></>;
}
return
(
<>
{
text
?
(
...
...
src/pages/orderManage/queryOrder/index.less
View file @
91599ce3
...
...
@@ -37,3 +37,7 @@
margin-left: 10px;
}
}
.blue {
color: #61b0ff;
}
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