From 1e8dc0ee9a426d2de3f68cc5bded3391fd537f63 Mon Sep 17 00:00:00 2001
From: "@fawn-nine" <1271023382@qq.com>
Date: Fri, 20 Oct 2023 14:34:01 +0800
Subject: [PATCH] =?UTF-8?q?=E8=AF=A6=E6=83=85=E9=A1=B5=E7=82=B9=E5=87=BB?=
=?UTF-8?q?=E5=9B=BE=E7=89=87=E6=94=BE=E5=A4=A7+=E5=90=AC=E4=B9=A6logo?=
=?UTF-8?q?=E4=B8=8D=E5=B1=85=E4=B8=AD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages/bookShop/commodityDetail.vue | 64 ++++++++++++++++++------------
pages/listen/home.vue | 17 +++++---
2 files changed, 51 insertions(+), 30 deletions(-)
diff --git a/pages/bookShop/commodityDetail.vue b/pages/bookShop/commodityDetail.vue
index 5e97b70..bca8187 100644
--- a/pages/bookShop/commodityDetail.vue
+++ b/pages/bookShop/commodityDetail.vue
@@ -8,7 +8,8 @@
-
+
+
@@ -36,7 +37,7 @@
-
+
{{item.productName}}
@@ -111,8 +112,8 @@
-
+
@@ -122,7 +123,8 @@
- 评价({{commentsList?commentsList.length:0}})
+ 评价({{commentsList?commentsList.length:0}})
+
@@ -176,7 +178,8 @@
-
+
查看详情
@@ -185,8 +188,8 @@
-
-
+
+
{{item.productName}}
-
@@ -213,7 +215,7 @@
import {
mapState
} from 'vuex';
- import loginVue from '../user/login.vue';
+ import loginVue from '../user/login.vue';
export default {
data() {
return {
@@ -223,7 +225,7 @@
options: [{
icon: 'cart',
text: '购物车'
- }],
+ }],
buttonGroup: [{
text: '加入购物车',
backgroundColor: 'linear-gradient(90deg, #FFCD1E, #FF8A18)',
@@ -253,7 +255,7 @@
listenList: [], // 关联得听书
linkProducts: [], // 关联的商品,
upoShow: false, // 显示底部购买选项
- linkCur: 0, // 当前选中的关联项
+ linkCur: 0, // 当前选中的关联项
}
},
onLoad(e) {
@@ -269,7 +271,13 @@
components: {
musicPlay
},
- methods: {
+ methods: {
+ showImg(e) {
+ // console.log(e,'点击的内容')
+ // let contentimg = e.target.dataset.nodes;
+ this.previewImage(e.target.node.attrs.src)
+ },
+
gotoDetail(item) {
// console.log(item,'gotoDetail')
uni.navigateTo({
@@ -295,14 +303,14 @@
})
.then(res => {
console.log('关联商品', res)
- if (res.code == 0) {
+ if (res.code == 0) {
if (res.result.length > 0) {
this.linkProducts = res.result
this.linkimg = this.linkProducts[0].productImages
this.linkCur = 0
- }else{
+ } else {
this.linkProducts = []
- }
+ }
}
})
.catch(e => {
@@ -320,9 +328,9 @@
console.log(url)
uni.previewImage({
urls: [url],
- longPressActions:{
- itemList:['很抱歉,暂不支持保存图片到本地'],
- success:function(res){
+ longPressActions: {
+ itemList: ['很抱歉,暂不支持保存图片到本地'],
+ success: function(res) {
// console.log(res,'+++++')
}
}
@@ -479,17 +487,17 @@
// console.log(e)
if (e.index == 0) {
// 点击的是加入购物车
- // console.log('+.........',this.linkProducts,'this.linkProducts')
- if (this.linkProducts.length == 0) {
- this.addCart()
+ // console.log('+.........',this.linkProducts,'this.linkProducts')
+ if (this.linkProducts.length == 0) {
+ this.addCart()
} else {
this.upoShow = true
}
} else {
// 点击的是立即购买
- if (this.linkProducts.length == 0) {
- this.goPurse()
+ if (this.linkProducts.length == 0) {
+ this.goPurse()
} else {
this.upoShow = true
}
@@ -699,6 +707,10 @@
'max-width:100%;');
return match;
});
+ // newContent = newContent.replace(/
]*>/gi, function(match, capture) {
+ // match = match.replace(/
]*>/gi, "@click='1111'").replace(/
]*>/gi, "@click='1111'");
+ // return match;
+ // });
newContent = newContent.replace(/
]*\/>/gi, '');
newContent = newContent.replace(/\
-
-
+
+
+
+
+