Commit a30dedd7 authored by Maofei94's avatar Maofei94

fix: 删除503

parent 1dea9961
Pipeline #22697 passed with stages
in 17 minutes 13 seconds
......@@ -143,8 +143,12 @@ const MobileConfigPage = props => {
setLoading(false);
if (res.success) {
setMiniTitle('');
setFlag(flag + 1);
deleteMiniMenu({ visible: val });
setTimeout(() => {
setFlag(flag + 1);
}, 500);
setTimeout(() => {
deleteMiniMenu({ visible: val });
}, 1500);
notification.success({
message: '提示',
duration: 3,
......
......@@ -4,6 +4,7 @@ import {
getLoginPage,
getMapCofigs,
getWebThemes,
getProductList,
} from '@/services/webConfig/api';
import { Row, Col } from 'antd';
import { getDefaultGetWebconfig, singleStyleData, webMode } from '../utils';
......@@ -21,6 +22,7 @@ const WebConfigForm = props => {
const [webThemes, setWebThemes] = useState([]);
const [mapConfigs, setMapConfigs] = useState([]);
const [loginPages, setLoginPages] = useState([]);
const [products, setProducts] = useState([]);
const [form, setForm] = useState(null);
const getForm = f => {
......@@ -50,6 +52,15 @@ const WebConfigForm = props => {
getMapCofigs().then(res => setMapConfigs(res));
}
};
const onGetProduct = () => {
if (products.length === 0) {
getProductList().then(res => {
if (res.code === 0) {
setProducts(res.data);
}
});
}
};
const itemsMap = getDefaultGetWebconfig({
initialValues: config,
......@@ -61,6 +72,8 @@ const WebConfigForm = props => {
mapConfigs,
onGetLoginPages,
onGetMapConfig,
products,
onGetProduct,
isEdit,
});
......
......@@ -80,6 +80,8 @@ export const getDefaultGetWebconfig = ({
onGetLoginPages,
mapConfigs,
onGetMapConfig,
products,
onGetProduct,
isEdit,
}) => {
const config = {
......@@ -183,6 +185,26 @@ export const getDefaultGetWebconfig = ({
},
],
},
product: {
label: '产品类型',
formType: ITEM_TYPE.SELECT,
placeholder: '请选择产品类型',
options: products.map(t => ({
value: t.ProductName,
children: t.ProductName,
key: t.Id,
})),
onDropdownVisibleChange: onGetProduct,
showSearch: true,
filterOption: (input, option) =>
option.children.toLowerCase().indexOf(input.toLowerCase()) >= 0,
rules: [
{
required: false,
message: '产品类型必填',
},
],
},
theme: {
label: '系统皮肤',
formType: ITEM_TYPE.SELECT,
......
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