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
b065c34d
Commit
b065c34d
authored
Aug 23, 2022
by
李腾
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 修改商户后台查询订单发货按钮文案
parent
a2f9c83c
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
59 additions
and
27 deletions
+59
-27
index.jsx
...s/orderManage/queryOrder/components/DetailModal/index.jsx
+13
-1
index.jsx
src/pages/orderManage/queryOrder/index.jsx
+39
-25
service.js
src/pages/orderManage/queryOrder/service.js
+7
-1
No files found.
src/pages/orderManage/queryOrder/components/DetailModal/index.jsx
View file @
b065c34d
import
React
,
{
useState
,
forwardRef
,
useImperativeHandle
}
from
'
react
'
;
import
React
,
{
useState
,
useEffect
,
forwardRef
,
useImperativeHandle
}
from
'
react
'
;
import
{
Modal
,
Table
}
from
'
antd
'
;
import
{
queryOrderDetail
}
from
'
../../service
'
;
import
style
from
'
./index.less
'
;
const
DetailModal
=
(
props
,
ref
)
=>
{
...
...
@@ -14,6 +15,15 @@ const DetailModal = (props, ref) => {
setVisible
(
false
);
},
};
const
getDetail
=
async
orderNo
=>
{
const
params
=
{
orderNo
,
};
const
res
=
await
queryOrderDetail
(
params
);
console
.
log
(
res
);
};
/** @module 基本信息 */
const
[
baseInfo
,
setBaseInfo
]
=
useState
({});
...
...
@@ -91,6 +101,8 @@ const DetailModal = (props, ref) => {
orderTime
,
payTime
,
});
getDetail
(
orderNo
);
};
useImperativeHandle
(
ref
,
()
=>
({
...
...
src/pages/orderManage/queryOrder/index.jsx
View file @
b065c34d
...
...
@@ -69,7 +69,7 @@ const OrderList = ref => {
queryOrderList
(
searchParams
).
then
(
res
=>
{
setLoading
(
false
);
const
{
current
,
total
,
records
}
=
res
.
data
;
const
{
total
,
records
}
=
res
.
data
;
setDataTotal
(
total
);
setTableData
(
records
);
});
...
...
@@ -277,8 +277,18 @@ const OrderList = ref => {
rowSpanMode
:
'
auto
'
,
align
:
'
center
'
,
width
:
100
,
render
:
({
value
,
record
,
index
,
subRecord
,
subIndex
})
=>
(
render
:
({
value
,
record
,
index
,
subRecord
,
subIndex
})
=>
{
let
text
=
''
;
if
([
12
,
14
].
includes
(
record
.
orderStatus
))
{
text
=
'
发货
'
;
}
if
([
13
].
includes
(
record
.
orderStatus
))
{
text
=
'
修改物流
'
;
}
console
.
log
(
text
);
return
(
<>
{
text
?
(
<
Button
type=
"primary"
onClick=
{
async
()
=>
{
...
...
@@ -297,10 +307,14 @@ const OrderList = ref => {
handleModalVisible
(
true
);
}
}
>
发货
{
text
}
</
Button
>
)
:
(
''
)
}
</>
),
);
},
},
];
...
...
src/pages/orderManage/queryOrder/service.js
View file @
b065c34d
...
...
@@ -12,7 +12,13 @@ export async function queryOrderList(params) {
data
:
params
,
});
}
// 订单详情
export
async
function
queryOrderDetail
(
params
)
{
return
request
.
post
(
'
/api/kdsp/queryOrderDetail
'
,
{
prefix
:
config
.
kdspApi
,
data
:
params
,
});
}
// 待发货订单
export
async
function
queryToSend
(
params
)
{
try
{
...
...
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