Commit cf5cb9fd by zhaochengxiang

服务可见列设置增加提示

parent e9b10b73
...@@ -2,6 +2,7 @@ import { useState, useEffect } from 'react'; ...@@ -2,6 +2,7 @@ import { useState, useEffect } from 'react';
import { Modal, Button, Switch, Row, Col, Checkbox, Typography } from 'antd'; import { Modal, Button, Switch, Row, Col, Checkbox, Typography } from 'antd';
import { dispatch } from '../../../../model'; import { dispatch } from '../../../../model';
import { showMessage } from '../../../../util';
const ColSettingModal = (props) => { const ColSettingModal = (props) => {
const {visible, onCancel} = props; const {visible, onCancel} = props;
...@@ -77,6 +78,11 @@ const ColSettingModal = (props) => { ...@@ -77,6 +78,11 @@ const ColSettingModal = (props) => {
} }
const onModalOk = () => { const onModalOk = () => {
if ((checkedKeys||[]).length === 0) {
showMessage('warn', '不可进行全不选操作');
return;
}
setConfirmLoading(true); setConfirmLoading(true);
dispatch({ dispatch({
type: 'pds.saveCols', type: 'pds.saveCols',
...@@ -89,6 +95,7 @@ const ColSettingModal = (props) => { ...@@ -89,6 +95,7 @@ const ColSettingModal = (props) => {
callback: () => { callback: () => {
setConfirmLoading(false); setConfirmLoading(false);
onCancel && onCancel(true); onCancel && onCancel(true);
showMessage('success', '操作成功');
}, },
error: () => { error: () => {
setConfirmLoading(false); setConfirmLoading(false);
......
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