duanshenglang 6 hónapja
szülő
commit
259fd801f4
1 módosított fájl, 14 hozzáadás és 3 törlés
  1. 14 3
      lottery/live_code.html

+ 14 - 3
lottery/live_code.html

@@ -321,9 +321,13 @@
         }).then(result => {
           let { data, code, msg } = result
           if (code === 1) {
-            this.step = 3
-            this.salesMan = data.salesMan
-            this.qrCode = data.qrCode 
+            if (data.qrCode) {
+              this.step = 3
+              this.salesMan = data.salesMan
+              this.qrCode = data.qrCode 
+            } else {
+              this.step = 1 
+            }
           } else {
             this.$message.error(msg)
             this.step = 1 
@@ -349,6 +353,13 @@
       },
       // 创建活码
       handleQrcode () {
+        if (!this.form.templateId) {
+          this.$message({
+            message: '请选择模板',
+            type: 'warning'
+          })
+          return false
+        }
         fetch(this.httpUrl + '/scrm/v1/wxcp-live-code-counselor/p/addByH5', {
           method: 'post',
           body: JSON.stringify({