jufubao-movie 1.0.70-beta1 → 1.0.71-beta1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jufubao-movie",
3
- "version": "1.0.70-beta1",
3
+ "version": "1.0.71-beta1",
4
4
  "private": false,
5
5
  "description": "聚福宝在线选座业务组件插件包",
6
6
  "main": "index.js",
@@ -185,7 +185,7 @@ export default {
185
185
  fastEntryStatus: false,
186
186
  cusNames: {}, //按钮名称
187
187
  cusEntry: {}, //入口状态
188
- isAutoJump: [],
188
+ isAutoJump: false,
189
189
  mapKeys: {
190
190
  id: "cinema_id",
191
191
  brand_id: "brand_id", //品牌ID
@@ -378,7 +378,32 @@ export default {
378
378
  this.initAttr = true;
379
379
  },
380
380
  //==evnet===
381
+ getAutoJumpType(options) {
382
+ // 从options数组中提取consume_mode属性,生成新的数组typeList
383
+ let typeList = options.map(item=>item.consume_mode)
384
+ // 定义优先级映射表,不同类型对应不同的优先级数值,数值越小优先级越高
385
+ const priorityMap = {
386
+ 'SEAT': 0, // 座位类型,优先级最高
387
+ 'JHD': 1,
388
+ 'WB': 2, // 核销类型,优先级次之
389
+ 'QP': 3,
390
+ 'CODE': 4 // 电子码类型,优先级最低
391
+ };
392
+
393
+ // 定义获取最高优先级类型的函数
394
+ const getPriorityType = (typeList) => {
395
+ return typeList.reduce((prev, current) => {
396
+ return (priorityMap[current] < priorityMap[prev]) ? current : prev;
397
+ });
398
+ };
399
+
400
+ const type = typeList.length > 0 ? getPriorityType(typeList) : '';
401
+ return type
402
+ },
381
403
  handleToEvent({ item, type }) {
404
+ if (item.consume_options.length > 1) {
405
+ type=this.getAutoJumpType(item.consume_options);
406
+ }
382
407
  let url = "";
383
408
  let parmas = [];
384
409
  //扫一扫
@@ -554,7 +579,9 @@ export default {
554
579
  });
555
580
  },
556
581
 
557
- handleItemClick() {},
582
+ handleItemClick() {
583
+
584
+ },
558
585
 
559
586
  onJfbReachBottom(options) {
560
587
  if (!this.page_token) return false;