@conecli/cone-render 0.10.1-shop3.29 → 0.10.1-shop3.30

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.
@@ -1 +1 @@
1
- import Taro from '@tarojs/taro';
2
1
  entrance: 'shop-page-tab',
3
2
  moduleId: 'shop-modular-floor',
4
3
 
5
4
  jdJumpToProduct(skuIds, logEventInfo, otherParams = {}) {
6
5
  skuIds = skuIds.toString().trim();
7
6
  const getSkuId = skuIds.indexOf(',') !== -1 ? skuIds.split(',')[0] : skuIds;
8
7
  const openAppParam = {
9
8
  category: 'jump',
10
9
  des: 'productDetail',
11
10
  skuId: getSkuId,
12
11
  logEventInfo,
13
12
  ...otherParams,
14
13
  };
15
14
  const adInfos = getAdInfoBySkuId(getSkuId);
16
15
  if (adInfos) {
17
16
  openAppParam.pdExtFlag = {
18
17
  adInfos,
19
18
  };
20
19
  }
21
20
  this.jdNavigateToNative(openAppParam);
22
21
  }
23
22
 
24
23
  jdJumpSkuInfoToProduct(skuInfo: any = {}, logEventInfo) {
25
24
  const getSkuId = skuInfo?.skuId;
26
25
  this.jdJumpToProduct(getSkuId, logEventInfo);
27
26
  }
28
27
 
29
28
  jdJumpToShopCategory(shopInfo = {}) {
30
29
  console.log(
31
30
  '🚀 ~ file: jdJumpJdApp.ts:40 ~ JdJumpJdApp ~ jdJumpToShopCategory ~ shopInfo:',
32
31
  shopInfo,
33
32
  );
34
33
  console.log('[降级H5] jdJumpToShopCategory jdJumpJdApp');
35
34
  this.jdNavigateToNative(
36
35
  Object.assign(
37
36
  {},
38
37
  {
39
38
  category: 'jump',
40
39
  des: 'jshopMain',
41
40
  jumpBottomTab: 'category',
42
41
  },
43
42
  shopInfo,
44
43
  {
45
44
  shopId: String(shopInfo.shopId ?? ''),
46
45
  venderId: String(shopInfo.venderId ?? ''),
47
46
  },
48
47
  ),
49
48
  );
50
49
  }
51
50
 
52
51
  jdJumpToOrderInfoView(wareId, wareNum = 1, logEventInfo) {
53
52
  this.jdNavigateToNative({
54
53
  category: 'jump',
55
54
  des: 'orderInfoView',
56
55
  wareId: `${wareId}`,
57
56
  wareNum: global.info.sysInfo.isIOS ? `${wareNum}` : wareNum,
58
57
  skuSource: 25,
59
58
  sourceType: 6,
60
59
  extFlag: '{}',
61
60
  logEventInfo,
62
61
  });
63
62
  }
64
63
 
65
64
  jdJumpToTryDetail(tryId) {
66
65
  this.jdNavigateToNative({
67
66
  category: 'jump',
68
67
  des: 'jdreactcommon',
69
68
  appname: 'JDReactNewProduct',
70
69
  modulename: 'JDReactNewProduct',
71
70
  param: {
72
71
  activityId: tryId,
73
72
  isNative: true,
74
73
  nativePage: 'jdtry_detail',
75
74
  transparentenable: true,
76
75
  },
77
76
  });
78
77
  }
79
78
 
80
79
  jdJumpToShopHome(shopInfo = {}) {
81
80
  console.log('[降级H5] jdJumpToShopHome jdJumpJdApp');
82
81
  const getInfo = Object.assign(
83
82
  {},
84
83
  {
85
84
  shopId: global.info.queryInfo.shopId,
86
85
  venderId: global.info.queryInfo.venderId,
87
86
  },
88
87
  shopInfo,
89
88
  );
90
89
  const getShopParams = this.getShopIdsInfo(getInfo);
91
90
  this.jdJumpToShopBase(getShopParams);
92
91
  }
93
92
 
94
93
  jdJumpToShopHomeInner(shopInfo: JumpEventReportInterFace.ShopIdsInfo = {}) {
95
94
  const getParam = Object.assign(
96
95
  {},
97
96
  {
98
97
  jumpTab: HOME_TOP_TAB_TYPE_APP.HOME,
99
98
  operation: 'jumpTabInner',
100
99
  },
101
100
  shopInfo,
102
101
  );
103
102
  this.jdJumpToShopBase(getParam);
104
103
  }
105
104
 
106
105
  jdJumpToUnifieddetail(sourceInfo) {
107
106
  this.jdNavigateToNative(
108
107
  Object.assign(
109
108
  {},
110
109
  {
111
110
  category: 'jump',
112
111
  des: 'unifieddetail',
113
112
  },
114
113
  sourceInfo,
115
114
  ),
116
115
  );
117
116
  }
118
117
 
119
118
  jdJumpToVideoImmersion(sourceInfo) {
120
119
  this.jdNavigateToNative(
121
120
  Object.assign(
122
121
  {},
123
122
  {
124
123
  category: 'jump',
125
124
  des: 'VideoImmersion',
126
125
  },
127
126
  sourceInfo,
128
127
  ),
129
128
  );
130
129
  }
131
130
 
132
131
  jdJumpToShopMember(shopInfo) {
133
132
  this.jdNavigateToNative(
134
133
  Object.assign(
135
134
  {},
136
135
  {
137
136
  category: 'jump',
138
137
  des: 'jshopMember',
139
138
  followAward: '-1',
140
139
  },
141
140
  shopInfo,
142
141
  ),
143
142
  );
144
143
  }
145
144
 
146
145
  jdJumpToMemberTab(shopInfo?) {
147
146
  this.jdNavigateToNative(
148
147
  Object.assign(
149
148
  {},
150
149
  {
151
150
  category: 'jump',
152
151
  des: 'jshopMain',
153
152
  shopId: global.info.queryInfo.shopId,
154
153
  venderId: global.info.queryInfo.venderId,
155
154
  operation: 'jumpBottomTabMember',
156
155
  sourceInfo: APP_SOURCE_INFO,
157
156
  },
158
157
  shopInfo,
159
158
  ),
160
159
  );
161
160
  }
162
161
 
163
162
  jdJumpToDongDongChatGroup(groupId, source = 'jdmini') {
164
163
  this.jdNavigateToNative({
165
164
  category: 'jump',
166
165
  des: 'dongdong_group_chat',
167
166
  source: source,
168
167
  groupId: `${groupId}`,
169
168
  });
170
169
  }
171
170
 
172
171
  jdJumpToDongDongChat(paramInfo: any = {}) {
173
172
  const { venderId, ...otherParams } = paramInfo;
174
173
  this.jdNavigateToNative(
175
174
  Object.assign(
176
175
  {},
177
176
  {
178
177
  category: 'jump',
179
178
  des: 'jd_dongdong_chat',
180
179
  venderId: `${venderId ? venderId : global.info.queryInfo?.venderId}`,
181
180
  entry: 'm_shop',
182
181
  },
183
182
  otherParams,
184
183
  ),
185
184
  );
186
185
  }
187
186
 
188
187
  jdJumpToShopActivity(shopInfo) {
189
188
  const getParams = Object.assign(
190
189
  {},
191
190
  {
192
191
  category: 'jump',
193
192
  des: 'jshopActivity',
194
193
  shopId: global.info.queryInfo.shopId,
195
194
  venderId: global.info.queryInfo.venderId,
196
195
  },
197
196
  shopInfo,
198
197
  );
199
198
  getParams['projectId'] && (getParams['projectId'] = `${getParams['projectId']}`);
200
199
  this.jdNavigateToNative(getParams);
201
200
  }
202
201
 
203
202
  jdJumpToShopActivityPage(shopInfo) {
204
203
  this.jdNavigateToNative(
205
204
  Object.assign(
206
205
  {},
207
206
  {
208
207
  category: 'jump',
209
208
  des: 'jshopActivityPage',
210
209
  shopId: global.info.queryInfo.shopId,
211
210
  title: global.info.queryInfo?.shopName,
212
211
  },
213
212
  shopInfo,
214
213
  ),
215
214
  );
216
215
  }
217
216
 
218
217
  jdJumpToShopDetail(shopInfo) {
219
218
  this.jdNavigateToNative(
220
219
  Object.assign(
221
220
  {},
222
221
  {
223
222
  category: 'jump',
224
223
  des: 'jshopDetail',
225
224
  shopId: global.info.queryInfo.shopId,
226
225
  venderId: global.info.queryInfo.venderId,
227
226
  sourceInfo: APP_SOURCE_INFO,
228
227
  },
229
228
  shopInfo,
230
229
  ),
231
230
  );
232
231
  }
233
232
 
234
233
  jdJumpToShopMemberCard(shopInfo) {
235
234
  const { url, logEventInfo } = shopInfo;
236
235
  if (this.isOpenJdAppUrl(url)) {
237
236
  const getOpenAppParams = this.jdOpenAppParams(url);
238
237
  console.log('jd web 获取自定义openApp链接解析后的参数结果', getOpenAppParams);
239
238
  if (getOpenAppParams) {
240
239
  this.jdNavigateToNative(Object.assign({}, getOpenAppParams, { logEventInfo }));
241
240
  }
242
241
  } else {
243
242
  super.jdJumpToWeb(url, {
244
243
  ...logEventInfo,
245
244
  });
246
245
  }
247
246
  }
248
247
 
249
248
  jdJumpToTotalPromotion(shopInfo) {
250
249
  const { url, logEventInfo } = shopInfo;
251
250
  if (this.isOpenJdAppUrl(url)) {
252
251
  const getOpenAppParams = this.jdOpenAppParams(url);
253
252
  console.log('jd web 获取自定义openApp链接解析后的参数结果', getOpenAppParams);
254
253
  if (getOpenAppParams) {
255
254
  this.jdNavigateToNative(Object.assign({}, getOpenAppParams, { logEventInfo }));
256
255
  }
257
256
  } else {
258
257
  super.jdJumpToWeb(url, {
259
258
  ...logEventInfo,
260
259
  });
261
260
  }
262
261
  }
