In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-03 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly explains "how to achieve the color effect of shopping cart selection specifications by WeChat Mini Programs". The explanation in the article is simple and clear, easy to learn and understand. Please follow the editor's ideas slowly and deeply. Let's study and learn how WeChat Mini Programs can achieve the color effect of shopping cart selection specifications.
The details are as follows:
Wxml:
Specification: {{item.name}} Color: {{item.name}} {{guige [gindex] .name}}: {{color [cindex] .name}}
Js:
/ / pages/guige/guige.jsPage (initial data of {/ * page * / data: {guige: [{id:1,name:'M'}, {id:2,name:'L'}, {id:3,name:'X'}, {id:4,name:'S'}], color: [{id:5,name:' Red'}, {id: 6 Name: 'orange'}, {id: 7, name: 'yellow'}, {id: 8, name: 'green'}]}, guige:function (e) {this.setData ({gid: e.currentTarget.dataset.index, gindex: e.currentTarget.dataset.current,})}, color:function (e) {this.setData ({cid: e.currentTarget.dataset.index) Cindex: e.currentTarget.dataset.current,})}, / * Lifecycle function-load the listening page * / onLoad: function (options) {}, / * Lifecycle function-completed the first rendering of the listening page * / onReady: function () {} / * Lifecycle function-listener page display * / onShow: function () {}, / * Lifecycle function-listener Page Hidden * / onHide: function () {}, / * Lifecycle function-listener Page Unload * / onUnload: function () {} / * Page-related event handler function-listens for user drop-down action * / onPullDownRefresh: function () {}, / * page event handler * / onReachBottom: function () {}, / * user clicks on the upper right corner to share * / onShareAppMessage: function () {}})
Css:
.color {color: red} .dis {display: flex;justify-content: space-around} thank you for reading, the above is "how to achieve the shopping cart selection specification color effect" content, after the study of this article, I believe that WeChat Mini Programs how to achieve shopping cart selection specification color effect of this problem has a deeper understanding, the specific use also needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 260
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.