# Other capacities

# 1、 Live Mini Program code


  • Mini Program must be released online after the introduction of live components Mini ProgramOtherwise, the Mini Program code in the live room will not take effect. The specific performance is that the user can scan the code to enter the live broadcast room and display "the page does not exist."

  • in MP Mini Program live background to create a good live room, you can directly get to the live room to share Mini Program codeNo additional development required

If the business in the background to generate their own broadcast room Mini Program code, need to do the following configuration: Jump to the path of the live room plus type = 9 Identify the scene entry with Mini Program code: "plugin-private://wx2b03c6e691cd7370/pages/live-player-pluginroom_id=[Live room id]&type=9"。 If you want to bring custom parameters, you also need to add custom_params: "plugin-private://wx2b03c6e691cd7370/pages/live-player-pluginroom_id=[Live room id]&type=9&custom_Parameters = encodeURIComponent(JSON.stringify(custom_params))"。

# 2、 merchant Official Account message template Article Add Mini Program card


Businesses are in Official Account message template Article to add a jump into the Mini Program card broadcast room, you need to do the following configuration: Jump to the path of the live room plus type = 10 Identify the scene entry to the Mini Program card: "plugin-private://wx2b03c6e691cd7370/pages/live-player-pluginroom_id=[Live room id]&type=10"。 If you want to bring custom parameters, you also need to add custom_params: "plugin-private://wx2b03c6e691cd7370/pages/live-player-pluginroom_id=[Live room id]&type=10&custom_Parameters = encodeURIComponent(JSON.stringify(custom_params))"。

# 3、 Product Details Note

(1) Add a back on: Click on the live component page of the shelf goods to jump to the commercial Mini Program product details page,In order to avoid users can not return to the live studio, businesses need to add a back on in the upper left corner of the Mini Program product details page, through wx.navigateBack to return to live components page.

If you click on a on (such as a shopping cart on) on the product details page, jump to the tabbar page via wx.switch Tab, Then click the small window to return to the live room when the page is stuck (WeChat client 7.0.15 version to fix). You can change the page to a non-tabbar page and jump through wx. navigateTo, or you can fix the problem by closing the small window.

(3) do not recommend the use of wx.reLaunch: If the product details page and the page elements after the use wx.Lunch jump, not only will close the window, and can not return to the previous page, the experience is not good.

# 4、 Method for Quickly Updating Live Component Version

Business Mini Program corresponding to the administrator micro signal**After receiving the service notice of the update of the live streaming component version issued by [Public Platform Security Assistant], you can click the notice for quick release.**The mobile terminal can quickly update the new version of the live component in the Mini Program without changing the code or resubmitting it for review.

# Service notifications are shown below:

Live Component Page

# 5、 Live cubicle

Version restrictions: live component version 1.3.0 And the above support through the following parameters set whether to close the small window.

close_picture_in_picture_Mode: the default support live small window, can be through close_picture_in_picture_Mode = 1 Turn off the small window function, such as "plugin-private://wx2b03c6e691cd7370/pages/live-player-pluginroom_Id = Live room number & close_picture_in_picture_mode=1 " 。

# 6、 Carry parameter

Version restrictions: live component version 1.3.0 And above support carry the following parameters, developers can establish according to these parameters users, live room, the mapping relationship between goods.

(1) Share Ticket: Share your card to the WeChat group, click on the card and you can share it in the App onShow Get this parameter (default can not get the parameter, can jump to live page path configuration open_share_ticket=1 open Share Ticket, such as "plugin-private://wx2b03c6e691cd7370/pages/live-player-pluginroom_Id = live room number & open_share_ticket=1 " , but you cannot forward a share card when you long press it. )

(2) room_id + openid + share_openid + custom_params Click on the live room shelf goods jump to the merchant Mini Program product details page or click on live room top left corner home icon jump to business Mini Program home page, you can Page onLoad Get room number, user openid, sharer share in options_Openid (if it is from the sharing card into the live broadcast and then jump to the business page to have this parameter), developers carry custom parameter custom_params