Commit 619f682d by 胡悦

Merge branch 'v1.0.7' of http://192.168.3.233:8090/glsx/gl_tape into v1.0.7

2 parents 66d19401 9c98bce9
...@@ -128,12 +128,19 @@ export default { ...@@ -128,12 +128,19 @@ export default {
}).then(res => { }).then(res => {
uni.hideLoading() uni.hideLoading()
this.carlist = res this.carlist = res
uni.setStorageSync(`${e.id}_${e.brandId}_carlist`, res)
if (auto && res.length) this.handleSelect(res[0]) if (auto && res.length) this.handleSelect(res[0])
else this.$refs.carBoxVisible.open() else this.$refs.carBoxVisible.open()
this.clickFlga = false this.clickFlga = false
}).catch(err => { }).catch(err => {
this.clickFlga = false this.clickFlga = false
uni.hideLoading() uni.hideLoading()
const carList = uni.getStorageSync(`${e.id}_${e.brandId}_carlist`)
if (carList) {
this.carlist = carList
if (auto && carList.length) this.handleSelect(res[0])
else this.$refs.carBoxVisible.open()
}
}) })
}, },
handleSelect (item) { handleSelect (item) {
......
...@@ -7,11 +7,18 @@ ...@@ -7,11 +7,18 @@
<view class="container-left"> <view class="container-left">
<view v-for="(item, index) in views" :key="item.name" class="item" @click.stop="showSection(index)" :class="item.class" :style="item.style"> <view v-for="(item, index) in views" :key="item.name" class="item" @click.stop="showSection(index)" :class="item.class" :style="item.style">
<view class="image-container"> <view class="image-container">
<image :src="item.detailUrl" mode="widthFix" class="item-image" /> <image
:src="item.detailUrl"
mode="widthFix"
class="item-image"
/>
<view class="item-text">{{item.name}}</view> <view class="item-text">{{item.name}}</view>
</view> </view>
<view class="details-container"> <view class="details-container">
<view class="details-section" :class="showIndex == index ? 'show' : 'hide'"> <view
class="details-section"
:class="showIndex == index ? 'show' : 'hide'"
>
<view class="section-title">{{item.name}}</view> <view class="section-title">{{item.name}}</view>
<view class="section-description">冷却风扇电机、散热器、冷却液水壶盖、冷却液水壶、冷却液循环泵</view> <view class="section-description">冷却风扇电机、散热器、冷却液水壶盖、冷却液水壶、冷却液循环泵</view>
</view> </view>
...@@ -19,12 +26,23 @@ ...@@ -19,12 +26,23 @@
</view> </view>
</view> </view>
<view class="container-right"> <view class="container-right">
<image src="https://img02.glsx.com.cn/weapp/resource/app-tape/media/guarantee/6-15.webp" mode="widthFix" class="serice-image" /> <image
src="https://img02.glsx.com.cn/weapp/resource/app-tape/media/guarantee/6-15.webp"
mode="widthFix"
class="serice-image"
/>
<view class="ul"> <view class="ul">
<view class="ul-title">高价值零部件</view> <view class="ul-title">高价值零部件</view>
<view class="li-item" v-for="i in ulList" :key="i.index" @click="open(i.flagName)"> <view
class="li-item"
v-for="i in ulList"
:key="i.index"
@click="open(i.flagName)"
>
<view class="li-content"> <view class="li-content">
<view class="li-item-content"><view class="li-number">{{i.index}}</view>{{i.name}}</view> <view class="li-item-content">
<view class="li-number">{{i.index}}</view>{{i.name}}
</view>
<image <image
v-if="i.hasArrow" v-if="i.hasArrow"
src="https://img02.glsx.com.cn/weapp/resource/app-tape/media/guarantee/icon-arrow.webp" src="https://img02.glsx.com.cn/weapp/resource/app-tape/media/guarantee/icon-arrow.webp"
...@@ -188,7 +206,7 @@ export default { ...@@ -188,7 +206,7 @@ export default {
title: String, title: String,
madiaId: Number, madiaId: Number,
}, },
data() { data () {
return { return {
viewIndex: 6, viewIndex: 6,
list, list,
...@@ -196,14 +214,14 @@ export default { ...@@ -196,14 +214,14 @@ export default {
showIndex: -1 showIndex: -1
}; };
}, },
mounted() { mounted () {
console.log(this.views); console.log(this.views);
}, },
methods: { methods: {
open(name) { open (name) {
console.log(name) console.log(name)
}, },
showSection(index) { showSection (index) {
console.log(index) console.log(index)
if (this.showIndex === index) { if (this.showIndex === index) {
// 如果当前点击的项已经是翻转状态,则关闭它 // 如果当前点击的项已经是翻转状态,则关闭它
...@@ -269,7 +287,7 @@ export default { ...@@ -269,7 +287,7 @@ export default {
left: 24rpx; left: 24rpx;
bottom: 24rpx; bottom: 24rpx;
font-size: 30rpx; font-size: 30rpx;
color: #FFFFFF; color: #ffffff;
line-height: 44rpx; line-height: 44rpx;
} }
.details-container { .details-container {
...@@ -284,7 +302,7 @@ export default { ...@@ -284,7 +302,7 @@ export default {
.details-section { .details-section {
width: 100%; width: 100%;
height: 100%; height: 100%;
color: #FFFFFF; color: #ffffff;
padding: 24rpx; padding: 24rpx;
border-radius: 24rpx; border-radius: 24rpx;
background-image: linear-gradient(180deg, #21425cb3 0%, #4A84F9 68%); background-image: linear-gradient(180deg, #21425cb3 0%, #4A84F9 68%);
...@@ -315,18 +333,18 @@ export default { ...@@ -315,18 +333,18 @@ export default {
} }
.ul { .ul {
width: 100%; width: 100%;
border: 4rpx solid #FDFDFF; border: 4rpx solid #fdfdff;
border-radius: 24rpx; border-radius: 24rpx;
margin-top: 36rpx; margin-top: 36rpx;
box-sizing: border-box; box-sizing: border-box;
&-title { &-title {
background-color: #4A84F9; background-color: #4a84f9;
box-shadow: inset 0 0 16rpx 0 #FFFFFF; box-shadow: inset 0 0 16rpx 0 #ffffff;
border-radius: 24rpx 24rpx 0 0; border-radius: 24rpx 24rpx 0 0;
height: 88rpx; height: 88rpx;
font-weight: 500; font-weight: 500;
font-size: 28rpx; font-size: 28rpx;
color: #FFFFFF; color: #ffffff;
line-height: 88rpx; line-height: 88rpx;
text-align: center; text-align: center;
} }
...@@ -339,7 +357,7 @@ export default { ...@@ -339,7 +357,7 @@ export default {
flex-direction: column; flex-direction: column;
padding-left: 40rpx; padding-left: 40rpx;
// margin-bottom: 4rpx; // margin-bottom: 4rpx;
border: 2rpx solid #FDFDFF; border: 2rpx solid #fdfdff;
.li-number { .li-number {
font-size: 32rpx; font-size: 32rpx;
margin-right: 12rpx; margin-right: 12rpx;
...@@ -360,10 +378,10 @@ export default { ...@@ -360,10 +378,10 @@ export default {
.li-value { .li-value {
margin-top: 8rpx; margin-top: 8rpx;
font-size: 22rpx; font-size: 22rpx;
color: #1462FF; color: #1462ff;
} }
&:nth-child(odd) { &:nth-child(odd) {
background-color: #E5EDFF; background-color: #e5edff;
} }
&:nth-child(even) { &:nth-child(even) {
background-color: rgba(255, 255, 255, 0.35); background-color: rgba(255, 255, 255, 0.35);
...@@ -406,5 +424,4 @@ export default { ...@@ -406,5 +424,4 @@ export default {
transform: translateY(100%); transform: translateY(100%);
} }
} }
</style> </style>
...@@ -94,7 +94,11 @@ export default { ...@@ -94,7 +94,11 @@ export default {
this.getSoure(); this.getSoure();
this.findPayInfo(); this.findPayInfo();
const userInfo = uni.$storage.get("userInfo"), const userInfo = uni.$storage.get("userInfo"),
{ shopMerchantId } = userInfo; storageCarBrandList = uni.$storage.get('carBrandList'),
storageEmployeeList = uni.$storage.get('employeeList'),
{ shopMerchantId } = userInfo
if (storageCarBrandList) this.$store.dispatch("setCarBrandsList", storageCarBrandList);
if (storageEmployeeList) this.$store.dispatch("setEmployeeList", storageEmployeeList);
/**获取品牌车型 */ /**获取品牌车型 */
uni.$api.commonApi uni.$api.commonApi
.getMerchantCarBrandList([shopMerchantId]) .getMerchantCarBrandList([shopMerchantId])
...@@ -108,7 +112,8 @@ export default { ...@@ -108,7 +112,8 @@ export default {
}); });
}); });
this.$store.dispatch("setCarBrandsList", carBrandList); this.$store.dispatch("setCarBrandsList", carBrandList);
}); uni.$storage.set('carBrandList', carBrandList)
})
/**获取销售人员 */ /**获取销售人员 */
uni.$api.commonApi uni.$api.commonApi
.getEmployeeList({ .getEmployeeList({
...@@ -116,6 +121,7 @@ export default { ...@@ -116,6 +121,7 @@ export default {
}) })
.then((res) => { .then((res) => {
this.$store.dispatch("setEmployeeList", res); this.$store.dispatch("setEmployeeList", res);
uni.$storage.set('employeeList', res)
}); });
}, },
// 查询素材 // 查询素材
......
...@@ -16,6 +16,8 @@ export const STORAGE_OBJECTkEY = { ...@@ -16,6 +16,8 @@ export const STORAGE_OBJECTkEY = {
noSignInUuid: "noSignInUuid", noSignInUuid: "noSignInUuid",
noviceGuideStatus: "noviceGuideStatus", noviceGuideStatus: "noviceGuideStatus",
accountLength: "accountLength", accountLength: "accountLength",
carBrandList:'carBrandList',
employeeList:'employeeList'
}; };
// export const IMG_VERSION = async () => { // export const IMG_VERSION = async () => {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!