shengbingg 2 лет назад
Родитель
Сommit
9711543a82

+ 6 - 1
src/config/dev.js

@@ -7,15 +7,20 @@ let devs = {
     provincialWorkOrderAreafresourceId:'a682dc9f-2fea-11ed-a6ed-02427ba2d388',//通用工单地市
     provincialWorkOrderfresourceId:'08368848-2fde-11ed-a6ed-02427ba2d388',//通用工单省
     riskMaterialsfresourceId:'c9104902-6575-11ed-8e1e-d6cd97160e00',//风险防控
+    materialApplicationfresourceId:'6cc2a037-a750-11ed-886f-d6cd97160e00',//宣传物料省
+    materialApplicationdsfresourceId:'241efa62-a816-11ed-886f-d6cd97160e00',//宣传物料地市
 }
 let dev = {
     TITLE:'本地环境',
-    BASE_URL:"http://192.168.2.188:8080", //本地环境
+    BASE_URL:"http://127.0.0.1:8080", //本地环境
     BASE_API:"http://43.138.50.94:8880/api",//工作流本地环境
     EXCEL_URL:"http://43.138.50.94:7777", //本地excel路径
     provincialWorkOrderAreafresourceId:'a682dc9f-2fea-11ed-a6ed-02427ba2d388',//通用工单地市
     provincialWorkOrderfresourceId:'08368848-2fde-11ed-a6ed-02427ba2d388',//通用工单省
     riskMaterialsfresourceId:'c9104902-6575-11ed-8e1e-d6cd97160e00',//风险防控
+    materialApplicationfresourceId:'6cc2a037-a750-11ed-886f-d6cd97160e00',//宣传物料省
+    materialApplicationdsfresourceId:'241efa62-a816-11ed-886f-d6cd97160e00',//宣传物料地市
+
 }
 let test = {
     TITLE:'测试环境',

+ 2 - 2
src/pages/main/advertising/index.vue

@@ -21,11 +21,11 @@
 			<div class="adv-type">
 				 <div class="wfour" @click="jumpinfo('/materialApplication','宣传物料申请及审批-省代地市下单')">
 			        <span><i class="el-icon-folder-opened"></i></span>
-			        <span>宣传物料申请及审批-省代地市下单</span>
+			        <span>宣传物料申请及审批-省公司发起</span>
 			    </div>
 				 <div class="wfour" @click="jumpinfo('/materialApplicationds','宣传物料申请及审批-地市下单')">
 			        <span><i class="el-icon-folder-opened"></i></span>
-			        <span>宣传物料申请及审批-地市下单</span>
+			        <span>宣传物料申请及审批-地市发起</span>
 			    </div>
 				<!-- <div class="wfour" @click="jumpinfo('/materialApplicationc','市级物料申请')">
 				        <span><i class="el-icon-folder-opened"></i></span>

+ 6 - 5
src/pages/main/advertising/materialApplication.vue

@@ -310,7 +310,7 @@
                       </div>
                     </template> -->
                   </el-table-column>
-                   <el-table-column label="操作"  fixed="right" align="center" v-if="this.infolist.tabletaskName == '起草'">
+                   <el-table-column label="操作"  fixed="right" align="center" v-if="this.infolist.tabletaskName == '起草' || this.infolist.tabletaskName == '地市宣传负责人'">
                                 <template slot-scope="scope">
                                     <el-button size="mini" type="text" @click="updatexiuform(scope.row)"  :disabled="xiugaizhuan">
                                         修改</el-button>
@@ -1176,7 +1176,7 @@
 
         this.operationZuo(r); //点标题
          
-         if(r.taskname == "起草"){
+         if(r.taskname == "起草" || r.taskname == "地市宣传负责人"){
           this.deal = true;
          }else{
           this.deal = false;
@@ -1219,13 +1219,14 @@
             this.infolist.gys = res.data.xcwlProProcessList[0].selectedGys;
             this.infolist.districtScore = res.data.xcwlProProcessList[0].districtScore;
             this.infolist.materialUrl = res.data.xcwlProProcessList[0].materialUrl;
-            if(r.taskName != "起草"){
+            this.infolist.id1 = res.data.xcwlProProcessList[0].xcwlId;
+            if(r.taskName != "起草" ||r.taskName != "地市宣传负责人"){
               this.disableStatus = true;
                this.updisabled = true;  //上传附件
             }else{
               this.updisabled = false;
             }
-             if(this.infolist.tabletaskName === "起草" || this.infolist.tabletaskName === "省公司宣传负责人" || this.infolist.tabletaskName === "区县公司负责人"){
+             if(this.infolist.tabletaskName === "起草" || this.infolist.tabletaskName === "省公司宣传负责人" || this.infolist.tabletaskName === "区县公司负责人" ||this.infolist.tabletaskName === "地市宣传负责人"){
             
             this.baocun = true;
             
@@ -1675,7 +1676,7 @@
           if (valid) {
                this.$message.success("保存成功");
               let list = {}
-              list.id = this.infolist.id;
+              list.id = this.infolist.id1;
               list.businessName = this.infolist.businessName;//业务名称
               list.cycleList = [this.$util.datetimeFormat(this.infolist.cycle[0]),this.$util.datetimeFormat(this.infolist.cycle[1])];
               list.needCode = this.infolist.needCode;

+ 46 - 8
src/pages/main/advertising/materialApplicationadd.vue

@@ -139,12 +139,15 @@
 
           <div style="width: 100%">
             <div>
+              <el-form-item label="附件:"  prop="wfFileShareAttachList" class="info-line online1">
               <myUpload
                 @uploadBack="uploadBack"
                 :fileInfo="fileInfo"
                 :fileList="fileInfo.fileList"
+                style="width: 100% ;height: 120px !important"
               >
               </myUpload>
+               </el-form-item>
             </div>
           </div>
         </div>
@@ -499,7 +502,19 @@ export default {
       ruless: {
         cycle: [{type: "array",required: true,trigger: "blur",message: "下单周期不能为空"}],
         needCode: [{required: true,trigger: "blur",message: "需求编号不能为空"}],
-        businessName: [{required: true,trigger: "blur",message: "业务名称不能为空"}],},
+        businessName: [{required: true,trigger: "blur",message: "业务名称不能为空"}],
+        // wfFileShareAttachList:[
+        //                 { required: true, validator: this.validatormk, trigger: "blur"},
+        //               ],
+        },
+         rulesss: {
+        cycle: [{type: "array",required: true,trigger: "blur",message: "下单周期不能为空"}],
+        needCode: [{required: true,trigger: "blur",message: "需求编号不能为空"}],
+        businessName: [{required: true,trigger: "blur",message: "业务名称不能为空"}],
+        wfFileShareAttachList:[
+                        { required: true, validator: this.validatormk, trigger: "blur"},
+                      ],
+        },
       rules: {
         useCase: [{required: true,trigger: "change",message: "请选择使用场景"}],
         formType: [{required: true,trigger: "change",message: "请选择表单类型"}],
@@ -514,7 +529,7 @@ export default {
       tableData: [{}],
       disableStatus: false,
       infolist: {},
-      needCode: "",
+      // needCode: "",
       pickerOptions0: {
         disabledDate(time) {
           return time.getTime() < Date.now() - 8.64e7; //如果没有后面的-8.64e7就是不可以选择今天的
@@ -674,6 +689,7 @@ export default {
       }).then((res) => {
        
         this.infolist.needCode = res.data;
+        console.log(this.infolist.needCode);
       });
     },
     //后台返部门
@@ -695,6 +711,15 @@ export default {
    
       this.multipleSelection = val;
     },
+      validatormk(rule,value,callback){
+      // console.log(this.ruleForm.wfFileShareAttachList)
+      if(this.infolist.wfFileShareAttachList == null){
+         console.log(111);
+        callback(new Error('请上传附件'));
+      }else{
+        callback();
+      }
+    },
     //物料名称联动
     changeMing(v,ev){
       if(v == 1){
@@ -1352,7 +1377,8 @@ export default {
     },
     uploadBack(v) {
       this.attList = v;
-      // console.log(this.attList);
+      this.infolist.wfFileShareAttachList = v;
+      console.log(this.infolist.wfFileShareAttachList);
 
     },
    
@@ -1419,11 +1445,17 @@ export default {
     this.getTermianl();
     this.getUser();
     this.getList();
-    this.getNeedCode();
+    
   },
   created() {
+    this.getNeedCode();
+    // console.log(this.infolist.needCode);
   //  console.log(this.$route.query); 
-  //  console.log(this.$route.query.applyType); 
+   console.log(this.$route.query.applyType);
+    if(this.$route.query.applyType == "地市"){
+      // this.ruless = { ...this.ruless, ...rulesss }
+      this.ruless = this.rulesss
+    }
     this.getDept();
   },
 };
@@ -1478,7 +1510,7 @@ export default {
     border-radius: 3px;
     background: #fff;
     position: relative;
-    height: 100px;
+    height: 150px;
 
     img {
       width: 100%;
@@ -1617,13 +1649,19 @@ export default {
   }
 }
 ::v-deep.online .el-form-item__content {
-  width: 98%;
+  width: 100%;
   margin-left: 0 !important;
+  line-height: 28px;
+}
+::v-deep.online1 .el-form-item__content {
+  width: 100%;
+  margin-left: 0 !important;
+  line-height: 28px;
 }
-
 ::v-deep.el-upload {
   width: 98% !important;
   padding: 0 !important;
+  height: 150% !important;
 }
 .el-row {
   margin: 0 !important;

+ 17 - 6
src/pages/main/advertising/materialApplicationds.vue

@@ -346,6 +346,7 @@
 
           <div style="width: 96%; margin:20px 0 0 38px">
             <div>
+              
               <myUpload
                 @uploadBack="uploadBack"
                 @clickDownload = "download"
@@ -354,6 +355,7 @@
                 :fileList="fileInfo.fileList"
               >
               </myUpload>
+              
             </div>
           </div>
         </div>
@@ -972,10 +974,6 @@
                     cycle: [{type: "array",required: true,trigger: "blur",message: "下单周期不能为空"}],
                     needCode: [{required: true,trigger: "blur",message: "需求编号不能为空"}],
                     businessName: [{required: true,trigger: "blur",message: "业务名称不能为空"}],
-                    // districtScore: [{required: true,trigger: "blur",message: "区县打分不能为空"}],
-                    // gys: [{required: true,trigger: "change",message: "请选择供应商"}],
-                    // materialUrl: [{required: true,trigger: "blur",message: "物料验证材料链接不能为空"}],
-
                 },
                 childname:"first",
                 tooltit:'物料申请管理',
@@ -1001,6 +999,7 @@
                 deal: true,
                 baocun: true,
                 rulelist:[],
+                wfFileShareAttachList:[],
                 teshuhuanjie: [],
                 isWorkflowStatus:false,
                 titname: '',
@@ -1208,10 +1207,22 @@
           });
         },
          uploadBack(v) {
+
           this.attList = v;
+          this.ruleForm.wfFileShareAttachList = v;
+          console.log(this.ruleForm.wfFileShareAttachList);
           // console.log(this.attList);
 
     },
+     validatormk(rule,value,callback){
+      console.log(this.ruleForm.wfFileShareAttachList)
+      if(this.ruleForm.wfFileShareAttachList == null){
+         console.log(111);
+        callback(new Error('请上传附件'));
+      }else{
+        callback();
+      }
+    },
     gysMing(n,ev){
         let that = this;
            
@@ -1956,8 +1967,8 @@
             },
             //文件返回值
             uploadBack(v) {
-            
-                this.attList = v;
+            this.attList = v;
+            this.ruleForm.wfFileShareAttachList = v;    
             },
             //功能栏
             iconCli(v) {