调整查看qc文件的判断条件
This commit is contained in:
parent
e61572f87b
commit
6cd3a38a3d
|
@ -256,9 +256,8 @@ export default {
|
|||
this.$store.commit('ADD_SAMPLE_DATA', {
|
||||
inputFileName,
|
||||
data: result,
|
||||
from: 'db'
|
||||
from: 'db',
|
||||
})
|
||||
|
||||
} else {
|
||||
this.$message.error(message)
|
||||
}
|
||||
|
@ -273,7 +272,7 @@ export default {
|
|||
this.$emit('getFiles', {
|
||||
detFileName: result.detBg.fileName,
|
||||
gasFileName: result.gasBg.fileName,
|
||||
qcFileName: result.qc ? result.qc.fileName : ''
|
||||
qcFileName: result.qc ? result.qc.fileName : '',
|
||||
})
|
||||
},
|
||||
|
||||
|
@ -301,7 +300,7 @@ export default {
|
|||
this.$store.commit('ADD_SAMPLE_DATA', {
|
||||
inputFileName: this.sample.sampleFileName,
|
||||
data: result,
|
||||
from: 'file'
|
||||
from: 'file',
|
||||
})
|
||||
this.isLoading = false
|
||||
} else {
|
||||
|
@ -326,7 +325,7 @@ export default {
|
|||
},
|
||||
|
||||
changeChartByType(val) {
|
||||
if (val === 'qc' && !this.sample.qcFileStatus) {
|
||||
if (val === 'qc' && !this.sampleDetail.qc) {
|
||||
this.$message.warning('No qc spectrum file!')
|
||||
} else {
|
||||
const {
|
||||
|
@ -456,11 +455,11 @@ export default {
|
|||
async handler(newVal, oldVal) {
|
||||
this.resultDisplay = []
|
||||
const sampleData = await this.$store.dispatch('GET_SAMPLE_DATA', newVal.inputFileName)
|
||||
if(sampleData) {
|
||||
if (sampleData) {
|
||||
const { data, from } = sampleData
|
||||
this.sampleDetail = data
|
||||
this.changeChartByType('sample')
|
||||
if(from == 'db') {
|
||||
if (from == 'db') {
|
||||
this.sampleDetail = data
|
||||
this.emitGetFiles(data)
|
||||
}
|
||||
|
|
|
@ -304,7 +304,7 @@ export default {
|
|||
postFileAction('/spectrumAnalysis/exportRLR', params).then((res) => {
|
||||
let name = this.newSampleData.inputFileName.split('.')[0]
|
||||
const blob = new Blob([res], { type: 'application/vnd.ms-excel' })
|
||||
saveAs(blob, `${name}RLR`)
|
||||
saveAs(blob, `${name}_RLR`)
|
||||
// let _this = this
|
||||
// this.$confirm({
|
||||
// title: 'Please enter file name',
|
||||
|
|
|
@ -282,25 +282,27 @@ export default {
|
|||
Conclusion_Res: this.conclusionVal.conclusionRes || this.allInfo.Conclusion_Res,
|
||||
Comment: this.commentVal.comment || this.allInfo.Comment,
|
||||
}
|
||||
let name = this.newSampleData.inputFileName.split('.')[0]
|
||||
postAction('/gamma/exportRLR', params).then((res) => {
|
||||
const blob = new Blob([res])
|
||||
let _this = this
|
||||
this.$confirm({
|
||||
title: 'Please enter file name',
|
||||
content: (h) => <a-input v-model={_this.fileName} />,
|
||||
okText: 'Cancle',
|
||||
cancelText: 'Save',
|
||||
okButtonProps: { style: { backgroundColor: '#b98326', color: '#fff', borderColor: 'transparent' } },
|
||||
cancelButtonProps: { style: { color: '#fff', backgroundColor: '#31aab0', borderColor: 'transparent' } },
|
||||
onOk() {
|
||||
console.log('Cancel')
|
||||
},
|
||||
onCancel() {
|
||||
if (_this.fileName) {
|
||||
saveAs(blob, `${_this.fileName}.RLR`)
|
||||
}
|
||||
},
|
||||
})
|
||||
saveAs(blob, `${name}_RLR`)
|
||||
// let _this = this
|
||||
// this.$confirm({
|
||||
// title: 'Please enter file name',
|
||||
// content: (h) => <a-input v-model={_this.fileName} />,
|
||||
// okText: 'Cancle',
|
||||
// cancelText: 'Save',
|
||||
// okButtonProps: { style: { backgroundColor: '#b98326', color: '#fff', borderColor: 'transparent' } },
|
||||
// cancelButtonProps: { style: { color: '#fff', backgroundColor: '#31aab0', borderColor: 'transparent' } },
|
||||
// onOk() {
|
||||
// console.log('Cancel')
|
||||
// },
|
||||
// onCancel() {
|
||||
// if (_this.fileName) {
|
||||
// saveAs(blob, `${_this.fileName}.RLR`)
|
||||
// }
|
||||
// },
|
||||
// })
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('Please finishi ti edit new inserted row first.')
|
||||
|
|
Loading…
Reference in New Issue
Block a user