| | |
| | | v-model="row.files"/> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="stepMarker=='pzxrk_first'" fixed="right" label="操作" align="center"> |
| | | <template slot-scope="scope"> |
| | | <zt-table-button @click="deleteRow(scope.$index,scope.row.id)">删除</zt-table-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <div v-if="showAddAndEdit && !dataForm.disabled" class="icon-container"> |
| | | <el-dropdown @command="handleCommand"> |
| | |
| | | import AddOrUpdateCheck from '../testCheckOrder/TestCheckOrder-AddOrUpdate' |
| | | import qs from "qs"; |
| | | import Cookies from "js-cookie"; |
| | | import cloneDeep from "lodash/cloneDeep"; |
| | | |
| | | export default { |
| | | data() { |
| | |
| | | console.log(row.libraryType,"row.libraryType") |
| | | this.dataForm.configItemWarehouse.libraryType = row.libraryType |
| | | } |
| | | this.getInfo() |
| | | this.getInfo2() |
| | | if (!this.dataForm.disabled) { |
| | | if (!row.stepMarker) { |
| | | this.stepMarker = 'pzxrk_first' |
| | |
| | | this.$set(row, 'checkId', checkId) |
| | | }, |
| | | // 获取信息 |
| | | async getInfo() { |
| | | async getInfo2() { |
| | | let params = { |
| | | warehouseId: this.dataForm.id, |
| | | projectId: this.dataForm.projectId, |
| | | libraryType:this.dataForm.configItemWarehouse.libraryType |
| | | } |
| | | let res = await this.$http.get(`/configItemWarehouse/ConfigItemWarehouse/getDto`, {params: params}) |
| | | this.dataForm = { |
| | | ...this.dataForm, |
| | | ...res.data |
| | | } |
| | | if (this.dataForm.project === null) { |
| | | this.dataForm.project = {} |
| | | } |
| | |
| | | if (this.dataForm.flowInfoDto === null) { |
| | | this.dataForm.flowInfoDto = {} |
| | | } |
| | | setTimeout(()=>{ |
| | | this.dataForm = { |
| | | ...this.dataForm, |
| | | ...res.data |
| | | } |
| | | },100) |
| | | console.log(this.dataForm, "getInfo this.dataForm") |
| | | }, |
| | | async deleteRow(index, id){ |
| | | if (await this.$tip.confirm(this.$t('prompt.info', {'handle': this.$t('delete')}))) { |
| | | if (id != null) { |
| | | let res = await this.$http.delete('/configItemWarehouse/WarehouseConfigItem/', {data: [id]}) |
| | | } |
| | | this.dataForm.configItemList.splice(index, 1) |
| | | } |
| | | }, |
| | | async print(){ |
| | | var params = qs.stringify({ |
| | |
| | | }, |
| | | // 表单提交 |
| | | async formSubmit(submitType) { |
| | | let isFiles = true; |
| | | this.dataForm.configItemList.forEach(item => { |
| | | console.log(item, "his.dataForm.technicalList.forEach") |
| | | item.files.groups.forEach(groups => { |
| | | groups.fields.forEach(files => { |
| | | if (files.files.length === 0) { |
| | | this.$alert("当前存在未上传附件的技术资料,请重新上传") |
| | | isFiles = false |
| | | return isFiles |
| | | } |
| | | }) |
| | | }) |
| | | }) |
| | | if (this.showColumn && submitType == 'bl') { |
| | | for (let item of this.dataForm.configItemList) { |
| | | if (item) { |
| | |
| | | } |
| | | } |
| | | } |
| | | if (submitType == 'tj' || submitType == 'bl') { |
| | | if (submitType === 'tj' || submitType === 'bl') { |
| | | if (!isFiles){ |
| | | return |
| | | } |
| | | let flowInfo = { |
| | | flowCode: 'pzxrk', |
| | | stepIdMark: this.stepMarker, |