feat
parent
4fdc3f5d43
commit
608a8a4944
|
|
@ -299,12 +299,12 @@ function EquipFormModal({
|
|||
if (cancelled) return;
|
||||
const list = res?.data || [];
|
||||
const unique = Array.from(
|
||||
new Map(list.map((item) => [item.deviceCode, item])).values(),
|
||||
new Map(list.map((item) => [item.deviceTypeCode, item])).values(),
|
||||
);
|
||||
setDeviceTypeOptions(
|
||||
unique.map((item) => ({
|
||||
label: item.deviceName,
|
||||
value: item.deviceCode,
|
||||
label: item.deviceTypeName,
|
||||
value: item.deviceTypeCode,
|
||||
})),
|
||||
);
|
||||
})
|
||||
|
|
|
|||
Loading…
Reference in New Issue