yuantianjiao 6 anni fa
parent
commit
5682a45c4e

+ 1
- 1
dist/index.html Vedi File

@@ -4,4 +4,4 @@
4 4
         overflow-x: hidden;
5 5
         overflow-y: scroll;
6 6
         -webkit-overflow-scrolling: touch;
7
-      }</style><link href=./static/css/app.5a4922bc0909e2595cb76162a12d90e2.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.2a96777d0d5038fab28c.js></script><script type=text/javascript src=./static/js/app.7659d20a1e7a8b2757e0.js></script></body></html>
7
+      }</style><link href=./static/css/app.fcf98233b413a15056689268ee9fcc4e.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.2a96777d0d5038fab28c.js></script><script type=text/javascript src=./static/js/app.c24e15d5c97d6f7df2d5.js></script></body></html>

+ 0
- 2
dist/static/css/app.5a4922bc0909e2595cb76162a12d90e2.css
File diff suppressed because it is too large
Vedi File


+ 0
- 1
dist/static/css/app.5a4922bc0909e2595cb76162a12d90e2.css.map
File diff suppressed because it is too large
Vedi File


+ 2
- 0
dist/static/css/app.fcf98233b413a15056689268ee9fcc4e.css
File diff suppressed because it is too large
Vedi File


+ 1
- 0
dist/static/css/app.fcf98233b413a15056689268ee9fcc4e.css.map
File diff suppressed because it is too large
Vedi File


+ 0
- 2
dist/static/js/app.7659d20a1e7a8b2757e0.js
File diff suppressed because it is too large
Vedi File


+ 0
- 1
dist/static/js/app.7659d20a1e7a8b2757e0.js.map
File diff suppressed because it is too large
Vedi File


+ 2
- 0
dist/static/js/app.c24e15d5c97d6f7df2d5.js
File diff suppressed because it is too large
Vedi File


+ 1
- 0
dist/static/js/app.c24e15d5c97d6f7df2d5.js.map
File diff suppressed because it is too large
Vedi File


+ 1
- 1
dist/static/js/manifest.3ad1d5771e9b13dbdad2.js.map Vedi File