263
262
 
264
263
  jdJumpToShopSearch(pageInfo = {}) {
265
264
  const getInfo = Object.assign(
266
265
  {},
267
266
  {
268
267
  shopId: global.info.queryInfo.shopId,
269
268
  venderId: global.info.queryInfo.venderId,
270
269
  sourceInfo: APP_SOURCE_INFO,
271
270
  },
272
271
  pageInfo,
273
272
  );
274
273
  const { keyword = '', categoryId = '', ...otherPageInfo }: any = getInfo;
275
274
  const searchInfo = {};
276
275
  if (categoryId !== '') {
277
276
  searchInfo['categoryId'] = typeof categoryId === 'string' ? categoryId?.trim() : categoryId;
278
277
  searchInfo['searchType'] = '5';
279
278
  } else if (keyword !== '') {
280
279
  searchInfo['keyWord'] = keyword;
281
280
  searchInfo['searchType'] = '4';
282
281
  }
283
282
  const openAppParam = {
284
283
  category: 'jump',
285
284
  des: 'jshopProductList',
286
285
  pageId: '1',
287
286
  ...searchInfo,
288
287
  };
289
288
  const jumpExtMap = getEnterShopExtInfo();
290
289
  if (jumpExtMap) {
291
290
  openAppParam.jumpExtMap = jumpExtMap;
292
291
  }
293
292
  this.jdNavigateToNative(Object.assign({}, openAppParam, otherPageInfo));
294
293
  }
295
294
 
296
295
  jdJumpToOrderList(logEventInfo = {}) {
297
296
  this.jdNavigateToNative(
298
297
  Object.assign(
299
298
  {},
300
299
  {
301
300
  category: 'jump',
302
301
  des: 'orderlist',
303
302
  from: 'dphycc',
304
303
  },
305
304
  logEventInfo,
306
305
  ),
307
306
  );
308
307
  }
309
308
 
310
309
  jdJumpToCouponSearchProductList(couponId, logEventInfo = {}) {
311
310
  this.jdNavigateToNative(
312
311
  Object.assign(
313
312
  {},
314
313
  {
315
314
  category: 'jump',
316
315
  des: 'productList',
317
316
  from: 'couponBatch',
318
317
  couponId: `${couponId}`,
319
318
  logEventInfo,
320
319
  },
321
320
  ),
322
321
  );
323
322
  }
324
323
 
325
324
  jdJumpToTabAllProduct(shopId, venderId, logEventInfo = {}) {
326
325
  console.log('jdJumpJdApp - jdJumpToTabAllProduct');
327
326
  if (typeof shopId === 'undefined') shopId = global.info.queryInfo.shopId;
328
327
  if (typeof venderId === 'undefined') venderId = global.info.queryInfo.venderId;
329
328
  this.jdNavigateToNative(
330
329
  Object.assign(
331
330
  {},
332
331
  {
333
332
  category: 'jump',
334
333
  des: 'jshopMain',
335
334
  jumpTab: 'allProduct',
336
335
  },
337
336
  shopId !== 'undefined'
338
337
  ? {
339
338
  shopId,
340
339
  }
341
340
  : {},
342
341
  venderId !== 'undefined'
343
342
  ? {
344
343
  venderId,
345
344
  }
346
345
  : {},
347
346
  {
348
347
  logEventInfo,
349
348
  },
350
349
  ),
351
350
  );
352
351
  }
353
352
 
354
353
  jdJumpToTabAllProductInner(shopId, venderId, logEventInfo = {}) {
355
354
  if (typeof shopId === 'undefined') shopId = global.info.queryInfo.shopId;
356
355
  if (typeof venderId === 'undefined') venderId = global.info.queryInfo.venderId;
357
356
  this.jdNavigateToNative(
358
357
  Object.assign(
359
358
  {},
360
359
  {
361
360
  category: 'jump',
362
361
  des: 'jshopMain',
363
362
  jumpTab: 'allProduct',
364
363
  operation: 'jumpTabInner',
365
364
  },
366
365
  shopId !== 'undefined'
367
366
  ? {
368
367
  shopId,
369
368
  }
370
369
  : {},
371
370
  venderId !== 'undefined'
372
371
  ? {
373
372
  venderId,
374
373
  }
375
374
  : {},
376
375
  {
377
376
  logEventInfo,
378
377
  },
379
378
  ),
380
379
  );
381
380
  }
382
381
 
383
382
  jdJumpToShopBase(shopInfo) {
384
383
  console.log('[降级H5] jdJumpToShopBase jdJumpJdApp');
385
384
  const getParam = Object.assign(
386
385
  {},
387
386
  {
388
387
  category: 'jump',
389
388
  des: 'jshopMain',
390
389
  jumpTab: HOME_TOP_TAB_TYPE_APP.HOME,
391
390
  shopId: global.info.queryInfo.shopId,
392
391
  venderId: global.info.queryInfo.venderId,
393
392
  sourceInfo: APP_SOURCE_INFO,
394
393
  },
395
394
  shopInfo,
396
395
  );
397
396
  this.jdNavigateToNative(getParam);
398
397
  }
399
398
 
400
399
  jdJumpToTabNew(shopInfo = {}) {
401
400
  const getParam = Object.assign(
402
401
  {},
403
402
  {
404
403
  jumpTab: HOME_TOP_TAB_TYPE_APP.NEW,
405
404
  },
406
405
  shopInfo,
407
406
  );
408
407
  this.jdJumpToShopBase(getParam);
409
408
  }
410
409
 
411
410
  jdJumpToTabNewInner(shopInfo = {}) {
412
411
  const getParam = Object.assign(
413
412
  {},
414
413
  {
415
414
  jumpTab: HOME_TOP_TAB_TYPE_APP.NEW,
416
415
  operation: 'jumpTabInner',
417
416
  },
418
417
  shopInfo,
419
418
  );
420
419
  this.jdJumpToShopBase(getParam);
421
420
  }
422
421
  jdJumpToTabRank(shopInfo = {}) {
423
422
  const getParam = Object.assign(
424
423
  {},
425
424
  {
426
425
  jumpTab: HOME_TOP_TAB_TYPE_APP.RANK,
427
426
  },
428
427
  shopInfo,
429
428
  );
430
429
  this.jdJumpToShopBase(getParam);
431
430
  }
432
431
  jdJumpToTabRankInner(shopInfo = {}) {
433
432
  const getParam = Object.assign(
434
433
  {},
435
434
  {
436
435
  jumpTab: HOME_TOP_TAB_TYPE_APP.RANK,
437
436
  operation: 'jumpTabInner',
438
437
  },
439
438
  shopInfo,
440
439
  );
441
440
  this.jdJumpToShopBase(getParam);
442
441
  }
443
442
  jdJumpToTabBuyerShow(shopInfo = {}) {
444
443
  const getParam = Object.assign(
445
444
  {},
446
445
  {
447
446
  jumpTab: HOME_TOP_TAB_TYPE_APP.BUYERSHOW,
448
447
  },
449
448
  shopInfo,
450
449
  );
451
450
  this.jdJumpToShopBase(getParam);
452
451
  }
453
452
  jdJumpToTabBuyerShowInner(shopInfo = {}) {
454
453
  const getParam = Object.assign(
455
454
  {},
456
455
  {
457
456
  jumpTab: HOME_TOP_TAB_TYPE_APP.BUYERSHOW,
458
457
  operation: 'jumpTabInner',
459
458
  },
460
459
  shopInfo,
461
460
  );
462
461
  this.jdJumpToShopBase(getParam);
463
462
  }
464
463
  jdJumpToTabActivity(shopInfo = {}) {
465
464
  const getParam = Object.assign(
466
465
  {},
467
466
  {
468
467
  jumpTab: HOME_TOP_TAB_TYPE_APP.ACTIVITY,
469
468
  },
470
469
  shopInfo,
471
470
  );
472
471
  this.jdJumpToShopBase(getParam);
473
472
  }
474
473
  jdJumpToTabActivityInner(shopInfo = {}) {
475
474
  const getParam = Object.assign(
476
475
  {},
477
476
  {
478
477
  jumpTab: HOME_TOP_TAB_TYPE_APP.ACTIVITY,
479
478
  operation: 'jumpTabInner',
480
479
  },
481
480
  shopInfo,
482
481
  );
483
482
  this.jdJumpToShopBase(getParam);
484
483
  }
485
484
  jdJumpToTabSecKill(shopInfo = {}) {
486
485
  const getParam = Object.assign(
487
486
  {},
488
487
  {
489
488
  jumpTab: HOME_TOP_TAB_TYPE_APP.SECKILL,
490
489
  },
491
490
  shopInfo,
492
491
  );
493
492
  this.jdJumpToShopBase(getParam);
494
493
  }
495
494
  jdJumpToTabSecKillInner(shopInfo = {}) {
496
495
  const getParam = Object.assign(
497
496
  {},
498
497
  {
499
498
  jumpTab: HOME_TOP_TAB_TYPE_APP.SECKILL,
500
499
  operation: 'jumpTabInner',
501
500
  },
502
501
  shopInfo,
503
502
  );
504
503
  this.jdJumpToShopBase(getParam);
505
504
  }
506
505
 
507
506
  jdJumpToBottomTabBase(type, shopInfo = {}) {
508
507
  this.jdNavigateToNative(
509
508
  Object.assign(
510
509
  {},
511
510
  {
512
511
  category: 'jump',
513
512
  des: 'jshopMain',
514
513
  shopId: global.info.queryInfo.shopId,
515
514
  venderId: global.info.queryInfo.venderId,
516
515
  jumpBottomTab: type,
517
516
  sourceInfo: APP_SOURCE_INFO,
518
517
  },
519
518
  shopInfo,
520
519
  ),
521
520
  );
522
521
  }
