From 67d134473c3f28b5f1b76cf343cdbbaeadafdc9e Mon Sep 17 00:00:00 2001 From: gaoxs Date: Mon, 10 Aug 2020 17:40:29 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 20 +++++++++++++++ components/ProductWindow.vue | 37 ++++++++++++--------------- pages/order/OrderSubmission/index.vue | 1 + pages/user/signIn/Integral/index.vue | 9 +++---- 4 files changed, 42 insertions(+), 25 deletions(-) diff --git a/README.md b/README.md index 3532314..e3615ec 100644 --- a/README.md +++ b/README.md @@ -21,6 +21,26 @@ - 如需修改样式问题,请编辑.less的文件,请勿编辑.css的文件 +## git issuse 地址 + +https://gitee.com/guchengwuyue/yshopmall + +### 请按照以下模板提交 issuse +标题: +H5/uni/后端代码/后台管理系统+简单描述 + +问题端: +H5/uni/后端代码/后台管理系统 + +代码版本: +v3.0 + +代码运行环境: +windows/macOS/Linux + +问题描述: +Ps:如果是uni出现问题,请具体描述是运行那个端小程序/android/ios + ## 声明 - app测试版已上,请通过 `https://www.pgyer.com/yRYf` 安装测试。 - 运行app项目ios需要安装xcode,安卓需要装安卓的sdk以及安卓模拟器,建议安卓安装genymotion https://www.genymotion.com/ 登录时可选择私人使用,勾选后无需付费 diff --git a/components/ProductWindow.vue b/components/ProductWindow.vue index a1b4ec9..2a522cd 100644 --- a/components/ProductWindow.vue +++ b/components/ProductWindow.vue @@ -9,7 +9,7 @@ {{ attr.productSelect.store_name }} ¥ - {{ attr.productSelect.price }} + {{ attr.productSelect.price+'' }} 库存: {{ attr.productSelect.stock }} @@ -55,54 +55,51 @@ export default { props: { attr: { type: Object, - default: () => {} + default: () => {}, }, cartNum: { type: Number, - default: () => 1 - } + default: () => 1, + }, }, - data: function() { + data: function () { return {}; }, - mounted: function() { + mounted: function () { console.log(this); }, methods: { - closeAttr: function() { + closeAttr: function () { this.$emit("changeFun", { action: "changeattr", value: false }); }, - CartNumDes: function() { + CartNumDes: function () { this.$emit("changeFun", { action: "ChangeCartNum", value: false }); }, - CartNumAdd: function() { + CartNumAdd: function () { this.$emit("changeFun", { action: "ChangeCartNum", value: 1 }); }, - tapAttr: function(indexw, indexn) { + tapAttr: function (indexw, indexn) { // 修改商品规格不生效的原因: // H5端下面写法,attr更新,但是除H5外其他端不支持, // 尽量避免下面的骚写法,不要在子组件内更新props // 这里修改是为了能获取到被选中的属性 this.attr.productAttr[indexw].index = indexn; let that = this; - let value = that - .getCheckedValue() - .sort() - .join(","); + let value = that.getCheckedValue().sort().join(","); that.$emit("changeFun", { action: "ChangeAttr", value: { value, indexw, - indexn - } + indexn, + }, }); }, //获取被选中属性; - getCheckedValue: function() { + getCheckedValue: function () { let productAttr = this.attr.productAttr; let value = []; - console.log(productAttr) + console.log(productAttr); for (let i = 0; i < productAttr.length; i++) { for (let j = 0; j < productAttr[i].attrValueArr.length; j++) { if (productAttr[i].index === j) { @@ -111,7 +108,7 @@ export default { } } return value; - } - } + }, + }, }; diff --git a/pages/order/OrderSubmission/index.vue b/pages/order/OrderSubmission/index.vue index 0c78d32..dcac7d8 100644 --- a/pages/order/OrderSubmission/index.vue +++ b/pages/order/OrderSubmission/index.vue @@ -486,6 +486,7 @@ export default { }, changeAddress(addressInfo) { this.addressInfo = addressInfo; + this.getCartInfo() }, createOrder() { let shipping_type = this.shipping_type; diff --git a/pages/user/signIn/Integral/index.vue b/pages/user/signIn/Integral/index.vue index 6662465..70f3188 100644 --- a/pages/user/signIn/Integral/index.vue +++ b/pages/user/signIn/Integral/index.vue @@ -44,9 +44,7 @@ > {{ item.title }} - - - +
{{ dataFormat(item.addTime) }}
+{{ item.number }} -{{ item.number }} @@ -74,12 +72,12 @@