许成详 6 years ago
parent
commit
0921e7f762

+ 2
- 2
config/index.js View File

12
     proxyTable: {
12
     proxyTable: {
13
       '/api': {
13
       '/api': {
14
         // target: 'https://dp.huiju360.com.cn/hj_operations',
14
         // target: 'https://dp.huiju360.com.cn/hj_operations',
15
-        target: 'http://192.168.0.62:8080', //wf
15
+        // target: 'http://192.168.0.62:8080', //wf
16
         // target: 'http://127.0.0.1:8080', 
16
         // target: 'http://127.0.0.1:8080', 
17
         // target: 'http://localhost:8080', //wf
17
         // target: 'http://localhost:8080', //wf
18
         // target: 'http://192.168.0.11', //ys
18
         // target: 'http://192.168.0.11', //ys
19
-        // target: 'http://192.168.0.125:8080', //hyq
19
+        target: 'http://192.168.0.125:8080', //hyq
20
         // target: 'http://dev.ycjcjy.com/', //frp
20
         // target: 'http://dev.ycjcjy.com/', //frp
21
         changeOrigin: true, // 如果接口跨域,需要进行这个参数配置
21
         changeOrigin: true, // 如果接口跨域,需要进行这个参数配置
22
         // pathRewrite: {
22
         // pathRewrite: {

+ 1
- 1
src/pages/system/cardAndCouponManager/cardManager/index.vue View File

91
               size="mini"
91
               size="mini"
92
               type="success"
92
               type="success"
93
               v-if="scope.row.SendType === 'channel'"
93
               v-if="scope.row.SendType === 'channel'"
94
-              v-clipboard:copy="clientUrl + '/receiveChannelShared/' + scope.row.CardId + '/card/receive'"
94
+              v-clipboard:copy="clientUrl + '/user.html#/receiveChannelShared/' + scope.row.CardId + '/card/receive'"
95
               v-clipboard:success="onCopy"
95
               v-clipboard:success="onCopy"
96
               v-clipboard:error="onError"
96
               v-clipboard:error="onError"
97
               >点击复制链接</el-button>
97
               >点击复制链接</el-button>

+ 1
- 1
src/pages/system/cardAndCouponManager/couponManager/index.vue View File

93
               size="mini"
93
               size="mini"
94
               type="success"
94
               type="success"
95
               v-if="scope.row.SendType === 'channel'"
95
               v-if="scope.row.SendType === 'channel'"
96
-              v-clipboard:copy="clientUrl + '/receiveChannelShared/' + scope.row.CouponId + '/coupon/receive'"
96
+              v-clipboard:copy="clientUrl + '/user.html#/receiveChannelShared/' + scope.row.CouponId + '/coupon/receive'"
97
               v-clipboard:success="onCopy"
97
               v-clipboard:success="onCopy"
98
               v-clipboard:error="onError"
98
               v-clipboard:error="onError"
99
               >点击复制链接</el-button>
99
               >点击复制链接</el-button>

+ 3
- 3
src/pages/system/cmsManager/bannerManager/add.vue View File

164
           })
164
           })
165
           return false
165
           return false