523
522
 
524
523
  jdJumpToBottomTabProduct(shopInfo = {}) {
525
524
  this.jdJumpToBottomTabBase(BOTTOM_TAB_TYPE_APP.PRODUCT, shopInfo);
526
525
  }
527
526
 
528
527
  jdJumpToBottomTabCategory(shopInfo = {}) {
529
528
  this.jdJumpToBottomTabBase(BOTTOM_TAB_TYPE_APP.CATEGORY, shopInfo);
530
529
  }
531
530
 
532
531
  jdJumpToBottomTabFind(shopInfo = {}) {
533
532
  this.jdJumpToBottomTabBase(BOTTOM_TAB_TYPE_APP.FIND, shopInfo);
534
533
  }
535
534
 
536
535
  jdJumpToBottomTabBrandMember(shopInfo = {}) {
537
536
  this.jdJumpToBottomTabBase(BOTTOM_TAB_TYPE_APP.BRANDMEMBER, shopInfo);
538
537
  }
539
538
 
540
539
  jdJumpToBottomTabBrandMemberInner(shopInfo = {}) {
541
540
  this.jdJumpToMemberTab(shopInfo);
542
541
  }
543
542
 
544
543
  jdJumpToWeb(
545
544
  url,
546
545
  logEventInfo,
547
546
  successBack?: functionType | undefined,
548
547
  failBack?: functionType | undefined,
549
548
  ) {
550
549
  const changeUrl = /^\/\//.test(url) ? `https:${url}` : url;
551
550
  this.jdNavigateToNative(
552
551
  {
553
552
  category: 'jump',
554
553
  des: 'm',
555
554
  url: encodeURIComponent(changeUrl),
556
555
  logEventInfo,
557
556
  },
558
557
  OpenAppHost,
559
558
  successBack,
560
559
  failBack,
561
560
  );
562
561
  }
563
562
 
564
563
  jdJumpToLive(clickUrlOrObj, logEventInfo) {
565
564
  if (typeof clickUrlOrObj === 'object') {
566
565
  this.jdNavigateToNative({
567
566
  category: 'jump',
568
567
  des: 'LivePlayerRoom',
569
568
  liveOrigin: '1',
570
569
  needLogin: '0',
571
570
  isNeedVideo: true,
572
571
  logEventInfo,
573
572
  ...clickUrlOrObj,
574
573
  });
575
574
  } else {
576
575
  const getShopLiveParams = this.jdOpenAppParams(clickUrlOrObj);
577
576
  console.log('getShopLiveParams=====', getShopLiveParams);
578
577
  if (typeof getShopLiveParams === 'object') {
579
578
  this.jdNavigateToNative({
580
579
  ...getShopLiveParams,
581
580
  logEventInfo,
582
581
  });
583
582
  }
584
583
  }
585
584
  }
586
585
 
587
586
  jdJumpToUgcContent(urlObj, logEventInfo = {}) {
588
587
  if (typeof urlObj === 'object') {
589
588
  this.jdNavigateToNative({
590
589
  category: 'jump',
591
590
  des: 'shareOrderUgcContent',
592
591
  channel: 'shopshangxin',
593
592
  cmtType: '10',
594
593
  isNeedVideo: true,
595
594
  ...urlObj,
596
595
  logEventInfo,
597
596
  });
598
597
  } else {
599
598
  const getShopUgcParams = this.jdOpenAppParams(urlObj);
600
599
  if (getShopUgcParams) {
601
600
  getShopUgcParams['logEventInfo'] = logEventInfo;
602
601
  console.log('getShopUgcParams=====', getShopUgcParams);
603
602
  getShopUgcParams && this.jdNavigateToNative(getShopUgcParams as string);
604
603
  }
605
604
  }
606
605
  }
607
606
 
608
607
  jdJumpToSeckillNewBrand(brandId) {
609
608
  this.jdNavigateToNative({
610
609
  category: 'jump',
611
610
  des: 'seckillnewbrand',
612
611
  brandId: `${brandId}`,
613
612
  });
614
613
  }
615
614
 
616
615
  jdJumpToJshopDynamicDetail(info) {
617
616
  this.jdNavigateToNative({
618
617
  category: 'jump',
619
618
  des: 'jshopDynamicDetail',
620
619
  shopId: global.info.queryInfo.shopId,
621
620
  venderId: global.info.queryInfo.venderId,
622
621
  ...info,
623
622
  });
624
623
  }
625
624
 
626
625
  jdJumpToRankList(rankingId, rankType, logEventInfo) {
627
626
  this.jdNavigateToNative(
628
627
  Object.assign(
629
628
  {},
630
629
  {
631
630
  category: 'jump',
632
631
  des: 'jdreactcommon',
633
632
  modulename: 'JDReactRankingList',
634
633
  appname: 'JDReactRankingList',
635
634
  transparentenable: true,
636
635
  ishidden: true,
637
636
  param: {
638
637
  contentId: '' + rankingId,
639
638
  fromSkuId: '',
640
639
  detailPageType: '5',
641
640
  rankType: rankType || 10 + '',
642
641
  },
643
642
  logEventInfo,
644
643
  },
645
644
  ),
646
645
  );
647
646
  }
648
647
 
649
648
  jdJumpToFlashSaleTab(logEventInfo) {
650
649
  this.jdNavigateToNative(
651
650
  Object.assign(
652
651
  {},
653
652
  {
654
653
  category: 'jump',
655
654
  des: 'jshopMain',
656
655
  jumpTab: 'flashPurchase',
657
656
  shopId: global.info.queryInfo.shopId,
658
657
  venderId: global.info.queryInfo.venderId,
659
658
  sourceType: 'JDReactShopActivityTAB',
660
659
  sourceValue: '2',
661
660
  operation: 'jumpTabInner',
662
661
  logEventInfo,
663
662
  },
664
663
  ),
665
664
  );
666
665
  }
667
666
 
668
667
 
669
668
  jdJumpToShopMemberInfo(logEventInfo) {
670
669
  this.jdNavigateToNative(
671
670
  Object.assign(
672
671
  {},
673
672
  {
674
673
  category: 'jump',
675
674
  des: 'jdreactcommon',
676
675
  modulename: 'JDReactShopMember',
677
676
  appname: 'JDReactShopMember',
678
677
  ishidden: true,
679
678
  param: {
680
679
  page: 'memberInfo',
681
680
  shopId: global.info.queryInfo.shopId,
682
681
  venderId: global.info.queryInfo.venderId,
683
682
  },
684
683
  logEventInfo,
685
684
  },
686
685
  ),
687
686
  );
688
687
  }
689
688
 
690
689
  jdJumpToShopMemberBenefit(logEventInfo) {
691
690
  const venderId = global.info.queryInfo.venderId;
692
691
  const shopId = global.info.queryInfo.shopId;
693
692
  this.jdJumpToWeb(
694
693
  `${this.jumpWebUrl.memberBenefit}?venderId=${venderId}&shopId=${shopId}`,
695
694
  logEventInfo,
696
695
  );
697
696
  }
698
697
 
699
698
  jdJumpToShopMemberPointExchange(venderType, levelZeroMenuUrl, logEventInfo) {
700
699
  this.jdNavigateToNative(
701
700
  Object.assign(
702
701
  {},
703
702
  {
704
703
  category: 'jump',
705
704
  des: 'jdreactcommon',
706
705
  modulename: 'JDReactShopMember',
707
706
  appname: 'JDReactShopMember',
708
707
  ishidden: true,
709
708
  param: {
710
709
  page: 'pointsExchangePage',
711
710
  shopId: global.info.queryInfo.shopId,
712
711
  venderId: global.info.queryInfo.venderId,
713
712
  levelZeroMenuUrl,
714
713
  },
715
714
  logEventInfo,
716
715
  },
717
716
  ),
718
717
  );
719
718
  }
720
719
 
721
720
  jdJumpToShopMemberBonusPurchase(customerLevel, logEventInfo) {
722
721
  this.jdNavigateToNative(
723
722
  Object.assign(
724
723
  {},
725
724
  {
726
725
  category: 'jump',
727
726
  des: 'jdreactcommon',
728
727
  modulename: 'JDReactShopMember',
729
728
  appname: 'JDReactShopMember',
730
729
  ishidden: true,
731
730
  param: {
732
731
  page: 'bonusPurchase',
733
732
  shopId: global.info.queryInfo.shopId,
734
733
  venderId: global.info.queryInfo.venderId,
735
734
  customerLevel,
736
735
  },
737
736
  logEventInfo,
738
737
  },
739
738
  ),
740
739
  );
741
740
  }
742
741
 
743
742
  jdJumpToMyRedEnvelope(logEventInfo) {
744
743
  this.jdNavigateToNative(
745
744
  Object.assign(
746
745
  {},
747
746
  {
748
747
  category: 'jump',
749
748
  des: 'jdreactcommon',
750
749
  modulename: 'JDReactMyRedEnvelope',
751
750
  appname: 'JDReactMyRedEnvelope',
752
751
  ishidden: true,
753
752
  fromName: 2,
754
753
  needLogin: true,
755
754
  logEventInfo,
756
755
  },
757
756
  ),
758
757
  );
759
758
  }
760
759
 
761
760
  jdJumpToMyCoupon(logEventInfo) {
762
761
  this.jdNavigateToNative(
763
762
  Object.assign(
764
763
  {},
765
764
  {
766
765
  category: 'jump',
767
766
  des: 'mycoupon',
768
767
  logEventInfo,
769
768
  },
770
769
  ),
771
770
  );
772
771
  }
773
772
 
774
773
 
