Pārlūkot izejas kodu

学习中心页面布局

xuqiaoying 3 gadi atpakaļ
vecāks
revīzija
dc93e0f1c4
3 mainītis faili ar 44 papildinājumiem un 5 dzēšanām
  1. 2 2
      common/request.js
  2. 20 2
      pages/learn/index.scss
  3. 22 1
      pages/learn/index.vue

+ 2 - 2
common/request.js

@@ -6,9 +6,9 @@ var num = 1
 //接口api   
 // export const BASE_URL = 'https://api.xyyxt.net'   //release
 // export const BASE_URL = 'https://test.xyyxt.net'   //预发布
-// export const BASE_URL = 'http://120.79.166.78:19012' // 测试环境
+export const BASE_URL = 'http://120.79.166.78:19012' // 测试环境
 // export const BASE_URL = 'http://42.192.164.187:19005'    //test(后端本地)
-export const BASE_URL = 'http://192.168.1.222:5055'    //后端本地更新到222
+// export const BASE_URL = 'http://192.168.1.222:5055'    //后端本地更新到222
 // export const BASE_URL = 'http://192.168.1.24:5055'    //后端本地
 // export const BASE_URL = 'http://192.168.1.7:5055'    //后端本地
 

+ 20 - 2
pages/learn/index.scss

@@ -141,6 +141,7 @@
 		.c_downs {
 			display: flex;
 			align-items: center;
+			// justify-content: flex-start;
 			justify-content: space-between;
 			margin-top: 24rpx;
 		}
@@ -179,12 +180,29 @@
 			// 	opacity: 0.6;
 			// }
 		}
+		.study_btns {
+			width: 100%;
+			margin-top: 40rpx;
+		}
+		.box_appoint {
+			display: flex;
+			align-items: center;
+			.img {
+				width: 32rpx;
+				height: 32rpx;
+				margin-right: 10rpx;
+			}
+			.exam_word {
+				font-size: 22rpx;
+				color: #484848;
+			}
+		}
 	}
 	.lefts {
 		width: 204rpx;
 		height: 120rpx;
 		border-radius: 12rpx;
-		margin-right: 24rpx;
+		margin-right: 48rpx;
 		position: relative;
 		top: 0;
 		left: 0;
@@ -209,7 +227,7 @@
 		}
 	}
 	.rights {
-		width: 400rpx;
+		width: 380rpx;
 		height: 120rpx;
 		display: flex;
 		flex-direction: column;

+ 22 - 1
pages/learn/index.vue

@@ -110,6 +110,28 @@
 								</view>
 							</view>
 						</view>
+						<!-- <view class="study_btns">
+							<template
+								v-if="item.gradeStatus == 1 && item.status == 1 && (item.serviceEndTime > sysTime) && (item.serviceStartTime < sysTime) &&  (item.classEndTime && (item.classEndTime < sysTime)) && (item.periodStatus == 0 || item.periodStatus == -1) && item.studyCount > 0">
+							</template>
+							<view v-else class="exam_btns">
+								<template v-for="(appoint,appointIndex) in item.examApplyGoodsList">
+									<view class="box_appoint" :key="appointIndex" v-if="item.applyStatus === 1 && !( sysTime <= item.serviceStartTime || sysTime >= item.serviceEndTime || (item.classStartTime && sysTime <= item.classStartTime) || (item.classEndTime && sysTime >= item.classEndTime) || item.learningStatus == 2 || item.classStatus == 0 || (item.learningStatus == 3 && sysTime < item.learningTimeStart))">
+										<image class="img" src="/static/questionBank_collect.png"></image>
+										<text class="exam_word" @click="appointment(item,appoint)">预约考试</text>
+									</view>
+								</template>
+								<view class="box_appoint" v-if="item.beforeStatus === 1 && !( sysTime <= item.serviceStartTime || sysTime >= item.serviceEndTime || (item.classStartTime && sysTime <= item.classStartTime) || (item.classEndTime && sysTime >= item.classEndTime) || item.learningStatus == 2 || item.classStatus == 0 || (item.learningStatus == 3 && sysTime < item.learningTimeStart))">
+									<image class="img" src="/static/questionBank_collect.png"></image>
+									<text class="exam_word"  @click="appBeforeAddress(item.goodsId,item)">进入刷题</text>
+								</view>
+								
+							</view>
+							<view class="box_appoint">
+								<image class="img" src="/static/questionBank_collect.png"></image>
+								<text class="exam_word" @click="studyIn(item.goodsId,item.gradeId,item,index)">进入学习</text>
+							</view> 
+						</view> -->
 
 						<!-- 不在学习服务期 -->
 						<template v-if="item.serviceStartTime && (sysTime < item.serviceStartTime || sysTime > item.serviceEndTime)">
@@ -244,7 +266,6 @@
 
 							</template>
 
-
 						</template>
 						<!-- 预约考试 进入刷题-->
 						<template