166
         } else {
166
         } else {
167
-          var reg = /[A-Za-z0-9-_]+\\.[A-Za-z0-9-_%&\?\/.=]+$/  // eslint-disable-line
168
-          if (!reg.test(this.postData.ForwardUrl)) {
167
+          var strRegex = '^((https|http|ftp|rtsp|mms)://)?[a-z0-9A-Z]{3}\.[a-z0-9A-Z][a-z0-9A-Z]{0,61}?[a-z0-9A-Z]\.com|net|cn|cc (:s[0-9]{1-4})?/$'  // eslint-disable-line
168
+          var re = new RegExp(strRegex)
169
+          if (!re.test(this.postData.ForwardUrl)) {
169
             this.$message({
170
             this.$message({
170
               message: '链接地址格式不正确',
171
               message: '链接地址格式不正确',
171
               type: 'error',
172
               type: 'error',
198
         return false
199
         return false
199
       }
200
       }
200
       this.postData.OrgId = this.OrgId
201
       this.postData.OrgId = this.OrgId
201
-      // this.ForwardType === '1' ? this.postData.ForwardType = 'url' : this.postData.ForwardType = 'course'
202
       this.$ajax(this.$api.cms.addImage.url, {
202
       this.$ajax(this.$api.cms.addImage.url, {
203
         method: this.$api.cms.addImage.method,
203
         method: this.$api.cms.addImage.method,
204
         data: this.postData
204
         data: this.postData

+ 3
- 2
src/pages/system/cmsManager/bannerManager/edit.vue View File

153
           })
153
           })
154
           return false
154
           return false
155
         } else {
155
         } else {
156
-          var reg = /[A-Za-z0-9-_]+\\.[A-Za-z0-9-_%&\?\/.=]+$/  // eslint-disable-line
157
-          if (!reg.test(this.postData.ForwardUrl)) {
156
+         var strRegex = '^((https|http|ftp|rtsp|mms)://)?[a-z0-9A-Z]{3}\.[a-z0-9A-Z][a-z0-9A-Z]{0,61}?[a-z0-9A-Z]\.com|net|cn|cc (:s[0-9]{1-4})?/$'  // eslint-disable-line
157
+          var re = new RegExp(strRegex)
158
+          if (!re.test(this.postData.ForwardUrl)) {
158
             this.$message({
159
             this.$message({
159
               message: '链接地址格式不正确',
160
               message: '链接地址格式不正确',
160
               type: 'error',
161
               type: 'error',

+ 25
- 14
src/pages/system/dashboard/index.vue View File

47
 import ringChart from '../../../components/ringChart/index'
47
 import ringChart from '../../../components/ringChart/index'
48
 import dashboard from '../../../components/dashboard/index'
48
 import dashboard from '../../../components/dashboard/index'
49
 import brokenLineGraphGroup from '../../../components/brokenLineGraphGroup/index'
49
 import brokenLineGraphGroup from '../../../components/brokenLineGraphGroup/index'
50
+
50
 const { mapActions: mapStaActions } = createNamespacedHelpers('sta')
51
 const { mapActions: mapStaActions } = createNamespacedHelpers('sta')
51
 
52
 
52
 export default {
53
 export default {
94
     }),
95
     }),
95
     CaseId: {
96
     CaseId: {
96
       get () {
97
       get () {
97
-        return this.postData.caseid || this.defaultCaseId
98
+        return this.postData.caseid || this.defaultCaseId || this.cases[0].CaseId
98
       },
99
       },
99
       set (val) {
100
       set (val) {
100
         this.postData.caseid = val
101
         this.postData.caseid = val
101
       }
102
       }
102
     }
103
     }
103
   },
104
   },
105
+  watch: {
106
+    defaultCaseId: function (val) {
107
+      if (!this.postData.caseid) {
108
+        this.postData.caseid = val
109
+      }
110
+      this.getData(val)
111
+      this.getBottomData(val, 'week')
112
+    },
113
+  },
104
   mounted () {
114
   mounted () {
105
     this.$nextTick(function () {
115
     this.$nextTick(function () {
106
-      console.log(this.defaultCaseId)
107
-      console.log(JSON.stringify(this.cases))
108
-      this.postData.caseid = this.postData.caseid || this.cases[0].CaseId
116
+    })
117
+  },
118
+  methods: {
119
+    ...mapStaActions([
120
+      'getDashboardData',
121
+      'getDashboardBottomData',
122
+    ]),
123
+    getData (id) {
109
       this.getDashboardData({
124
       this.getDashboardData({
110
-        caseid: this.postData.caseid
125
+        caseid: id
111
       }).then((res) => {
126
       }).then((res) => {
112
         console.log(JSON.stringify(res))
127
         console.log(JSON.stringify(res))
113
       })
128
       })
129
+    },
130
+    getBottomData (id, type) {
114
       this.getDashboardBottomData({
131
       this.getDashboardBottomData({
115
-        caseid: this.postData.caseid,
116
-        statype: 'week'
132
+        caseid: id,
133
+        statype: type
117
       }).then((res) => {
134
       }).then((res) => {
118
         console.log(JSON.stringify(res))
135
         console.log(JSON.stringify(res))
119
       })
136
       })
120
-    })
121
-  },
122
-  methods: {
123
-    ...mapStaActions([
124
-      'getDashboardData',
125
-      'getDashboardBottomData',
126
-    ]),
137
+    },
127
   }
138
   }
128
 }
139
 }
129
 </script>
140
 </script>