Commit 77526c73 authored by 武广's avatar 武广

fix: 修改弹窗不显示问题

parent a68f202a
...@@ -329,9 +329,10 @@ const ServiceGoods = options => { ...@@ -329,9 +329,10 @@ const ServiceGoods = options => {
// 保存草稿 // 保存草稿
const onSaveDraft = async () => { const onSaveDraft = async () => {
console.log('newCategoryList :>> ', newCategoryList); console.log('newCategoryList :>> ', newCategoryList);
const info = localStorage.get(localAutoSaveKey); const info = localStorage.get(localAutoSaveKey);
if (info) {
if ( if (
!info ||
!info.infoMation || !info.infoMation ||
!info.infoMation.name || !info.infoMation.name ||
!info.infoMation.categoryId || !info.infoMation.categoryId ||
...@@ -340,6 +341,10 @@ const ServiceGoods = options => { ...@@ -340,6 +341,10 @@ const ServiceGoods = options => {
message.warning('请添加商品类目和名称'); message.warning('请添加商品类目和名称');
return; return;
} }
Modal.confirm({
title: '确认提示',
content: '确定将商品信息保存至草稿箱?',
onOk: async () => {
info.type = productType; info.type = productType;
let arr = newCategoryList[info.type]; let arr = newCategoryList[info.type];
const first = arr.find(item => item.id === info.infoMation.categoryId[0]); const first = arr.find(item => item.id === info.infoMation.categoryId[0]);
...@@ -371,7 +376,8 @@ const ServiceGoods = options => { ...@@ -371,7 +376,8 @@ const ServiceGoods = options => {
setPageLoading(false); setPageLoading(false);
message.success('草稿保存成功!'); message.success('草稿保存成功!');
handleCancel(true); handleCancel(true);
} },
});
}; };
const providerValue = { const providerValue = {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment