fix(erp-frontend-vue): resolve TypeScript build errors (duplicate ids, unused vars, null guards, type mismatches)
Made-with: Cursor
This commit is contained in:
@@ -432,6 +432,7 @@ async function handleUpdate(row?: MdItem) {
|
||||
resetForm()
|
||||
await getTreeselect()
|
||||
const itemId = row?.itemId || ids.value[0]
|
||||
if (!itemId) return
|
||||
const res = await getMdItem(itemId)
|
||||
Object.assign(form, res.data)
|
||||
optType.value = 'edit'
|
||||
|
||||
@@ -218,6 +218,7 @@ function handleAdd() {
|
||||
async function handleUpdate(row?: UnitMeasure) {
|
||||
resetForm()
|
||||
const measureId = row?.measureId || ids.value[0]
|
||||
if (!measureId) return
|
||||
const res = await getUnitMeasure(measureId)
|
||||
Object.assign(form, res.data)
|
||||
dialogTitle.value = '修改计量单位'
|
||||
|
||||
@@ -209,6 +209,7 @@ function handleAdd() {
|
||||
async function handleUpdate(row?: Workshop) {
|
||||
resetForm()
|
||||
const workshopId = row?.workshopId || ids.value[0]
|
||||
if (!workshopId) return
|
||||
const res = await getWorkshop(workshopId)
|
||||
Object.assign(form, res.data)
|
||||
dialogTitle.value = '修改车间'
|
||||
|
||||
@@ -230,6 +230,7 @@ async function handleUpdate(row?: Workstation) {
|
||||
resetForm()
|
||||
await getWorkshops()
|
||||
const workstationId = row?.workstationId || ids.value[0]
|
||||
if (!workstationId) return
|
||||
const res = await getWorkstation(workstationId)
|
||||
Object.assign(form, res.data)
|
||||
dialogTitle.value = '修改工作站'
|
||||
|
||||
Reference in New Issue
Block a user