Quellcode durchsuchen

排班新信息

zhaomin vor 3 Jahren
Ursprung
Commit
93110697f6

+ 6 - 13
CallCenterWeb.UI/RMYY/src/views/scheduleManagement/scheduleInfo/components/addAutoGroupClass.vue

@@ -127,12 +127,11 @@ export default {
127 127
               stime: this.ruleForm.workTime && this.ruleForm.workTime[0], // 开始时间
128 128
               endtime: this.ruleForm.workTime && this.ruleForm.workTime[1], // 结束时间
129 129
               classcode: this.ruleForm.classInf, // 班别代码
130
-              usercode: this.ruleForm.usercode, // 值班人员
130
+              usercode: this.getString(this.ruleForm.usercode), // 值班人员
131 131
               skipholidays: this.ruleForm.isSkipHoliday, // 是否跳过节假日
132 132
               rotationdays: this.ruleForm.beondutyDays, // 轮班天数
133 133
               type: this.ruleForm.beondutyType // 值班方式
134 134
             }
135
-            console.log(params)
136 135
             autoAddGroupClass(params).then((response) => {
137 136
               this.$parent.$layer.close(this.layerid)
138 137
               this.$parent.getBeOnDuty(this.stime, this.etime)
@@ -146,17 +145,11 @@ export default {
146 145
         }
147 146
       })
148 147
     },
149
-    // 获取详情
150
-    getDetail(blackid) {
151
-      getClassInf({ id: this.rowid }).then((response) => {
152
-        if (response.state.toLowerCase() === 'success') {
153
-          this.ruleForm.workStartTime = response.data.F_InTime
154
-          this.ruleForm.workOverTime = response.data.F_OutTime
155
-          this.ruleForm.name = response.data.F_Name
156
-          this.ruleForm.remark = response.data.F_Remark
157
-          this.ruleForm.code = response.data.F_Code
158
-        }
159
-      })
148
+    getString(string) {
149
+      const strings = string.toString()
150
+      const stringss = (strings.substring(strings.length - 1) == ',')
151
+        ? strings.substring(0, strings.length - 1) : strings
152
+      return stringss
160 153
     }
161 154
   }
162 155
 }

+ 8 - 1
CallCenterWeb.UI/RMYY/src/views/scheduleManagement/scheduleInfo/components/addGroupClass.vue

@@ -85,12 +85,13 @@ export default {
85 85
       })
86 86
     },
87 87
     submitForm() {
88
+      console.log(this.ruleForm.usercode)
88 89
       this.$refs.ruleForm.validate((valid) => {
89 90
         if (valid) {
90 91
           return new Promise((resolve) => {
91 92
             const params = {
92 93
               date: this.dataTime, //
93
-              usercode: this.ruleForm.usercode, //
94
+              usercode: this.getString(this.ruleForm.usercode), //
94 95
               classcode: this.ruleForm.classInf,
95 96
               id: '0'
96 97
             }
@@ -106,6 +107,12 @@ export default {
106 107
           })
107 108
         }
108 109
       })
110
+    },
111
+    getString(string) {
112
+      const strings = string.toString()
113
+      const stringss = (strings.substring(strings.length - 1) == ',')
114
+        ? strings.substring(0, strings.length - 1) : strings
115
+      return stringss
109 116
     }
110 117
   }
111 118
 }