店铺首页
This commit is contained in:
commit
9377e4e869
|
@ -240,9 +240,9 @@ const shop = {
|
||||||
*/
|
*/
|
||||||
merchant(param) {
|
merchant(param) {
|
||||||
return util.request({
|
return util.request({
|
||||||
url: `/shopify/merchant`,
|
url: `/shopify/appMerInfoApi/getMerDetail`,
|
||||||
method: 'GET',
|
method: 'GET',
|
||||||
path: param.path,
|
query: param.query,
|
||||||
load: true,
|
load: true,
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
|
@ -6,7 +6,8 @@ const config = {
|
||||||
// host: 'h5api',
|
// host: 'h5api',
|
||||||
// #endif
|
// #endif
|
||||||
// #ifndef H5
|
// #ifndef H5
|
||||||
host: 'http://91f.xyz:8080',
|
// host: 'http://91f.xyz:8080',
|
||||||
|
host: 'http://chi9fe.natappfree.cc',
|
||||||
// #endif
|
// #endif
|
||||||
// 支付方式配置
|
// 支付方式配置
|
||||||
payType: {
|
payType: {
|
||||||
|
|
|
@ -586,11 +586,10 @@
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 只有公开赞显示点赞数 -->
|
<!-- 只有公开赞显示点赞数 -->
|
||||||
<view class="txt mt10" v-if="item.isLike && item.likeType == 0">
|
<view class="txt mt10">
|
||||||
<text class="text">{{ item.likeCount }}</text>
|
<text class="text" v-if="item.isLike == 0 && item.likeType == 0">{{ item.likeCount }}</text>
|
||||||
</view>
|
<text class="text" v-else-if="item.isLike == 0 && item.likeType == 1">隐私赞</text>
|
||||||
<view class="txt mt10" v-else>
|
<text class="text" v-else>点赞</text>
|
||||||
<text class="text">点赞</text>
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -89,23 +89,26 @@ function handleBuy() {
|
||||||
|
|
||||||
// 客服
|
// 客服
|
||||||
function toCustomer() {
|
function toCustomer() {
|
||||||
api.shop.getCustomerService({ merchantId: props.detail.merId }).then(rs => {
|
|
||||||
if (rs.code == 200) {
|
|
||||||
let param = {};
|
|
||||||
param.type = 'C2C'
|
|
||||||
param.name = `${props.detail.merName}`
|
|
||||||
param.msgId = `${rs.data.serviceId}`
|
|
||||||
param.isCustomer = true
|
|
||||||
|
|
||||||
util.toChat(param)
|
|
||||||
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: util.setUrl('/pages/news/chat/chat', param)
|
url: util.setUrl('/pages/mine/setting/feedback')
|
||||||
})
|
|
||||||
} else {
|
|
||||||
util.alert(rs.msg)
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
// api.shop.getCustomerService({ merchantId: props.detail.merId }).then(rs => {
|
||||||
|
// if (rs.code == 200) {
|
||||||
|
// let param = {};
|
||||||
|
// param.type = 'C2C'
|
||||||
|
// param.name = `${props.detail.merName}`
|
||||||
|
// param.msgId = `${rs.data.serviceId}`
|
||||||
|
// param.isCustomer = true
|
||||||
|
|
||||||
|
// util.toChat(param)
|
||||||
|
|
||||||
|
// uni.navigateTo({
|
||||||
|
// url: util.setUrl('/pages/news/chat/chat', param)
|
||||||
|
// })
|
||||||
|
// } else {
|
||||||
|
// util.alert(rs.msg)
|
||||||
|
// }
|
||||||
|
// })
|
||||||
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
@ -116,7 +119,7 @@ function toCustomer() {
|
||||||
<view class="menu df fdr jcsb aic">
|
<view class="menu df fdr jcsb aic">
|
||||||
<view class="option df fdc aic">
|
<view class="option df fdc aic">
|
||||||
<image class="wh30" src="/static/store.png" mode="aspectFit" />
|
<image class="wh30" src="/static/store.png" mode="aspectFit" />
|
||||||
<text class="text mt10">店铺</text>
|
<text class="text mt10" @click="link(`/pages/shop/store/index?storeId=${detail.merId}`)">店铺</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="option df fdc aic" @click="handleCollect">
|
<view class="option df fdc aic" @click="handleCollect">
|
||||||
|
|
|
@ -163,20 +163,16 @@
|
||||||
util.getMyTask()
|
util.getMyTask()
|
||||||
|
|
||||||
// 监听登录
|
// 监听登录
|
||||||
uni.$on('login', () => {
|
// uni.$on('login', () => {
|
||||||
recList.data.length = 0
|
// // 获取列表
|
||||||
attList.data.length = 0
|
// tabCurrent.value.refreshList()
|
||||||
nextTick(() => {
|
// })
|
||||||
// 获取列表
|
|
||||||
tabCurrent.value.refreshList()
|
|
||||||
})
|
|
||||||
})
|
|
||||||
|
|
||||||
// 监听登录
|
// 监听登录
|
||||||
uni.$on('logout', () => {
|
// uni.$on('logout', () => {
|
||||||
// 获取列表
|
// // 获取列表
|
||||||
tabCurrent.value.refreshList()
|
// tabCurrent.value.refreshList()
|
||||||
})
|
// })
|
||||||
|
|
||||||
// 视频数据被修改
|
// 视频数据被修改
|
||||||
uni.$on('updateVideo', (item) => {
|
uni.$on('updateVideo', (item) => {
|
||||||
|
|
|
@ -356,7 +356,7 @@ function toCommentsList() {
|
||||||
<view class="btns df">
|
<view class="btns df">
|
||||||
<template v-if="detail.isAttention == 0">
|
<template v-if="detail.isAttention == 0">
|
||||||
<view class="btn lg cancel f1" @click="handleAttention">已关注</view>
|
<view class="btn lg cancel f1" @click="handleAttention">已关注</view>
|
||||||
<view class="btn lg cancel f1 ml20" @click="handleMessage">私信</view>
|
<view class="btn lg cancel f1 ml20" @click="handleMessage" v-if="!userinfo.teenTime">私信</view>
|
||||||
</template>
|
</template>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<view class="btn lg focus f1" @click="handleAttention">关注</view>
|
<view class="btn lg focus f1" @click="handleAttention">关注</view>
|
||||||
|
@ -401,7 +401,7 @@ function toCommentsList() {
|
||||||
<view class="txt mt20 c111 f20">分享主页</view>
|
<view class="txt mt20 c111 f20">分享主页</view>
|
||||||
</view> -->
|
</view> -->
|
||||||
|
|
||||||
<view class="option ver jcc bfff br10" @click="handleMessage">
|
<view class="option ver jcc bfff br10" @click="handleMessage" v-if="!userinfo.teenTime">
|
||||||
<image class="wh50" src="/static/email.png" mode="aspectFit" />
|
<image class="wh50" src="/static/email.png" mode="aspectFit" />
|
||||||
<view class="txt mt20 c111 f20">私信Ta</view>
|
<view class="txt mt20 c111 f20">私信Ta</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -20,8 +20,8 @@
|
||||||
totalAmount: '',
|
totalAmount: '',
|
||||||
})
|
})
|
||||||
|
|
||||||
onLoad(() => {
|
onLoad((option) => {
|
||||||
//
|
if(option.amount) form.totalAmount = option.amount
|
||||||
})
|
})
|
||||||
|
|
||||||
// 充值
|
// 充值
|
||||||
|
|
|
@ -58,7 +58,6 @@ function toCustomer() {
|
||||||
|
|
||||||
util.toChat(param)
|
util.toChat(param)
|
||||||
|
|
||||||
|
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: util.setUrl('/pages/news/chat/chat', param)
|
url: util.setUrl('/pages/news/chat/chat', param)
|
||||||
})
|
})
|
||||||
|
|
|
@ -55,9 +55,11 @@
|
||||||
// 商品佣金
|
// 商品佣金
|
||||||
form.commission = detail.commission
|
form.commission = detail.commission
|
||||||
// 商品详情
|
// 商品详情
|
||||||
form.infoRichText = detail.infoRichText || ''
|
if (detail.infoRichText) {
|
||||||
|
form.infoRichText = JSON.parse(detail.infoRichText)
|
||||||
// 富文本编辑器初始化
|
// 富文本编辑器初始化
|
||||||
proxy.$refs.editorAreaRef.init(form.infoRichText)
|
proxy.$refs.editorAreaRef.init(form.infoRichText)
|
||||||
|
}
|
||||||
// 规格
|
// 规格
|
||||||
form.specs = detail.specs.map(item => {
|
form.specs = detail.specs.map(item => {
|
||||||
return {
|
return {
|
||||||
|
@ -176,7 +178,7 @@
|
||||||
*/
|
*/
|
||||||
function handleCate(ev) {
|
function handleCate(ev) {
|
||||||
let index = ev.detail.value
|
let index = ev.detail.value
|
||||||
if (index == categoryIndex.value) return
|
if (index === categoryIndex.value) return
|
||||||
categoryIndex.value = index
|
categoryIndex.value = index
|
||||||
form.categoryId = category[categoryIndex.value].id
|
form.categoryId = category[categoryIndex.value].id
|
||||||
}
|
}
|
||||||
|
@ -228,7 +230,11 @@
|
||||||
|
|
||||||
// 轮播图
|
// 轮播图
|
||||||
data.sliderImage = data.sliderImage.join(',')
|
data.sliderImage = data.sliderImage.join(',')
|
||||||
|
// 商品详情
|
||||||
|
// if (data.infoRichText) data.infoRichText = Buffer.from(data.infoRichText, 'utf8').toString('base64');
|
||||||
|
// if (data.infoRichText) data.infoRichText = JSON.stringify(data.infoRichText)
|
||||||
|
console.log(btoa, data.infoRichText)
|
||||||
|
return
|
||||||
//
|
//
|
||||||
api.shop.saveProduct({
|
api.shop.saveProduct({
|
||||||
data,
|
data,
|
||||||
|
|
|
@ -111,6 +111,20 @@
|
||||||
form.description = detail.description
|
form.description = detail.description
|
||||||
// //视频状态 0草稿 1待审核 2审核失败 3已发布 4已下架
|
// //视频状态 0草稿 1待审核 2审核失败 3已发布 4已下架
|
||||||
form.status = detail.status
|
form.status = detail.status
|
||||||
|
// 第几秒展示
|
||||||
|
if (detail.popupTime) form.popupTime = detail.popupTime
|
||||||
|
// 关联视频的商品id
|
||||||
|
if (detail.productId) {
|
||||||
|
form.productId = detail.productId
|
||||||
|
// 商品名称
|
||||||
|
form.productName = detail.productName
|
||||||
|
// 商品价格
|
||||||
|
form.productPrice = detail.productPrice
|
||||||
|
// 商品图片
|
||||||
|
form.productImage = detail.productImage
|
||||||
|
// 商品佣金
|
||||||
|
form.commission = detail.commission
|
||||||
|
}
|
||||||
// 回显话题列表
|
// 回显话题列表
|
||||||
if (detail.tagsList) labelSelect.push(...detail.tagsList)
|
if (detail.tagsList) labelSelect.push(...detail.tagsList)
|
||||||
// 匹配用户id
|
// 匹配用户id
|
||||||
|
@ -527,7 +541,7 @@
|
||||||
<view class="df oh mtb20">
|
<view class="df oh mtb20">
|
||||||
<view class="col oh df fdc jcsb f1 mr20">
|
<view class="col oh df fdc jcsb f1 mr20">
|
||||||
<view class="name">{{form.productName}}</view>
|
<view class="name">{{form.productName}}</view>
|
||||||
<view class="price thd cFF9B27 f28">
|
<view class="price thd mt10 cFF9B27 f28">
|
||||||
<text class="price thd mr20">价格{{form.productPrice}}</text>
|
<text class="price thd mr20">价格{{form.productPrice}}</text>
|
||||||
<text class="commission thd">佣金{{form.commission}}</text>
|
<text class="commission thd">佣金{{form.commission}}</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
|
@ -94,7 +94,10 @@
|
||||||
if (rs.code == 200) {
|
if (rs.code == 200) {
|
||||||
//
|
//
|
||||||
const result = rs.data
|
const result = rs.data
|
||||||
if (result.infoRichText) result.infoRichText = util.imgReplace(result.infoRichText)
|
if (result.infoRichText) {
|
||||||
|
result.infoRichText = JSON.parse(result.infoRichText)
|
||||||
|
result.infoRichText = util.imgReplace(result.infoRichText)
|
||||||
|
}
|
||||||
Object.assign(detail, {}, result)
|
Object.assign(detail, {}, result)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -131,7 +134,13 @@
|
||||||
|
|
||||||
// 拉起订单
|
// 拉起订单
|
||||||
function showMakeOrder() {
|
function showMakeOrder() {
|
||||||
|
util.isLogin(() => {
|
||||||
proxy.$refs.makeOrderRef.open()
|
proxy.$refs.makeOrderRef.open()
|
||||||
|
}).then(rs => {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: '/pages/login/loginPhone'
|
||||||
|
})
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -149,6 +149,14 @@
|
||||||
uni.$off('updateOrderDetail')
|
uni.$off('updateOrderDetail')
|
||||||
uni.navigateBack()
|
uni.navigateBack()
|
||||||
return
|
return
|
||||||
|
} else if (res.code === 501) {
|
||||||
|
util.alert(res.msg)
|
||||||
|
uni.navigateTo({
|
||||||
|
url: util.setUrl('/pages/index/wallet/topUp', {
|
||||||
|
amount: detail.totalPrice,
|
||||||
|
}),
|
||||||
|
})
|
||||||
|
return
|
||||||
}
|
}
|
||||||
util.alert({
|
util.alert({
|
||||||
content: res.msg,
|
content: res.msg,
|
||||||
|
|
|
@ -1,18 +1,25 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
// 店铺首页
|
// 店铺首页
|
||||||
import {
|
import {
|
||||||
ref
|
computed,
|
||||||
|
reactive,
|
||||||
|
ref,
|
||||||
|
defineExpose,
|
||||||
} from 'vue'
|
} from 'vue'
|
||||||
import {
|
import {
|
||||||
onLoad,
|
onLoad,
|
||||||
onPageScroll
|
onPageScroll
|
||||||
} from '@dcloudio/uni-app';
|
} from '@dcloudio/uni-app';
|
||||||
|
|
||||||
|
// 工具库
|
||||||
|
import util from '@/common/js/util.js'
|
||||||
// 顶部
|
// 顶部
|
||||||
import apex from '@/components/header/apex.vue'
|
import apex from '@/components/header/apex.vue'
|
||||||
// 商品列表
|
// 商品列表
|
||||||
import productList from '@/components/shop/productList/productList'
|
import productList from '@/components/shop/productList/productList'
|
||||||
|
|
||||||
|
import api from '@/api/index.js'
|
||||||
|
|
||||||
// 分类选项
|
// 分类选项
|
||||||
const filteredList = ref([{
|
const filteredList = ref([{
|
||||||
label: '默认',
|
label: '默认',
|
||||||
|
@ -39,9 +46,25 @@
|
||||||
const apexBgColor = ref('#ffffff00')
|
const apexBgColor = ref('#ffffff00')
|
||||||
// 店铺id
|
// 店铺id
|
||||||
const storeId = ref('')
|
const storeId = ref('')
|
||||||
|
// 详情
|
||||||
|
const detail = reactive({})
|
||||||
|
// 参数
|
||||||
|
const listPrototype = reactive({
|
||||||
|
pageSize: 10,
|
||||||
|
pageNum: 1,
|
||||||
|
total: 0,
|
||||||
|
// 商户主键
|
||||||
|
merId: '',
|
||||||
|
data: [],
|
||||||
|
})
|
||||||
|
|
||||||
|
// 用户信息
|
||||||
|
const userinfo = computed(() => uni.$store.state.userinfo || {})
|
||||||
onLoad((option) => {
|
onLoad((option) => {
|
||||||
if (option.storeId) storeId.value = option.storeId
|
if (option.storeId) storeId.value = option.storeId
|
||||||
|
getDetail()
|
||||||
|
listPrototype.merId = storeId.value
|
||||||
|
getList()
|
||||||
})
|
})
|
||||||
|
|
||||||
onPageScroll((ev) => {
|
onPageScroll((ev) => {
|
||||||
|
@ -50,11 +73,14 @@
|
||||||
|
|
||||||
// 获取店铺详情
|
// 获取店铺详情
|
||||||
function getDetail() {
|
function getDetail() {
|
||||||
//
|
|
||||||
api.shop.merchant({
|
api.shop.merchant({
|
||||||
path: [id.value],
|
query: {
|
||||||
|
merId: storeId.value,
|
||||||
|
userId: userinfo.value.id,
|
||||||
|
}
|
||||||
}).then(rs => {
|
}).then(rs => {
|
||||||
if (rs.code == 200) {
|
if (rs.code == 200) {
|
||||||
|
Object.assign(detail, {}, rs.data)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
util.alert({
|
util.alert({
|
||||||
|
@ -63,6 +89,110 @@
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 收藏店铺
|
||||||
|
function handleCollectStore() {
|
||||||
|
api.shop.followShop({
|
||||||
|
data: {
|
||||||
|
shopId: storeId.value,
|
||||||
|
status: {
|
||||||
|
0: 1,
|
||||||
|
1: 0,
|
||||||
|
}[detail.isFollow]
|
||||||
|
}
|
||||||
|
}).then(rs => {
|
||||||
|
if (rs.code == 200) {
|
||||||
|
// 关注状态
|
||||||
|
detail.isFollow = {
|
||||||
|
0: 1,
|
||||||
|
1: 0,
|
||||||
|
}[detail.isFollow]
|
||||||
|
// 关注数量
|
||||||
|
detail.followNum = rs.data
|
||||||
|
|
||||||
|
getDetail()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
util.alert({
|
||||||
|
content: rs.msg,
|
||||||
|
showCancel: false,
|
||||||
|
})
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 客服
|
||||||
|
function toCustomer() {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: util.setUrl('/pages/mine/setting/feedback')
|
||||||
|
})
|
||||||
|
// api.shop.getCustomerService({ merchantId: storeId.value }).then(rs => {
|
||||||
|
// if (rs.code == 200) {
|
||||||
|
// let param = {};
|
||||||
|
// param.type = 'C2C'
|
||||||
|
// param.name = `${detail.name}`
|
||||||
|
// param.msgId = `${rs.data.serviceId}`
|
||||||
|
// param.isCustomer = true
|
||||||
|
|
||||||
|
// util.toChat(param)
|
||||||
|
|
||||||
|
// uni.navigateTo({
|
||||||
|
// url: util.setUrl('/pages/news/chat/chat', param)
|
||||||
|
// })
|
||||||
|
// } else {
|
||||||
|
// util.alert(rs.msg)
|
||||||
|
// }
|
||||||
|
// })
|
||||||
|
|
||||||
|
}
|
||||||
|
// 商品列表
|
||||||
|
function getList() {
|
||||||
|
|
||||||
|
api.shop.getProduct({
|
||||||
|
data: {
|
||||||
|
pageSize: listPrototype.pageSize,
|
||||||
|
pageNum: listPrototype.pageNum,
|
||||||
|
// 商户主键
|
||||||
|
merId: listPrototype.merId,
|
||||||
|
},
|
||||||
|
}).then(rs => {
|
||||||
|
if (rs.code == 200) {
|
||||||
|
if (listPrototype.pageNum == 1) listPrototype.data.length = []
|
||||||
|
listPrototype.data.push(...rs.rows)
|
||||||
|
listPrototype.total = rs.total
|
||||||
|
return
|
||||||
|
}
|
||||||
|
util.alert({
|
||||||
|
content: rs.msg,
|
||||||
|
showCancel: false,
|
||||||
|
})
|
||||||
|
}).finally(rs => {
|
||||||
|
uni.stopPullDownRefresh()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 点击列表项
|
||||||
|
function handleItem(item) {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: util.setUrl('/pages/shop/commodity/index', {
|
||||||
|
productId: item.id
|
||||||
|
})
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 重载列表
|
||||||
|
function refreshList() {
|
||||||
|
listPrototype.pageNum = 1
|
||||||
|
listPrototype.total = 0
|
||||||
|
getList()
|
||||||
|
}
|
||||||
|
|
||||||
|
// 加载更多列表
|
||||||
|
function getMoreList() {
|
||||||
|
if (listPrototype.total <= listPrototype.data.length) return
|
||||||
|
listPrototype.pageNum++
|
||||||
|
getList()
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
refreshList,
|
||||||
|
getMoreList,
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -71,25 +201,24 @@
|
||||||
<apex :bgColor="apexBgColor" mode="flex">
|
<apex :bgColor="apexBgColor" mode="flex">
|
||||||
<template #content>
|
<template #content>
|
||||||
<view class="search df jcr">
|
<view class="search df jcr">
|
||||||
<view class="">
|
<view class="" v-if="0">
|
||||||
<image class="wh50" src="/static/share2.png" mode="aspectFit" />
|
<image class="wh50" src="/static/share2.png" mode="aspectFit" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
</apex>
|
</apex>
|
||||||
|
|
||||||
<!-- -->
|
|
||||||
<view class="shopHeaderBg"></view>
|
<view class="shopHeaderBg"></view>
|
||||||
|
|
||||||
<!-- 店铺卡片 -->
|
<!-- 店铺卡片 -->
|
||||||
<view class="store pr rows ptb25 plr25 mt40">
|
<view class="store pr rows ptb25 plr25 mt40">
|
||||||
<!-- 店铺头像 -->
|
<!-- 店铺头像 -->
|
||||||
<image class="wh120 fs0 br10" src="/static/logo.png" mode="aspectFill" />
|
<image class="wh120 fs0 br10" :src="detail.rectangleLogo" mode="aspectFill" />
|
||||||
<!-- 店铺信息 名称 评分 关注数量 -->
|
<!-- 店铺信息 名称 评分 关注数量 -->
|
||||||
<view class="info f1 ml20">
|
<view class="info f1 ml20">
|
||||||
<!-- 店铺名称 -->
|
<!-- 店铺名称 -->
|
||||||
<view class="c333 f28">
|
<view class="c333 f28">
|
||||||
<text>店铺名称</text>
|
<text>{{ detail.name }}</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="df aic mt10">
|
<view class="df aic mt10">
|
||||||
|
@ -101,7 +230,7 @@
|
||||||
</view>
|
</view>
|
||||||
<!-- 关注数量 -->
|
<!-- 关注数量 -->
|
||||||
<view class="c666 f24">
|
<view class="c666 f24">
|
||||||
<text>123关注</text>
|
<text>{{ detail.followNum }}关注</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -109,13 +238,14 @@
|
||||||
<!-- 按钮区 -->
|
<!-- 按钮区 -->
|
||||||
<view class="btns w150">
|
<view class="btns w150">
|
||||||
<view>
|
<view>
|
||||||
<view class="btn ti warmHollow fmid" @click="followButton">
|
<view @click="handleCollectStore" class="btn sm warm fmid fdr plr30">
|
||||||
<uni-icons class="mr10" color="#FF9B27" type="plusempty" size="13" />
|
<uni-icons class="mr10" color="#fff" type="plusempty" size="13" v-if="detail.isFollow != 1" />
|
||||||
<text>关注</text>
|
<text class="cfff f28" v-else>已</text>
|
||||||
|
<text class="cfff f28">关注</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="mt10">
|
<view class="mt10" @click="toCustomer">
|
||||||
<view class="btn ti warmHollow fmid">
|
<view class="btn ti warmHollow fmid">
|
||||||
<image class="kefu wh30" src="/static/customer-service1.png" mode="aspectFit" />
|
<image class="kefu wh30" src="/static/customer-service1.png" mode="aspectFit" />
|
||||||
<text>客服</text>
|
<text>客服</text>
|
||||||
|
@ -126,14 +256,46 @@
|
||||||
|
|
||||||
<!-- 商品列表 -->
|
<!-- 商品列表 -->
|
||||||
<view class="product oh ptb30 plr30">
|
<view class="product oh ptb30 plr30">
|
||||||
<productList ref="product" />
|
<view class="list">
|
||||||
|
<view class="item oh bfff br20" v-for="(item, index) in listPrototype.data" :key="index"
|
||||||
|
@click="handleItem(item)">
|
||||||
|
<!-- 需要展示的图 -->
|
||||||
|
<image class="poster" :src="item.sliderImage.split(',')[0]" mode="aspectFill" />
|
||||||
|
|
||||||
|
<!-- 标题 -->
|
||||||
|
<view class="main plr20">
|
||||||
|
<view class="title mtb10 thd c333 f30">{{ item.name }}</view>
|
||||||
|
<view class="info mtb10 df aic">
|
||||||
|
<!-- 价格 -->
|
||||||
|
<view class="price thd wsn cFF9B27">
|
||||||
|
<text class="txt f20">¥</text>
|
||||||
|
<text class="txt f36">{{ item.price }}</text>
|
||||||
|
</view>
|
||||||
|
<!-- 销量 -->
|
||||||
|
<view class="sales fs0 thd wsn ml10 c999 f26">销量:{{ item.sales }}</view>
|
||||||
|
<view class="f1"></view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
//
|
// 卡片
|
||||||
.store {
|
.list {
|
||||||
// margin-top: -50rpx;
|
display: grid;
|
||||||
|
grid-template-columns: repeat(2, 1fr);
|
||||||
|
grid-gap: 20rpx;
|
||||||
|
|
||||||
|
// 单个
|
||||||
|
.item {
|
||||||
|
.poster {
|
||||||
|
width: 100%;
|
||||||
|
height: 340rpx;
|
||||||
|
border-radius: 20rpx 20rpx 0 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
Binary file not shown.
Before Width: | Height: | Size: 386 B After Width: | Height: | Size: 773 B |
Binary file not shown.
Before Width: | Height: | Size: 865 B After Width: | Height: | Size: 2.7 KiB |
|
@ -3,7 +3,8 @@ import {
|
||||||
} from 'vite';
|
} from 'vite';
|
||||||
import uni from '@dcloudio/vite-plugin-uni';
|
import uni from '@dcloudio/vite-plugin-uni';
|
||||||
|
|
||||||
let target = 'http://91f.xyz:8080'
|
// let target = 'http://91f.xyz:8080'
|
||||||
|
let target = 'http://chi9fe.natappfree.cc'
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
plugins: [uni()],
|
plugins: [uni()],
|
||||||
|
|
Loading…
Reference in New Issue