Commit 95b61952 authored by 黄奎's avatar 黄奎

样式修改

parent b2f88fb8
......@@ -58,23 +58,26 @@
</div>
</view>
<!-- 新加div -->
<view v-if="u.TenantId==27" class="Teachers">
<view class="portrait-box">
<image v-if="cx.edudata.TeacherIcon" class="portrait" mode="aspectFit" :src="cx.edudata.TeacherIcon" />
<view v-if="cx.edudata.TeacherName" class="sell2">{{cx.edudata.TeacherName}}</view>
</view>
<!-- 价格 -->
<view class="cart-box">
<view class="vip2" :style="{ color: mainColor }">
{{ cx.price_content }}
<template v-if="u&&u.TenantId==27">
<view class="Teachers">
<view class="portrait-box">
<image v-if="cx.edudata.TeacherIcon" class="portrait" mode="aspectFit" :src="cx.edudata.TeacherIcon" />
<view v-if="cx.edudata.TeacherName" class="sell2">{{cx.edudata.TeacherName}}</view>
</view>
<!-- 价格 -->
<view class="cart-box">
<view class="vip2" :style="{ color: mainColor }">
{{ cx.price_content }}
</view>
<div @click.stop="showSkuHandler(cx)" class="right">
<!-- todo 点击加入购物车-->
<u-icon name="cart-circle-o" size="44" :color="mainColor" />
</div>
</view>
<div @click.stop="showSkuHandler(cx)" class="right">
<!-- todo 点击加入购物车-->
<u-icon name="cart-circle-o" size="44" :color="mainColor" />
</div>
</view>
</view>
</template>
</div>
<u-divider v-if="isover" :margin-top="20" :margin-bottom="20">没有更多商品了</u-divider>
......
......@@ -8,34 +8,45 @@
'border-color': classification == i ? 'mainColor' : '#F0F0F0',
}" v-for="(item, i) in Theclass" :key="i" @click="subjects(item,i)">
<view class="classification-text">{{item.name}}</view>
<u-icon name="arrow-down" size="32" ></u-icon>
<u-icon name="arrow-down" size="32"></u-icon>
</view>
</view>
<!-- 内容 -->
<!-- <u-popup mode="top" length="auto" v-model="mask"> -->
<scroll-view scroll-y="true" style="max-height: 300rpx;" v-show="mask">
<view class="drop-down-content">
<view class="content-box" @click="content()" :style="{
<view class="drop-down-content" >
<!-- 年级不限 -->
<view v-show="classification==0" class="content-box" @click="content()" :style="{
color: index ? mainColor : '',
'border-color': index == i ? 'mainColor' : '#F0F0F0',
}">
<view class="content-tetx">不限</view>
</view>
<view class="content-box" v-show="classification==0" :style="{
color: index2 == i ? mainColor : '',
'border-color': index2 == i ? 'mainColor' : '#F0F0F0',
}" v-for="(item, i) in d" :key='i'@click="content2(item,i)">
<!-- 类型不限 -->
<view v-show="classification==1" class="content-box" @click="content33()" :style="{
color: indexx ? mainColor : '',
'border-color': indexx == i ? 'mainColor' : '#F0F0F0',
}">
<view class="content-tetx">不限</view>
</view>
<!-- 年级内容 -->
<view class="content-box" v-show="classification==0" :style="{
color: index22 == i ? mainColor : '',
'border-color': index22 == i ? 'mainColor' : '#F0F0F0',
}" v-for="(item, i) in d" :key='i' @click="content2(item,i)">
<view class="content-tetx">{{item.Name}}</view>
</view>
<view class="content-box" v-show="classification==1" :style="{
<view class="content-tetx">{{item.Name}}</view>
</view>
<!-- 类型内容 -->
<view class="content-box" v-show="classification==1" :style="{
color: index2 == i ? mainColor : '',
'border-color': index2 == i ? 'mainColor' : '#F0F0F0',
}" v-for="(item, i) in subjectslist" @click="content3(item,i)">
<view class="content-tetx">{{item.CateName}}</view>
<view class="content-tetx">{{item.CateName}}</view>
</view>
</view>
</view>
</scroll-view>
<!-- </u-popup> -->
<!-- 内容 -->
......@@ -113,24 +124,27 @@
</div>
</view>
<!-- 新加div -->
<view v-if="u.TenantId==27" class="Teachers">
<view class="portrait-box">
<image v-if="cx.edudata.TeacherIcon" class="portrait" mode="aspectFit"
:src="cx.edudata.TeacherIcon" />
<view v-if="cx.edudata.TeacherName" class="sell2">{{cx.edudata.TeacherName}}</view>
</view>
<!-- 价格 -->
<view class="cart-box">
<view class="vip2" :style="{ color: mainColor }">
{{ cx.price_content }}
<template v-if="u&&u.TenantId==27">
<view class="Teachers">
<view class="portrait-box">
<image v-if="cx.edudata.TeacherIcon" class="portrait" mode="aspectFit"
:src="cx.edudata.TeacherIcon" />
<view v-if="cx.edudata.TeacherName" class="sell2">{{cx.edudata.TeacherName}}</view>
</view>
<!-- 价格 -->
<view class="cart-box">
<view class="vip2" :style="{ color: mainColor }">
{{ cx.price_content }}
</view>
<div @click.stop="showSkuHandler(cx)" class="right">
<!-- todo 点击加入购物车-->
<u-icon name="cart-circle-o" size="44" :color="mainColor" />
</div>
</view>
<div @click.stop="showSkuHandler(cx)" class="right">
<!-- todo 点击加入购物车-->
<u-icon name="cart-circle-o" size="44" :color="mainColor" />
</div>
</view>
</view>
</template>
</div>
<u-divider v-if="isover" :margin-top="20" :margin-bottom="20">没有更多商品了</u-divider>
......@@ -169,10 +183,15 @@
id: "1"
}
],
obj2: {
EduClassTypeId: ''
},
subjectslist: [],
classification: -1,
index: true,
indexx: true,
index2: -1,
index22: -1,
textColor: "#F0F0F0",
mask: false,
......@@ -195,16 +214,7 @@
OrderBy: 1,
UserId: 0,
StoreId: 0,
},
msg: {
pageIndex: 1,
pageSize: 14,
Name: '',
GoodsType: 0,
CategoryIds: '',
OrderBy: 1,
UserId: 0,
StoreId: 0,
EduClassTypeId: '',
},
sku: {},
showSku: false,
......@@ -220,6 +230,7 @@
auth
},
created() {
this.u = uni.getStorageSync('mall_UserInfo');
this.mainColor = this.$uiConfig.mainColor;
this.activeStyle = `background:${this.mainColor};`;
this.IsEducation = uni.getStorageSync('basedata') ?
......@@ -230,7 +241,7 @@
},
mounted() {
this.init();
this.u = uni.getStorageSync('mall_UserInfo5')
// this.u = uni.getStorageSync('mall_UserInfo5')
},
methods: {
// 接口
......@@ -287,46 +298,63 @@
}
},
// 内容点击
// 年级不限
content() {
this.index = !this.index
if (this.index) {
this.index2 = -1
// this.index =true
this.index22 = -1
this.msg.CategoryIds = ''
this.msg.EduClassTypeId=''
this.msg.page = 1;
this.subjectslist = [];
this.g = [];
this.init()
this.mask = false
this.classification = -1
this.Theclass[0].name = '年级不限'
}
},
// 类型不限
content33() {
this.indexx = !this.indexx
if (this.indexx) {
// this.indexx =true
this.index2 = -1
this.msg.EduClassTypeId = ''
this.msg.page = 1;
this.subjectslist = [];
this.g = [];
this.init()
this.mask = false
this.classification = -1
this.Theclass[1].name = '类型不限'
}
},
// 年级内容
content2(item, i) {
this.index2 = i
this.index22 = i
this.index = false
this.classification = -1
this.mask = false
this.msg.page = 1;
this.g = [];
this.msg.CategoryIds = item.Id
this.Theclass[0].name = item.Name
this.init()
},
// 类型内容
content3(item, i) {
let obj2={
EduClassTypeId:''
}
this.index2 = i
this.index = false
this.indexx = false
this.classification = -1
this.mask = false
this.msg.page = 1;
this.g = [];
obj2.EduClassTypeId =item.CateId
let obj = Object.assign({}, this.msg, obj2);
this.msg= obj
this.msg.EduClassTypeId = item.CateId
this.Theclass[1].name = item.CateName
this.init()
},
// 购物车
showSkuHandler(g) {
......
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