xx
This commit is contained in:
@@ -228,9 +228,9 @@ export default function DeviceAccessPage() {
|
||||
setPropertyList(targetModel?.supportProperties || []);
|
||||
form.setFieldsValue({
|
||||
...record,
|
||||
modelId,
|
||||
modelId: Number(modelId),
|
||||
limitConfig,
|
||||
actionConfig, // 👈 回显
|
||||
actionConfig,
|
||||
});
|
||||
} else {
|
||||
form.setFieldsValue(record);
|
||||
@@ -416,11 +416,11 @@ export default function DeviceAccessPage() {
|
||||
messageApi.success('删除成功');
|
||||
};
|
||||
|
||||
const getAlarmProps = () => modelDetail?.props?.filter(item => item.isAlarm) || [];
|
||||
const getAlarmProps = () => {
|
||||
|
||||
return modelDetail?.props?.filter(item => item.isAlarm) || [];
|
||||
};
|
||||
|
||||
// ======================
|
||||
// 【优化】切换 tab 才加载对应数据,不一次性请求所有
|
||||
// ======================
|
||||
useEffect(() => {
|
||||
if (activeTab === 'product') {
|
||||
fetchProtocolList();
|
||||
|
||||
@@ -112,7 +112,7 @@ export default function DeviceOverviewPage({ devices, planedevices, devicesAll,
|
||||
};
|
||||
|
||||
return (
|
||||
<Content style={{ maxWidth: 1800, margin: '0 8', }}>
|
||||
<Content style={{ margin: '0 8', }}>
|
||||
<Row gutter={[8, 8]} style={{ marginBottom: 12, flexWrap: 'wrap' }}>
|
||||
{dynamicTopCards.map((card, idx) => (
|
||||
<Col key={idx} style={{ minWidth: '160px', flex: '1 0 auto' }}>
|
||||
|
||||
Reference in New Issue
Block a user