Ver código fonte

Merge remote-tracking branch 'origin/develop' into develop

maqingyang 11 meses atrás
pai
commit
357703e4a2
2 arquivos alterados com 23 adições e 9 exclusões
  1. 1 1
      src/views/system/business.vue
  2. 22 8
      src/views/system/businessInfo.vue

+ 1 - 1
src/views/system/business.vue

@@ -178,7 +178,7 @@ export default {
 
           }
       )
-     
+
     },
     toggleCollapse(){
       this.isCollapse = !this.isCollapse;

+ 22 - 8
src/views/system/businessInfo.vue

@@ -75,7 +75,7 @@
                 </el-descriptions-item>
                 <el-descriptions-item label="证件类型">
                   <p>
-                    {{this.customInfoData.idTypeCode }}
+                    {{this.idTypeName }}
                   </p>
                 </el-descriptions-item>
                 <el-descriptions-item label="证件号码">
@@ -112,7 +112,7 @@
   
               <div class="top_show" style="margin-top: 20px">
                 <span> 解析文件:</span>
-                <el-button size="small" class="el-icon-upload" type="primary" round style="position: absolute; right: 10%;" @click="add_file_show=true">上传</el-button>
+                <el-button size="small" class="el-icon-upload" type="primary" round style="position: absolute; right: 10%;" @click="fileUp()">上传</el-button>
                 <el-button size="small" class="el-icon-download" type="primary" round style="position: absolute; right: 1%;" @click="fileDown()">下载</el-button>
   
               </div>
@@ -284,7 +284,7 @@
   
         selectedAll:false,
         selectedAll2:false,
-  
+        idTypeName:"",
   
         reportFileData : [],
         reportFileData1 : [],
@@ -339,6 +339,8 @@
               {
                 if(res.data.custom_info){
                 this.customInfoData=res.data.custom_info;}
+                if(this.customInfoData.idTypeCode==10)
+                  this.idTypeName = "身份证"
               }
           )
       reportFileList(this.businessNum).then(
@@ -499,10 +501,22 @@
         // console.log(fileList)
       },
   
-  
+      fileUp: function (){
+        if(this.headInfId){
+        this.add_file_show=true}
+        else {
+          this.$alert("失败业务不进行上传文件操作");
+          return;
+        }
+      },
+
       // 文件下载
       fileDown: function (){
-        if (this.downSelected2.length+this.downSelected.length==0) {
+        if(!this.headInfId) {
+          this.$alert("失败业务不进行下载文件操作");
+          return;
+        }
+          if (this.downSelected2.length+this.downSelected.length==0) {
           this.$alert("请选择下载文件");
           return;
         }
@@ -558,8 +572,8 @@
   
       //1.2 上传方法具体实现重写
       upload(){
+
         let fd = new FormData();
-  
         this.fileList.forEach(item=>{
           //文件信息中raw才是真的文件
           fd.append("files",item.raw);
@@ -572,7 +586,7 @@
           else if(item.raw.name.toString().endsWith("xml")){
             this.fileNameXml = "1"
           }
-          else {
+          else if(this.model_type != "模型文件"){
             {
               this.$alert("请上传正确的文件类型");
               return;
@@ -589,7 +603,7 @@
             businessNum:this.businessNum,
           })
           console.log("模型类")
-  
+
           console.log(this.fileNameModel)
           if(this.model_type == "模型文件") {
             request.post('/up/uploadMod', fd).then(res => {