浏览代码

0507lhj修改

liuhj 1 年之前
父节点
当前提交
27d7d452fc
共有 1 个文件被更改,包括 7 次插入5 次删除
  1. 7 5
      src/components/OP/DecreasePayments.vue

+ 7 - 5
src/components/OP/DecreasePayments.vue

@@ -127,16 +127,18 @@ export default {
                 }
             }).then(function (res) {
                 if (res.data.code == 200) {
-                    if(that.DiId==undefined){
+                    console.log(that.DiId)
+                    that.delegationInfoList = res.data.data.groupName;
+                    if(that.DiId!=that.DiId){
                         that.DiId = that.delegationInfoList[0].id;
                     }
-                    that.delegationInfoList = res.data.data.groupName;
-                    console.log(that.DiId)
                     that.delegationInfo = that.delegationInfoList[0];
                     that.DecreasePaymentsList()
+                }else{
+                    console.log("400")
                 }
             }).catch(function (error) {
-                that.$message.error("网络错误,请稍后重试");
+                that.$message.error(error);
             });
         },
         DecreasePaymentsChange() {
@@ -255,7 +257,7 @@ export default {
         }
     },
     mounted() {
-        this.DiId = JSON.parse(this.$route.query.DiId);
+        this.DiId = Number(this.$route.query.DiId);
         this.token = JSON.parse(localStorage.getItem('userinif')).token;
         this.userId = JSON.parse(localStorage.getItem('userinif')).userInfo.userId
         this.DecreasePaymentsSelect();