775
774
  jdJumpToMiniProgram({ vapptype, appId, path, param }) {
776
775
  const pageName = param['pageType'] || 'home';
777
776
  const nowMiniPath = `pages/${pageName}/index`;
778
777
  if (appId === global.info.pageInfo.appId) {
779
778
  Taro.navigateTo({
780
779
  url: `/${nowMiniPath}?${objectToUrlEncode(param)}`,
781
780
  }).catch((err) => {
782
781
  console.warn('跳转小程序页面错误:', err);
783
782
  });
784
783
  } else {
785
784
  const params = {
786
785
  category: 'jump',
787
786
  des: 'jdmp',
788
787
  appId,
789
788
  vapptype,
790
789
  param,
791
790
  path: '',
792
791
  };
793
792
  if (path) {
794
793
  params.path = `${path}.html`;
795
794
  }
796
795
  this.jdNavigateToNative(params);
797
796
  }
798
797
  }
799
798
 
800
799
  jdJumpToAppMiniProgram(
801
800
  path: string,
802
801
  param = {},
803
802
  successBack?: functionType,
804
803
  failBack?: functionType,
805
804
  ) {
806
805
  this.jdNavigateToNative(param, path, successBack, failBack);
807
806
  }
808
807
 
809
808
  jdNavigateToNative(
810
809
  params: object,
811
810
  url = OpenAppHost,
812
811
  successBack?: functionType | undefined,
813
812
  failBack?: functionType | undefined,
814
813
  ) {
815
814
  console.log('[降级H5] jdNavigateToNative jdJumJdApp:', params);
816
815
  const getResParams: JumpEventReportInterFace.JdMiniJumpParams = Object.assign(
817
816
  {},
818
817
  {
819
818
  sourceValue: 'sourceValue_jshopMini',
820
819
  sourceType: 'sourceType_jshopMini',
821
820
  param: {},
822
821
  },
823
822
  params,
824
823
  );
825
824
  const { logEventInfo, ...otherParams } = getResParams;
826
825
  console.log('jdNavigateToNative params: ', getResParams);
827
826
  console.log('logEventInfo params: ', logEventInfo);
828
827
  this.clickEventLog(logEventInfo || getResParams, getResParams.des);
829
828
  jd.navigateToNative({
830
829
  dataParam: {
831
830
  url: url,
832
831
  params: otherParams,
833
832
  },
834
833
  success(res) {
835
834
  typeof successBack === 'function' && successBack(res);
836
835
  console.log('navigateToNative.success', res);
837
836
  },
838
837
  fail(res) {
839
838
  typeof failBack === 'function' && failBack(res);
840
839
  console.log('navigateToNative.fail', res);
841
840
  },
842
841
  });
843
842
  }
844
843
 
845
844
  clickEventLog(opts: JumpEventReportInterFace.OptEventLogParams = {}, clickKey = 'click') {
846
845
  const { eventId, jsonParam, eventLevel = 3, skuId, ...otherParams } = opts;
847
846
  if (eventId && jsonParam) {
848
847
  const { etModelInfo, logBaseInfo } = jsonParam;
849
848
  let getJsonParam = {};
850
849
  if (etModelInfo && logBaseInfo) {
851
850
  getJsonParam = logBaseInfo;
852
851
  } else {
853
852
  if (Array.isArray(jsonParam)) {
854
853
  getJsonParam = jsonParam;
855
854
  } else {
856
855
  getJsonParam = Object.assign(
857
856
  {},
858
857
  {
859
858
  shopid: global.info.queryInfo?.shopId,
860
859
  },
861
860
  jsonParam,
862
861
  );
863
862
  }
864
863
  }
865
864
  if (
866
865
  clickKey === 'exposure' &&
867
866
  /^TerminatorNew/.test(eventId) &&
868
867
  !Array.isArray(getJsonParam)
869
868
  ) {
870
869
  getJsonParam = [getJsonParam];
871
870
  }
872
871
  const miniLogParams = {
873
872
  eid: eventId,
874
873
  elevel: eventLevel,
875
874
  eparam: JSON.stringify(getJsonParam),
876
875
  pageId: this.logPageId,
877
876
  pname: this.logPname,
878
877
  pparam: JSON.stringify(this.routerInfo.params),
879
878
  target: this.routerInfo.path,
880
879
  event: this.nativeEvent,
881
880
  ...otherParams,
882
881
  };
883
882
  if (clickKey === 'addToCart' && skuId) {
884
883
  miniLogParams['shoppingList'] = {
885
884
  [skuId]: 1,
886
885
  };
887
886
  }
888
887
  console.log('点击埋点参数对象', miniLogParams, clickKey);
889
888
  global.miniAppLogInstance && global.miniAppLogInstance[clickKey](miniLogParams);
890
889
  } else {
891
890
  console.log('暂无埋点参数eventId和eventParam');
892
891
  }
893
892
  }
894
893
 
895
894
  exposureEventLog(opts: JumpEventReportInterFace.OptEventLogParams = {}) {
896
895
  return this.clickEventLog(opts, 'exposure');
897
896
  }
898
897
 
899
898
  jdJumpToSearch(shopId, suggestWord) {
900
899
  if (typeof shopId === 'undefined') shopId = global.info.queryInfo.shopId;
901
900
  this.jdNavigateToNative({
902
901
  category: 'jump',
903
902
  des: 'jshopGuessWord',
904
903
  shopId: String(shopId),
905
904
  transparentEnable: true,
906
905
  suggestWord,
907
906
  sourceInfo: APP_SOURCE_INFO,
908
907
  });
909
908
  }
910
909
 
911
910
  jdJumpToMyMessageBox() {
912
911
  this.jdNavigateToNative({
913
912
  category: 'jump',
914
913
  des: 'myMessageBox',
915
914
  });
916
915
  }
917
916
 
918
917
  jdJumpToAppHome() {
919
918
  this.jdNavigateToNative({
920
919
  category: 'jump',
921
920
  des: 'HomePage',
922
921
  });
923
922
  }
924
923
 
925
924
  jdJumpToShopHomeDetail({ shopId, venderId }) {
926
925
  this.jdNavigateToNative({
927
926
  category: 'jump',
928
927
  des: 'jshopDetail',
929
928
  shopId: String(shopId),
930
929
  venderId: String(venderId),
931
930
  });
932
931
  }
933
932
 
934
933
  jdJumpToShopLottery(shopTotalInfo) {
935
934
  this.jdNavigateToNative(
936
935
  Object.assign(
937
936
  {},
938
937
  {
939
938
  category: 'jump',
940
939
  des: 'jshopSign',
941
940
  activityRuleType: '0',
942
941
  shopId: global.info.queryInfo.shopId,
943
942
  venderId: global.info.queryInfo.venderId,
944
943
  },
945
944
  shopTotalInfo,
946
945
  ),
947
946
  );
948
947
  }
949
948
 
950
949
  jdJumpToSageAuthorHome(shopTotalInfo) {
951
950
  this.jdNavigateToNative(
952
951
  Object.assign(
953
952
  {},
954
953
  {
955
954
  category: 'jump',
956
955
  des: 'faxian_author',
957
956
  channel: 'shopHomePage',
958
957
  selectTab: '0',
959
958
  },
960
959
  shopTotalInfo,
961
960
  ),
962
961
  );
963
962
  }
963
+ import Taro from '@tarojs/taro';
964
964
  entrance: 'shop-page-tab',
965
965
  moduleId: 'shop-modular-floor',
966
966
 
967
967
  jdJumpToProduct(skuIds, logEventInfo, otherParams = {}) {
968
968
  skuIds = skuIds.toString().trim();
969
969
  const getSkuId = skuIds.indexOf(',') !== -1 ? skuIds.split(',')[0] : skuIds;
970
970
  const openAppParam = {
971
971
  category: 'jump',
972
972
  des: 'productDetail',
973
973
  skuId: getSkuId,
974
974
  logEventInfo,
975
975
  ...otherParams,
976
976
  };
977
977
  const adInfos = getAdInfoBySkuId(getSkuId);
978
978
  if (adInfos) {
979
979
  openAppParam.pdExtFlag = {
980
980
  adInfos,
981
981
  };
982
982
  }
983
983
  this.jdNavigateToNative(openAppParam);
984
984
  }
985
985
 
986
986
  jdJumpSkuInfoToProduct(skuInfo: any = {}, logEventInfo) {
987
987
  const getSkuId = skuInfo?.skuId;
988
988
  this.jdJumpToProduct(getSkuId, logEventInfo);
989
989
  }
990
990
 
991
991
  jdJumpToShopCategory(shopInfo = {}) {
992
992
  console.log(
993
993
  '🚀 ~ file: jdJumpJdApp.ts:40 ~ JdJumpJdApp ~ jdJumpToShopCategory ~ shopInfo:',
994
994
  shopInfo,
995
995
  );
996
996
  console.log('[降级H5] jdJumpToShopCategory jdJumpJdApp');
997
997
  this.jdNavigateToNative(
998
998
  Object.assign(
999
999
  {},
1000
1000
  {
1001
1001
  category: 'jump',
1002
1002
  des: 'jshopMain',
1003
1003
  jumpBottomTab: 'category',
1004
1004
  },
1005
1005
  shopInfo,
1006
1006
  {
1007
1007
  shopId: String(shopInfo.shopId ?? ''),
1008
1008
  venderId: String(shopInfo.venderId ?? ''),
1009
1009
  },
1010
1010
  ),
1011
1011
  );
1012
1012
  }
1013
1013
 
1014
1014
  jdJumpToOrderInfoView(wareId, wareNum = 1, logEventInfo) {
1015
1015
  this.jdNavigateToNative({
1016
1016
  category: 'jump',
1017
1017
  des: 'orderInfoView',
1018
1018
  wareId: `${wareId}`,
1019
1019
  wareNum: global.info.sysInfo.isIOS ? `${wareNum}` : wareNum,
1020
1020
  skuSource: 25,
1021
1021
  sourceType: 6,
1022
1022
  extFlag: '{}',
1023
1023
  logEventInfo,
1024
1024
  });
1025
1025
  }
