|
@@ -59,10 +59,22 @@
|
|
|
<!-- <j-dict-select-tag placeholder="请选择试验类型" v-model="queryParam.shiyanType" dictCode="shiiyan_type"/> -->
|
|
|
<a-select
|
|
|
v-model="queryParam2.shiyanType"
|
|
|
- placeholder="请选择实验类型"
|
|
|
+ placeholder="请选择试验类型"
|
|
|
show-search
|
|
|
allowClear
|
|
|
:options="shiyanTypeOption"
|
|
|
+ @change="getSb">
|
|
|
+ </a-select>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :xl="6" :lg="7" :md="8" :sm="24">
|
|
|
+ <a-form-item label="试验设备">
|
|
|
+ <a-select
|
|
|
+ v-model="queryParam2.shebeiId"
|
|
|
+ placeholder="请选择试验设备"
|
|
|
+ show-search
|
|
|
+ allowClear
|
|
|
+ :options="shiyanSbOption"
|
|
|
@change="getSj">
|
|
|
</a-select>
|
|
|
</a-form-item>
|
|
@@ -209,7 +221,7 @@ import { httpAction, getAction } from '@/api/manage'
|
|
|
import { mixinDevice } from '@/utils/mixin'
|
|
|
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
|
|
// import {initDictOptions, filterDictText} from '@/components/dict/JDictSelectUtil'
|
|
|
-import { getWeituoClientList, getWeituoInfoListByClient, getWeituoRq, getWeituoGdh, getWeiYi, getWeiSj, listSj, saveSj, upload, getUpload } from '@/api/api'
|
|
|
+import { getWeituoClientList, getWeituoInfoListByClient, getWeituoRq, getWeituoGdh, getWeiYi, getWeiSb, getWeiSj, listSj, saveSj, upload, getUpload } from '@/api/api'
|
|
|
import VXETable from 'vxe-table'
|
|
|
import JImageUpload from '@/components/jeecg/JImageUpload'
|
|
|
export default {
|
|
@@ -229,8 +241,10 @@ export default {
|
|
|
weituoRqOptions:[],
|
|
|
// 工单号下拉列表
|
|
|
weituoGdOptions: [],
|
|
|
- // 实验类型下拉列表
|
|
|
+ // 试验类型下拉列表
|
|
|
shiyanTypeOption: [],
|
|
|
+ // 试验设备下拉列表
|
|
|
+ shiyanSbOption: [],
|
|
|
// 新增默认的试验类型
|
|
|
shiyanType: '',
|
|
|
// url: {
|
|
@@ -317,7 +331,6 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
})
|
|
|
- this.toggleSearchStatus = true;
|
|
|
},
|
|
|
// // 获取字典数据-试验类型
|
|
|
// initDictConfig() {
|
|
@@ -336,7 +349,7 @@ export default {
|
|
|
}
|
|
|
return typeLabel
|
|
|
},
|
|
|
- // 获取试验类型
|
|
|
+ // 监听选中的工单,获取试验类型
|
|
|
getWoId(value){
|
|
|
// this.queryParam = {...this.queryParam}
|
|
|
this.shiyanTypeOption = []
|
|
@@ -354,6 +367,26 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
})
|
|
|
+ this.toggleSearchStatus = true;
|
|
|
+ },
|
|
|
+ getSb(){
|
|
|
+ // this.queryParam2 = {...this.queryParam2}
|
|
|
+ this.shiyanSbOption = []
|
|
|
+ this.queryParam2.shebeiId = ''
|
|
|
+ const query ={}
|
|
|
+ query.riqi = this.queryParam2.riqi
|
|
|
+ query.woId = this.queryParam.woId
|
|
|
+ query.shiyanType = this.queryParam2.shiyanType
|
|
|
+ console.log(query)
|
|
|
+ getWeiSb(query).then((res) => {
|
|
|
+ console.log(22222,res)
|
|
|
+ this.shiyanSbOption = res.result.map( res => {
|
|
|
+ return{
|
|
|
+ value: res.type, //传的值
|
|
|
+ label: res.name, //展示
|
|
|
+ }
|
|
|
+ })
|
|
|
+ })
|
|
|
},
|
|
|
// 获取实绩开始时间结束时间
|
|
|
getSj(){
|
|
@@ -364,9 +397,10 @@ export default {
|
|
|
query.riqi = this.queryParam2.riqi
|
|
|
query.woId = this.queryParam.woId
|
|
|
query.shiyanType = this.queryParam2.shiyanType
|
|
|
+ query.shebeiId = this.queryParam2.shebeiId
|
|
|
console.log(query)
|
|
|
getWeiSj(query).then((res) => {
|
|
|
- console.log(res)
|
|
|
+ console.log(22222222,res)
|
|
|
this.queryParam2.shiyanKaishitime = res.result.shiyanKaishitime
|
|
|
this.queryParam2.shiyanJieshutime = res.result.shiyanJieshutime
|
|
|
this.queryParam2 = {...this.queryParam2}
|
|
@@ -419,7 +453,7 @@ export default {
|
|
|
querySubmit.woId = this.queryParam.woId
|
|
|
querySubmit.shiyanDateTime = this.queryParam2.riqi
|
|
|
querySubmit.list = this.$refs.xTable.afterFullData
|
|
|
- console.log(777,querySubmit)
|
|
|
+ console.log(querySubmit)
|
|
|
saveSj(querySubmit).then((res) => {
|
|
|
if (res.success) {
|
|
|
this.$message.success("提交成功")
|
|
@@ -462,6 +496,7 @@ export default {
|
|
|
var select = this.queryParam
|
|
|
select.riqi = this.queryParam2.riqi
|
|
|
select.shiyanType = this.queryParam2.shiyanType
|
|
|
+ select.shebeiId = this.queryParam2.shebeiId
|
|
|
select.shiyanKaishitime = this.queryParam2.shiyanKaishitime
|
|
|
select.shiyanJieshutime = this.queryParam2.shiyanJieshutime
|
|
|
select.pinci = this.queryParam2.pinci
|