wangguoyu 2 nedēļas atpakaļ
vecāks
revīzija
658b91c7ef
2 mainītis faili ar 47 papildinājumiem un 27 dzēšanām
  1. 46 27
      pages/study/index.vue
  2. 1 0
      pages/study/product/yingyuNew.vue

+ 46 - 27
pages/study/index.vue

@@ -404,7 +404,7 @@
 
 		let req = {
 			levelId: data.levelId,
-			zhangId: data.youkeZhangId
+			zhangId: data.zhangId
 		}
 		getCommonZhangInfo(req).then(res => {
 			translateData(res.data)
@@ -492,13 +492,13 @@
 
 	function goDanciList(data, index) {
 		if (!cacheManager.get('auth')) {
-			let youkeData = {
-				subjectId:subjectId.value,
-				typeId:typeId.value,
-				levelId:levelId.value,
-				tipFlag:tipFlag.value,
-				youkeZhangId:youkeZhangId.value,
-				jieId:data.jieId
+			let youkeData = {
+				subjectId: subjectId.value,
+				typeId: typeId.value,
+				levelId: levelId.value,
+				tipFlag: tipFlag.value,
+				youkeZhangId: youkeZhangId.value,
+				jieId: data.jieId
 			}
 			uni.redirectTo({
 				url: '/pages/wordList/wordList?youkePageData=' + JSON.stringify(youkeData)
@@ -571,33 +571,52 @@
 	}
 
 	function listClick(data, data2, index) {
-		console.log('data', data); // 节内容
-		console.log('data2', data2); //章内容
-		if (!cacheManager.get('auth') && data.firstFlag != 1) {
-			youkeDialogRef.value.handleShow();
-			return;
-		}
-		const authCode = getUserIdentity();
-		console.log('authCode', authCode);
-		if (!(authCode == 'VIP' || data.firstFlag == 1)) {
-			//	debugger
-			goPayDialogRef.value.handleShow();
-			return false
-		}
+		//console.log('data', data); // 节内容
+	//	console.log('data2', data2); //章内容
+		chooseMethodListClick(data,data2,index)
 
-		if (data.type == 2) {
-			// 最后一项
-			goKaoshi(data, index)
+	}
+
+	function chooseMethodListClick(data,data2,index) {
+
+	console.log('data', data); // 节内容
+		console.log('data2', data2); //章内容
+		 const authCode = getUserIdentity();
+		if (currentProduct.value == 2 && typeId.value == 1) {
+			const	isFirst  =  data.jieName ==data2.jieList[0].jieName
+			 if(!cacheManager.get('auth') &&!isFirst){
+				youkeDialogRef.value.handleShow();
+				return false;
+			 }
+			 console.log('authCode', authCode);
+			 if (!(authCode == 'VIP' || isFirst)) {
+			 	goPayDialogRef.value.handleShow();
+			 	return false
+			 }
+			 debugger
+			goDanciList(data, index)
 		} else {
-			if (currentProduct.value == 2 && typeId.value == 1) {
-				goDanciList(data, index)
+			if (!cacheManager.get('auth') && data.firstFlag != 1) {
+				youkeDialogRef.value.handleShow();
+				return;
+			}
+			console.log('authCode', authCode);
+			if (!(authCode == 'VIP' || data.firstFlag == 1)) {
+				//	debugger
+				goPayDialogRef.value.handleShow();
+				return false
+			}
+
+			if (data.type == 2) {
+				// 最后一项
+				goKaoshi(data, index)
 			} else {
 				goLookShipin(data, index)
 			}
-
 		}
 	}
 
+
 	function handleCheckCatalogue(item) {
 		catalogueRef.value.showPopup(item);
 	}

+ 1 - 0
pages/study/product/yingyuNew.vue

@@ -9,6 +9,7 @@
 			<view v-if="growthType!=null" :class="currentGrowth()"></view>
 			<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,item)">
 					<view v-if="isVip === 'VIP'">