1026
1026
 
1027
1027
  jdJumpToTryDetail(tryId) {
1028
1028
  this.jdNavigateToNative({
1029
1029
  category: 'jump',
1030
1030
  des: 'jdreactcommon',
1031
1031
  appname: 'JDReactNewProduct',
1032
1032
  modulename: 'JDReactNewProduct',
1033
1033
  param: {
1034
1034
  activityId: tryId,
1035
1035
  isNative: true,
1036
1036
  nativePage: 'jdtry_detail',
1037
1037
  transparentenable: true,
1038
1038
  },
1039
1039
  });
1040
1040
  }
1041
1041
 
1042
1042
  jdJumpToShopHome(shopInfo: JumpEventReportInterFace.ShopIdsInfo = {}) {
1043
1043
  console.log('[降级H5] jdJumpToShopHome jdJumpJdApp');
1044
1044
  const currentShopInfo = {
1045
1045
  shopId: global.info.queryInfo.shopId,
1046
1046
  venderId: global.info.queryInfo.venderId,
1047
1047
  };
1048
1048
  const restParams =
1049
1049
  (shopInfo?.shopId && shopInfo.shopId !== currentShopInfo.shopId) ||
1050
1050
  (shopInfo?.venderId && shopInfo.venderId !== currentShopInfo.venderId)
1051
1051
  ? {}
1052
1052
  : currentShopInfo;
1053
1053
  const getInfo = Object.assign({}, restParams, shopInfo);
1054
1054
  const getShopParams = this.getShopIdsInfo(getInfo);
1055
1055
  this.jdJumpToShopBase(getShopParams);
1056
1056
  }
1057
1057
 
1058
1058
  jdJumpToShopHomeInner(shopInfo: JumpEventReportInterFace.ShopIdsInfo = {}) {
1059
1059
  const getParam = Object.assign(
1060
1060
  {},
1061
1061
  {
1062
1062
  jumpTab: HOME_TOP_TAB_TYPE_APP.HOME,
1063
1063
  operation: 'jumpTabInner',
1064
1064
  },
1065
1065
  shopInfo,
1066
1066
  );
1067
1067
  this.jdJumpToShopBase(getParam);
1068
1068
  }
1069
1069
 
1070
1070
  jdJumpToUnifieddetail(sourceInfo) {
1071
1071
  this.jdNavigateToNative(
1072
1072
  Object.assign(
1073
1073
  {},
1074
1074
  {
1075
1075
  category: 'jump',
1076
1076
  des: 'unifieddetail',
1077
1077
  },
1078
1078
  sourceInfo,
1079
1079
  ),
1080
1080
  );
1081
1081
  }
1082
1082
 
1083
1083
  jdJumpToVideoImmersion(sourceInfo) {
1084
1084
  this.jdNavigateToNative(
1085
1085
  Object.assign(
1086
1086
  {},
1087
1087
  {
1088
1088
  category: 'jump',
1089
1089
  des: 'VideoImmersion',
1090
1090
  },
1091
1091
  sourceInfo,
1092
1092
  ),
1093
1093
  );
1094
1094
  }
1095
1095
 
1096
1096
  jdJumpToShopMember(shopInfo) {
1097
1097
  this.jdNavigateToNative(
1098
1098
  Object.assign(
1099
1099
  {},
1100
1100
  {
1101
1101
  category: 'jump',
1102
1102
  des: 'jshopMember',
1103
1103
  followAward: '-1',
1104
1104
  },
1105
1105
  shopInfo,
1106
1106
  ),
1107
1107
  );
1108
1108
  }
1109
1109
 
1110
1110
  jdJumpToMemberTab(shopInfo?) {
1111
1111
  this.jdNavigateToNative(
1112
1112
  Object.assign(
1113
1113
  {},
1114
1114
  {
1115
1115
  category: 'jump',
1116
1116
  des: 'jshopMain',
1117
1117
  shopId: global.info.queryInfo.shopId,
1118
1118
  venderId: global.info.queryInfo.venderId,
1119
1119
  operation: 'jumpBottomTabMember',
1120
1120
  sourceInfo: APP_SOURCE_INFO,
1121
1121
  },
1122
1122
  shopInfo,
1123
1123
  ),
1124
1124
  );
1125
1125
  }
1126
1126
 
1127
1127
  jdJumpToDongDongChatGroup(groupId, source = 'jdmini') {
1128
1128
  this.jdNavigateToNative({
1129
1129
  category: 'jump',
1130
1130
  des: 'dongdong_group_chat',
1131
1131
  source: source,
1132
1132
  groupId: `${groupId}`,
1133
1133
  });
1134
1134
  }
1135
1135
 
1136
1136
  jdJumpToDongDongChat(paramInfo: any = {}) {
1137
1137
  const { venderId, ...otherParams } = paramInfo;
1138
1138
  this.jdNavigateToNative(
1139
1139
  Object.assign(
1140
1140
  {},
1141
1141
  {
1142
1142
  category: 'jump',
1143
1143
  des: 'jd_dongdong_chat',
1144
1144
  venderId: `${venderId ? venderId : global.info.queryInfo?.venderId}`,
1145
1145
  entry: 'm_shop',
1146
1146
  },
1147
1147
  otherParams,
1148
1148
  ),
1149
1149
  );
1150
1150
  }
1151
1151
 
1152
1152
  jdJumpToShopActivity(shopInfo) {
1153
1153
  const getParams = Object.assign(
1154
1154
  {},
1155
1155
  {
1156
1156
  category: 'jump',
1157
1157
  des: 'jshopActivity',
1158
1158
  shopId: global.info.queryInfo.shopId,
1159
1159
  venderId: global.info.queryInfo.venderId,
1160
1160
  },
1161
1161
  shopInfo,
1162
1162
  );
1163
1163
  getParams['projectId'] && (getParams['projectId'] = `${getParams['projectId']}`);
1164
1164
  this.jdNavigateToNative(getParams);
1165
1165
  }
1166
1166
 
1167
1167
  jdJumpToShopActivityPage(shopInfo) {
1168
1168
  this.jdNavigateToNative(
1169
1169
  Object.assign(
1170
1170
  {},
1171
1171
  {
1172
1172
  category: 'jump',
1173
1173
  des: 'jshopActivityPage',
1174
1174
  shopId: global.info.queryInfo.shopId,
1175
1175
  title: global.info.queryInfo?.shopName,
1176
1176
  },
1177
1177
  shopInfo,
1178
1178
  ),
1179
1179
  );
1180
1180
  }
1181
1181
 
1182
1182
  jdJumpToShopDetail(shopInfo) {
1183
1183
  this.jdNavigateToNative(
1184
1184
  Object.assign(
1185
1185
  {},
1186
1186
  {
1187
1187
  category: 'jump',
1188
1188
  des: 'jshopDetail',
1189
1189
  shopId: global.info.queryInfo.shopId,
1190
1190
  venderId: global.info.queryInfo.venderId,
1191
1191
  sourceInfo: APP_SOURCE_INFO,
1192
1192
  },
1193
1193
  shopInfo,
1194
1194
  ),
1195
1195
  );
1196
1196
  }
1197
1197
 
1198
1198
  jdJumpToShopMemberCard(shopInfo) {
1199
1199
  const { url, logEventInfo } = shopInfo;
1200
1200
  if (this.isOpenJdAppUrl(url)) {
1201
1201
  const getOpenAppParams = this.jdOpenAppParams(url);
1202
1202
  console.log('jd web 获取自定义openApp链接解析后的参数结果', getOpenAppParams);
1203
1203
  if (getOpenAppParams) {
1204
1204
  this.jdNavigateToNative(Object.assign({}, getOpenAppParams, { logEventInfo }));
1205
1205
  }
1206
1206
  } else {
1207
1207
  super.jdJumpToWeb(url, {
1208
1208
  ...logEventInfo,
1209
1209
  });
1210
1210
  }
1211
1211
  }
1212
1212
 
1213
1213
  jdJumpToTotalPromotion(shopInfo) {
1214
1214
  const { url, logEventInfo } = shopInfo;
1215
1215
  if (this.isOpenJdAppUrl(url)) {
1216
1216
  const getOpenAppParams = this.jdOpenAppParams(url);
1217
1217
  console.log('jd web 获取自定义openApp链接解析后的参数结果', getOpenAppParams);
1218
1218
  if (getOpenAppParams) {
1219
1219
  this.jdNavigateToNative(Object.assign({}, getOpenAppParams, { logEventInfo }));
1220
1220
  }
1221
1221
  } else {
1222
1222
  super.jdJumpToWeb(url, {
1223
1223
  ...logEventInfo,
1224
1224
  });
1225
1225
  }
1226
1226
  }
1227
1227
 
1228
1228
  jdJumpToShopSearch(pageInfo = {}) {
1229
1229
  const getInfo = Object.assign(
1230
1230
  {},
1231
1231
  {
1232
1232
  shopId: global.info.queryInfo.shopId,
1233
1233
  venderId: global.info.queryInfo.venderId,
1234
1234
  sourceInfo: APP_SOURCE_INFO,
1235
1235
  },
1236
1236
  pageInfo,
1237
1237
  );
1238
1238
  const { keyword = '', categoryId = '', ...otherPageInfo }: any = getInfo;
1239
1239
  const searchInfo = {};
1240
1240
  if (categoryId !== '') {
1241
1241
  searchInfo['categoryId'] = typeof categoryId === 'string' ? categoryId?.trim() : categoryId;
1242
1242
  searchInfo['searchType'] = '5';
1243
1243
  } else if (keyword !== '') {
1244
1244
  searchInfo['keyWord'] = keyword;
1245
1245
  searchInfo['searchType'] = '4';
1246
1246
  }
1247
1247
  const openAppParam = {
1248
1248
  category: 'jump',
1249
1249
  des: 'jshopProductList',
1250
1250
  pageId: '1',
1251
1251
  ...searchInfo,
1252
1252
  };
1253
1253
  const jumpExtMap = getEnterShopExtInfo();
1254
1254
  if (jumpExtMap) {
1255
1255
  openAppParam.jumpExtMap = jumpExtMap;
1256
1256
  }
1257
1257
  this.jdNavigateToNative(Object.assign({}, openAppParam, otherPageInfo));
1258
1258
  }
