From adc8607684261c94b71bc17c1994ada4612a9a9d Mon Sep 17 00:00:00 2001 From: jinlin <jinlin> Date: 星期二, 02 一月 2024 09:03:14 +0800 Subject: [PATCH] 修改 --- web/src/views/modules/configItemWarehouse/ConfigItemWarehouse-AddOrUpdate.vue | 31 +++++++++++++++++++++---------- 1 files changed, 21 insertions(+), 10 deletions(-) diff --git a/web/src/views/modules/configItemWarehouse/ConfigItemWarehouse-AddOrUpdate.vue b/web/src/views/modules/configItemWarehouse/ConfigItemWarehouse-AddOrUpdate.vue index 462cae9..235983c 100644 --- a/web/src/views/modules/configItemWarehouse/ConfigItemWarehouse-AddOrUpdate.vue +++ b/web/src/views/modules/configItemWarehouse/ConfigItemWarehouse-AddOrUpdate.vue @@ -28,7 +28,7 @@ </el-date-picker> </el-form-item> <el-form-item class="marginTopAndMarginBottom2" label="搴撶被鍨�" style="width: 99%"> - <zt-dict v-model="dataForm.configItemWarehouse.libraryType" :radio="true" dict="library_type"></zt-dict> + <zt-dict disabled="disabled" v-model="dataForm.configItemWarehouse.libraryType" :radio="true" dict="library_type"></zt-dict> </el-form-item> </div> <div class="el-flexManageDialog el-border-bottom"> @@ -88,7 +88,7 @@ <el-table-column fixed="right" prop="files" label="涓婁紶闄勪欢" width="240" align="center"> <template v-slot="{ row }"> <!-- <zt-table-button @click="files(row.id)">涓婁紶闄勪欢</zt-table-button>--> - <table-uploader busi-type="config_item_warehouse" model-name="row" :dataForm="row" + <table-uploader :disabled="!showAddAndEdit" busi-type="config_item_warehouse" model-name="row" :dataForm="row" v-model="row.files"/> </template> </el-table-column> @@ -238,11 +238,16 @@ </div> <add-or-update-check ref="addOrUpdate" @recall="setCheckId"/> </el-form> + <template v-slot:footer> + <el-button v-if="dataForm.disabled" type="primary" @click="print()">鎵撳嵃</el-button> + </template> </zt-dialog> </template> <script> import AddOrUpdateCheck from '../testCheckOrder/TestCheckOrder-AddOrUpdate' + import qs from "qs"; + import Cookies from "js-cookie"; export default { data() { @@ -320,6 +325,10 @@ if (row.projectId) { this.dataForm.projectId = row.projectId } + if (row.libraryType) { + console.log(row.libraryType,"row.libraryType") + this.dataForm.configItemWarehouse.libraryType = row.libraryType + } this.getInfo() if (!this.dataForm.disabled) { if (!row.stepMarker) { @@ -332,13 +341,6 @@ } console.log(this.dataForm.id, this.dataForm.projectId, 'params params') }, - // addConfigItemWarehouseRow(){ - // this.dataForm.configItemList.push({}) - // this.$nextTick(()=>{ - // const tableBody=this.$refs.tableConfigItemList.$el.querySelector('.el-table__body-wrapper') - // tableBody.scrollTop = tableBody.scrollHeight; - // }) - // }, handleCommand(pageCode) { const selectedItem = this.menuOptions.find(item => item.pageCode === pageCode); console.log(selectedItem, "handleCommand(pageCode) selectedItem") @@ -373,7 +375,8 @@ async getInfo() { let params = { warehouseId: this.dataForm.id, - projectId: this.dataForm.projectId + projectId: this.dataForm.projectId, + libraryType:this.dataForm.configItemWarehouse.libraryType } let res = await this.$http.get(`/configItemWarehouse/ConfigItemWarehouse/getDto`, {params: params}) this.dataForm = { @@ -391,6 +394,14 @@ } console.log(this.dataForm, "getInfo this.dataForm") }, + async print(){ + var params = qs.stringify({ + token: Cookies.get('token'), + id:this.dataForm.id + }) + let apiURL = `/configItemWarehouse/ConfigItemWarehouse/exportWarehouseOrder` + window.location.href = `${window.SITE_CONFIG['apiURL']}${apiURL}?${params}` + }, // 琛ㄥ崟鎻愪氦 async formSubmit(submitType) { if (this.showColumn && submitType == 'bl') { -- Gitblit v1.9.1