youlaitech / mall-app Goto Github PK
View Code? Open in Web Editor NEWyoulai-mall 微信小程序/H5/Android/iOS 移动应用端,uni-app终极跨平台前端框架。
Home Page: http://app.youlai.tech
License: Apache License 2.0
youlai-mall 微信小程序/H5/Android/iOS 移动应用端,uni-app终极跨平台前端框架。
Home Page: http://app.youlai.tech
License: Apache License 2.0
请问有vue3版本的小程序吗
/pages/cart/cart.vue
购物车价格计算在非全选的状态下都是错误的,下面给一个参考实现:
changeCart() {
if (this.cartItems.length === 0) {
this.empty = true;
return;
}
let checked = true;
for (let i = 0; i < this.cartItems.length; i++) {
if (this.cartItems[i].checked === false) {
checked = false;
break;
}
}
this.allChecked = checked;
const checkedItemsList = this.cartItems.filter(item => item.checked)
if (!checkedItemsList || checkedItemsList.length === 0) {
this.totalPrice = 0
} else if (checkedItemsList.length === 1) {
this.totalPrice = checkedItemsList[0].count * checkedItemsList[0].price;
} else {
this.totalPrice = checkedItemsList.reduce((prev, curr) => {
return prev.price * prev.count + curr.price * curr.count
})
}
},
大佬 麻烦请教下 HubilderX 能做 vue3-element-admin 那种代码规范吗
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.