This commit is contained in:
xhf 2025-02-14 11:45:02 +08:00
commit b5a0f02d4e

View File

@ -174,14 +174,7 @@ const submit = async (formEl) => {
let list = []
for (let index = 0; index < form.value.layersNumber; index++) {
if (
form.value.dataList.length > 0 &&
form.value.dataList[index] &&
form.value.dataList[index].id
) {
list.push(form.value.dataList[index])
} else {
list.push({
let item = {
positionMapId: props.positionMapId,
locationWide: form.value.locationWide || undefined,
locationDeep: form.value.locationDeep || undefined,
@ -189,8 +182,18 @@ const submit = async (formEl) => {
inDirection: form.value.inDirection || undefined, //
outDirection: form.value.outDirection || undefined, //
locationStorey: index + 1 //
})
}
if (
form.value.dataList.length > 0 &&
form.value.dataList[index] &&
form.value.dataList[index].id
) {
item.id = form.value.dataList[index].id
item.locationNo = form.value.dataList[index].locationNo
item.mapItemId = form.value.dataList[index].mapItemId
item.laneId = form.value.dataList[index].laneId
}
list.push(item)
}
form.value.dataList = list
//dataJson