Commit bbc88816 authored by 王建威's avatar 王建威

bug fix

parent 73c7e7e9
// php测试环境 // php测试环境
export const php = 'http://test.pet-dbc.cn/mobile/index.php?' // export const php = 'http://test.pet-dbc.cn/mobile/index.php?'
// php镜像 // php镜像
// export const php = 'https://jingxiang.pet-dbc.cn/mobile/index.php?' export const php = 'https://jingxiang.pet-dbc.cn/mobile/index.php?'
// php正式环境 // php正式环境
// export const php = 'https://shop.pet-dbc.cn/mobile/index.php?' // export const php = 'https://shop.pet-dbc.cn/mobile/index.php?'
// go测试环境 // go测试环境
export const go = 'https://tm.pet-dbc.cn' // export const go = 'https://tm.pet-dbc.cn'
// go镜像环境 // go镜像环境
// export const go = 'https://jxm.pet-dbc.cn' export const go = 'https://jxm.pet-dbc.cn'
// go正式环境 // go正式环境
// export const go = 'https://m.pet-dbc.cn'; // export const go = 'https://m.pet-dbc.cn';
\ No newline at end of file
{ {
"name": "shop_mobile_uni", "name": "shop_mobile_uni",
"version": "1.0.3", "version": "1.0.5",
"description": "谛宝多多商城", "description": "谛宝多多商城",
"scripts": { "scripts": {
"test": "echo \"Error: no test specified\" && exit 1", "test": "echo \"Error: no test specified\" && exit 1",
......
...@@ -6,9 +6,9 @@ ...@@ -6,9 +6,9 @@
<text v-if="style_setting.font_show" class="title" :style="{'color': style_setting.font_color}">{{item.title}}</text> <text v-if="style_setting.font_show" class="title" :style="{'color': style_setting.font_color}">{{item.title}}</text>
</view> </view>
</view> </view>
<swiper v-else indicator-dots="true" :style="[{'height': style_setting.rank*200+10+'rpx'}, style_setting.bg_style === 1 ? {'width':'702rpx','margin':'0 auto 20rpx'}: null, {'background-image':style_setting.bg_url}, {'background-color': style_setting.bg_color}]" class="swiper_view"> <swiper v-else indicator-dots="true" :style="[{'height': style_setting.rank*200+10+'rpx'}, style_setting.bg_style === 1 ? {'width':'702rpx','margin':'0 auto 20rpx'}: null, {'background-image':style_setting.bg_url}, {'background-color': style_setting.bg_color}, {'border-bottom-left-radius':style_setting.radius_bottom_left*2+'rpx', 'border-bottom-right-radius':style_setting.radius_bottom_right*2+'rpx', 'border-top-left-radius':style_setting.radius_top_left*2+'rpx', 'border-top-right-radius':style_setting.radius_top_right*2+'rpx'}]" class="swiper_view">
<swiper-item v-for="(item, key) in menuArray" :key="key" class="rank rank1"> <swiper-item v-for="(item, key) in menuArray" :key="key" class="rank rank1">
<view class="menuItem" v-for="(val, index) in item" :key="index" :style="{'width': width}" @click="$jump(item.img_href)"> <view class="menuItem" v-for="(val, index) in item" :key="index" :style="{'width': width}" @click="$jump(val.img_href)">
<image :src="val.img_url" class="icon_img"></image> <image :src="val.img_url" class="icon_img"></image>
<text v-if="style_setting.font_show" class="title" :style="{'color': style_setting.font_color}">{{val.title}}</text> <text v-if="style_setting.font_show" class="title" :style="{'color': style_setting.font_color}">{{val.title}}</text>
</view> </view>
......
<template> <template>
<view class="goods_content" v-if="dataList.length"> <view class="goods_content" v-if="dataList.length">
<view v-if="style_setting.arrange == 1" class="goods_box" :style="[{'background-color': style_setting.bg_color}, style_setting.listType === 3 ? {'padding': '24rpx 0'} : null]"> <view v-if="style_setting.arrange == 1" class="goods_box" :style="[{'background-color': style_setting.bg_color}, style_setting.listType === 2 ? {'padding': '24rpx'} : (style_setting.listType === 3 ? {padding: '24rpx 32rpx'} : {'padding':'24rpx 14rpx'})]">
<view v-for="(item, key) in dataList" :key="key" class="goods_item" :style="width ? {'width':width} : ''"> <view v-for="(item, key) in dataList" :key="key" class="goods_item" :style="{width: width+'rpx'}">
<view :class="style_setting.listType === 2 ? 'image_box2' : 'image_box'"> <view :class="style_setting.listType === 2 ? 'image_box2' : 'image_box'" :style="{width: width+'rpx',height:width+'rpx'}">
<image v-if="style_setting.sign_show" class="logo" :style="{'width': style_setting.sign_size*2+'rpx','height': style_setting.sign_size*2+'rpx'}" :src="style_setting.sign_url"></image> <image v-if="style_setting.sign_show" class="logo" :style="{'width': style_setting.sign_size*2+'rpx','height': style_setting.sign_size*2+'rpx'}" :src="style_setting.sign_url"></image>
<image class="goods_img" :src="item.default_image || $noGoodsImg" @click="$jumpGoodDetail(item.goods_id)"></image> <image class="goods_img" :src="item.default_image || $noGoodsImg" @click="$jumpGoodDetail(item.goods_id)"></image>
</view> </view>
...@@ -12,15 +12,15 @@ ...@@ -12,15 +12,15 @@
<text v-if="style_setting.price_show">{{item.price}}</text> <text v-if="style_setting.price_show">{{item.price}}</text>
<i class="eosfont icon_cart" v-if="style_setting.cart_show" @click="$addCart(item.spec_id,1,isLogin)">&#xe7e6;</i> <i class="eosfont icon_cart" v-if="style_setting.cart_show" @click="$addCart(item.spec_id,1,isLogin)">&#xe7e6;</i>
</view> </view>
<view v-else class="unshow_price1">登录显示价格</view> <view v-else class="unshow_price">登录显示价格</view>
</view> </view>
<view v-if="spaceArray.length" v-for="(item, key) in spaceArray" :key="key+65535" :style="width ? {'width':width} : ''"></view> <view v-if="spaceArray.length" v-for="(item, key) in spaceArray" :key="key+65535" :style="width ? {'width':width+'rpx'} : ''"></view>
</view> </view>
<uni-swiper-dot v-else :info="dataList" :dotsStyles="{'width': 4,'height':4, 'bottom':15,'border':'none','selectedBorder':'none'}" mode="dot" :current="current"> <uni-swiper-dot v-else :info="dataList" :dotsStyles="{'width': 4,'height':4, 'bottom':15,'border':'none','selectedBorder':'none'}" mode="dot" :current="current">
<swiper class="swiper_content" @change="change" :autoplay="true" :style="[style_setting.listType === 2 ? {'height': '536rpx'} : {'height': '346rpx'}, {'background-color': style_setting.bg_color}]"> <swiper class="swiper_content" @change="change" :autoplay="false" :style="[style_setting.listType === 2 ? {'height': '536rpx'} : {'height': width+180+'rpx'}, {'background-color': style_setting.bg_color}]">
<swiper-item v-for="(val, index) in dataList" :key="index" class="goods_box2"> <swiper-item v-for="(val, index) in dataList" :key="index" class="goods_box2" :style="style_setting.listType === 3 || style_setting.listType === 2 ? {'padding': '24rpx'} : {'padding':'24rpx 14rpx'}">
<view v-for="(item, key) in val" :key="key" class="goods_item" :style="width ? {'width':width} : ''"> <view v-for="(item, key) in val" :key="key" class="goods_item" :style="{width: width+'rpx'}">
<view :class="style_setting.listType === 2 ? 'image_box2' : 'image_box'"> <view :class="style_setting.listType === 2 ? 'image_box2' : 'image_box'" :style="{width: width+'rpx',height:width+'rpx'}">
<image v-if="style_setting.sign_show" class="logo" :style="{'width': style_setting.sign_size*2+'rpx','height': style_setting.sign_size*2+'rpx'}" :src="style_setting.sign_url"></image> <image v-if="style_setting.sign_show" class="logo" :style="{'width': style_setting.sign_size*2+'rpx','height': style_setting.sign_size*2+'rpx'}" :src="style_setting.sign_url"></image>
<image class="goods_img" :src="item.default_image || $noGoodsImg" @click="$jumpGoodDetail(item.goods_id)"></image> <image class="goods_img" :src="item.default_image || $noGoodsImg" @click="$jumpGoodDetail(item.goods_id)"></image>
</view> </view>
...@@ -30,9 +30,9 @@ ...@@ -30,9 +30,9 @@
<text v-if="style_setting.price_show">{{item.price}}</text> <text v-if="style_setting.price_show">{{item.price}}</text>
<i class="eosfont icon_cart" v-if="style_setting.cart_show" @click="$addCart(item.spec_id,1,isLogin)">&#xe7e6;</i> <i class="eosfont icon_cart" v-if="style_setting.cart_show" @click="$addCart(item.spec_id,1,isLogin)">&#xe7e6;</i>
</view> </view>
<view v-else class="unshow_price">登录显示价</view> <view v-else class="unshow_price">登录显示价</view>
</view> </view>
<view v-if="spaceArray.length" v-for="(item, key) in spaceArray" :key="key+65535" :style="width ? {'width':width} : ''"></view> <view v-if="spaceArray.length" v-for="(item, key) in spaceArray" :key="key+65535" :style="width ? {'width':width+'rpx'} : ''"></view>
</swiper-item> </swiper-item>
</swiper> </swiper>
</uni-swiper-dot> </uni-swiper-dot>
...@@ -69,11 +69,9 @@ ...@@ -69,11 +69,9 @@
const { listType, arrange, goods_data_type, width, additional_goods_show, goods_num } = this.style_setting; const { listType, arrange, goods_data_type, width, additional_goods_show, goods_num } = this.style_setting;
const { goods_list, cate_goods_list, buy_goods_list } =this.wrapper_props; const { goods_list, cate_goods_list, buy_goods_list } =this.wrapper_props;
if(listType == 2) { if(listType == 2) {
this.width = '320rpx'; this.width = '320';
} else if (listType == 3) {
this.width = '230rpx';
} else { } else {
this.width = width * 2 + 'rpx'; this.width = width * 2;
} }
let list = []; let list = [];
if(goods_data_type === 3) { if(goods_data_type === 3) {
...@@ -121,7 +119,7 @@ ...@@ -121,7 +119,7 @@
flex-wrap: wrap; flex-wrap: wrap;
width: 702rpx; width: 702rpx;
margin: 0 auto; margin: 0 auto;
padding: 24rpx; padding: 24rpx 20rpx;
box-sizing: border-box; box-sizing: border-box;
.goods_item { .goods_item {
margin-bottom: 20rpx; margin-bottom: 20rpx;
...@@ -132,14 +130,14 @@ ...@@ -132,14 +130,14 @@
} }
.unshow_price { .unshow_price {
font-size: 20rpx; font-size: 20rpx;
width: 90%;
text-align: left;
}
.unshow_price1 {
font-size: 20rpx;
width: 160rpx;
text-align: left; text-align: left;
width: 100%;
} }
// .unshow_price1 {
// font-size: 20rpx;
// width: 160rpx;
// text-align: left;
// }
.needAfter::after { .needAfter::after {
// content: ''; // content: '';
flex: auto; flex: auto;
...@@ -164,10 +162,10 @@ ...@@ -164,10 +162,10 @@
width:320rpx; width:320rpx;
height: 320rpx; height: 320rpx;
} }
.goods_name1, .goods_sub_name1, .goods_price1 { // .goods_name1, .goods_sub_name1, .goods_price1 {
width: 160rpx !important; // width: 160rpx !important;
margin: 0 auto; // margin: 0 auto;
} // }
.goods_name, .goods_name1 { .goods_name, .goods_name1 {
font-size: 22rpx; font-size: 22rpx;
color: #212121; color: #212121;
...@@ -179,7 +177,7 @@ ...@@ -179,7 +177,7 @@
height: 32rpx; height: 32rpx;
line-height: 32rpx; line-height: 32rpx;
margin-bottom: 6rpx; margin-bottom: 6rpx;
width: 90%; width: 100%;
} }
.goods_sub_name, .goods_sub_name1 { .goods_sub_name, .goods_sub_name1 {
font-size: 22rpx; font-size: 22rpx;
...@@ -188,16 +186,16 @@ ...@@ -188,16 +186,16 @@
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
width: 90%; width: 100%;
} }
.goods_price, .goods_price1 { .goods_price, .goods_price1 {
width: 90%;
position: relative; position: relative;
top: -4rpx; top: -4rpx;
height: 40rpx; height: 40rpx;
line-height: 40rpx; line-height: 40rpx;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
width: 100%;
text { text {
font-size: 24rpx; font-size: 24rpx;
color: #c3a070; color: #c3a070;
......
...@@ -54,6 +54,15 @@ ...@@ -54,6 +54,15 @@
hotIndex: 0 hotIndex: 0
} }
}, },
mounted() {
var flag = true;
this.cate_list.map((item, index) => {
if(item.goods_list.length && flag) {
this.hotIndex = index;
flag = false;
}
});
},
methods: { methods: {
changeCate(index) { changeCate(index) {
this.hotIndex = index this.hotIndex = index
......
...@@ -44,15 +44,13 @@ ...@@ -44,15 +44,13 @@
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
border-radius: 16rpx 16rpx 0 0; border-radius: 16rpx 16rpx 0 0;
padding: 0 24rpx 0 28rpx;
text { text {
vertical-align: middle; vertical-align: middle;
margin-left: 10rpx; margin-left: 10rpx;
} }
} }
.maintitle_content2 { .maintitle_content2 {
box-sizing: border-box;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
......
...@@ -77,7 +77,7 @@ ...@@ -77,7 +77,7 @@
margin: 0 auto; margin: 0 auto;
padding: 0 24rpx 0 28rpx; padding: 0 24rpx 0 28rpx;
box-sizing: border-box; box-sizing: border-box;
border-radius: 0 0 16rpx 16rpx; border-radius: 16rpx;
} }
.flex { .flex {
display: flex; display: flex;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment