| | |
| | | </div> |
| | | </el-form> |
| | | </div> |
| | | <div class="finishedProduct-detail"> |
| | | <el-row style="width:100%;z-index: 10;height:30px;"> |
| | | <el-col :span="12" class="inspectionProject_span">检验项目</el-col> |
| | | <el-col v-if="resultVal==null" :span="12" class="inspectionProject_span" style="text-align: right;"> |
| | | <div> |
| | | <el-tabs class="finishedProduct-detail" @tab-click="tabsClick"> |
| | | <el-tab-pane label="检验项目"> |
| | | <el-row> |
| | | <el-col v-if="resultVal==null" :span="24" class="inspectionProject_span" style="text-align: right;"> |
| | | <el-button size="mini" @click="clickAddInspectionColumn()">添加检测值列</el-button> |
| | | <el-button size="mini" @click="clickDeleteInspectionColumn()">删除检测值列</el-button> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row style="width:100%;"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-table border :data="inspectionItems" height="400" |
| | | :header-cell-style="{textAlign:'center',color:'black',backgroundColor:'#fafafa'}" |
| | |
| | | </el-table> |
| | | </el-col> |
| | | </el-row> |
| | | </el-tab-pane> |
| | | <el-tab-pane label="附件上传" type="card"> |
| | | <div style="display: flex;justify-content:flex-end;"> |
| | | <div></div> |
| | | </div> |
| | | <div |
| | | v-loading="progrecessFileLoading" |
| | | element-loading-text="请稍等,文件上传中" |
| | | > |
| | | <el-upload |
| | | drag |
| | | ref="upload" |
| | | action="/mes/attachment/upload" |
| | | :auto-upload="true" |
| | | :headers="headers" |
| | | :before-upload="submitUpload" |
| | | :on-success="uploadSuccess" |
| | | :data="paramData" |
| | | :with-credentials="true" |
| | | :show-file-list="false" |
| | | > |
| | | <i class="el-icon-upload"></i> |
| | | <div class="el-upload__text"> |
| | | 将文件拖到此处,或<em>点击上传</em> |
| | | </div> |
| | | </el-upload> |
| | | </div> |
| | | <el-table :data="processConfigFileTableData" height="260px"> |
| | | <el-table-column |
| | | prop="finishedInsNo" |
| | | align="center" |
| | | width="120" |
| | | label="产品检验编号" |
| | | show-overflow-tooltip |
| | | ></el-table-column> |
| | | <el-table-column |
| | | prop="originalFileName" |
| | | align="center" |
| | | label="原文件名" |
| | | width="200" |
| | | ></el-table-column> |
| | | <el-table-column prop="fileName" align="center" label="文件后缀"></el-table-column> |
| | | <el-table-column prop="createUser" align="center" label="上传人"></el-table-column> |
| | | <el-table-column |
| | | prop="createTime" |
| | | align="center" |
| | | label="上传时间" |
| | | show-overflow-tooltip |
| | | ></el-table-column> |
| | | <el-table-column prop="updateUser" align="center" label="更新人"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="updateTime" |
| | | align="center" |
| | | label="更新时间" |
| | | show-overflow-tooltip |
| | | ></el-table-column> |
| | | <el-table-column align="center" label="操作"> |
| | | <template slot-scope="scope"> |
| | | <el-button |
| | | @click="delProcessConfigFile(scope.row)" |
| | | type="text" |
| | | size="small" |
| | | :disabled="(resultVal!=null && resultVal!='')" |
| | | >删除</el-button |
| | | > |
| | | <el-button |
| | | @click="downloadProcessConfigFile(scope.row)" |
| | | type="text" |
| | | size="small" |
| | | >下载</el-button |
| | | > |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-tab-pane> |
| | | </el-tabs> |
| | | |
| | | </div> |
| | | <div class="finishedProduct-result"> |
| | | <el-row style="width:100%"> |
| | |
| | | selectDeviceAPI, |
| | | updateLocationIdById, |
| | | } from '@/api/quality/finishedProduct' |
| | | import { |
| | | getProcessConfigFiles, |
| | | deleteProcessConfigFile, |
| | | downloadProcessConfigFile |
| | | } from '@/api/quality/attachment' |
| | | import { getIfsLocationByGroupCopyAll } from '@/api/warehouse/location' |
| | | import { remote } from '@/api/admin/dict' |
| | | import qrCodeApp from '@/views/common/qrCodeApp' |
| | | import { getStore } from '@/util/store' |
| | | export default { |
| | | components:{ |
| | | qrCodeApp |
| | | }, |
| | | data() { |
| | | return { |
| | | progrecessFileLoading: false, |
| | | processConfigFileTableData: [], |
| | | headers: { |
| | | Authorization: 'Bearer ' + getStore({ name: 'access_token' }) |
| | | }, |
| | | paramData: { |
| | | no: '', |
| | | lineNumber: '', |
| | | type: 1, |
| | | }, |
| | | row: null, |
| | | proIndex: 0, |
| | | deviceCode: false, |
| | |
| | | this.init() |
| | | }, |
| | | methods: { |
| | | delProcessConfigFile(row) { |
| | | this.$confirm('是否删除该附件', '提示', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | | type: 'warning', |
| | | closeOnClickModal: false |
| | | }).then(function() { |
| | | return deleteProcessConfigFile(row.id) |
| | | }).then((data) => { |
| | | this.getConfigFiles() |
| | | }) |
| | | }, |
| | | getConfigFiles() { |
| | | const param = { |
| | | no: this.processInspectVo.finInsNo, |
| | | lineNumber: this.processInspectVo.id, |
| | | type: 1 |
| | | } |
| | | getProcessConfigFiles(param).then((res) => { |
| | | this.processConfigFileTableData = res.data.data |
| | | }) |
| | | }, |
| | | downloadProcessConfigFile(row) { |
| | | downloadProcessConfigFile({ |
| | | bucket: row.bucketName, |
| | | fileName: row.fileName, |
| | | originalFileName: row.originalFileName |
| | | }) |
| | | }, |
| | | submitUpload() { |
| | | this.paramData.no = this.processInspectVo.finInsNo |
| | | this.paramData.lineNumber = this.processInspectVo.id |
| | | this.progrecessFileLoading = true |
| | | }, |
| | | uploadSuccess() { |
| | | this.progrecessFileLoading = false |
| | | this.getConfigFiles() |
| | | }, |
| | | tabsClick(tab,even){ |
| | | if(tab.index == 1){ |
| | | this.getConfigFiles(); |
| | | } |
| | | }, |
| | | cancelDeviceCodeDialog(){ |
| | | this.deviceCode = false |
| | | }, |
| | |
| | | <style scoped> |
| | | .finishedProduct-detail { |
| | | width: 100%; |
| | | height: 500px; |
| | | height: 520px; |
| | | padding: 10px 20px; |
| | | display: flex; |
| | | border: 1px solid #ddd; |
| | | background-color: #fff; |
| | | margin-top: 10px; |
| | | box-sizing: border-box; |
| | | flex-wrap: wrap; |
| | | /* display: flex; |
| | | flex-wrap: wrap; */ |
| | | } |
| | | |
| | | basic.finishedProduct-result { |