Commit f2b50150 authored by 张子雨's avatar 张子雨

Merge branch 'feat/storeManagement' into feature/meal-3.0

* feat/storeManagement:
  feat: 删除多余接口
parents fdd8d796 bd575acf
import React, { useState, useEffect, forwardRef, useRef, useImperativeHandle } from 'react'; import React, { useState, useEffect, forwardRef, useRef, useImperativeHandle } from 'react';
import { Button, Modal, Select, Form, notification } from 'antd'; import { Button, Modal, Select, Form, notification } from 'antd';
import styles from '../index.less'; import styles from '../index.less';
import { apiSelectedList, apiSelectList, apiShopAdd } from '../service.js'; import { apiSelectList, apiShopAdd } from '../service.js';
const AddModal = props => { const AddModal = props => {
const [form] = Form.useForm(); const [form] = Form.useForm();
...@@ -30,18 +30,6 @@ const AddModal = props => { ...@@ -30,18 +30,6 @@ const AddModal = props => {
handleCancel(true); handleCancel(true);
} }
}; };
const getSelectedList = async () => {
const res = await apiSelectedList({ enterpriseId });
if (res.businessCode === '0000') {
const { data } = res;
const list = [];
data.forEach(item => {
list.push(item.shopId);
});
form.setFieldsValue({ shopIds: list });
setSelectList(list);
}
};
const getSelectList = async () => { const getSelectList = async () => {
const res = await apiSelectList({ enterpriseId }); const res = await apiSelectList({ enterpriseId });
if (res.businessCode === '0000') { if (res.businessCode === '0000') {
...@@ -50,7 +38,6 @@ const AddModal = props => { ...@@ -50,7 +38,6 @@ const AddModal = props => {
label: item.shopName, label: item.shopName,
})); }));
setOptions(optionData); setOptions(optionData);
// getSelectedList();
} }
}; };
......
...@@ -101,13 +101,3 @@ export const apiShopAdd = async params => { ...@@ -101,13 +101,3 @@ export const apiShopAdd = async params => {
}); });
return data; return data;
}; };
// [企业店铺]-企业已选的店铺
// http://yapi.quantgroups.com/project/389/interface/api/65534
export const apiSelectedList = async params => {
const data = await request.post(`${apiPrefix}/enterprise/shop/selected/list`, {
prefix: roleApi,
data: params,
});
return data;
};
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