1259
1259
 
1260
1260
  jdJumpToOrderList(logEventInfo = {}) {
1261
1261
  this.jdNavigateToNative(
1262
1262
  Object.assign(
1263
1263
  {},
1264
1264
  {
1265
1265
  category: 'jump',
1266
1266
  des: 'orderlist',
1267
1267
  from: 'dphycc',
1268
1268
  },
1269
1269
  logEventInfo,
1270
1270
  ),
1271
1271
  );
1272
1272
  }
1273
1273
 
1274
1274
  jdJumpToCouponSearchProductList(couponId, logEventInfo = {}) {
1275
1275
  this.jdNavigateToNative(
1276
1276
  Object.assign(
1277
1277
  {},
1278
1278
  {
1279
1279
  category: 'jump',
1280
1280
  des: 'productList',
1281
1281
  from: 'couponBatch',
1282
1282
  couponId: `${couponId}`,
1283
1283
  logEventInfo,
1284
1284
  },
1285
1285
  ),
1286
1286
  );
1287
1287
  }
1288
1288
 
1289
1289
  jdJumpToTabAllProduct(shopId, venderId, logEventInfo = {}) {
1290
1290
  console.log('jdJumpJdApp - jdJumpToTabAllProduct');
1291
1291
  if (typeof shopId === 'undefined') shopId = global.info.queryInfo.shopId;
1292
1292
  if (typeof venderId === 'undefined') venderId = global.info.queryInfo.venderId;
1293
1293
  this.jdNavigateToNative(
1294
1294
  Object.assign(
1295
1295
  {},
1296
1296
  {
1297
1297
  category: 'jump',
1298
1298
  des: 'jshopMain',
1299
1299
  jumpTab: 'allProduct',
1300
1300
  },
1301
1301
  shopId !== 'undefined'
1302
1302
  ? {
1303
1303
  shopId,
1304
1304
  }
1305
1305
  : {},
1306
1306
  venderId !== 'undefined'
1307
1307
  ? {
1308
1308
  venderId,
1309
1309
  }
1310
1310
  : {},
1311
1311
  {
1312
1312
  logEventInfo,
1313
1313
  },
1314
1314
  ),
1315
1315
  );
1316
1316
  }
1317
1317
 
1318
1318
  jdJumpToTabAllProductInner(shopId, venderId, logEventInfo = {}) {
1319
1319
  if (typeof shopId === 'undefined') shopId = global.info.queryInfo.shopId;
1320
1320
  if (typeof venderId === 'undefined') venderId = global.info.queryInfo.venderId;
1321
1321
  this.jdNavigateToNative(
1322
1322
  Object.assign(
1323
1323
  {},
1324
1324
  {
1325
1325
  category: 'jump',
1326
1326
  des: 'jshopMain',
1327
1327
  jumpTab: 'allProduct',
1328
1328
  operation: 'jumpTabInner',
1329
1329
  },
1330
1330
  shopId !== 'undefined'
1331
1331
  ? {
1332
1332
  shopId,
1333
1333
  }
1334
1334
  : {},
1335
1335
  venderId !== 'undefined'
1336
1336
  ? {
1337
1337
  venderId,
1338
1338
  }
1339
1339
  : {},
1340
1340
  {
1341
1341
  logEventInfo,
1342
1342
  },
1343
1343
  ),
1344
1344
  );
1345
1345
  }
1346
1346
 
1347
1347
  jdJumpToShopBase(shopInfo) {
1348
1348
  console.log('[降级H5] jdJumpToShopBase jdJumpJdApp');
1349
1349
  const currentShopInfo = {
1350
1350
  shopId: global.info.queryInfo.shopId,
1351
1351
  venderId: global.info.queryInfo.venderId,
1352
1352
  };
1353
1353
  const restParams =
1354
1354
  (shopInfo?.shopId && shopInfo.shopId !== currentShopInfo.shopId) ||
1355
1355
  (shopInfo?.venderId && shopInfo.venderId !== currentShopInfo.venderId)
1356
1356
  ? {}
1357
1357
  : currentShopInfo;
1358
1358
  const getParam = Object.assign(
1359
1359
  {},
1360
1360
  {
1361
1361
  category: 'jump',
1362
1362
  des: 'jshopMain',
1363
1363
  jumpTab: HOME_TOP_TAB_TYPE_APP.HOME,
1364
1364
  ...restParams,
1365
1365
  sourceInfo: APP_SOURCE_INFO,
1366
1366
  },
1367
1367
  shopInfo,
1368
1368
  );
1369
1369
  this.jdNavigateToNative(getParam);
1370
1370
  }
1371
1371
 
1372
1372
  jdJumpToTabNew(shopInfo = {}) {
1373
1373
  const getParam = Object.assign(
1374
1374
  {},
1375
1375
  {
1376
1376
  jumpTab: HOME_TOP_TAB_TYPE_APP.NEW,
1377
1377
  },
1378
1378
  shopInfo,
1379
1379
  );
1380
1380
  this.jdJumpToShopBase(getParam);
1381
1381
  }
1382
1382
 
1383
1383
  jdJumpToTabNewInner(shopInfo = {}) {
1384
1384
  const getParam = Object.assign(
1385
1385
  {},
1386
1386
  {
1387
1387
  jumpTab: HOME_TOP_TAB_TYPE_APP.NEW,
1388
1388
  operation: 'jumpTabInner',
1389
1389
  },
1390
1390
  shopInfo,
1391
1391
  );
1392
1392
  this.jdJumpToShopBase(getParam);
1393
1393
  }
1394
1394
  jdJumpToTabRank(shopInfo = {}) {
1395
1395
  const getParam = Object.assign(
1396
1396
  {},
1397
1397
  {
1398
1398
  jumpTab: HOME_TOP_TAB_TYPE_APP.RANK,
1399
1399
  },
1400
1400
  shopInfo,
1401
1401
  );
1402
1402
  this.jdJumpToShopBase(getParam);
1403
1403
  }
1404
1404
  jdJumpToTabRankInner(shopInfo = {}) {
1405
1405
  const getParam = Object.assign(
1406
1406
  {},
1407
1407
  {
1408
1408
  jumpTab: HOME_TOP_TAB_TYPE_APP.RANK,
1409
1409
  operation: 'jumpTabInner',
1410
1410
  },
1411
1411
  shopInfo,
1412
1412
  );
1413
1413
  this.jdJumpToShopBase(getParam);
1414
1414
  }
1415
1415
  jdJumpToTabBuyerShow(shopInfo = {}) {
1416
1416
  const getParam = Object.assign(
1417
1417
  {},
1418
1418
  {
1419
1419
  jumpTab: HOME_TOP_TAB_TYPE_APP.BUYERSHOW,
1420
1420
  },
1421
1421
  shopInfo,
1422
1422
  );
1423
1423
  this.jdJumpToShopBase(getParam);
1424
1424
  }
1425
1425
  jdJumpToTabBuyerShowInner(shopInfo = {}) {
1426
1426
  const getParam = Object.assign(
1427
1427
  {},
1428
1428
  {
1429
1429
  jumpTab: HOME_TOP_TAB_TYPE_APP.BUYERSHOW,
1430
1430
  operation: 'jumpTabInner',
1431
1431
  },
1432
1432
  shopInfo,
1433
1433
  );
1434
1434
  this.jdJumpToShopBase(getParam);
1435
1435
  }
1436
1436
  jdJumpToTabActivity(shopInfo = {}) {
1437
1437
  const getParam = Object.assign(
1438
1438
  {},
1439
1439
  {
1440
1440
  jumpTab: HOME_TOP_TAB_TYPE_APP.ACTIVITY,
1441
1441
  },
1442
1442
  shopInfo,
1443
1443
  );
1444
1444
  this.jdJumpToShopBase(getParam);
1445
1445
  }
1446
1446
  jdJumpToTabActivityInner(shopInfo = {}) {
1447
1447
  const getParam = Object.assign(
1448
1448
  {},
1449
1449
  {
1450
1450
  jumpTab: HOME_TOP_TAB_TYPE_APP.ACTIVITY,
1451
1451
  operation: 'jumpTabInner',
1452
1452
  },
1453
1453
  shopInfo,
1454
1454
  );
1455
1455
  this.jdJumpToShopBase(getParam);
1456
1456
  }
1457
1457
  jdJumpToTabSecKill(shopInfo = {}) {
1458
1458
  const getParam = Object.assign(
1459
1459
  {},
1460
1460
  {
1461
1461
  jumpTab: HOME_TOP_TAB_TYPE_APP.SECKILL,
1462
1462
  },
1463
1463
  shopInfo,
1464
1464
  );
1465
1465
  this.jdJumpToShopBase(getParam);
1466
1466
  }
1467
1467
  jdJumpToTabSecKillInner(shopInfo = {}) {
1468
1468
  const getParam = Object.assign(
1469
1469
  {},
1470
1470
  {
1471
1471
  jumpTab: HOME_TOP_TAB_TYPE_APP.SECKILL,
1472
1472
  operation: 'jumpTabInner',
1473
1473
  },
1474
1474
  shopInfo,
1475
1475
  );
1476
1476
  this.jdJumpToShopBase(getParam);
1477
1477
  }
1478
1478
 