@@ -1 +1 @@
1
-{"version":3,"sources":["webpack:///webpack/bootstrap 85e6daea8807f15ebbcd"],"names":["parentJsonpFunction","window","chunkIds","moreModules","executeModules","moduleId","chunkId","result","i","resolves","length","installedChunks","push","Object","prototype","hasOwnProperty","call","modules","shift","__webpack_require__","s","installedModules","2","exports","module","l","m","c","d","name","getter","o","defineProperty","configurable","enumerable","get","n","__esModule","object","property","p","oe","err","console","error"],"mappings":"aACA,IAAAA,EAAAC,OAAA,aACAA,OAAA,sBAAAC,EAAAC,EAAAC,GAIA,IADA,IAAAC,EAAAC,EAAAC,EAAAC,EAAA,EAAAC,KACQD,EAAAN,EAAAQ,OAAoBF,IAC5BF,EAAAJ,EAAAM,GACAG,EAAAL,IACAG,EAAAG,KAAAD,EAAAL,GAAA,IAEAK,EAAAL,GAAA,EAEA,IAAAD,KAAAF,EACAU,OAAAC,UAAAC,eAAAC,KAAAb,EAAAE,KACAY,EAAAZ,GAAAF,EAAAE,IAIA,IADAL,KAAAE,EAAAC,EAAAC,GACAK,EAAAC,QACAD,EAAAS,OAAAT,GAEA,GAAAL,EACA,IAAAI,EAAA,EAAYA,EAAAJ,EAAAM,OAA2BF,IACvCD,EAAAY,IAAAC,EAAAhB,EAAAI,IAGA,OAAAD,GAIA,IAAAc,KAGAV,GACAW,EAAA,GAIA,SAAAH,EAAAd,GAGA,GAAAgB,EAAAhB,GACA,OAAAgB,EAAAhB,GAAAkB,QAGA,IAAAC,EAAAH,EAAAhB,IACAG,EAAAH,EACAoB,GAAA,EACAF,YAUA,OANAN,EAAAZ,GAAAW,KAAAQ,EAAAD,QAAAC,IAAAD,QAAAJ,GAGAK,EAAAC,GAAA,EAGAD,EAAAD,QAKAJ,EAAAO,EAAAT,EAGAE,EAAAQ,EAAAN,EAGAF,EAAAS,EAAA,SAAAL,EAAAM,EAAAC,GACAX,EAAAY,EAAAR,EAAAM,IACAhB,OAAAmB,eAAAT,EAAAM,GACAI,cAAA,EACAC,YAAA,EACAC,IAAAL,KAMAX,EAAAiB,EAAA,SAAAZ,GACA,IAAAM,EAAAN,KAAAa,WACA,WAA2B,OAAAb,EAAA,SAC3B,WAAiC,OAAAA,GAEjC,OADAL,EAAAS,EAAAE,EAAA,IAAAA,GACAA,GAIAX,EAAAY,EAAA,SAAAO,EAAAC,GAAsD,OAAA1B,OAAAC,UAAAC,eAAAC,KAAAsB,EAAAC,IAGtDpB,EAAAqB,EAAA,KAGArB,EAAAsB,GAAA,SAAAC,GAA8D,MAApBC,QAAAC,MAAAF,GAAoBA","file":"static/js/manifest.3ad1d5771e9b13dbdad2.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tvar parentJsonpFunction = window[\"webpackJsonp\"];\n \twindow[\"webpackJsonp\"] = function webpackJsonpCallback(chunkIds, moreModules, executeModules) {\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [], result;\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(chunkIds, moreModules, executeModules);\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n \t\tif(executeModules) {\n \t\t\tfor(i=0; i < executeModules.length; i++) {\n \t\t\t\tresult = __webpack_require__(__webpack_require__.s = executeModules[i]);\n \t\t\t}\n \t\t}\n \t\treturn result;\n \t};\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// objects to store loaded and loading chunks\n \tvar installedChunks = {\n \t\t2: 0\n \t};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"./\";\n\n \t// on error function for async loading\n \t__webpack_require__.oe = function(err) { console.error(err); throw err; };\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 85e6daea8807f15ebbcd"],"sourceRoot":""}
1
+{"version":3,"sources":["webpack:///webpack/bootstrap 377e1a3654d0a2f81f43"],"names":["parentJsonpFunction","window","chunkIds","moreModules","executeModules","moduleId","chunkId","result","i","resolves","length","installedChunks","push","Object","prototype","hasOwnProperty","call","modules","shift","__webpack_require__","s","installedModules","2","exports","module","l","m","c","d","name","getter","o","defineProperty","configurable","enumerable","get","n","__esModule","object","property","p","oe","err","console","error"],"mappings":"aACA,IAAAA,EAAAC,OAAA,aACAA,OAAA,sBAAAC,EAAAC,EAAAC,GAIA,IADA,IAAAC,EAAAC,EAAAC,EAAAC,EAAA,EAAAC,KACQD,EAAAN,EAAAQ,OAAoBF,IAC5BF,EAAAJ,EAAAM,GACAG,EAAAL,IACAG,EAAAG,KAAAD,EAAAL,GAAA,IAEAK,EAAAL,GAAA,EAEA,IAAAD,KAAAF,EACAU,OAAAC,UAAAC,eAAAC,KAAAb,EAAAE,KACAY,EAAAZ,GAAAF,EAAAE,IAIA,IADAL,KAAAE,EAAAC,EAAAC,GACAK,EAAAC,QACAD,EAAAS,OAAAT,GAEA,GAAAL,EACA,IAAAI,EAAA,EAAYA,EAAAJ,EAAAM,OAA2BF,IACvCD,EAAAY,IAAAC,EAAAhB,EAAAI,IAGA,OAAAD,GAIA,IAAAc,KAGAV,GACAW,EAAA,GAIA,SAAAH,EAAAd,GAGA,GAAAgB,EAAAhB,GACA,OAAAgB,EAAAhB,GAAAkB,QAGA,IAAAC,EAAAH,EAAAhB,IACAG,EAAAH,EACAoB,GAAA,EACAF,YAUA,OANAN,EAAAZ,GAAAW,KAAAQ,EAAAD,QAAAC,IAAAD,QAAAJ,GAGAK,EAAAC,GAAA,EAGAD,EAAAD,QAKAJ,EAAAO,EAAAT,EAGAE,EAAAQ,EAAAN,EAGAF,EAAAS,EAAA,SAAAL,EAAAM,EAAAC,GACAX,EAAAY,EAAAR,EAAAM,IACAhB,OAAAmB,eAAAT,EAAAM,GACAI,cAAA,EACAC,YAAA,EACAC,IAAAL,KAMAX,EAAAiB,EAAA,SAAAZ,GACA,IAAAM,EAAAN,KAAAa,WACA,WAA2B,OAAAb,EAAA,SAC3B,WAAiC,OAAAA,GAEjC,OADAL,EAAAS,EAAAE,EAAA,IAAAA,GACAA,GAIAX,EAAAY,EAAA,SAAAO,EAAAC,GAAsD,OAAA1B,OAAAC,UAAAC,eAAAC,KAAAsB,EAAAC,IAGtDpB,EAAAqB,EAAA,KAGArB,EAAAsB,GAAA,SAAAC,GAA8D,MAApBC,QAAAC,MAAAF,GAAoBA","file":"static/js/manifest.3ad1d5771e9b13dbdad2.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tvar parentJsonpFunction = window[\"webpackJsonp\"];\n \twindow[\"webpackJsonp\"] = function webpackJsonpCallback(chunkIds, moreModules, executeModules) {\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [], result;\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(chunkIds, moreModules, executeModules);\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n \t\tif(executeModules) {\n \t\t\tfor(i=0; i < executeModules.length; i++) {\n \t\t\t\tresult = __webpack_require__(__webpack_require__.s = executeModules[i]);\n \t\t\t}\n \t\t}\n \t\treturn result;\n \t};\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// objects to store loaded and loading chunks\n \tvar installedChunks = {\n \t\t2: 0\n \t};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"./\";\n\n \t// on error function for async loading\n \t__webpack_require__.oe = function(err) { console.error(err); throw err; };\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 377e1a3654d0a2f81f43"],"sourceRoot":""}

