更新
This commit is contained in:
@@ -250,17 +250,32 @@ export default {
|
|||||||
const response = await importBasics(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
const response = await importBasics(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
||||||
const res = response.data
|
const res = response.data
|
||||||
console.log(res)
|
console.log(res)
|
||||||
if (res[0].result === '0') {
|
if (res.hasOwnProperty('output') === false) {
|
||||||
this.$notify.error(`${drawingNum}导入失败`)
|
if (res[0].result === '0') {
|
||||||
}
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
if (res[0].result === '2') {
|
}
|
||||||
this.$notify.error(`${drawingNum}导入重复`)
|
} else {
|
||||||
|
if (res.result[0].result === '0') {
|
||||||
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
|
}
|
||||||
|
if (res.output[0].导入类型 === '2') {
|
||||||
|
this.$notify.warning(`存在重复数据`)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
const response = await importPurcharse(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
const response = await importPurcharse(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
||||||
const res = response.data
|
const res = response.data
|
||||||
if (res[0].result === '0') {
|
if (res.hasOwnProperty('output') === false) {
|
||||||
this.$notify.error(`${drawingNum}导入失败`)
|
if (res[0].result === '0') {
|
||||||
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (res.result[0].result === '0') {
|
||||||
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
|
}
|
||||||
|
if (res.output[0].导入类型 === '2') {
|
||||||
|
this.$notify.warning(`存在重复数据`)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|||||||
@@ -414,22 +414,34 @@ export default {
|
|||||||
const response = await importBasics(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
const response = await importBasics(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
||||||
const res = response.data
|
const res = response.data
|
||||||
console.log(res, 11111111)
|
console.log(res, 11111111)
|
||||||
if (res.result[0].result === '0') {
|
if (res.hasOwnProperty('output') === false) {
|
||||||
this.$notify.error(`${drawingNum}导入失败`)
|
if (res[0].result === '0') {
|
||||||
}
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
if (res.output[0].导入类型 === '2') {
|
}
|
||||||
this.$notify.warning(`存在重复数据`)
|
} else {
|
||||||
|
if (res.result[0].result === '0') {
|
||||||
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
|
}
|
||||||
|
if (res.output[0].导入类型 === '2') {
|
||||||
|
this.$notify.warning(`存在重复数据`)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
console.log(drawingNum, 1111111111)
|
console.log(drawingNum, 1111111111)
|
||||||
const response = await importPurcharse(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
const response = await importPurcharse(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
||||||
const res = response.data
|
const res = response.data
|
||||||
console.log(res, 222222)
|
console.log(res, 222222)
|
||||||
if (res.result[0].result === '0') {
|
if (res.hasOwnProperty('output') === false) {
|
||||||
this.$notify.error(`${drawingNum}导入失败`)
|
if (res[0].result === '0') {
|
||||||
}
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
if (res.output[0].导入类型 === '2') {
|
}
|
||||||
this.$notify.warning(`存在重复数据`)
|
} else {
|
||||||
|
if (res.result[0].result === '0') {
|
||||||
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
|
}
|
||||||
|
if (res.output[0].导入类型 === '2') {
|
||||||
|
this.$notify.warning(`存在重复数据`)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|||||||
Reference in New Issue
Block a user