Showing
1 changed file
with
15 additions
and
3 deletions
@@ -515,17 +515,29 @@ module.exports = class extends global.yoho.BaseModel { | @@ -515,17 +515,29 @@ module.exports = class extends global.yoho.BaseModel { | ||
515 | * @returns {*} | 515 | * @returns {*} |
516 | */ | 516 | */ |
517 | sendWechatMessage(uid, actPrizeId, extra = {}) { | 517 | sendWechatMessage(uid, actPrizeId, extra = {}) { |
518 | + let info = {}; | ||
519 | + let baseUri = 'page/subPackage/pages/zeroSell/detail'; | ||
520 | + | ||
521 | + switch (+extra.miniAppType) { | ||
522 | + case 29: | ||
523 | + info.miniAppType = extra.miniAppType; | ||
524 | + baseUri = 'pages/zeroSell/detail'; | ||
525 | + break; | ||
526 | + default: | ||
527 | + break; | ||
528 | + } | ||
529 | + | ||
518 | return this.get({ | 530 | return this.get({ |
519 | - data: { | 531 | + data: Object.assign({ |
520 | method: 'wechat.message.send', | 532 | method: 'wechat.message.send', |
521 | sendScene: 'MINI_ACTIVITY_JOIN', | 533 | sendScene: 'MINI_ACTIVITY_JOIN', |
522 | params: JSON.stringify({ | 534 | params: JSON.stringify({ |
523 | activityTitle: extra.actName, | 535 | activityTitle: extra.actName, |
524 | activityTime: `${timeFormat(extra.actStartTime)} - ${timeFormat(extra.actEndTime)}`, | 536 | activityTime: `${timeFormat(extra.actStartTime)} - ${timeFormat(extra.actEndTime)}`, |
525 | - pageUrl: 'page/subPackage/pages/zeroSell/detail?actPrizeId=' + actPrizeId | 537 | + pageUrl: `${baseUri}?actPrizeId=${actPrizeId}` |
526 | }), | 538 | }), |
527 | uidList: [uid] | 539 | uidList: [uid] |
528 | - } | 540 | + }, info) |
529 | }); | 541 | }); |
530 | } | 542 | } |
531 | }; | 543 | }; |
-
Please register or login to post a comment