Selaa lähdekoodia

个贷新增简易预评模版生成

wucl 1 kuukausi sitten
vanhempi
commit
5cf5d0e6d1

+ 3 - 0
src/api/modules/personal.js

@@ -60,4 +60,7 @@ export default {
   getDataCount(params){
     return request.get(`personal/count`, { params: params })
   },
+  updateCustomerFullName(params1,params2){
+    return request.post(`personal/customer/fullName?id=${params1}&fullName=${params2}`,)
+  }
 }

+ 3 - 0
src/api/modules/personalScene.js

@@ -9,5 +9,8 @@ export default {
   getScene(params){
     return request.get(`personalScene/${params}`)
   },
+  updateScene(params){
+    return request.put(`personalScene`, params)
+  }
 
 }

+ 1 - 0
src/components/personalForms/sellingAbilityInfo.vue

@@ -356,6 +356,7 @@ export default {
       this.outwardStaffs.forEach(element => {
         if (element.id === this.sellingAbilityInfo.outStaffId) {
           this.sellingAbilityInfo.outStaffTelNo = element.mobile;
+          this.sellingAbilityInfo.outStaffName = element.name;
         }
       })
     },

+ 188 - 125
src/views/personal/todoDetail.vue

@@ -861,7 +861,8 @@
               <div class="control">
                 <el-button type="text" class="button" @click="doStamp(statementProd.files)"
                   :disabled="!statementProd.isOnline">加盖公章</el-button>
-                <el-button type="text" class="button" @click="genProductionFile(1)" >系统生成</el-button>
+                <el-button type="text" class="button" @click="genProductionFile(1)" >通用版</el-button>
+                <el-button type="text" class="button" @click="uploadSceneImagesDialog = true" >简易版</el-button>
                 <el-button type="text" class="button" @click="downloadDoc(statementProd.files)">下载</el-button>
               </div>
               <!-- <a href="#" @click.prevent="openPageoffice()">打开文件</a> -->
@@ -1104,6 +1105,90 @@
                 <el-button style="margin-top: 10px; float: right;" type="success" @click="commit('PASS')">确认</el-button>
             </div>
         </el-dialog>
+        <el-dialog  :visible.sync="uploadSceneImagesDialog" width="50%" center top="15vh" custom-class="doWarehouseClass">
+              <el-form>
+                <el-row>
+                  <el-col :xs="24" :sm="12" :lg="24" :span="6">
+                    <el-form-item label="银行客户全称:" prop="" label-width="150px" class="postInfo-container-item">
+                        <el-input v-model="sceneForm.personalSceneImage.customerFullName"></el-input>
+                    </el-form-item>
+                  </el-col>
+                </el-row>
+                <el-row>
+                <el-col :xs="24" :sm="12" :lg="12" :span="6">
+                  <el-form-item label="估价对象地图截图:" prop="" label-width="150px" class="postInfo-container-item">
+                    <el-upload
+                      class="upload-demo"
+                      action="/api/personalScene/upload/1"
+                      :on-exceed="handleExceed"
+                      :limit="1"
+                      :file-list="mapLocationImage"
+                      :on-remove="handleRemoveMapLocationImage"
+                      :on-success="uploadSuccess"
+                      list-type="picture"
+                      >
+                      <el-button size="small" type="text">点击上传</el-button>
+                    </el-upload>
+                  </el-form-item>
+                </el-col>
+                <el-col :xs="24" :sm="12" :lg="12" :span="6">
+                  <el-form-item label="估价对象楼栋图:" prop="" label-width="150px" class="postInfo-container-item">
+                    <el-upload
+                      class="upload-demo"
+                      action="/api/personalScene/upload/2"
+                      :on-exceed="handleExceed"
+                      :limit="1"
+                      :file-list="buildingImage"
+                      :on-remove="handleRemoveBuildingImage"
+                       :on-success="uploadSuccess"
+                       list-type="picture"
+                      >
+                      <el-button size="small" type="text">点击上传</el-button>
+                    </el-upload>
+                  </el-form-item>
+                </el-col>
+              </el-row>
+              <el-row>
+                <el-col :xs="24" :sm="12" :lg="12" :span="6">
+                  <el-form-item label="估价对象外景图:" prop="" label-width="150px" class="postInfo-container-item">
+                    <el-upload
+                      class="upload-demo"
+                      multiple
+                      :limit="6"
+                      action="/api/personalScene/upload/3"
+                      :on-exceed="handleExceed6"
+                      :file-list="outterViewImages"
+                      :on-remove="handleRmoveOutterViewImages"
+                      :on-success="uploadSuccess"
+                      list-type="picture"
+                      >
+                      <el-button size="small" type="text">点击上传</el-button>
+                    </el-upload>
+                  </el-form-item>
+                </el-col>
+                <el-col :xs="24" :sm="12" :lg="12" :span="6">
+                  <el-form-item label="估价对象内景图:" prop="" label-width="150px" class="postInfo-container-item">
+                    <el-upload
+                      class="upload-demo"
+                      multiple
+                      :limit="6"
+                      action="/api/personalScene/upload/4"
+                      :on-exceed="handleExceed6"
+                      :file-list="innerViewImages"
+                      :on-remove="handleRmoveInnerViewImages"
+                      :on-success="uploadSuccess"
+                      list-type="picture">
+                      <el-button type="text" size="small">点击上传</el-button>
+                    </el-upload>
+                  </el-form-item>
+                </el-col>
+              </el-row>
+              </el-form>
+            <div style="display: flex;">
+                <el-button style="margin-left: 43%; margin-top: 10px;" type="info" @click="this.checkerDialog=false">取消</el-button>
+                <el-button style="margin-top: 10px; float: right;" type="success" @click="saveSceneImages()">确认</el-button>
+            </div>
+        </el-dialog>
   </div>
 </template>
 <script>
