许成详 6 年前
父节点
当前提交
1ae3b4bee9

+ 1
- 1
dist/index.html 查看文件

1
-<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1"><link rel=stylesheet href=//at.alicdn.com/t/font_775069_dwqa9wy3lkh.css><title>城的空间后台管理系统</title><link href=./static/css/app.ca5c568553d422363d3de51590c1ce78.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.992319e39e0ff64940a3.js></script><script type=text/javascript src=./static/js/app.09d071b18239c91b0a7d.js></script></body></html>
1
+<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1"><link rel=stylesheet href=//at.alicdn.com/t/font_775069_dwqa9wy3lkh.css><title>城的空间后台管理系统</title><link href=./static/css/app.74e2f4a85378fd8f1cdc28df9fe4c4c3.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.992319e39e0ff64940a3.js></script><script type=text/javascript src=./static/js/app.40d79b6e7915c878f744.js></script></body></html>

+ 15
- 6
package-lock.json 查看文件

674
     "async-limiter": {
674
     "async-limiter": {
675
       "version": "1.0.0",
675
       "version": "1.0.0",
676
       "resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.0.tgz",
676
       "resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.0.tgz",
677
-      "integrity": "sha512-jp/uFnooOiO+L211eZOoSyzpOITMXx1rBITauYykG3BRYPu8h0UcxsPNB04RR5vo4Tyz3+ay17tR6JVf9qzYWg==",
678
-      "dev": true
677
+      "integrity": "sha512-jp/uFnooOiO+L211eZOoSyzpOITMXx1rBITauYykG3BRYPu8h0UcxsPNB04RR5vo4Tyz3+ay17tR6JVf9qzYWg=="
679
     },
678
     },
680
     "async-validator": {
679
     "async-validator": {
681
       "version": "1.8.5",
680
       "version": "1.8.5",
8431
         "whatwg-url": "6.5.0",
8430
         "whatwg-url": "6.5.0",
8432
         "ws": "5.2.2",
8431
         "ws": "5.2.2",
8433
         "xml-name-validator": "3.0.0"
8432
         "xml-name-validator": "3.0.0"
8433
+      },
8434
+      "dependencies": {
8435
+        "ws": {
8436
+          "version": "5.2.2",
8437
+          "resolved": "https://registry.npmjs.org/ws/-/ws-5.2.2.tgz",
8438
+          "integrity": "sha512-jaHFD6PFv6UgoIVda6qZllptQsMlDEJkTQcybzzXDYM1XO9Y8em691FGMPmM46WGyLU4z9KMgQN+qrux/nhlHA==",
8439
+          "dev": true,
8440
+          "requires": {
8441
+            "async-limiter": "1.0.0"
8442
+          }
8443
+        }
8434
       }
8444
       }
8435
     },
8445
     },
8436
     "jsesc": {
8446
     "jsesc": {
16154
       }
16164
       }
16155
     },
16165
     },
16156
     "ws": {
16166
     "ws": {
16157
-      "version": "5.2.2",
16158
-      "resolved": "https://registry.npmjs.org/ws/-/ws-5.2.2.tgz",
16159
-      "integrity": "sha512-jaHFD6PFv6UgoIVda6qZllptQsMlDEJkTQcybzzXDYM1XO9Y8em691FGMPmM46WGyLU4z9KMgQN+qrux/nhlHA==",
16160
-      "dev": true,
16167
+      "version": "6.0.0",
16168
+      "resolved": "https://registry.npmjs.org/ws/-/ws-6.0.0.tgz",
16169
+      "integrity": "sha512-c2UlYcAZp1VS8AORtpq6y4RJIkJ9dQz18W32SpR/qXGfLDZ2jU4y4wKvvZwqbi7U6gxFQTeE+urMbXU/tsDy4w==",
16161
       "requires": {
16170
       "requires": {
16162
         "async-limiter": "1.0.0"
16171
         "async-limiter": "1.0.0"
16163
       }
16172
       }

+ 2
- 1
package.json 查看文件

28
     "vue-fullcalendar": "^1.0.9",
28
     "vue-fullcalendar": "^1.0.9",
29
     "vue-morris": "0.0.13",
29
     "vue-morris": "0.0.13",
30
     "vue-router": "^3.0.1",
30
     "vue-router": "^3.0.1",
31
-    "vuex": "^3.0.1"
31
+    "vuex": "^3.0.1",
32
+    "ws": "^6.0.0"
32
   },
33
   },
