|
@@ -75,7 +75,6 @@
|
|
|
valueField: 'cameraType',
|
|
valueField: 'cameraType',
|
|
|
immediate: true,
|
|
immediate: true,
|
|
|
onChange: (val) => {
|
|
onChange: (val) => {
|
|
|
- setFieldsValue({ color: '', wifiNamePrefix: '', version: '标准版' });
|
|
|
|
|
let option = [
|
|
let option = [
|
|
|
{
|
|
{
|
|
|
label: '标准版',
|
|
label: '标准版',
|
|
@@ -91,11 +90,13 @@
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
// ifShow: val == 9 || val == 10
|
|
// ifShow: val == 9 || val == 10
|
|
|
|
|
+ let wifiNamePrefixlist = getWifilist(val);
|
|
|
updateSchema([
|
|
updateSchema([
|
|
|
{ field: 'colour', componentProps: { options: getColor(val) } },
|
|
{ field: 'colour', componentProps: { options: getColor(val) } },
|
|
|
{ field: 'version', componentProps: { options: option } },
|
|
{ field: 'version', componentProps: { options: option } },
|
|
|
- { field: 'wifiNamePrefix', componentProps: { options: getWifilist(val) } },
|
|
|
|
|
|
|
+ { field: 'wifiNamePrefix', componentProps: { options: wifiNamePrefixlist } },
|
|
|
]);
|
|
]);
|
|
|
|
|
+ setFieldsValue({ color: '', wifiNamePrefix: wifiNamePrefixlist[0].value, version: '标准版' });
|
|
|
},
|
|
},
|
|
|
},
|
|
},
|
|
|
},
|
|
},
|
|
@@ -104,7 +105,6 @@
|
|
|
component: 'Select',
|
|
component: 'Select',
|
|
|
label: 'wifi前缀',
|
|
label: 'wifi前缀',
|
|
|
required: true,
|
|
required: true,
|
|
|
- defaultValue: '4DKKPRO_',
|
|
|
|
|
colProps: {
|
|
colProps: {
|
|
|
span: 18,
|
|
span: 18,
|
|
|
},
|
|
},
|
|
@@ -164,13 +164,12 @@
|
|
|
onMounted(() => {});
|
|
onMounted(() => {});
|
|
|
let addListFunc = () => {};
|
|
let addListFunc = () => {};
|
|
|
const [register, { closeModal }] = useModalInner((data) => {
|
|
const [register, { closeModal }] = useModalInner((data) => {
|
|
|
- // console.log(data);
|
|
|
|
|
|
|
+ fileFlow.title = data.id ? '编辑' : '设备入库';
|
|
|
data && onDataReceive(data);
|
|
data && onDataReceive(data);
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
function onDataReceive(data) {
|
|
function onDataReceive(data) {
|
|
|
modelRef.value = data;
|
|
modelRef.value = data;
|
|
|
- fileFlow.title = data.id ? '编辑' : '设备入库';
|
|
|
|
|
resetFields();
|
|
resetFields();
|
|
|
let wifiNamePrefix = data.wifiName && data.wifiName.split('_')[0];
|
|
let wifiNamePrefix = data.wifiName && data.wifiName.split('_')[0];
|
|
|
updateSchema([
|
|
updateSchema([
|
|
@@ -201,12 +200,13 @@
|
|
|
],
|
|
],
|
|
|
},
|
|
},
|
|
|
},
|
|
},
|
|
|
- { field: 'wifiNamePrefix', componentProps: { options: getWifilist(data.type || 1) } },
|
|
|
|
|
|
|
+ { field: 'wifiNamePrefix', show: !data.id, componentProps: { options: getWifilist(data.type || 1) } },
|
|
|
|
|
+ { field: 'snCode', show: !data.id, },
|
|
|
]);
|
|
]);
|
|
|
setFieldsValue({
|
|
setFieldsValue({
|
|
|
...data,
|
|
...data,
|
|
|
cameraType: data.type,
|
|
cameraType: data.type,
|
|
|
- wifiNamePrefix: wifiNamePrefix + '_',
|
|
|
|
|
|
|
+ wifiNamePrefix: wifiNamePrefix && (wifiNamePrefix + '_') || '',
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
function handleVisibleChange() {}
|
|
function handleVisibleChange() {}
|