1479
1479
  jdJumpToBottomTabBase(type, shopInfo = {}) {
1480
1480
  this.jdNavigateToNative(
1481
1481
  Object.assign(
1482
1482
  {},
1483
1483
  {
1484
1484
  category: 'jump',
1485
1485
  des: 'jshopMain',
1486
1486
  shopId: global.info.queryInfo.shopId,
1487
1487
  venderId: global.info.queryInfo.venderId,
1488
1488
  jumpBottomTab: type,
1489
1489
  sourceInfo: APP_SOURCE_INFO,
1490
1490
  },
1491
1491
  shopInfo,
1492
1492
  ),
1493
1493
  );
1494
1494
  }
1495
1495
 
1496
1496
  jdJumpToBottomTabProduct(shopInfo = {}) {
1497
1497
  this.jdJumpToBottomTabBase(BOTTOM_TAB_TYPE_APP.PRODUCT, shopInfo);
1498
1498
  }
1499
1499
 
1500
1500
  jdJumpToBottomTabCategory(shopInfo = {}) {
1501
1501
  this.jdJumpToBottomTabBase(BOTTOM_TAB_TYPE_APP.CATEGORY, shopInfo);
1502
1502
  }
1503
1503
 
1504
1504
  jdJumpToBottomTabFind(shopInfo = {}) {
1505
1505
  this.jdJumpToBottomTabBase(BOTTOM_TAB_TYPE_APP.FIND, shopInfo);
1506
1506
  }
1507
1507
 
1508
1508
  jdJumpToBottomTabBrandMember(shopInfo = {}) {
1509
1509
  this.jdJumpToBottomTabBase(BOTTOM_TAB_TYPE_APP.BRANDMEMBER, shopInfo);
1510
1510
  }
1511
1511
 
1512
1512
  jdJumpToBottomTabBrandMemberInner(shopInfo = {}) {
1513
1513
  this.jdJumpToMemberTab(shopInfo);
1514
1514
  }
1515
1515
 
1516
1516
  jdJumpToWeb(
1517
1517
  url,
1518
1518
  logEventInfo,
1519
1519
  successBack?: functionType | undefined,
1520
1520
  failBack?: functionType | undefined,
1521
1521
  ) {
1522
1522
  const changeUrl = /^\/\//.test(url) ? `https:${url}` : url;
1523
1523
  this.jdNavigateToNative(
1524
1524
  {
1525
1525
  category: 'jump',
1526
1526
  des: 'm',
1527
1527
  url: encodeURIComponent(changeUrl),
1528
1528
  logEventInfo,
1529
1529
  },
1530
1530
  OpenAppHost,
1531
1531
  successBack,
1532
1532
  failBack,
1533
1533
  );
1534
1534
  }
1535
1535
 
1536
1536
  jdJumpToLive(clickUrlOrObj, logEventInfo) {
1537
1537
  if (typeof clickUrlOrObj === 'object') {
1538
1538
  this.jdNavigateToNative({
1539
1539
  category: 'jump',
1540
1540
  des: 'LivePlayerRoom',
1541
1541
  liveOrigin: '1',
1542
1542
  needLogin: '0',
1543
1543
  isNeedVideo: true,
1544
1544
  logEventInfo,
1545
1545
  ...clickUrlOrObj,
1546
1546
  });
1547
1547
  } else {
1548
1548
  const getShopLiveParams = this.jdOpenAppParams(clickUrlOrObj);
1549
1549
  console.log('getShopLiveParams=====', getShopLiveParams);
1550
1550
  if (typeof getShopLiveParams === 'object') {
1551
1551
  this.jdNavigateToNative({
1552
1552
  ...getShopLiveParams,
1553
1553
  logEventInfo,
1554
1554
  });
1555
1555
  }
1556
1556
  }
1557
1557
  }
1558
1558
 
1559
1559
  jdJumpToUgcContent(urlObj, logEventInfo = {}) {
1560
1560
  if (typeof urlObj === 'object') {
1561
1561
  this.jdNavigateToNative({
1562
1562
  category: 'jump',
1563
1563
  des: 'shareOrderUgcContent',
1564
1564
  channel: 'shopshangxin',
1565
1565
  cmtType: '10',
1566
1566
  isNeedVideo: true,
1567
1567
  ...urlObj,
1568
1568
  logEventInfo,
1569
1569
  });
1570
1570
  } else {
1571
1571
  const getShopUgcParams = this.jdOpenAppParams(urlObj);
1572
1572
  if (getShopUgcParams) {
1573
1573
  getShopUgcParams['logEventInfo'] = logEventInfo;
1574
1574
  console.log('getShopUgcParams=====', getShopUgcParams);
1575
1575
  getShopUgcParams && this.jdNavigateToNative(getShopUgcParams as string);
1576
1576
  }
1577
1577
  }
1578
1578
  }
1579
1579
 
1580
1580
  jdJumpToSeckillNewBrand(brandId) {
1581
1581
  this.jdNavigateToNative({
1582
1582
  category: 'jump',
1583
1583
  des: 'seckillnewbrand',
1584
1584
  brandId: `${brandId}`,
1585
1585
  });
1586
1586
  }
1587
1587
 
1588
1588
  jdJumpToJshopDynamicDetail(info) {
1589
1589
  this.jdNavigateToNative({
1590
1590
  category: 'jump',
1591
1591
  des: 'jshopDynamicDetail',
1592
1592
  shopId: global.info.queryInfo.shopId,
1593
1593
  venderId: global.info.queryInfo.venderId,
1594
1594
  ...info,
1595
1595
  });
1596
1596
  }
1597
1597
 
1598
1598
  jdJumpToRankList(rankingId, rankType, logEventInfo) {
1599
1599
  this.jdNavigateToNative(
1600
1600
  Object.assign(
1601
1601
  {},
1602
1602
  {
1603
1603
  category: 'jump',
1604
1604
  des: 'jdreactcommon',
1605
1605
  modulename: 'JDReactRankingList',
1606
1606
  appname: 'JDReactRankingList',
1607
1607
  transparentenable: true,
1608
1608
  ishidden: true,
1609
1609
  param: {
1610
1610
  contentId: '' + rankingId,
1611
1611
  fromSkuId: '',
1612
1612
  detailPageType: '5',
1613
1613
  rankType: rankType || 10 + '',
1614
1614
  },
1615
1615
  logEventInfo,
1616
1616
  },
1617
1617
  ),
1618
1618
  );
1619
1619
  }
1620
1620
 
1621
1621
  jdJumpToFlashSaleTab(logEventInfo) {
1622
1622
  this.jdNavigateToNative(
1623
1623
  Object.assign(
1624
1624
  {},
1625
1625
  {
1626
1626
  category: 'jump',
1627
1627
  des: 'jshopMain',
1628
1628
  jumpTab: 'flashPurchase',
1629
1629
  shopId: global.info.queryInfo.shopId,
1630
1630
  venderId: global.info.queryInfo.venderId,
1631
1631
  sourceType: 'JDReactShopActivityTAB',
1632
1632
  sourceValue: '2',
1633
1633
  operation: 'jumpTabInner',
1634
1634
  logEventInfo,
1635
1635
  },
1636
1636
  ),
1637
1637
  );
1638
1638
  }
1639
1639
 
1640
1640
 
1641
1641
  jdJumpToShopMemberInfo(logEventInfo) {
1642
1642
  this.jdNavigateToNative(
1643
1643
  Object.assign(
1644
1644
  {},
1645
1645
  {
1646
1646
  category: 'jump',
1647
1647
  des: 'jdreactcommon',
1648
1648
  modulename: 'JDReactShopMember',
1649
1649
  appname: 'JDReactShopMember',
1650
1650
  ishidden: true,
1651
1651
  param: {
1652
1652
  page: 'memberInfo',
1653
1653
  shopId: global.info.queryInfo.shopId,
1654
1654
  venderId: global.info.queryInfo.venderId,
1655
1655
  },
1656
1656
  logEventInfo,
1657
1657
  },
1658
1658
  ),
1659
1659
  );
1660
1660
  }
1661
1661
 
1662
1662
  jdJumpToShopMemberBenefit(logEventInfo) {
1663
1663
  const venderId = global.info.queryInfo.venderId;
1664
1664
  const shopId = global.info.queryInfo.shopId;
1665
1665
  this.jdJumpToWeb(
1666
1666
  `${this.jumpWebUrl.memberBenefit}?venderId=${venderId}&shopId=${shopId}`,
1667
1667
  logEventInfo,
1668
1668
  );
1669
1669
  }
1670
1670
 
1671
1671
  jdJumpToShopMemberPointExchange(venderType, levelZeroMenuUrl, logEventInfo) {
1672
1672
  this.jdNavigateToNative(
1673
1673
  Object.assign(
1674
1674
  {},
1675
1675
  {
1676
1676
  category: 'jump',
1677
1677
  des: 'jdreactcommon',
1678
1678
  modulename: 'JDReactShopMember',
1679
1679
  appname: 'JDReactShopMember',
1680
1680
  ishidden: true,
1681
1681
  param: {
1682
1682
  page: 'pointsExchangePage',
1683
1683
  shopId: global.info.queryInfo.shopId,
1684
1684
  venderId: global.info.queryInfo.venderId,
1685
1685
  levelZeroMenuUrl,
1686
1686
  },
1687
1687
  logEventInfo,
1688
1688
  },
1689
1689
  ),
1690
1690
  );
1691
1691
  }
1692
1692
 
