From 812bf3afc02f8e32fd8e7763cf0d0dddf4f08e4b Mon Sep 17 00:00:00 2001 From: fantasticbin Date: Mon, 20 Jun 2022 18:30:01 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E5=A4=9A=E4=BD=99=E4=BB=A3?= =?UTF-8?q?=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/ProductList.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/ProductList.vue b/src/components/ProductList.vue index 1615235..366145e 100644 --- a/src/components/ProductList.vue +++ b/src/components/ProductList.vue @@ -42,7 +42,7 @@ export default { if (this.numbers[product.id] === undefined) { // this.$set(this.numbers, product.id, 1); // Vue 3 已不再需要动态设置数据属性绑定了 - this.numbers[product.id] = product.inventory ? 1 : 0; + this.numbers[product.id] = 1; } }); },