beta 重新分析接口对接,及save to DB 功能调试
This commit is contained in:
parent
0db383e436
commit
90cfebf23e
|
@ -596,6 +596,7 @@ export default {
|
||||||
count: 0, //反算时需要传递的数值 非反算的情况下不需要传递 数值大小是 第一次调用接口时返回的tableWidgets 大小
|
count: 0, //反算时需要传递的数值 非反算的情况下不需要传递 数值大小是 第一次调用接口时返回的tableWidgets 大小
|
||||||
isFirstFitting: true,
|
isFirstFitting: true,
|
||||||
isInverse: false, // 是否需要反算
|
isInverse: false, // 是否需要反算
|
||||||
|
betaIsFitting: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -869,6 +870,8 @@ export default {
|
||||||
})
|
})
|
||||||
if (success) {
|
if (success) {
|
||||||
this.isFirstFitting = false
|
this.isFirstFitting = false
|
||||||
|
this.betaIsFitting = true
|
||||||
|
this.$emit('isFitting', this.betaIsFitting)
|
||||||
|
|
||||||
const { EToC, newLineSeries, newScatterSeriesData, tableWidgets, CToE } = result
|
const { EToC, newLineSeries, newScatterSeriesData, tableWidgets, CToE } = result
|
||||||
this.newE2C = EToC
|
this.newE2C = EToC
|
||||||
|
|
|
@ -467,6 +467,7 @@ export default {
|
||||||
count: 0, //反算时需要传递的数值 非反算的情况下不需要传递 数值大小是 第一次调用接口时返回的tableWidgets 大小
|
count: 0, //反算时需要传递的数值 非反算的情况下不需要传递 数值大小是 第一次调用接口时返回的tableWidgets 大小
|
||||||
isFirstFitting: true,
|
isFirstFitting: true,
|
||||||
isInverse: false, // 是否需要反算
|
isInverse: false, // 是否需要反算
|
||||||
|
gammaIsFitting: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -646,6 +647,8 @@ export default {
|
||||||
})
|
})
|
||||||
if (success) {
|
if (success) {
|
||||||
this.isFirstFitting = false
|
this.isFirstFitting = false
|
||||||
|
this.gammaIsFitting = false
|
||||||
|
this.$emit('isFitting', this.gammaIsFitting)
|
||||||
|
|
||||||
const { EToC, newLineSeries, newScatterSeriesData, tableWidgets, CToE } = result
|
const { EToC, newLineSeries, newScatterSeriesData, tableWidgets, CToE } = result
|
||||||
this.newE2C = EToC
|
this.newE2C = EToC
|
||||||
|
|
|
@ -9,19 +9,19 @@
|
||||||
>
|
>
|
||||||
<a-tabs :animated="false" v-model="currTab">
|
<a-tabs :animated="false" v-model="currTab">
|
||||||
<a-tab-pane tab="Gamma Detector Calibration" key="gamma">
|
<a-tab-pane tab="Gamma Detector Calibration" key="gamma">
|
||||||
<gamma-detector-calibration />
|
<gamma-detector-calibration @isFitting="getFittingFlag_gamma" />
|
||||||
</a-tab-pane>
|
</a-tab-pane>
|
||||||
<a-tab-pane tab="Beta Detector Calibration" key="beta">
|
<a-tab-pane tab="Beta Detector Calibration" key="beta">
|
||||||
<beta-detector-calibration />
|
<beta-detector-calibration @isFitting="getFittingFlag_beta" />
|
||||||
</a-tab-pane>
|
</a-tab-pane>
|
||||||
</a-tabs>
|
</a-tabs>
|
||||||
<div class="footer">
|
<div class="footer">
|
||||||
<title-over-border title="New Calibration is Applied to">
|
<title-over-border title="New Calibration is Applied to">
|
||||||
<a-radio-group v-model="newCalibrationIsAppliedTo">
|
<a-radio-group v-model="newCalibrationIsAppliedTo">
|
||||||
<p>
|
<p>
|
||||||
<a-radio value="1">All Spectra</a-radio>
|
<a-radio value="AllSpectrum">All Spectra</a-radio>
|
||||||
</p>
|
</p>
|
||||||
<a-radio value="2">Current Spectrum</a-radio>
|
<a-radio value="CurrentSpectrum">Current Spectrum</a-radio>
|
||||||
</a-radio-group>
|
</a-radio-group>
|
||||||
</title-over-border>
|
</title-over-border>
|
||||||
<title-over-border title="Recalculate ROI Counts For">
|
<title-over-border title="Recalculate ROI Counts For">
|
||||||
|
@ -44,22 +44,26 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import ModalMixin from '@/mixins/ModalMixin'
|
import ModalMixin from '@/mixins/ModalMixin'
|
||||||
|
import SampleDataMixin from '@/views/spectrumAnalysis/SampleDataMixin'
|
||||||
|
import { postAction } from '@/api/manage'
|
||||||
import BetaDetectorCalibration from './components/BetaDetectorCalibration.vue'
|
import BetaDetectorCalibration from './components/BetaDetectorCalibration.vue'
|
||||||
import GammaDetectorCalibration from './components/GammaDetectorCalibration.vue'
|
import GammaDetectorCalibration from './components/GammaDetectorCalibration.vue'
|
||||||
import TitleOverBorder from '@/views/spectrumAnalysis/components/TitleOverBorder.vue'
|
import TitleOverBorder from '@/views/spectrumAnalysis/components/TitleOverBorder.vue'
|
||||||
export default {
|
export default {
|
||||||
components: { BetaDetectorCalibration, GammaDetectorCalibration, TitleOverBorder },
|
components: { BetaDetectorCalibration, GammaDetectorCalibration, TitleOverBorder },
|
||||||
mixins: [ModalMixin],
|
mixins: [ModalMixin, SampleDataMixin],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
currTab: 'gamma',
|
currTab: 'gamma',
|
||||||
newCalibrationIsAppliedTo: '2',
|
newCalibrationIsAppliedTo: 'CurrentSpectrum',
|
||||||
recalculateROICountsFor: [],
|
recalculateROICountsFor: [],
|
||||||
checkFlag: {
|
checkFlag: {
|
||||||
checkSample: false,
|
checkSample: false,
|
||||||
checkGas: false,
|
checkGas: false,
|
||||||
checkDet: false,
|
checkDet: false,
|
||||||
},
|
},
|
||||||
|
betaEnergyValid: false,
|
||||||
|
gammaEnergyValid: true,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
@ -74,8 +78,42 @@ export default {
|
||||||
this.checkFlag.checkDet = checkedVal.includes('detBg') ? true : false
|
this.checkFlag.checkDet = checkedVal.includes('detBg') ? true : false
|
||||||
this.$emit('sendInfo', this.checkFlag)
|
this.$emit('sendInfo', this.checkFlag)
|
||||||
},
|
},
|
||||||
|
getFittingFlag_beta(val) {
|
||||||
|
this.betaEnergyValid = val
|
||||||
|
},
|
||||||
|
getFittingFlag_gamma(val) {
|
||||||
|
this.gammaEnergyValid = val
|
||||||
|
},
|
||||||
handleReAnalyse() {
|
handleReAnalyse() {
|
||||||
console.log(this.currTab)
|
let params = {
|
||||||
|
applyType: this.newCalibrationIsAppliedTo,
|
||||||
|
sampleData: this.recalculateROICountsFor.includes('sample') ? true : false,
|
||||||
|
gasBgData: this.recalculateROICountsFor.includes('gasBg') ? true : false,
|
||||||
|
detBgData: this.recalculateROICountsFor.includes('detBg') ? true : false,
|
||||||
|
qcData: this.recalculateROICountsFor.includes('qc') ? true : false,
|
||||||
|
betaEnergyValid: this.betaEnergyValid,
|
||||||
|
gammaEnergyValid: this.gammaEnergyValid,
|
||||||
|
dbNames: [this.newSampleData.dbName],
|
||||||
|
sampleIds: [this.newSampleData.sampleId ? this.newSampleData.sampleId : ''],
|
||||||
|
sampleFileNames: [this.newSampleData.inputFileName],
|
||||||
|
gasFileNames: [this.newSampleData.gasFileName],
|
||||||
|
detFileNames: [this.newSampleData.detFileName],
|
||||||
|
qcFileNames: [this.newSampleData.qcFileName],
|
||||||
|
currentFileName: this.newSampleData.inputFileName,
|
||||||
|
}
|
||||||
|
postAction('/spectrumAnalysis/ReAnalyse', params).then((res) => {
|
||||||
|
if (res.success) {
|
||||||
|
res.result.XeData.forEach((item) => {
|
||||||
|
item.conc = item.conc.toFixed(6)
|
||||||
|
item.concErr = item.concErr.toFixed(6)
|
||||||
|
item.lc = item.lc.toFixed(6)
|
||||||
|
item.mdc = item.mdc.toFixed(6)
|
||||||
|
})
|
||||||
|
this.$emit('sendXeData', res.result.XeData)
|
||||||
|
} else {
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
handleExit() {
|
handleExit() {
|
||||||
this.visible = false
|
this.visible = false
|
||||||
|
|
|
@ -160,7 +160,11 @@
|
||||||
<!-- Beta-Gamma 的Comments 结束 -->
|
<!-- Beta-Gamma 的Comments 结束 -->
|
||||||
|
|
||||||
<!-- Beta-Gamma 的Energy Calibration开始 -->
|
<!-- Beta-Gamma 的Energy Calibration开始 -->
|
||||||
<beta-gamma-energy-calibration-modal v-model="betaGammaEnergyCalibrationModalVisible" @sendInfo="getCheckFlag" />
|
<beta-gamma-energy-calibration-modal
|
||||||
|
v-model="betaGammaEnergyCalibrationModalVisible"
|
||||||
|
@sendInfo="getCheckFlag"
|
||||||
|
@sendXeData="getXeData"
|
||||||
|
/>
|
||||||
<!-- Beta-Gamma 的Energy Calibration结束 -->
|
<!-- Beta-Gamma 的Energy Calibration结束 -->
|
||||||
|
|
||||||
<!-- Beta-Gamma 的 Extrapolation 弹窗开始 -->
|
<!-- Beta-Gamma 的 Extrapolation 弹窗开始 -->
|
||||||
|
@ -404,6 +408,12 @@ export default {
|
||||||
this.params_toDB.comment = val.spectrumAnalysisCommentInfo
|
this.params_toDB.comment = val.spectrumAnalysisCommentInfo
|
||||||
},
|
},
|
||||||
getStationName(arg, val) {
|
getStationName(arg, val) {
|
||||||
|
arg.forEach((item) => {
|
||||||
|
item.conc = item.conc.toFixed(6)
|
||||||
|
item.concErr = item.concErr.toFixed(6)
|
||||||
|
item.lc = item.lc.toFixed(6)
|
||||||
|
item.mdc = item.mdc.toFixed(6)
|
||||||
|
})
|
||||||
this.resultDisplayFlag = arg
|
this.resultDisplayFlag = arg
|
||||||
this.params_toDB.stationName = val
|
this.params_toDB.stationName = val
|
||||||
},
|
},
|
||||||
|
@ -412,6 +422,10 @@ export default {
|
||||||
this.params_toDB.checkGas = val.checkGas
|
this.params_toDB.checkGas = val.checkGas
|
||||||
this.params_toDB.checkDet = val.checkDet
|
this.params_toDB.checkDet = val.checkDet
|
||||||
},
|
},
|
||||||
|
getXeData(val) {
|
||||||
|
this.$set(this.analyseCurrentSpectrumData, 'XeData', val)
|
||||||
|
this.resultDisplayFlag = val
|
||||||
|
},
|
||||||
// formDB 来源 吧接口返回的文件名称添加到sampleData
|
// formDB 来源 吧接口返回的文件名称添加到sampleData
|
||||||
getFiles(val) {
|
getFiles(val) {
|
||||||
this.newSampleData = { ...this.sampleData, ...val }
|
this.newSampleData = { ...this.sampleData, ...val }
|
||||||
|
@ -610,10 +624,11 @@ export default {
|
||||||
getAnalyzeCurrentSpectrum() {
|
getAnalyzeCurrentSpectrum() {
|
||||||
let params = {
|
let params = {
|
||||||
dbNames: [this.newSampleData.dbName],
|
dbNames: [this.newSampleData.dbName],
|
||||||
sampleIds: [this.newSampleData.sampleId],
|
sampleIds: [this.newSampleData.sampleId ? this.newSampleData.sampleId : ''],
|
||||||
sampleFileNames: [this.newSampleData.inputFileName],
|
sampleFileNames: [this.newSampleData.inputFileName],
|
||||||
gasFileNames: [this.newSampleData.gasFileName],
|
gasFileNames: [this.newSampleData.gasFileName],
|
||||||
detFileNames: [this.newSampleData.detFileName],
|
detFileNames: [this.newSampleData.detFileName],
|
||||||
|
qcFileNames: [this.newSampleData.qcFileName],
|
||||||
}
|
}
|
||||||
postAction('/spectrumAnalysis/analyseCurrentSpectrum', params).then((res) => {
|
postAction('/spectrumAnalysis/analyseCurrentSpectrum', params).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
|
@ -630,6 +645,32 @@ export default {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
getAnalyzeAllSpectrum() {
|
||||||
|
let params = {
|
||||||
|
dbNames: [this.newSampleData.dbName],
|
||||||
|
sampleIds: [this.newSampleData.sampleId ? this.newSampleData.sampleId : ''],
|
||||||
|
sampleFileNames: [this.newSampleData.inputFileName],
|
||||||
|
gasFileNames: [this.newSampleData.gasFileName],
|
||||||
|
detFileNames: [this.newSampleData.detFileName],
|
||||||
|
qcFileNames: [this.newSampleData.qcFileName],
|
||||||
|
currentFileName: this.newSampleData.inputFileName,
|
||||||
|
}
|
||||||
|
postAction('/spectrumAnalysis/analyseAllSpectrum', params).then((res) => {
|
||||||
|
if (res.success) {
|
||||||
|
console.log(res)
|
||||||
|
this.analyseCurrentSpectrumData = res.result
|
||||||
|
this.resultDisplayFlag = res.result.XeData
|
||||||
|
this.resultDisplayFlag.forEach((item) => {
|
||||||
|
item.conc = item.conc.toFixed(6)
|
||||||
|
item.concErr = item.concErr.toFixed(6)
|
||||||
|
item.lc = item.lc.toFixed(6)
|
||||||
|
item.mdc = item.mdc.toFixed(6)
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
handleEnergyCalib() {
|
handleEnergyCalib() {
|
||||||
if (this.newSampleData.sampleId) {
|
if (this.newSampleData.sampleId) {
|
||||||
if (this.newSampleData.qcFileName) {
|
if (this.newSampleData.qcFileName) {
|
||||||
|
@ -823,7 +864,9 @@ export default {
|
||||||
type: 'a-menu-item',
|
type: 'a-menu-item',
|
||||||
title: 'Analyze all spectra',
|
title: 'Analyze all spectra',
|
||||||
show: this.isBetaGamma,
|
show: this.isBetaGamma,
|
||||||
handler: () => {},
|
handler: () => {
|
||||||
|
this.getAnalyzeAllSpectrum()
|
||||||
|
},
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue
Block a user