1693
1693
  jdJumpToShopMemberBonusPurchase(customerLevel, logEventInfo) {
1694
1694
  this.jdNavigateToNative(
1695
1695
  Object.assign(
1696
1696
  {},
1697
1697
  {
1698
1698
  category: 'jump',
1699
1699
  des: 'jdreactcommon',
1700
1700
  modulename: 'JDReactShopMember',
1701
1701
  appname: 'JDReactShopMember',
1702
1702
  ishidden: true,
1703
1703
  param: {
1704
1704
  page: 'bonusPurchase',
1705
1705
  shopId: global.info.queryInfo.shopId,
1706
1706
  venderId: global.info.queryInfo.venderId,
1707
1707
  customerLevel,
1708
1708
  },
1709
1709
  logEventInfo,
1710
1710
  },
1711
1711
  ),
1712
1712
  );
1713
1713
  }
1714
1714
 
1715
1715
  jdJumpToMyRedEnvelope(logEventInfo) {
1716
1716
  this.jdNavigateToNative(
1717
1717
  Object.assign(
1718
1718
  {},
1719
1719
  {
1720
1720
  category: 'jump',
1721
1721
  des: 'jdreactcommon',
1722
1722
  modulename: 'JDReactMyRedEnvelope',
1723
1723
  appname: 'JDReactMyRedEnvelope',
1724
1724
  ishidden: true,
1725
1725
  fromName: 2,
1726
1726
  needLogin: true,
1727
1727
  logEventInfo,
1728
1728
  },
1729
1729
  ),
1730
1730
  );
1731
1731
  }
1732
1732
 
1733
1733
  jdJumpToMyCoupon(logEventInfo) {
1734
1734
  this.jdNavigateToNative(
1735
1735
  Object.assign(
1736
1736
  {},
1737
1737
  {
1738
1738
  category: 'jump',
1739
1739
  des: 'mycoupon',
1740
1740
  logEventInfo,
1741
1741
  },
1742
1742
  ),
1743
1743
  );
1744
1744
  }
1745
1745
 
1746
1746
 
1747
1747
  jdJumpToMiniProgram({ vapptype, appId, path, param }) {
1748
1748
  const pageName = param['pageType'] || 'home';
1749
1749
  const nowMiniPath = `pages/${pageName}/index`;
1750
1750
  if (appId === global.info.pageInfo.appId) {
1751
1751
  Taro.navigateTo({
1752
1752
  url: `/${nowMiniPath}?${objectToUrlEncode(param)}`,
1753
1753
  }).catch((err) => {
1754
1754
  console.warn('跳转小程序页面错误:', err);
1755
1755
  });
1756
1756
  } else {
1757
1757
  const params = {
1758
1758
  category: 'jump',
1759
1759
  des: 'jdmp',
1760
1760
  appId,
1761
1761
  vapptype,
1762
1762
  param,
1763
1763
  path: '',
1764
1764
  };
1765
1765
  if (path) {
1766
1766
  params.path = `${path}.html`;
1767
1767
  }
1768
1768
  this.jdNavigateToNative(params);
1769
1769
  }
1770
1770
  }
1771
1771
 
1772
1772
  jdJumpToAppMiniProgram(
1773
1773
  path: string,
1774
1774
  param = {},
1775
1775
  successBack?: functionType,
1776
1776
  failBack?: functionType,
1777
1777
  ) {
1778
1778
  this.jdNavigateToNative(param, path, successBack, failBack);
1779
1779
  }
1780
1780
 
1781
1781
  jdNavigateToNative(
1782
1782
  params: object,
1783
1783
  url = OpenAppHost,
1784
1784
  successBack?: functionType | undefined,
1785
1785
  failBack?: functionType | undefined,
1786
1786
  ) {
1787
1787
  console.log('[降级H5] jdNavigateToNative jdJumJdApp:', params);
1788
1788
  const getResParams: JumpEventReportInterFace.JdMiniJumpParams = Object.assign(
1789
1789
  {},
1790
1790
  {
1791
1791
  sourceValue: 'sourceValue_jshopMini',
1792
1792
  sourceType: 'sourceType_jshopMini',
1793
1793
  param: {},
1794
1794
  },
1795
1795
  params,
1796
1796
  );
1797
1797
  const { logEventInfo, ...otherParams } = getResParams;
1798
1798
  console.log('jdNavigateToNative params: ', getResParams);
1799
1799
  console.log('logEventInfo params: ', logEventInfo);
1800
1800
  this.clickEventLog(logEventInfo || getResParams, getResParams.des);
1801
1801
  jd.navigateToNative({
1802
1802
  dataParam: {
1803
1803
  url: url,
1804
1804
  params: otherParams,
1805
1805
  },
1806
1806
  success(res) {
1807
1807
  typeof successBack === 'function' && successBack(res);
1808
1808
  console.log('navigateToNative.success', res);
1809
1809
  },
1810
1810
  fail(res) {
1811
1811
  typeof failBack === 'function' && failBack(res);
1812
1812
  console.log('navigateToNative.fail', res);
1813
1813
  },
1814
1814
  });
1815
1815
  }
1816
1816
 
1817
1817
  clickEventLog(opts: JumpEventReportInterFace.OptEventLogParams = {}, clickKey = 'click') {
1818
1818
  const { eventId, jsonParam, eventLevel = 3, skuId, ...otherParams } = opts;
1819
1819
  if (eventId && jsonParam) {
1820
1820
  const { etModelInfo, logBaseInfo } = jsonParam;
1821
1821
  let getJsonParam = {};
1822
1822
  if (etModelInfo && logBaseInfo) {
1823
1823
  getJsonParam = logBaseInfo;
1824
1824
  } else {
1825
1825
  if (Array.isArray(jsonParam)) {
1826
1826
  getJsonParam = jsonParam;
1827
1827
  } else {
1828
1828
  getJsonParam = Object.assign(
1829
1829
  {},
1830
1830
  {
1831
1831
  shopid: global.info.queryInfo?.shopId,
1832
1832
  },
1833
1833
  jsonParam,
1834
1834
  );
1835
1835
  }
1836
1836
  }
1837
1837
  if (
1838
1838
  clickKey === 'exposure' &&
1839
1839
  /^TerminatorNew/.test(eventId) &&
1840
1840
  !Array.isArray(getJsonParam)
1841
1841
  ) {
1842
1842
  getJsonParam = [getJsonParam];
1843
1843
  }
1844
1844
  const miniLogParams = {
1845
1845
  eid: eventId,
1846
1846
  elevel: eventLevel,
1847
1847
  eparam: JSON.stringify(getJsonParam),
1848
1848
  pageId: this.logPageId,
1849
1849
  pname: this.logPname,
1850
1850
  pparam: JSON.stringify(this.routerInfo.params),
1851
1851
  target: this.routerInfo.path,
1852
1852
  event: this.nativeEvent,
1853
1853
  ...otherParams,
1854
1854
  };
1855
1855
  if (clickKey === 'addToCart' && skuId) {
1856
1856
  miniLogParams['shoppingList'] = {
1857
1857
  [skuId]: 1,
1858
1858
  };
1859
1859
  }
1860
1860
  console.log('点击埋点参数对象', miniLogParams, clickKey);
1861
1861
  global.miniAppLogInstance && global.miniAppLogInstance[clickKey](miniLogParams);
1862
1862
  } else {
1863
1863
  console.log('暂无埋点参数eventId和eventParam');
1864
1864
  }
1865
1865
  }
1866
1866
 
1867
1867
  exposureEventLog(opts: JumpEventReportInterFace.OptEventLogParams = {}) {
1868
1868
  return this.clickEventLog(opts, 'exposure');
1869
1869
  }
1870
1870
 
1871
1871
  jdJumpToSearch(shopId, suggestWord) {
1872
1872
  if (typeof shopId === 'undefined') shopId = global.info.queryInfo.shopId;
1873
1873
  this.jdNavigateToNative({
1874
1874
  category: 'jump',
1875
1875
  des: 'jshopGuessWord',
1876
1876
  shopId: String(shopId),
1877
1877
  transparentEnable: true,
1878
1878
  suggestWord,
1879
1879
  sourceInfo: APP_SOURCE_INFO,
1880
1880
  });
1881
1881
  }
1882
1882
 
1883
1883
  jdJumpToMyMessageBox() {
1884
1884
  this.jdNavigateToNative({
1885
1885
  category: 'jump',
1886
1886
  des: 'myMessageBox',
1887
1887
  });
1888
1888
  }
1889
1889
 
1890
1890
  jdJumpToAppHome() {
1891
1891
  this.jdNavigateToNative({
1892
1892
  category: 'jump',
1893
1893
  des: 'HomePage',
1894
1894
  });
1895
1895
  }
1896
1896
 
1897
1897
  jdJumpToShopHomeDetail({ shopId, venderId }) {
1898
1898
  this.jdNavigateToNative({
1899
1899
  category: 'jump',
1900
1900
  des: 'jshopDetail',
1901
1901
  shopId: String(shopId),
1902
1902
  venderId: String(venderId),
1903
1903
  });
1904
1904
  }
1905
1905
 
1906
1906
  jdJumpToShopLottery(shopTotalInfo) {
1907
1907
  this.jdNavigateToNative(
1908
1908
  Object.assign(
1909
1909
  {},
1910
1910
  {
1911
1911
  category: 'jump',
1912
1912
  des: 'jshopSign',
1913
1913
  activityRuleType: '0',
1914
1914
  shopId: global.info.queryInfo.shopId,
1915
1915
  venderId: global.info.queryInfo.venderId,
1916
1916
  },
1917
1917
  shopTotalInfo,
1918
1918
  ),
1919
1919
  );
1920
1920
  }
1921
1921
 
1922
1922
  jdJumpToSageAuthorHome(shopTotalInfo) {
1923
1923
  this.jdNavigateToNative(
1924
1924
  Object.assign(
1925
1925
  {},
1926
1926
  {
1927
1927
  category: 'jump',
1928
1928
  des: 'faxian_author',
1929
1929
  channel: 'shopHomePage',
1930
1930
  selectTab: '0',
1931
1931
  },
1932
1932
  shopTotalInfo,
1933
1933
  ),
1934
1934
  );
1935
1935
  }