33
   "devDependencies": {
34
   "devDependencies": {
34
     "@antv/g2": "^3.2.7",
35
     "@antv/g2": "^3.2.7",

+ 1
- 1
src/pages/system/cardAndCouponManager/couponManager/index.vue 查看文件

54
             <span v-if="scope.row.StartDate.substr(0, 4) !== '0001'" style="width:100%;display:block;text-align:center;white-space: nowrap;">{{toolClass.dateFormat(scope.row.StartDate, 'yyyy-MM-dd')}}</span>
54
             <span v-if="scope.row.StartDate.substr(0, 4) !== '0001'" style="width:100%;display:block;text-align:center;white-space: nowrap;">{{toolClass.dateFormat(scope.row.StartDate, 'yyyy-MM-dd')}}</span>
55
             <span v-if="scope.row.StartDate.substr(0, 4) !== '0001'" style="width:100%;display:block;text-align:center;white-space: nowrap;">至</span>
55
             <span v-if="scope.row.StartDate.substr(0, 4) !== '0001'" style="width:100%;display:block;text-align:center;white-space: nowrap;">至</span>
56
             <span v-if="scope.row.StartDate.substr(0, 4) !== '0001'" style="width:100%;display:block;text-align:center;white-space: nowrap;">{{toolClass.dateFormat(scope.row.EndDate, 'yyyy-MM-dd')}}</span>
56
             <span v-if="scope.row.StartDate.substr(0, 4) !== '0001'" style="width:100%;display:block;text-align:center;white-space: nowrap;">{{toolClass.dateFormat(scope.row.EndDate, 'yyyy-MM-dd')}}</span>
57
-            <span v-else>-</span>
57
+            <span v-else>领取后{{scope.row.ValidDays}}天内有效</span>
58
           </template>
58
           </template>
59
         </el-table-column>
59
         </el-table-column>
60
         <el-table-column
60
         <el-table-column

+ 1
- 1
src/pages/system/cmsManager/newsManager/edit.vue 查看文件

23
             </div>
23
             </div>
24
           </div>
24
           </div>
25
         </li>
25
         </li>
26
-        <li class="flex-h" v-else>
26
+        <li class="flex-h" v-if="postData.ForwardType==='course'">
27
           <span>课程:<em>*</em></span>
27
           <span>课程:<em>*</em></span>
28
           <div class="flex-item">
28
           <div class="flex-item">
29
             <div style="width:50%">
29
             <div style="width:50%">

+ 12
- 13
src/pages/system/cmsManager/newsManager/index.vue 查看文件

69
     </div>
69
     </div>
70
     <el-pagination
70
     <el-pagination
71
       @current-change="handleCurrentChange"
71
       @current-change="handleCurrentChange"
72
-      :current-page.sync="postData.currentPage"
73
-      :page-size="postData.pageSize"
72
+      :current-page.sync="postData.page"
73
+      :page-size="postData.pagesize"
74
       layout="prev, pager, next, jumper"
74
       layout="prev, pager, next, jumper"
75
-      :total="postData.total">
75
+      :total="total">
76
     </el-pagination>
76
     </el-pagination>
77
   </div>
77
   </div>
78
 </template>
78
 </template>
85
   name: '',
85
   name: '',
86
   data () {
86
   data () {
87
     return {
87
     return {
88
+      total: 0,
88
       postData: {
89
       postData: {
89
-        currentPage: 1, // 当前页码
90
-        pageSize: 10,
91
-        total: 0,
90
+        page: 1, // 当前页码
91
+        pagesize: 10,
92
       },
92
       },
93
       tableSearch: { // 表格搜索条件
93
       tableSearch: { // 表格搜索条件
94
         key: '', // 搜索关键字
94
         key: '', // 搜索关键字
113
   methods: {
113
   methods: {
114
     ...mapCmsActions(['updateLocationInfo']),
114
     ...mapCmsActions(['updateLocationInfo']),
115
     handleCurrentChange (val) {
115
     handleCurrentChange (val) {
116
-      console.log(`当前页: ${val}`)
116
+      this.postData.page = val
117
       this.getList()
117
       this.getList()
118
     },
118
     },
119
     handleEdit (index, row) { // 编辑
119
     handleEdit (index, row) { // 编辑
120
-      console.log(index, row)
121
       this.$router.push({ name: 'editNews', query: { id: row.NewsId } })
120
       this.$router.push({ name: 'editNews', query: { id: row.NewsId } })
122
     },
121
     },
123
     handleDelete (index, row) { // 删除
122
     handleDelete (index, row) { // 删除
124
-      console.log(index, row)
125
       this.$confirm('确认删除此资讯?', '提示', {
123
       this.$confirm('确认删除此资讯?', '提示', {
126
         confirmButtonText: '确定',
124
         confirmButtonText: '确定',
127
         cancelButtonText: '取消',
125
         cancelButtonText: '取消',
136
       })
134
       })
137
     },
135
     },
138
     searchList (key) { // 搜索列表
136
     searchList (key) { // 搜索列表
137
+      this.postData.page = 1
138
+      this.total = 1
139
       this.tableSearch.key = key
139
       this.tableSearch.key = key
140
       this.getList()
140
       this.getList()
141
     },
141
     },
147
       this.$ajax(this.$api.cms.news.url, {
147
       this.$ajax(this.$api.cms.news.url, {
148
         method: this.$api.cms.news.method,
148
         method: this.$api.cms.news.method,
149
         queryData: {
149
         queryData: {
150
-          page: this.postData.currentPage,
151
-          pagesize: this.postData.pageSize,
150
+          ...this.postData,
152
           locationid: this.tableSearch.LocationId,
151
           locationid: this.tableSearch.LocationId,
153
           title: this.tableSearch.key
152
           title: this.tableSearch.key
154
         }
153
         }
157
           res.list[i].Status === 1 ? res.list[i].StatusShow = '是' : res.list[i].StatusShow = '否'
156
           res.list[i].Status === 1 ? res.list[i].StatusShow = '是' : res.list[i].StatusShow = '否'
158
         }
157
         }
159
         this.tableData = res.list
158
         this.tableData = res.list
160
-        this.postData.total = res.pagenum
161
-        this.postData.currentPage = res.page
159
+        this.total = res.pagenum
160
+        this.postData.page = res.page
162
       }).catch(msg => {
161
       }).catch(msg => {
163
 
162
 
164
       })
163
       })

+ 26
- 12
src/pages/system/newOrder/newOrderList/index.vue 查看文件

83
 import { getLodop } from '@/util/LodopFuncs'
83
 import { getLodop } from '@/util/LodopFuncs'
84
 
84
 
85
 import { formatTimeBySeconds } from '@/util/util'
85
 import { formatTimeBySeconds } from '@/util/util'
86
-
86
+// const WebSocket = require('ws')
87
 const { mapState: mapOrderState, mapActions: mapOrderActions } = createNamespacedHelpers('goodsorder')
87
 const { mapState: mapOrderState, mapActions: mapOrderActions } = createNamespacedHelpers('goodsorder')
88
 
88
 
89
 var LODOP
89
 var LODOP
130
       }
130
       }
131
     })
131
     })
132
   },
132
   },
