| | |
| | | <el-button @click="cancel">取 消</el-button> |
| | | </div> |
| | | </div> |
| | | <!-- 完结流程 --> |
| | | <div class="boxdiv" v-show="actives > 6"> |
| | | <h3>全部流程已完结!</h3> |
| | | </div> |
| | | </div> |
| | | <!-- 附件弹窗 --> |
| | | <el-dialog |
| | |
| | | type="card" |
| | | @tab-click="handleClick" |
| | | > |
| | | <el-tab-pane label="潜在捐献" :name="1"> </el-tab-pane> |
| | | <el-tab-pane label="医学评估" :name="2"> </el-tab-pane> |
| | | <el-tab-pane :label="activetele" :name="1"> </el-tab-pane> |
| | | <!-- <el-tab-pane label="医学评估" :name="2"> </el-tab-pane> |
| | | <el-tab-pane label="捐献确认" :name="3"> </el-tab-pane> |
| | | <el-tab-pane label="伦理审查" :name="4"> </el-tab-pane> |
| | | <el-tab-pane label="完成登记" :name="7"> </el-tab-pane> |
| | | <el-tab-pane label="完成登记" :name="7"> </el-tab-pane> --> |
| | | </el-tabs> |
| | | <div class="pdfimg"> |
| | | <div class="box-pdf"> |
| | |
| | | registerlist: [], //完成附件 |
| | | fileList: [], |
| | | fileListto: [], |
| | | donatelist: [], //总 |
| | | activetele:'潜在捐献', |
| | | //上传附件路径 |
| | | uploadFileUrl: process.env.VUE_APP_BASE_API + "/common/upload", |
| | | //文件上传token |
| | |
| | | }; |
| | | }, |
| | | |
| | | created() { |
| | | this.infoid = this.$route.query.id; |
| | | }, |
| | | mounted() { |
| | | // this.id = this.$route.query.id; |
| | | this.Getbasicinformation(); |
| | |
| | | }, |
| | | |
| | | methods: { |
| | | // 获取主表数据 |
| | | // 获取主表及附属数据 |
| | | Getbasicinformation() { |
| | | // 左侧流程数据 |
| | | getDonatebaseinfoflow(this.infoid).then(res => { |
| | |
| | | this.residenceAddresss.qu = response.data.residencetownname; |
| | | this.registerAddresss.qu = response.data.registertownname; |
| | | }); |
| | | // 获取二级表 |
| | | this.GetAttacheddata(); |
| | | }, |
| | | // 获取二级表数据 |
| | | GetAttacheddata() { |
| | | let searchParam = { |
| | | infoid: this.form.id |
| | | infoid: this.infoid |
| | | }; |
| | | if (this.actives == 1) { |
| | | this.annexfilesList = this.medicinelist; |
| | | this.activetele="医学评估"; |
| | | listMedicalevaluation(searchParam).then(response => { |
| | | if (response.code == 200 && response.rows[0]) { |
| | | this.medicineform = response.rows[0]; |
| | |
| | | }); |
| | | } else if (this.actives == 2) { |
| | | this.annexfilesList = this.affirmlist; |
| | | this.activetele="捐献确认"; |
| | | listRelativesconfirmation(searchParam).then(response => { |
| | | if (response.code == 200 && response.rows[0]) { |
| | | this.affirmform = response.rows[0]; |
| | |
| | | }); |
| | | } else if (this.actives == 3) { |
| | | this.annexfilesList = this.ethiclist; |
| | | this.activetele="伦理审查"; |
| | | |
| | | listDonateflowchart(searchParam).then(response => { |
| | | if (response.code == 200 && response.rows.length == 1) { |
| | |
| | | if (response.code == 200) { |
| | | if (response.data) { |
| | | this.witnessform = response.data; |
| | | this.witnessform.infoid = this.form.id; |
| | | this.witnessform.infoid = this.infoid; |
| | | } |
| | | } else { |
| | | this.$modal.msgError( |
| | |
| | | }); |
| | | } else if (this.actives == 6) { |
| | | this.annexfilesList = this.registerlist; |
| | | this.activetele="完成登记"; |
| | | |
| | | let accpre = { |
| | | id: searchParam.infoid |
| | | }; |
| | | listnewDonatecompletioninfo(accpre).then(response => { |
| | | if (response.code == 200 && response.rows.length) { |
| | | this.accomplishform = response.rows[0]; |
| | | this.accomplishform.infoid = this.form.id; |
| | | this.accomplishform.infoid = this.infoid; |
| | | } else { |
| | | this.$modal.msgError("完成登记失败:" + JSON.stringify(response)); |
| | | } |
| | | }); |
| | | } else if (this.actives == 0) { |
| | | this.annexfilesList = this.registerlist; |
| | | this.activetele="潜在捐献"; |
| | | |
| | | } |
| | | }, |
| | | /** 保存主表按钮 */ |
| | |
| | | } |
| | | |
| | | if (this.form.id != null) { |
| | | if (this.form.workflow == 0) { |
| | | this.form.workflow = 1; |
| | | } |
| | | updateDonatebaseinfo(this.form).then(response => { |
| | | this.$modal.msgSuccess("保存成功"); |
| | | Modifydonationattachment(this.donatelist).then(res => { |
| | | console.log(res); |
| | | }); |
| | | this.Getbasicinformation(); |
| | | this.Processvalidation(); |
| | | // this.Processvalidation(); |
| | | this.open = false; |
| | | }); |
| | | } else { |
| | |
| | | addDonatebaseinfo(this.form).then(response => { |
| | | if (response.code == 200) { |
| | | this.$modal.msgSuccess("新增成功"); |
| | | Modifydonationattachment(this.donatelist).then(res => { |
| | | console.log(res); |
| | | }); |
| | | this.Getbasicinformation(); |
| | | this.Processvalidation(); |
| | | // this.Processvalidation(); |
| | | this.open = false; |
| | | } else { |
| | | this.$modal.msgError("新增失败:" + response.msg); |
| | |
| | | Savethedetails() { |
| | | console.log(this.actives); |
| | | if (this.actives == 1) { |
| | | this.medicineform.infoid = this.form.id; |
| | | this.medicineform.infoid = this.infoid; |
| | | this.$refs["medicineform"].validate(valid => { |
| | | if (valid) { |
| | | if (this.medicineform.id != null) { |
| | |
| | | this.$modal.msgSuccess("医学评估信息新增成功"); |
| | | }); |
| | | } |
| | | this.submitForm(); |
| | | this.Processvalidation(); |
| | | } |
| | | }); |
| | | } else if (this.actives == 2) { |
| | | this.affirmform.infoid = this.form.id; |
| | | this.affirmform.infoid = this.infoid; |
| | | this.$refs["affirmform"].validate(valid => { |
| | | if (valid) { |
| | | if (this.affirmform.id != null) { |
| | |
| | | this.$modal.msgSuccess("捐献确认信息新增成功"); |
| | | }); |
| | | } |
| | | this.submitForm(); |
| | | this.Processvalidation(); |
| | | } |
| | | }); |
| | | } else if (this.actives == 3) { |
| | | this.ethicform.infoid = this.form.id; |
| | | this.ethicform.infoid = this.infoid; |
| | | this.$refs["ethicform"].validate(valid => { |
| | | if (valid) { |
| | | if (this.ethicform.id != null) { |
| | |
| | | this.$modal.msgSuccess("伦理审查信息新增成功"); |
| | | }); |
| | | } |
| | | this.submitForm(); |
| | | this.Processvalidation(); |
| | | } |
| | | }); |
| | | } else if (this.actives == 4) { |
| | | this.allocationform.infoid = this.form.id; |
| | | this.allocationform.infoid = this.infoid; |
| | | this.$refs["allocationform"].validate(valid => { |
| | | if (valid) { |
| | | let arrallo = []; |
| | |
| | | this.$modal.msgSuccess("器官捐献信息新增成功"); |
| | | }); |
| | | } |
| | | this.submitForm(); |
| | | this.Processvalidation(); |
| | | } |
| | | }); |
| | | } else if (this.actives == 5) { |
| | | this.witnessform.infoid = this.form.id; |
| | | this.witnessform.infoid = this.infoid; |
| | | this.$refs["witnessform"].validate(valid => { |
| | | let coordinatedusernameIndex = this.coordinatorlist1.findIndex( |
| | | item => this.witnessform.coordinateduserido == item.reportNo |
| | |
| | | this.$modal.msgSuccess("获取见证信息新增成功"); |
| | | }); |
| | | } |
| | | this.submitForm(); |
| | | this.Processvalidation(); |
| | | } |
| | | }); |
| | | } else if (this.actives == 6) { |
| | | this.accomplishform.infoid = this.form.id; |
| | | this.accomplishform.infoid = this.infoid; |
| | | this.$refs["accomplishform"].validate(valid => { |
| | | if (valid) { |
| | | if (this.accomplishform.id) { |
| | |
| | | this.$modal.msgSuccess("完成登记成功"); |
| | | }); |
| | | } |
| | | this.submitForm(); |
| | | this.Processvalidation(); |
| | | } |
| | | }); |
| | | } |
| | |
| | | on_click(e) { |
| | | console.log(e); |
| | | // if (e != "" || e != null) { |
| | | this.actives = e; |
| | | if (this.form.workflow >= e) { |
| | | this.actives = e; |
| | | this.Processvalidation(e); |
| | | } else { |
| | | this.$modal.msgWarning("请先完成前部步骤"); |
| | | } |
| | | // } |
| | | this.Processvalidation(); |
| | | }, |
| | | // 器官分配栏目控制 |
| | | changeorganState(value) { |
| | |
| | | organname: temporganname, |
| | | organno: value, |
| | | id: null, |
| | | infoid: this.form.id, |
| | | infoid: this.infoid, |
| | | donorno: this.form.donorno, |
| | | transplanthospitalname: null, |
| | | transplanthospitalno: null, |
| | |
| | | this.$modal.msgSuccess("删除成功"); |
| | | }); |
| | | } else { |
| | | this.allocationform.splice(deleteIndex, 1); |
| | | this.allocationform.splice(organIndex, 1); |
| | | } |
| | | } |
| | | }) |
| | |
| | | console.log(this.actives); |
| | | if (this.form.workflow == this.actives) { |
| | | this.form.workflow++; |
| | | this.GetAttacheddata(); |
| | | this.submitForm(); |
| | | // this.GetAttacheddata(); |
| | | } else if (this.form.workflow > this.actives) { |
| | | // this.submitForm(); |
| | | this.GetAttacheddata(); |
| | | } else { |
| | | this.$modal.msgWarning("请先完成前部步骤"); |
| | |
| | | this.registerlist = arr; |
| | | } |
| | | // 删除时修改主列delFlag |
| | | console.log(delvalue); |
| | | const index = this.donatelist.indexOf(delvalue); |
| | | console.log(index); |
| | | if (index !== -1) { |
| | | if (delvalue.id) { |
| | | this.donatelist[index].delFlag = 1; |
| | | console.log("修改老数据后", this.donatelist); |
| | | } else { |
| | | this.donatelist.splice(index, 1); |
| | | console.log("删除新数据后", this.donatelist); |
| | | } |
| | | } else { |
| | | console.log("查询不到可能是新数据无id"); |
| | |
| | | // 新增时修改主列 |
| | | if (addvalue.annexurl) { |
| | | this.donatelist.push(addvalue); |
| | | console.log("新增后", this.donatelist); |
| | | } |
| | | }, |
| | | //文件上传 |
| | |
| | | // this.form.filename = file.raw.name; |
| | | this.previewpdf = true; |
| | | this.$modal.msgSuccess(response.msg); |
| | | this.fileListto.push({ |
| | | let addvalue = { |
| | | annexname: file.name, |
| | | annexurl: response.fileName |
| | | }); |
| | | annexurl: response.fileName, |
| | | delFlag: 0, |
| | | infoid: this.infoid, |
| | | annexfilestype: this.actives |
| | | }; |
| | | this.fileListto.push(addvalue); |
| | | this.Newconversion(this.fileListto, "", addvalue); |
| | | this.pdfimgsrcList.push( |
| | | this.Networkheader + "/prod-api" + response.fileName |
| | | ); |
| | |
| | | ); |
| | | this.pdfimgsrcList.splice(indexlist, 1); |
| | | const index = this.getIndexInArray(this.fileListto, row); |
| | | this.Newconversion(this.fileListto, this.fileListto[index], ""); |
| | | this.fileListto.splice(index, 1); |
| | | console.log(index); |
| | | }, |
| | | // 点击上移 |
| | | moveupdowfile(row) { |