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
82de3154
Commit
82de3154
authored
Jun 26, 2023
by
武广
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 修改review问题
parent
31d6d7b0
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
37 deletions
+25
-37
CustomerInfo.jsx
src/pages/businessCustomer/components/CustomerInfo.jsx
+8
-12
SelectGoodsModal.jsx
src/pages/businessGoods/components/SelectGoodsModal.jsx
+6
-7
takeawayGoods.jsx
src/pages/businessGoods/takeawayGoods.jsx
+11
-18
No files found.
src/pages/businessCustomer/components/CustomerInfo.jsx
View file @
82de3154
...
...
@@ -162,18 +162,14 @@ const CustomerInfo = props => {
if
(
props
.
id
&&
ms
.
length
<
mealTypes
.
length
)
{
await
checkConfirm
();
}
// 添加餐段
if
(
mealTypes
.
length
<
ms
.
length
)
{
if
(
!
ms
.
includes
(
'
1
'
)
&&
ms
.
includes
(
'
2
'
))
{
ms
.
push
(
'
1
'
);
}
}
else
if
(
!
ms
.
includes
(
'
1
'
)
&&
ms
.
includes
(
'
2
'
))
{
// 去除餐段
if
(
ms
.
includes
(
'
4
'
))
{
ms
=
[
'
4
'
];
}
else
{
ms
=
[];
}
// 取消外卖,必须取消自助餐
if
(
mealTypes
.
includes
(
'
1
'
)
&&
!
ms
.
includes
(
'
1
'
))
{
ms
=
ms
.
filter
(
item
=>
item
!==
'
2
'
);
}
// 选择自助餐,必须选择外卖
if
(
!
mealTypes
.
includes
(
'
1
'
)
&&
ms
.
includes
(
'
2
'
))
{
ms
.
push
(
'
1
'
);
}
form
.
setFieldsValue
({
mealType
:
ms
,
...
...
src/pages/businessGoods/components/SelectGoodsModal.jsx
View file @
82de3154
...
...
@@ -51,14 +51,13 @@ const SaleDateModal = props => {
api
=
apiSelVirtualGoodsList
;
}
const
res
=
await
api
(
data
);
console
.
log
(
'
res :>>
'
,
res
);
if
(
res
&&
res
.
data
&&
res
.
data
.
records
)
{
res
.
data
.
records
.
forEach
(
item
=>
{
const
arr
=
res
?.
data
?.
records
?.
map
(
item
=>
{
item
.
enterprisePrice
=
item
.
salePrice
;
})
;
setDataSource
(
res
.
data
.
records
)
;
setTotal
(
res
.
data
.
total
);
}
return
item
;
})
||
[]
;
setDataSource
(
arr
);
setTotal
(
res
?.
data
?.
total
||
0
);
setLoading
(
false
);
};
...
...
src/pages/businessGoods/takeawayGoods.jsx
View file @
82de3154
...
...
@@ -108,24 +108,17 @@ const TakeawayGoods = () => {
// 根据企业ID获取取餐点
const
getPickSelf
=
async
id
=>
{
const
res
=
await
apiSelPickSelfList
({
enterpriseId
:
id
});
if
(
res
&&
res
.
data
&&
res
.
data
.
length
)
{
setPickSelfList
(
res
.
data
.
map
(
item
=>
({
key
:
`
${
item
.
pickSelfId
}
`
,
label
:
<
span
>
{
item
.
pickSelfName
}
</
span
>,
})),
);
const
pid
=
res
.
data
[
0
].
pickSelfId
;
setActiveKey
(
`
${
pid
}
`
);
if
(
pageLoaded
)
{
onRefresh
();
}
}
else
{
setPickSelfList
([]);
setActiveKey
(
''
);
if
(
pageLoaded
)
{
onRefresh
();
}
const
arr
=
res
?.
data
?.
map
(
item
=>
({
key
:
`
${
item
.
pickSelfId
}
`
,
label
:
<
span
>
{
item
.
pickSelfName
}
</
span
>,
}))
||
[];
setPickSelfList
(
arr
);
const
[
obj
]
=
res
?.
data
||
[];
const
pid
=
`
${
obj
?.
pickSelfId
||
''
}
`;
setActiveKey(`
$
{
pid
}
`);
if (pageLoaded) {
onRefresh();
}
};
...
...
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