@@ -1627,7 +1712,24 @@ export default {
         outRingDewlling: null,
         inRingBuilding: null,
         outRingBuilding: null,
-        remark: null
+        remark: null,
+        personalSceneImage:{
+          customerFullName:null,
+          mapLocationImage:null,
+          sceneImage1:null,
+          sceneImage2:null,
+          sceneImage3:null,
+          sceneImage4:null,
+          sceneImage5:null,
+          sceneImage6:null,
+          sceneImage7:null,
+          sceneImage8:null,
+          sceneImage9:null,
+          sceneImage10:null,
+          sceneImage11:null,
+          sceneImage12:null,
+          sceneImage13:null,
+        }
       },
       houseShow: false,
       immovalbeShow: false,
@@ -1639,8 +1741,13 @@ export default {
       checkers:[],
       decideProduction:false,
       checkStateFlag:false,
-      valueTiming:null
-
+      valueTiming:null,
+      uploadSceneImagesDialog:false,
+      mapLocationImage:[],
+      outterViewImages:[],
+      innerViewImages:[],
+      buildingImage:[],
+      
     }
   },
 
@@ -1807,126 +1914,6 @@ export default {
           case "GENERATE_STATEMENT":
           case "WRITE_REPORT":
           case "WRITE_LETTER":
-            // if (this.isOnline) {
-            //   let ok = true;
-            //   this.personal.credentials.forEach(item => {
-            //     if (item === 'HOUSE_CERTIFICATE' && !this.target.houseCertificate) {
-            //       this.$notify({
-            //         title: '提示',
-            //         message: '请先完成房产证信息录入再提交,否则请切换为线下流程。',
-            //         type: 'error',
-            //         duration: 2000
-            //       });
-            //       ok = false;
-                
-            //     }
-            //     if (item === 'LAND_CERTIFICATE' && !this.target.landCertificate) {
-            //       this.$notify({
-            //         title: '提示',
-            //         message: '请先完成国土证信息录入再提交,否则请切换为线下流程。',
-            //         type: 'error',
-            //         duration: 2000
-            //       });
-            //       ok = false;
-                
-            //     }
-            //     if (item === 'IMMOVABLE_CERTIFICATE' && !this.target.immovableCertificate) {
-            //       this.$notify({
-            //         title: '提示',
-            //         message: '请先完成不动产权证信息录入再提交,否则请切换为线下流程。',
-            //         type: 'error',
-            //         duration: 2000
-            //       });
-            //       ok = false;
-                
-            //     }
-            //   })
-            //   if (!ok){
-            //     verify.state = false;
-            //     callback(verify);
-            //     return;
-            //   }
-            //   if (this.compareList.calculateId==null || this.compareList.targetId==null){
-            //     this.$notify({
-            //       title: '提示',
-            //       message: '请先完成可比实例表。',
-            //       type: 'error',
-            //       duration: 2000
-            //     });
-            //     verify.state = false;
-            //     callback(verify);
-            //     return;
-            //   }
-            //   if (ok && nodeCode === 'GENERATE_STATEMENT' && (this.statementProd == null || this.statementProd.files.length === 0)) {
-            //     this.$notify({
-            //       title: '提示',
-            //       message: '请生成意见书,再提交流程',
-            //       type: 'error',
-            //       duration: 2000
-            //     });
-            //     verify.state = false;
-            //     callback(verify);
-            //     return;
-            //   }
-            //   if (ok && nodeCode === 'WRITE_REPORT' && (this.technicReportProd == null || this.technicReportProd.files.length === 0)) {
-            //     this.$notify({
-            //       title: '提示',
-            //       message: '请生成报告,再提交流程',
-            //       type: 'error',
-            //       duration: 2000
-            //     });
-            //     verify.state = false;
-            //     callback(verify);
-            //     return;
-            //   }
-            //   if (ok && nodeCode === 'WRITE_LETTER' && (this.letterReprotProd == null || this.letterReprotProd.files.length === 0)) {
-            //     this.$notify({
-            //       title: '提示',
-            //       message: '请生成复评函,再提交流程',
-            //       type: 'error',
-            //       duration: 2000
-            //     });
-            //     verify.state = false;
-            //     callback(verify);
-            //     return;
-            //   }
-              
-            // }
-            // else{
-            //   if (nodeCode === 'GENERATE_STATEMENT' && (this.statementProd == null || this.statementProd.files.length === 0)) {
-            //     this.$notify({
-            //       title: '提示',
-            //       message: '流程类型为下线请上传意见书,再提交流程',
-            //       type: 'error',
-            //       duration: 2000
-            //     });
-            //     verify.state = false;
-            //     callback(verify);
-            //     return;
-            //   }
-            //   if (nodeCode === 'WRITE_REPORT' && (this.technicReportProd == null || this.technicReportProd.files.length === 0)) {
-            //     this.$notify({
-            //       title: '提示',
-            //       message: '流程类型为下线请上传报告,再提交流程',
-            //       type: 'error',
-            //       duration: 2000
-            //     });
-            //     verify.state = false;
-            //     callback(verify);
-            //     return;
-            //   }
-            //   if (nodeCode === 'WRITE_LETTER' && (this.letterReprotProd == null || this.letterReprotProd.files.length === 0)) {
-            //     this.$notify({
-            //       title: '提示',
-            //       message: '流程类型为下线请上传复评函,再提交流程',
-            //       type: 'error',
-            //       duration: 2000
-            //     });
-            //     verify.state = false;
-            //     callback(verify);
-            //     return;
-            //   }
-            // }
             if (!verify.nextHandlerId ){
               this.checkerDialog = true;
               this.$api.user.postUserVOList("个贷审核岗").then(res => {
@@ -2226,6 +2213,7 @@ export default {
       this.decideProductionTypeDialog = false;
       this.commit("PASS");
     },
+
     genProductionFile(tag) {
       const certificates = this.personal.credentials
       for (let i in certificates) {
@@ -2347,7 +2335,10 @@ export default {
       }
     },
     handleExceed(files, fileList) {
-      this.$message(`当前限制选择 1个文件,本次选择了 ${files.length} 个文件`);
+      this.$message(`当前限制选择 1个文件.`);
+    },
+    handleExceed6(files, fileList) {
+      this.$message(`当前限制选择 6个文件.`);
     },
     handleAttachmentPreview(file) {
       // window.open(file.url)
@@ -2648,6 +2639,26 @@ export default {
       this.$api.personalScene.getScene(this.personalId).then(res => {
         if (res.code === 200 && res.data) {
           this.sceneForm = res.data;
+          this.mapLocationImage.push(this.sceneForm.personalSceneImage.mapLocationImage);
+          this.buildingImage.push(this.sceneForm.personalSceneImage.sceneImage1);
+          this.outterViewImages.push(this.sceneForm.personalSceneImage.sceneImage2);
+          this.outterViewImages.push(this.sceneForm.personalSceneImage.sceneImage3);
+          this.outterViewImages.push(this.sceneForm.personalSceneImage.sceneImage4);
+          this.outterViewImages.push(this.sceneForm.personalSceneImage.sceneImage5);
+          this.outterViewImages.push(this.sceneForm.personalSceneImage.sceneImage6);
+          this.outterViewImages.push(this.sceneForm.personalSceneImage.sceneImage7);
+          this.innerViewImages.push(this.sceneForm.personalSceneImage.sceneImage8);
+          this.innerViewImages.push(this.sceneForm.personalSceneImage.sceneImage9);
+          this.innerViewImages.push(this.sceneForm.personalSceneImage.sceneImage10);
+          this.innerViewImages.push(this.sceneForm.personalSceneImage.sceneImage11);
+          this.innerViewImages.push(this.sceneForm.personalSceneImage.sceneImage12);
+          this.innerViewImages.push(this.sceneForm.personalSceneImage.sceneImage13);
+          this.mapLocationImage = this.mapLocationImage.filter(item=>item!=null);
+          this.buildingImage = this.buildingImage.filter(item=>item!=null);
+          this.outterViewImages = this.outterViewImages.filter(item=>item!=null);
+          this.innerViewImages = this.innerViewImages.filter(item=>item!=null);
+          console.log(this.outterViewImages)
+          console.log(this.innerViewImages)
         }
       })
     },
@@ -2827,6 +2838,58 @@ export default {
        //此处为了方便演示,我们传递了file_id和file_name两个参数,具体以您实际开发为准。
       POBrowser.openWindow('/admin/#/showDoc', 'width=1150px;height=900px;',paramString);
      },
+     handleRemoveMapLocationImage(file, fileList){
+      this.mapLocationImage = this.mapLocationImage.filter(item=>item.uid!=file.uid)
+     },
+     handleRemoveBuildingImage(file, fileList){
+      this.buildingImage = this.buildingImage.filter(item=>item.uid!=file.uid)
+     },
+     handleRmoveOutterViewImages(file, fileList){
+      this.outterViewImages = this.outterViewImages.filter(item=>item.uid!=file.uid)
+     },
+     handleRmoveInnerViewImages(file, fileList){
+      this.innerViewImages = this.innerViewImages.filter(item=>item.uid!=file.uid)
+     },
+     saveSceneImages(){
+        this.sceneForm.personalSceneImage.mapLocationImage = this.mapLocationImage.filter(item=>item!=null)[0];
+        this.sceneForm.personalSceneImage.sceneImage1 = this.buildingImage.filter(item=>item!=null)[0];
+        this.sceneForm.personalSceneImage.sceneImage2 = this.outterViewImages.filter(item=>item!=null)[0];
+        this.sceneForm.personalSceneImage.sceneImage3 = this.outterViewImages.filter(item=>item!=null)[1];
+        this.sceneForm.personalSceneImage.sceneImage4 = this.outterViewImages.filter(item=>item!=null)[2];
+        this.sceneForm.personalSceneImage.sceneImage5 = this.outterViewImages.filter(item=>item!=null)[3];
+        this.sceneForm.personalSceneImage.sceneImage6 = this.outterViewImages.filter(item=>item!=null)[4];
+        this.sceneForm.personalSceneImage.sceneImage7 = this.outterViewImages.filter(item=>item!=null)[5];
+        this.sceneForm.personalSceneImage.sceneImage8 = this.innerViewImages.filter(item=>item!=null)[0];
+        this.sceneForm.personalSceneImage.sceneImage9 = this.innerViewImages.filter(item=>item!=null)[1];
+        this.sceneForm.personalSceneImage.sceneImage10 = this.innerViewImages.filter(item=>item!=null)[2];
+        this.sceneForm.personalSceneImage.sceneImage11 = this.innerViewImages.filter(item=>item!=null)[3];
+        this.sceneForm.personalSceneImage.sceneImage12 = this.innerViewImages.filter(item=>item!=null)[4];
+        this.sceneForm.personalSceneImage.sceneImage13 = this.innerViewImages.filter(item=>item!=null)[5];
+        this.$api.personalScene.updateScene(this.sceneForm).then(res=>{
+          if (res.code === 200 && res.data){
+              this.genProductionFile(4);
+          }
+        })
+     },
+     uploadSuccess(response, file, fileList){
+        let fileObj = new Object();
+        fileObj.name = file.name;
+        fileObj.url = response.data.url;
+        fileObj.uid = file.uid;
+        if (response.data.type===1){
+          this.mapLocationImage.push(fileObj)
+        }
+        if (response.data.type===2){
+          this.buildingImage.push(fileObj)
+        }
+        if (response.data.type===3){
+          this.outterViewImages.push(fileObj)
+        }
+        if (response.data.type===4){
+          this.innerViewImages.push(fileObj)
+        }
+        
+     }
   }
 }
 </script>