Commit fbafe19e authored by 李纪文's avatar 李纪文

fix: 指标选择增加isCommonTag参数

parent 5c4f7901
......@@ -50,3 +50,4 @@ group:
| onModalClose | 模态框点击关闭回调 | function(value){ } | - |
| quotaListService`必需` | 获取指标列表的服务 | promise | - |
| updateDeviceConfService`user存在时必需` | 更新设备配置的服务 | promise | - |
| isCommonTag | 是否展示点表存在差异的指标 | boolean | false |
......@@ -12,6 +12,7 @@ import {
Tree,
ConfigProvider,
message,
Tooltip
} from 'antd';
import Empty from '@wisdom-components/empty';
import {
......@@ -19,6 +20,7 @@ import {
ExclamationCircleFilled,
SearchOutlined,
CloseOutlined,
InfoCircleOutlined
} from '@ant-design/icons';
import './index.less';
import { getQuataList, updateMonitorConf } from './apis';
......@@ -45,6 +47,7 @@ const QuotaSelect = ({
treeProps,
defaultSelect,
disabledList,
isCommonTag,
}) => {
const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
const prefixCls = getPrefixCls('ec-quota-select');
......@@ -62,7 +65,8 @@ const QuotaSelect = ({
// 请求指标列表
getQuataList({
accountName: item.deviceType,
addrSchemeID: item.pointAddressID,
// addrSchemeID: item.pointAddressID,
isCommonTag: isCommonTag,
}).then((res) => {
if (res.code === 0) {
const data =
......@@ -428,6 +432,7 @@ const QuotaSelect = ({
onChange={(e) => handleCheckboxChange(e, item)}
>
{item.title}
{item.notInFVersion && <Tooltip placement="bottom" title={`${item.notInFVersion} 版本不存在当前指标`}><InfoCircleOutlined className={classNames(`${prefixCls}-modal-class-mark`)}/></Tooltip>}
</Checkbox>
</Col>
))}
......@@ -483,6 +488,7 @@ QuotaSelect.defaultProps = {
onModalClose: () => {},
defaultSelect: 'emphasis',
disabledList: [],
isCommonTag: false,
};
QuotaSelect.propTypes = {
......@@ -505,6 +511,7 @@ QuotaSelect.propTypes = {
onModalClose: PropTypes.func,
defaultSelect: PropTypes.string,
disabledList: PropTypes.array,
isCommonTag: PropTypes.bool,
};
export default QuotaSelect;
......@@ -102,6 +102,16 @@
}
}
&-class-mark {
margin-left: 5px;
color: #aaaaaa;;
}
.@{ant-prefix}-checkbox + span {
display: flex;
align-items: center;
}
&-number {
margin-bottom: 10px;
padding: 4px 0 10px 20px;
......
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