+ 2
- 2
src/components/model1/index.vue Vedi File

@@ -72,7 +72,7 @@
72 72
           <img :src="jt" alt="">
73 73
         </div>
74 74
         <div class="content">
75
-          <pre>{{data.prize.LuckdrawRule}}</pre>
75
+          <div v-html='data.prize.LuckdrawRule'></div>
76 76
         </div>
77 77
       </div>
78 78
       <img class="bird" :src="bird" alt="">
@@ -213,7 +213,7 @@ export default {
213 213
     },
214 214
     get () {
215 215
       console.log('去领取')
216
-      window.location.href = `${window.location.origin}/wechat/user.html#/${this.jump}?isAuto=auto`
216
+      window.location.href = `${window.location.origin}/wechat/user.html#/receiveShared${this.jump}?isAuto=auto`
217 217
     },
218 218
     close (data) {
219 219
       this.showDialog = false

+ 5
- 6
src/components/model1/page.scss Vedi File

@@ -178,7 +178,7 @@ body * {
178 178
       }
179 179
       .dialog-name {
180 180
         font-size: 0.18rem;
181
-        margin: 0.1rem 0;
181
+        margin: 0.05rem 0;
182 182
       }
183 183
       .qrCode {
184 184
         width: 0.8rem;
@@ -186,7 +186,6 @@ body * {
186 186
       }
187 187
       .lq {
188 188
         width: 1rem;
189
-        margin: 0.1rem 0 0.05rem;
190 189
       }
191 190
       .desc {
192 191
         font-size: 0.12rem;
@@ -303,10 +302,10 @@ body * {
303 302
         }
304 303
       }
305 304
       .content {
306
-        pre{
307
-          white-space:pre-line; 
308
-          text-align: left;
309
-          line-height: .18rem;
305
+        div{
306
+          // white-space:pre-line; 
307
+          // text-align: left;
308
+          // line-height: .18rem;
310 309
         }
311 310
       }
312 311
     }

+ 2
- 2
src/components/model2/index.vue Vedi File

@@ -57,7 +57,7 @@
57 57
           <img :src="right" alt="">
58 58
         </div>
59 59
         <div class="content">
60
-          <pre>{{data.prize.LuckdrawRule}}</pre>
60
+          <div v-html='data.prize.LuckdrawRule'></div>
61 61
         </div>
62 62
       </div>
63 63
     </div>
@@ -239,7 +239,7 @@ export default {
239 239
     },
240 240
     get () {
241 241
       console.log('去领取')
242
-      window.location.href = `${window.location.origin}/wechat/user.html#/${this.jump}?isAuto=auto`
242
+      window.location.href = `${window.location.origin}/wechat/user.html#/receiveShared${this.jump}?isAuto=auto`
243 243
     },
244 244
     close (data) {
245 245
       this.showDialog = false

+ 5
- 6
src/components/model2/page.scss Vedi File

@@ -42,7 +42,7 @@
42 42
       }
43 43
       .dialog-name {
44 44
         font-size: 0.18rem;
45
-        margin: 0.1rem 0;
45
+        margin: 0.05rem 0;
46 46
       }
47 47
       .qrCode {
48 48
         width: 0.8rem;
@@ -50,7 +50,6 @@
50 50
       }
51 51
       .lq {
52 52
         width: 1rem;
53
-        margin: 0.1rem 0 0.05rem;
54 53
       }
55 54
       .desc {
56 55
         font-size: 0.12rem;
@@ -265,10 +264,10 @@
265 264
         }
266 265
       }
267 266
       .content {
268
-        pre{
269
-          white-space:pre-line;
270
-          text-align: left;
271
-          line-height: .18rem;
267
+        div{
268
+          // white-space:pre-line;
269
+          // text-align: left;
270
+          // line-height: .18rem;
272 271
           color: #895B2F;
273 272
         }
274 273
       }

+ 2
- 2
src/components/model3/index.vue Vedi File

@@ -58,7 +58,7 @@
58 58
           <span>活动规则</span>
59 59
         </div>
60 60
         <div class='content'>
61
-          <pre>{{data.prize.LuckdrawRule}}</pre>
61
+          <div v-html='data.prize.LuckdrawRule'></div>
62 62
         </div>
63 63
       </div>
64 64
     </div>
@@ -183,7 +183,7 @@ export default {
183 183
     },
184 184
     get () {
185 185
       console.log('去领取')
186
-      window.location.href = `${window.location.origin}/wechat/user.html#/${this.jump}?isAuto=auto`
186
+      window.location.href = `${window.location.origin}/wechat/user.html#/receiveShared${this.jump}?isAuto=auto`
187 187
     },
188 188
     close (data) {
189 189
       this.showDialog = false

+ 9
- 8
src/components/model3/page.scss Vedi File

@@ -42,7 +42,7 @@
42 42
       }
43 43
       .dialog-name {
44 44
         font-size: 0.18rem;
45
-        margin: 0.1rem 0;
45
+        margin: 0.05rem 0;
46 46
       }
47 47
       .qrCode {
48 48
         width: 0.8rem;
@@ -50,7 +50,6 @@
50 50
       }
51 51
       .lq {
52 52
         width: 1rem;
53
-        margin: 0.1rem 0 0.05rem;
54 53
       }
55 54
       .desc {
56 55
         font-size: 0.12rem;
@@ -197,11 +196,13 @@
197 196
       .list {
198 197
         overflow-x: hidden;
199 198
         overflow-y: scroll;
200
-        height: 1.9rem;
199
+        height: 1.8rem;
200
+        width: 2.8rem;
201 201
         position: absolute;
202
-        top: .3rem;
202
+        top: .4rem;
203 203
         left: .1rem;
204 204
         div {
205
+          width: 100%;
205 206
           display: flex;
206 207
           align-items: center;
207 208
           justify-content: space-between;
@@ -293,10 +294,10 @@
293 294
         width: 100%;
294 295
         box-sizing: border-box;
295 296
         padding: 0 .1rem;
296
-        pre{
297
-          white-space:pre-line;
298
-          text-align: left;
299
-          line-height: .18rem;
297
+        div{
298
+          // white-space:pre-line;
299
+          // text-align: left;
300
+          // line-height: .18rem;
300 301
           color: #585858;
301 302
         }
302 303
       }

+ 6
- 5
src/page/index/index.vue Vedi File

@@ -55,6 +55,7 @@ export default {
55 55
     model3
56 56
   },
57 57
   created () {
58
+    this.LotteryId(this.$route.query.lotteryId)
58 59
     // this.showPage = true
59 60
     // this.model = 3 // 模板
60 61
     if (location.search && this.toolClass.UrlSearch(location.search).code) {
@@ -86,19 +87,19 @@ export default {
86 87
     })
87 88
   },
88 89
   methods: {
89
-    ...mapAppActions(['getUserInfo', 'getPrize', 'setPrize', 'getRecord', 'setUser', 'setRunState']),
90
+    ...mapAppActions(['getUserInfo', 'getPrize', 'setPrize', 'getRecord', 'setUser', 'setRunState', 'LotteryId']),
90 91
     getData () {
91 92
       this.getPrize({ id: this.lotteryId }).then((res) => {
92 93
         this.showPage = true
93 94
         this.data.prize = this.prize
94 95
         this.data.prizeList = this.data.prize.Prizes
95
-        this.model = res.TplId ? res.TplId : 3 // 模板
96
+        this.model = res.TplId ? Math.floor(res.TplId) : 3 // 模板
96 97
         if (this.model === 1) {
97
-          this.bg1 = res.Imgs ? res.Imgs[0] : this.bg1
98
+          this.bg1 = res.Imgs ? res.Imgs[0].ImgUrl : this.bg1
98 99
         } else if (this.model === 2) {
99
-          this.bg2 = res.Imgs ? res.Imgs[0] : this.bg2
100
+          this.bg2 = res.Imgs ? res.Imgs[0].ImgUrl : this.bg2
100 101
         } else if (this.model === 3) {
101
-          this.bg3 = res.Imgs ? res.Imgs[0] : this.bg3
102
+          this.bg3 = res.Imgs ? res.Imgs[0].ImgUrl : this.bg3
102 103
         }
103 104
         this.data.hasTitle = res.Imgs ? 0 : 1
104 105
         this.activityStatus = this.data.prize.Status

+ 24
- 7
src/page/lotteryDetail/index.vue Vedi File

@@ -36,15 +36,32 @@ export default {
36 36
     })
37 37
   },
38 38
   created () {
39
-    this.getLotteryDetail({ id: this.$route.query.id }).then((res) => {
40
-      this.data = this.detail
41
-      this.msg.luckydraw_id = this.data.record.LuckdrawId
42
-      this.msg.record_id = this.data.record.CustomerQrcode
43
-      this.showPage = true
44
-    })
39
+    if (this.$route.query.type === 1) {
40
+      this.getLotteryDetail({ id: this.$route.query.id }).then((res) => {
41
+        this.data = this.detail
42
+        this.msg.record_id = this.data.record.CustomerQrcode
43
+        this.showPage = true
44
+      })
45
+    } else {
46
+      this.getRushDetail({ customerFlashBuyId: this.$route.query.id }).then((res) => {
47
+        this.data = {
48
+          prize: {
49
+            VerificationStart: this.detail.ValidateStart,
50
+            VerificationEnd: this.detail.ValidateEnd
51
+          },
52
+          record: {
53
+            Status: this.detail.VerifyStatus === 'useable' ? 0 : 1,
54
+            CustomerQrcode: this.detail.CustomerQrcode
55
+          },
56
+          caseAddress: this.detail.CaseName
57
+        }
58
+        this.msg.record_id = this.data.record.CustomerQrcode
59
+        this.showPage = true
60
+      })
61
+    }
45 62
   },
46 63
   methods: {
47
-    ...mapPrizeActions(['getLotteryDetail']),
64
+    ...mapPrizeActions(['getLotteryDetail', 'getRushDetail']),
48 65
     showDate (dt) {
49 66
       const theDT = new Date(dt)
50 67
       const fullYear = theDT.getFullYear(theDT)

+ 27
- 8
src/page/lotteryList/index.vue Vedi File

@@ -1,12 +1,12 @@
1 1
 <template>
2 2
   <div class="mainPage">
3 3
     <div class="list title">
4
-      <span :class="{active:active === 1}" @click="active=1">城的空间卡券</span>
5
-      <span :class="{active:active === 2}" @click="active=2">其他奖品</span>
4
+      <span :class="{active:active === 1}" @click="prize()">抽奖奖品</span>
5
+      <span :class="{active:active === 2}" @click="rush()">抢购奖品</span>
6 6
     </div>
7 7
     <div class="list" v-if="data.list" v-for='(item,index) in data.list' :key='index' @click="toDetail(item)">
8 8
       <div>
9
-        <span>{{item.PrizeName}}</span>
9
+        <span>{{item.PrizeName || item.FlashBuyName}}</span>
10 10
         <span>获得时间:{{toolClass.dateFormat(item.CreateDate)}}</span>
11 11
       </div>
12 12
       <div>
@@ -46,15 +46,17 @@ export default {
46 46
   mounted () {
47 47
     this.getUserInfo({ luckdrawid: this.lotteryId, from: this.$route.query.from || '' }).then((res) => {
48 48
       this.data.userInfo = this.userInfo
49
-      this.getLotteryList({ userid: this.data.userInfo.user.Id }).then((res) => {
50
-        this.data.list = this.list
51
-      })
49
+      if (this.$route.query.type === '2') {
50
+        this.rush()
51
+      } else {
52
+        this.prize()
53
+      }
52 54
     }).catch((err) => {
53 55
       console.log(err)
54 56
     })
55 57
   },
56 58
   methods: {
57
-    ...mapPrizeActions(['getLotteryList']),
59
+    ...mapPrizeActions(['getLotteryList', 'rushList']),
58 60
     ...mapAppActions(['getUserInfo']),
59 61
     toDetail (item) {
60 62
       if (item.Status === 1) {
@@ -63,8 +65,25 @@ export default {
63 65
       if (item.Url) {
64 66
         window.location.href = item.Url
65 67
       } else {
66
-        this.$router.push({ name: 'lotteryDetail', query: { id: item.Id } })
68
+        this.$router.push({ name: 'lotteryDetail', query: { id: item.Id ? item.Id : item.CustomerFlashBuyId, type: this.active } })
67 69
       }
70
+    },
71
+    prize () {
72
+      this.active = 1
73
+      this.data.list = []
74
+      this.getLotteryList().then((res) => {
75
+        this.data.list = this.list
76
+      })
77
+    },
78
+    rush () {
79
+      this.active = 2
80
+      this.data.list = []
81
+      this.rushList().then((res) => {
82
+        this.data.list = this.list
83
+        for (let i = 0; i < this.data.list.length; i++) {
84
+          this.data.list[i].Status = this.data.list[i].VerifyStatus === 'useable' ? 0 : 1
85
+        }
86
+      })
68 87
     }
69 88
   }
70 89
 }

+ 7
- 0
src/store/app.js Vedi File

@@ -105,6 +105,9 @@ export default {
105 105
     runState: 0 // 0为未启动,1为进行中,2为已结束
106 106
   },
107 107
   mutations: {
108
+    setLotteryId (state, data) {
109
+      state.lotteryId = data
110
+    },
108 111
     setUserInfo (state, data) {
109 112
       state.userInfo = data
110 113
     },
@@ -119,6 +122,9 @@ export default {
119 122
     }
120 123
   },
121 124
   actions: {
125
+    LotteryId (context, data) {
126
+      context.commit('setLotteryId', data)
127
+    },
122 128
     getUserInfo (context, data) {
123 129
       return new Promise((resolve) => {
124 130
         http.getUserInfo(data).then((res) => {
@@ -150,6 +156,7 @@ export default {
150 156
     getRecord (context, data) {
151 157
       return new Promise((resolve) => {
152 158
         http.getRecord(data).then((res) => {
159
+          res = res || []
153 160
           if (res.length >= 100) {
154 161
             res = res.slice(0, 100)
155 162
           }

+ 31
- 5
src/store/prize.js Vedi File

@@ -6,10 +6,7 @@ const http = {}
6 6
 http.getLotteryList = (data) => {
7 7
   return new Promise((resolve, reject) => {
8 8
     Ajax(api.lottery.userRecordList.url, {
9
-      method: api.lottery.userRecordList.method,
10
-      queryData: {
11
-        userid: data.userid
12
-      }
9
+      method: api.lottery.userRecordList.method
13 10
     }).then(res => {
14 11
       console.log(res)
15 12
       resolve(res)
@@ -42,7 +39,7 @@ export default {
42 39
   },
43 40
   mutations: {
44 41
     setLotteryList (state, data) {
45
-      state.list = data
42
+      state.list = data || []
46 43
     },
47 44
     setLotteryDetail (state, data) {
48 45
       state.detail = data
@@ -65,6 +62,35 @@ export default {
65 62
           resolve(res)
66 63
         })
67 64
       })
65
+    },
66
+    getRushDetail (context, data) {
67
+      return new Promise((resolve, reject) => {
68
+        Ajax({
69
+          ...api.lottery.rushDetail,
70
+          urlData: { ...data }
71
+        }).then(res => {
72
+          context.commit('setLotteryDetail', res)
73
+          resolve(res)
74
+        }).catch((err) => {
75
+          reject(err)
76
+        })
77
+      })
78
+    },
79
+    rushList (context, data) {
80
+      return new Promise((resolve, reject) => {
81
+        Ajax({
82
+          ...api.lottery.rushList,
83
+          queryData: {
84
+            page: 1,
85
+            pagesize: 10000
86
+          }
87
+        }).then(res => {
88
+          context.commit('setLotteryList', res.list)
89
+          resolve(res)
90
+        }).catch((err) => {
91
+          reject(err)
92
+        })
93
+      })
68 94
     }
69 95
   }
70 96
 }

+ 8
- 0
src/util/api.js Vedi File

@@ -39,6 +39,14 @@ const $api = {
39 39
     setUser: { // 分享发送userId
40 40
       method: 'post',
41 41
       url: `${baseUrl}${wechat}/luckdraw/:id/share`
42
+    },
43
+    rushList: { // 抢购列表
44
+      method: 'get',
45
+      url: `${baseUrl}${wechat}/flashbuy/customer`
46
+    },
47
+    rushDetail: { // 抢购核销
48
+      method: 'get',
49
+      url: `${baseUrl}${wechat}/flashbuy/customerFlash/:customerFlashBuyId`
42 50
     }
43 51
   }
44 52
 }