133
+  mounted () {
134
+    setTimeout(window.location.reload, 600 * 1000)
135
+  },
133
   methods: {
136
   methods: {
134
     init () {
137
     init () {
138
+      var param = []
135
       if (!this.caseid) {
139
       if (!this.caseid) {
136
         this.$message({
140
         this.$message({
137
           type: 'info',
141
           type: 'info',
141
       }
145
       }
142
       clearInterval(this.interval)
146
       clearInterval(this.interval)
143
       this.GetOrdersList({ caseid: this.caseid }).then((res) => {
147
       this.GetOrdersList({ caseid: this.caseid }).then((res) => {
144
-        // console.log(JSON.stringify(res))
145
         for (var n = 0; n < res.list.length; n++) {
148
         for (var n = 0; n < res.list.length; n++) {
146
           if (res.list[n].IsIntimidate === 0) {
149
           if (res.list[n].IsIntimidate === 0) {
147
-            this.printPdf(`item_${res.list[n].OrdersId}`).then(() => {
148
-              this.putPrintGoodsOrder({
149
-                id: res.list[n].OrdersId
150
-              })
151
-            })
150
+            param.push(res.list[n].OrdersId)
152
           }
151
           }
153
         }
152
         }
153
+        var bool = true
154
+        var timer = setInterval(() => {
155
+          if (param.length && bool) {
156
+            bool = false
157
+            this.printPdf(`item_${param[0]}`)
158
+            console.log(param[0])
159
+            this.putPrintGoodsOrder({
160
+              id: param[0]
161
+            }).then(() => {
162
+              param.splice(0, 1)
163
+              bool = true
164
+            })
165
+          } else {
166
+            clearInterval(timer)
167
+          }
168
+        }, 300)
154
         this.getBusinessStatus(this.caseid).then(() => {
169
         this.getBusinessStatus(this.caseid).then(() => {
155
           if (this.businessStatus) {
170
           if (this.businessStatus) {
156
             this.initWebSocket()
171
             this.initWebSocket()
232
       })
247
       })
233
     },
248
     },
234
     printPdf (cl) {
249
     printPdf (cl) {
235
-      return new Promise((resolve) => {
236
-        this.CreateOneFormPage(cl)
237
-        LODOP.PRINT()
238
-        resolve()
239
-      })
250
+      this.CreateOneFormPage(cl)
251
+      LODOP.PRINT()
240
     },
252
     },
241
     CreateOneFormPage (cl) {
253
     CreateOneFormPage (cl) {
242
       LODOP = getLodop()
254
       LODOP = getLodop()
258
       this.websock.onopen = console.log
270
       this.websock.onopen = console.log
259
       this.websock.onmessage = this.websocketonmessage
271
       this.websock.onmessage = this.websocketonmessage
260
       this.websock.onclose = console.log
272
       this.websock.onclose = console.log
273
+
274
+      setInterval(() => this.websock.send(10), 120000)
261
     },
275
     },
262
     websocketonmessage (e) {
276
     websocketonmessage (e) {
263
       // let oldList = this.list
277
       // let oldList = this.list

+ 2
- 2
src/util/api.js 查看文件

1
-// const baseUrl = '/api-v2'
2
-const baseUrl = '/api'
1
+const baseUrl = '/api-v2'
2
+// const baseUrl = '/api'
3
 const common = '/common/:org'
3
 const common = '/common/:org'
4
 const guest = '/guest/:org'
4
 const guest = '/guest/:org'
5
 
5