|
@@ -11,7 +11,7 @@
|
|
|
<view>
|
|
|
<!-- 小岛 -->
|
|
|
<view class="brand-item" v-for="(item, index) in options.jieList" :key="item.jieId"
|
|
|
- @click="listClick(item, index,options)" :class="getClass(options,index,isVip)">
|
|
|
+ @click="listClick(item, index,options)" :class="getClass(options,index,isVip,item)">
|
|
|
<view v-if="isVip === 'VIP'">
|
|
|
<!-- 序号 -->
|
|
|
<view class="brand-icon" v-if="item.studyFlag===0">{{ item.number }}</view>
|
|
@@ -22,14 +22,28 @@
|
|
|
<!-- 节名称 -->
|
|
|
<view class="brand-content">{{ item.jieName }}</view>
|
|
|
</view>
|
|
|
- <view v-if="isVip !== 'VIP'">
|
|
|
+ <view v-if="isVip == 'Not-Vip'">
|
|
|
<!-- 序号或锁 -->
|
|
|
- <view v-if="options.number ==1" class="brand-icon">{{ item.number }}
|
|
|
+ <view class="brand-icon">{{ item.number }}
|
|
|
</view>
|
|
|
<!-- 锁 -->
|
|
|
- <view v-else class="brand-lock"></view>
|
|
|
+ <view v-if="options.number !='1'" class="brand-lock"></view>
|
|
|
<!-- 箭头 -->
|
|
|
- <view v-if="item.daeFlag && animalNum == index &&isVip != 'Visitor'" class="brand-arrow"></view>
|
|
|
+ <view v-if="item.daeFlag && animalNum == index &&isVip != 'Visitor'" class="brand-arrow">
|
|
|
+ </view>
|
|
|
+ <!-- 节名称 -->
|
|
|
+ <view class="brand-content"> {{ item.jieName }} </view>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view v-if="isVip == 'Visitor'">
|
|
|
+ <!-- 序号或锁 -->
|
|
|
+ <view class="brand-icon">{{ item.number }}
|
|
|
+ </view>
|
|
|
+ <!-- 锁 -->
|
|
|
+ <view v-if="options.number !='1' || item.type==2" class="brand-lock"></view>
|
|
|
+ <!-- 箭头 -->
|
|
|
+ <view v-if="item.daeFlag && animalNum == index &&isVip != 'Visitor'" class="brand-arrow">
|
|
|
+ </view>
|
|
|
<!-- 节名称 -->
|
|
|
<view class="brand-content"> {{ item.jieName }} </view>
|
|
|
</view>
|
|
@@ -58,9 +72,9 @@
|
|
|
} from '@dcloudio/uni-app';
|
|
|
const growthType = ref(null);
|
|
|
onShow(() => {
|
|
|
- growthType.value = cacheManager.get('auth')?cacheManager.get('auth').growthType:null
|
|
|
+ growthType.value = cacheManager.get('auth') ? cacheManager.get('auth').growthType : null
|
|
|
})
|
|
|
-
|
|
|
+
|
|
|
const $emit = defineEmits(['clickGradeTerm', 'onLeft', 'onRight', 'handleCheckCatalogue', 'listClick'])
|
|
|
const props = defineProps({
|
|
|
options: {
|
|
@@ -71,7 +85,7 @@
|
|
|
},
|
|
|
})
|
|
|
const isVip = getUserIdentity();
|
|
|
-// console.log('isVip',isVip);
|
|
|
+ console.log('isVip', isVip);
|
|
|
const gradeMapping = {
|
|
|
1: '一年级',
|
|
|
2: '二年级',
|
|
@@ -96,13 +110,13 @@
|
|
|
$emit('clickGradeTerm');
|
|
|
}
|
|
|
|
|
|
- function listClick(data, index,data2) {
|
|
|
+ function listClick(data, index, data2) {
|
|
|
data.daeFlag = true
|
|
|
nextTick(() => {
|
|
|
animalNum.value = index
|
|
|
})
|
|
|
setTimeout(() => {
|
|
|
- $emit('listClick', data,data2,index);
|
|
|
+ $emit('listClick', data, data2, index);
|
|
|
}, 300)
|
|
|
|
|
|
}
|
|
@@ -154,12 +168,14 @@
|
|
|
}
|
|
|
|
|
|
// 获取节class
|
|
|
- function getClass(data, index, isVip) {
|
|
|
- console.log('data',data);
|
|
|
+ function getClass(data, index, isVip,item) {
|
|
|
+ // console.log('data',data);
|
|
|
let brandActive = '';
|
|
|
if (isVip === 'VIP') {
|
|
|
brandActive = 'brand-active';
|
|
|
- } else if (data.number == 1) {
|
|
|
+ } else if (data.number == 1 && isVip =='Not-Vip') {
|
|
|
+ brandActive = 'brand-active';
|
|
|
+ } else if (data.number == 1 && isVip =='Visitor' &&item.type ==1) {
|
|
|
brandActive = 'brand-active';
|
|
|
} else {
|
|
|
brandActive = '';
|