index.vue 40 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635
  1. <template>
  2. <view class="index">
  3. <u-navbar class="navbar" :is-back="false" :border-bottom="false" title-color="#333333" back-icon-color="#ffffff">
  4. <view class="slot-wrap">
  5. <image src="/static/logo2.png"></image>
  6. </view>
  7. </u-navbar>
  8. <view class="swiper">
  9. <swiper :indicator-dots="false" indicator-color="#fff" indicator-active-color="#007AFF" :style="{'height':swiperHeight+'rpx'}" @change="swiperChange" :interval="interval" :duration="duration" :autoplay="autoplay" :circular="true">
  10. <swiper-item v-for="(swiper,index) in list" :key="index" @click="swiperClick(swiper)">
  11. <image @load="imageLoad" :src="$method.splitImgHost(swiper.adverUrl)" mode="widthFix"></image>
  12. </swiper-item>
  13. </swiper>
  14. <view class="dots">
  15. <view class="dot" :class="{'active':index == current}" v-for="(swiper,index) in list" :key="index"></view>
  16. </view>
  17. </view>
  18. <view class="content">
  19. <!-- <view class="notice" v-if="infoNums">
  20. <view class="notice__content">
  21. <image src="/static/icon/msg_icon1.png" class="icon"></image>
  22. <view class="text">
  23. 您有{{infoNums}}条新的通知
  24. </view>
  25. <view class="btn" @click="jumpPage">立即查看</view>
  26. </view>
  27. </view>
  28. <view class="my-list">
  29. <view class="my-list__item my-list__item--course" @click="go('course')">
  30. <image src="../../static/mycourse.png"></image>
  31. <text>我的网课</text>
  32. </view>
  33. <view class="my-list__item my-list__item--bank" @click="go('bank')">
  34. <image src="../../static/mybank.png"></image>
  35. <text>我的题库</text>
  36. </view>
  37. </view> -->
  38. <!-- 日历-->
  39. <!-- <view>
  40. <view class="calendar_card">
  41. <view class="card_box">
  42. <u-row gutter="16">
  43. <u-col span="10" >
  44. <view style="height:60rpx;">
  45. <text class="t1" v-if="nearByDay !== '' && nearByDay !== null">距离最近一次考试还剩{{nearByDay}}天</text>
  46. </view>
  47. </u-col>
  48. <u-col offset="1" span="1">
  49. <view @click="jumpPlan"><image src="/static/more.png" class="img_more"></image></view>
  50. </u-col>
  51. </u-row>
  52. </view>
  53. <u-line color="#EEEEEE" />
  54. <view style="width: 100%;display: flex;justify-content:center;margin-top: 20rpx;">
  55. <view v-for="(item, index) in date" :key="index" class="card_date">{{ item }}</view>
  56. </view>
  57. <view style="width: 100%; display: flex; margin-top: 40rpx; flex-wrap: wrap;">
  58. <view v-for="(item, index) in date_num" :key="index" class="date_num">
  59. <view class="items">
  60. {{ item.date }}
  61. </view>
  62. <view v-if="item.color == 0" class="date_num_color0" v-show="item.date > 0">
  63. {{ item.date }}
  64. <view v-if="item.note > 0" class="date_note">{{ item.note }}</view>
  65. <view v-if="item.dot" class="date_dot"></view>
  66. </view>
  67. <view v-if="item.color == 1" class="date_num_color1">
  68. {{ item.date }}
  69. <view v-if="item.note > 0" class="date_note">{{ item.note }}</view>
  70. <view v-if="item.dot" class="date_dot"></view>
  71. </view>
  72. <view v-if="item.color == 2" class="date_num_color2">
  73. {{ item.date }}
  74. <view v-if="item.note > 0" class="date_note">{{ item.note }}</view>
  75. <view v-if="item.dot" class="date_dot"></view>
  76. </view>
  77. <view v-if="item.color == 3" class="date_num_color3">
  78. {{ item.date }}
  79. <view v-if="item.note > 0" class="date_note">{{ item.note }}</view>
  80. <view v-if="item.dot" class="date_dot"></view>
  81. </view>
  82. </view>
  83. </view>
  84. <view style="width: 100%;margin-top: 20rpx;" v-if="workList.length > 0">
  85. <u-row gutter="16">
  86. <u-col span="2" text-align="center">
  87. <view><image src="/static/left.png" class="arr-icon" @click="preveItem"></image></view>
  88. </u-col>
  89. <u-col span="8" text-align="center">
  90. <view class="course_title" @click="jumpGoodsDetail(goodsItem)">{{ goodsItem.goodsName }}</view>
  91. </u-col>
  92. <u-col span="2" text-align="center">
  93. <view><image src="/static/right.png" class="arr-icon" @click="nextItem"></image></view>
  94. </u-col>
  95. </u-row>
  96. </view>
  97. </view>
  98. </view> -->
  99. <!-- <u-tabs class="tabs" :current="tabCurrent" @change="tab" :list="menu" :activeStyle="{fontSize:'36rpx'}" :inactiveStyle="{color:'#EAEEF1',fontSize:'30rpx'}" sticky></u-tabs> -->
  100. <view class="tabs">
  101. <view v-for="(item, index) in menu" :key="index" class="tab_item" :class="{nactive: tabNum == index}" @click="tab(index)">{{ item.name }}</view>
  102. </view>
  103. <view class="filters">
  104. <scroll-view class="scroll_view_H" scroll-x="true" >
  105. <template v-if="tabNum == 0 && courseName.length > 1">
  106. <view v-for="(item, index) in courseName" :key="index" class="filter_item" @click="changeCou(item.recommendId, index)">
  107. <view class="name" :class="{nactive: couIndex == index}">{{ item.name }}</view>
  108. </view>
  109. </template>
  110. <template v-if="tabNum == 1 && bankName.length > 1">
  111. <view v-for="(item, index) in bankName" :key="index" class="filter_item" @click="changebank(item.recommendId, index)">
  112. <view class="name" :class="{nactive: bankIndex == index}">{{ item.name }}</view>
  113. </view>
  114. </template>
  115. </scroll-view>
  116. </view>
  117. <!-- v-if="tabNum == 0" -->
  118. <!-- <view class="filters">
  119. <scroll-view class="scroll_view_H" scroll-x="true" >
  120. <template >
  121. <view v-for="(item, index) in subjectList" :key="index" class="filter_item" @click="changeSub(item.id, index)">
  122. <view class="name" :class="{nactive: subIndex == index}">{{ item.subjectName }}</view>
  123. </view>
  124. </template>
  125. </scroll-view>
  126. </view> -->
  127. <view class="course-list" v-show="tabCurrent==0">
  128. <template v-if="list1.length">
  129. <!-- hover-class="none" -->
  130. <view class="list_item" v-for="(item,index) in list1" :key="index" @click="tobuy(item)">
  131. <view class="course_content">
  132. <view class="c_title">{{item.goodsName}}</view>
  133. <view class="c_downs">
  134. <view class="img">
  135. <image :src="$method.splitImgHost(item.coverUrl, true)"></image>
  136. <view class="time" v-if="item.year">{{item.year?item.year:''}}</view>
  137. </view>
  138. <view class="text">
  139. <view class="desc">
  140. <view class="left">
  141. <text v-if="item.standPrice" class="mon_t">¥ {{toFixed(item.standPrice)}}</text>
  142. <text v-else class="mon_t free">免费</text>
  143. <!-- <text class="sale">/限时优惠</text> -->
  144. <text v-if="item.linePrice" class="sale"> ¥ </text>
  145. <text v-if="item.linePrice" class="price_line">&nbsp;{{ item.linePrice }}</text>
  146. </view>
  147. <view class="right">
  148. <view v-if="!hideBuyState" class="regiser_row">立即购买</view>
  149. </view>
  150. </view>
  151. <view v-if="item.buyUserNum" class="joins">
  152. <!-- <image class="people" src="/static/index/people.png"></image> -->
  153. <!-- 为0时,不显示 -->
  154. <view class="people">{{ item.buyUserNum }}人参与</view>
  155. </view>
  156. </view>
  157. </view>
  158. </view>
  159. </view>
  160. </template>
  161. <template v-else>
  162. <u-empty text="暂无推荐课程" mode="list" margin-top="100"></u-empty>
  163. </template>
  164. </view>
  165. <view class="course-list" v-show="tabCurrent==1">
  166. <template v-if="list2.length">
  167. <navigator hover-class="none" class="list_item" v-for="(item,index) in list2" :key="index" :url="'/pages2/bank/detail?id='+item.goodsId">
  168. <view class="course_content">
  169. <view class="c_title">{{item.goodsName}}</view>
  170. <view class="c_downs">
  171. <view class="img">
  172. <image :src="$method.splitImgHost(item.coverUrl, true)"></image>
  173. <view class="time" v-if="item.year">{{item.year?item.year:''}}</view>
  174. </view>
  175. <view class="text">
  176. <view class="desc">
  177. <view class="left">
  178. <text v-if="item.standPrice" class="mon_t">¥ {{toFixed(item.standPrice)}}</text>
  179. <text v-else class="mon_t free">免费</text>
  180. <!-- <text class="sale">/限时优惠</text> -->
  181. <text v-if="item.linePrice" class="sale"> ¥ </text>
  182. <text v-if="item.linePrice" class="price_line">&nbsp;{{ item.linePrice }}</text>
  183. </view>
  184. <view class="right">
  185. <view v-if="!hideBuyState" class="regiser_row">立即购买</view>
  186. </view>
  187. </view>
  188. <view v-if="item.buyUserNum" class="joins">
  189. <!-- 为0时,不显示 -->
  190. <view class="people">{{ item.buyUserNum }}人参与</view>
  191. </view>
  192. </view>
  193. </view>
  194. </view>
  195. </navigator>
  196. </template>
  197. <template v-else>
  198. <u-empty text="暂无推荐题库" mode="list" margin-top="100"></u-empty>
  199. </template>
  200. </view>
  201. </view>
  202. <!-- #ifdef MP-WEIXIN -->
  203. <view :style="{'opacity':opacitys}" class="officials">
  204. <view class="weixin_official_account">
  205. <image class="off_logo" src="/static/index/official.png"></image>
  206. <view>
  207. <view class="one">关注 “祥粤学校” 公众号</view>
  208. <view class="two">学习提醒、 报考通知不会错过</view>
  209. </view>
  210. <button type="default" class="btn btn-official" >
  211. 去关注
  212. <official-account class="official-account" id="official_account"></official-account>
  213. </button>
  214. <view class="close_icon">
  215. <u-icon name="close" class="icon-close" @click="closeOff"></u-icon>
  216. </view>
  217. </view>
  218. </view>
  219. <!-- #endif -->
  220. </view>
  221. </template>
  222. <script>
  223. import { mapGetters, mapActions } from 'vuex';
  224. import { socket_url, version} from '@/common/request.js';
  225. export default {
  226. data() {
  227. return {
  228. tabNum: 0,
  229. infoNums:0,
  230. list:[],
  231. tabCurrent:0,
  232. date:['日','一','二','三','四','五','六'],
  233. date_num: [],
  234. current:0,
  235. indicatorDots: true,
  236. autoplay: true,
  237. interval: 2000,
  238. duration: 500,
  239. swiperHeight:0,
  240. nearByDay:'', //距离最近一天考试
  241. menu: [{
  242. name: '推荐课程',
  243. }, {
  244. name: '推荐题库',
  245. }],
  246. goodsIndex: 0,
  247. goodsItem: 0,
  248. workList: [],
  249. workTextList: [],
  250. planGoodsList: [],
  251. paramList: [
  252. {
  253. pageNum: 1,
  254. pageSize: 10,
  255. total: 0,
  256. // showStatus: 0,
  257. getUserNum: 1, //是否返回商品购买用户数量 1带 0不带 ,会返回个buyUserNum
  258. goodsType:1
  259. },
  260. {
  261. pageNum: 1,
  262. pageSize: 10,
  263. total: 0,
  264. // showStatus: 0,
  265. getUserNum: 1,
  266. goodsType:2
  267. }
  268. ],
  269. total1: 0,
  270. total2: 0,
  271. list1: [],
  272. list2: [],
  273. isLogin:false,
  274. isOld:false,
  275. current: 0,
  276. showOfficial: false,
  277. // opacity: 1,
  278. isFollow: null, //是否关注过,不是1就是没关注
  279. curClose: true, // 当天时是否关闭过
  280. courseName: [],
  281. bankName: [],
  282. couIndex: 0,
  283. bankIndex: 0,
  284. courseId: '',
  285. bankId: '',
  286. subjectList: [],
  287. subIndex: 0,
  288. courSubjectId: '',
  289. optObj: {},
  290. };
  291. },
  292. async onLoad(option) {
  293. console.log('onLoadonLoad');
  294. this.isLogin = this.$method.isLogin()
  295. this.dictObj
  296. this.getAdvertising();
  297. if(this.$method.isLogin()) {
  298. try {
  299. await this.getUserInfo()
  300. // websocket.sokcet(socket_url+this.userInfo.userId+'-'+this.$method.getRandomString(6))
  301. // websocket.sokcet(socket_url+this.userInfo.userAccount)
  302. }catch(err) {
  303. }
  304. } else {
  305. if(uni.getStorageSync('needToLogin')) {
  306. uni.removeStorageSync('needToLogin');
  307. uni.navigateTo({
  308. url:'/pages4/login/login'
  309. })
  310. }
  311. }
  312. this.init()
  313. wx.getSystemInfo({
  314. success: function (res) {
  315. let version = res.SDKVersion
  316. console.log('该版本号为: ', version)
  317. }
  318. })
  319. },
  320. async onShow() {
  321. // #ifdef H5
  322. // this.OfficialLogin()
  323. if (location.search) {
  324. let arrs = location.search.slice(1).split("&")
  325. for (let i = 0; i < arrs.length; i++) {
  326. this.optObj[arrs[i].split('=')[0]] = arrs[i].split('=')[1]
  327. }
  328. console.log('optObj:', this.optObj);
  329. uni.setStorageSync('h5_code', this.optObj.code)
  330. // this.OfficialLogin()
  331. } else {
  332. // 没有code,就重定向到地址https://www.xyyxt.net?ask_type=h.xyyxt.net 去获取code,授权后就会把code带上然后访问域名,这时候你就拿到code了
  333. if (!uni.getStorageSync('h5_code')) {
  334. console.log('跳转');
  335. location.replace(
  336. "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx6f48f721d18244eb" +
  337. "&redirect_uri=" +
  338. encodeURIComponent('https://www.xyyxt.net/?ask_type=h.xyyxt.net') +
  339. "&response_type=code&scope=snsapi_userinfo&state=STATE#wechat_redirect"
  340. )
  341. return
  342. } else {
  343. this.$set(this.optObj, 'code', uni.getStorageSync('h5_code'))
  344. // this.OfficialLogin()
  345. }
  346. }
  347. // #endif
  348. this.getInfo() // 判断有没有关注公众号
  349. this.isClickOff() //关注公众号,每天最多显示1次;当天学员关闭弹窗后,无需再显示
  350. uni.removeStorageSync('goPath')
  351. // if (this.courseId || this.bankId) {
  352. // if (this.tabNum == 0) {
  353. // this.list1 = []
  354. // this.paramList[0].pageNum = 1
  355. // this.list1 = await this.getGoodsList(this.courseId, 0)
  356. // } else {
  357. // this.list2 = []
  358. // this.paramList[1].pageNum = 1
  359. // this.list2 = await this.getGoodsList(this.bankId, 1)
  360. // }
  361. // } else {
  362. this.list1 = []
  363. this.list2 = []
  364. this.paramList[0].pageNum = 1
  365. this.paramList[1].pageNum = 1
  366. this.courseLists()
  367. // }
  368. if (uni.getStorageSync('updateHome')){
  369. this.init()
  370. uni.removeStorageSync('updateHome'); //消费首页刷新事件
  371. }
  372. this.appCommonConfig({
  373. version
  374. });
  375. if(this.$method.isLogin()){
  376. this.$store.state.allowLoading = false;
  377. this.$api.getinfoAttached().then(res => {
  378. if(res.data.code ===200){
  379. this.infoNums = res.data.data.informSum
  380. const nums = res.data.data.informSum + res.data.data.orderSum + res.data.data.periodSum + res.data.data.planSum + res.data.data.subscribeSum;
  381. this.$store.commit('tabNum', nums);
  382. }
  383. })
  384. this.$store.state.allowLoading = true;
  385. }else{
  386. this.$store.commit('tabNum', 0);
  387. }
  388. },
  389. onShareAppMessage(res) {
  390. return {
  391. title: '中正',
  392. path: `/pages/index/index?inviteCode=` + userInfo == null ? '' : userInfo.userAccount
  393. };
  394. },
  395. async onPullDownRefresh() {
  396. // console.log('下拉this.courseId:', this.courseId)
  397. if (this.tabNum == 0) {
  398. this.list1 = []
  399. this.paramList[0].pageNum = 1
  400. this.list1 = await this.getGoodsList(this.courseId, 0, this.courSubjectId)
  401. } else {
  402. this.list2 = []
  403. this.paramList[1].pageNum = 1
  404. this.list2 = await this.getGoodsList(this.bankId, 1, this.courSubjectId)
  405. }
  406. },
  407. async onReachBottom() {
  408. // console.log('加载this.courseId:', this.courseId, this.list1.length, this.paramList[0].total)
  409. if (this.tabNum == 0) {
  410. if (this.list1.length < this.paramList[0].total) {
  411. this.paramList[0].pageNum++
  412. let list1 = await this.getGoodsList(this.courseId, 0, this.courSubjectId)
  413. this.list1.push(...list1)
  414. }
  415. } else {
  416. if (this.list2.length < this.paramList[1].total) {
  417. this.paramList[1].pageNum++
  418. let list2 = await this.getGoodsList(this.bankId, 1, this.courSubjectId)
  419. this.list1.push(...list2)
  420. }
  421. }
  422. },
  423. computed: {
  424. ...mapGetters(['dictObj','userInfo', 'hideBuyState']),
  425. opacitys() {
  426. const value = [1011,1017,1025,1047,1124].includes(this.$store.state.scene) && this.isLogin && (this.isFollow != 1) && this.curClose ? 1 : 0
  427. return value
  428. },
  429. },
  430. methods: {
  431. ...mapActions(['getUserInfo','appCommonConfig']),
  432. // 公众号登录
  433. OfficialLogin() {
  434. this.$http({
  435. url: '/app/common/gzh_login',
  436. method: 'post',
  437. data: {
  438. code: this.optObj.code || '011j2t0w3R1oNZ2Vh44w3sgS251j2t0B'
  439. },
  440. noToken: true
  441. }).then((res) => {
  442. if (res.data.code == 200) {
  443. } else {
  444. this.$u.toast(res.data.msg)
  445. }
  446. })
  447. },
  448. tobuy(item) {
  449. if (item.goodsType == 2) {
  450. uni.navigateTo({
  451. url: '/pages2/bank/detail?id='+item.goodsId
  452. })
  453. } else {
  454. // 视频、直播 /pages5/liveDetail/index
  455. uni.navigateTo({
  456. url: '/pages3/course/detail?id='+item.goodsId + '&goodsType=' + item.goodsType
  457. })
  458. }
  459. },
  460. getInfo() {
  461. // /app/user/getInfo 登录用户信息 // fromPlat来源平台 1小程序 2PC网站
  462. this.$api.getInfo({ fromPlat: 1 }).then(res => {
  463. if(res.data.code == 200){
  464. this.$store.state.userInfo = res.data.data
  465. this.isFollow = res.data.data.userFollowWx // 不是1就是没关注
  466. }
  467. })
  468. },
  469. // 每天最多显示1次;当天学员关闭弹窗后,无需再显示
  470. isClickOff() {
  471. //当天23:59:59秒 转换成的毫秒数
  472. const end = new Date(new Date(new Date().toLocaleDateString()).getTime()+24*60*60*1000-1).getTime()
  473. const start = new Date().getTime() //当前时间的毫秒数
  474. if(uni.getStorageSync('endTime')){ //首先判断本地有没有存入当天23:59:59秒的毫秒数
  475. if(start > uni.getStorageSync('endTime')){ //当前时间毫秒数大于当天23:59:59秒
  476. this.curClose = true
  477. uni.removeStorageSync('curClose')
  478. uni.removeStorageSync('endTime')
  479. } else {
  480. this.curClose = uni.getStorageSync('curClose') ? false : true
  481. }
  482. }else{
  483. uni.setStorageSync("endTime", end) //存入当天晚上23:59:59秒的毫秒数
  484. }
  485. },
  486. closeOff() {
  487. this.curClose = false
  488. uni.setStorageSync("curClose", '1')
  489. },
  490. toFixed(number) {
  491. if(number > 0) {
  492. return number.toFixed(2)
  493. } else {
  494. return '0.00'
  495. }
  496. },
  497. /**
  498. * @param {Object} swiper
  499. * 点击轮播图
  500. */
  501. swiperClick(swiper) {
  502. if(swiper.jumpType == 1) { //无跳转
  503. return;
  504. } else if(swiper.jumpType == 2) { //url
  505. let url = encodeURIComponent(swiper.jumpUrl)
  506. uni.navigateTo({
  507. url:'/pages/webview/index?url='+swiper.jumpUrl
  508. })
  509. } else if(swiper.jumpType == 3) { //内部接口
  510. uni.navigateTo({
  511. url:swiper.jumpUrl
  512. })
  513. } else if(swiper.jumpType == 4) { //外部接口
  514. uni.navigateToMiniProgram({
  515. appId: swiper.remarks,
  516. path: swiper.jumpUrl,
  517. extraData: {
  518. },
  519. success(res) {
  520. // 打开成功
  521. },
  522. fail(err) {
  523. // console.log(err)
  524. }
  525. })
  526. }
  527. },
  528. /**
  529. * banner图片加载完成
  530. */
  531. imageLoad(e) {
  532. let winW = 750;
  533. let imgW = e.detail.width;
  534. let imgH = e.detail.height;
  535. this.swiperHeight = 750 * imgH / imgW;
  536. },
  537. async getAdvertising() {
  538. await this.advertisingHomeLocation();
  539. await this.getLocation()
  540. // await this.advertisingList();
  541. },
  542. getUserSubscribeRecentExam() {
  543. return new Promise(resolve => {
  544. this.$api.getUserSubscribeRecentExam().then(res => {
  545. if(res.data.code == 200) {
  546. if(res.data.data) {
  547. let day = this.$method.timestampToTime(res.data.data.applySiteExamTime,true).replace(/-/g,'/')
  548. let dayTime = day + ' ' + res.data.data.applySiteStartTime
  549. let NowTime = new Date(); //考试时间
  550. let examTime = new Date(dayTime); //考试时间
  551. let t = (examTime.getTime() / 1000) - (NowTime.getTime() / 1000).toFixed(0);
  552. if(t > 0) {
  553. let day = +this.$method.GetRTime(examTime.getTime() / 1000,true)
  554. this.nearByDay = day;
  555. }
  556. }
  557. resolve()
  558. }
  559. })
  560. })
  561. },
  562. advertisingHomeLocation() {
  563. return new Promise(resolve => {
  564. this.$api.advertisingHomeLocation().then(res => {
  565. this.interval = res.data.data.intervalTime * 1000
  566. resolve()
  567. })
  568. })
  569. },
  570. getLocation() {
  571. this.$api.advertisingLocation({
  572. platform: 1,
  573. status: 1,
  574. locationKey: 'home-banner'
  575. }).then((res) => {
  576. if (res.data.code == 200) {
  577. let locationId = res.data.data && res.data.data[0].locationId || 1
  578. console.log('locationId:', locationId);
  579. this.advertisingList(locationId)
  580. }
  581. })
  582. },
  583. advertisingList(locationId) {
  584. // return new Promise(resolve => {
  585. this.$api.advertisingList({locationId: locationId}).then(res => {
  586. this.list = res.data.rows;
  587. // resolve()
  588. })
  589. // })
  590. },
  591. jumpPage(){
  592. this.$navTo.togo('/pages4/msg/index')
  593. },
  594. go(type) {
  595. if (!this.$method.isLogin()) {
  596. if(type == 'course') {
  597. uni.setStorageSync('goPath','course')
  598. } else if(type == 'bank' ) {
  599. uni.setStorageSync('goPath','bank')
  600. }
  601. this.$navTo.togo('/pages4/login/login');
  602. } else {
  603. if(type == 'course') {
  604. uni.navigateTo({
  605. url:'/pages2/wd/class'
  606. })
  607. } else if(type == 'bank') {
  608. this.$api.lockLockStatus({
  609. action:'bank'
  610. }).then(res => {
  611. if(res.data.code == 200) { //有其他端在操作,不能学习
  612. uni.showToast({
  613. icon:'none',
  614. title:res.data.msg,
  615. duration:3000,
  616. })
  617. } else if(res.data.code == 500) { //可以学习
  618. uni.navigateTo({
  619. url:'/pages2/wd/question_bank'
  620. })
  621. }
  622. })
  623. }
  624. }
  625. },
  626. async changeCou(recommendId, index) {
  627. this.couIndex = index
  628. this.courseId = recommendId
  629. this.paramList[0].pageNum = 1
  630. this.list1 = []
  631. let list1 = await this.getGoodsList(recommendId, 0, this.courSubjectId)
  632. this.list1.push(...list1)
  633. },
  634. async changebank(recommendId, index) {
  635. this.bankIndex = index
  636. this.bankId = recommendId
  637. this.paramList[1].pageNum = 1
  638. this.list2 = []
  639. let list2 = await this.getGoodsList(recommendId, 1, this.courSubjectId)
  640. this.list2.push(...list2)
  641. },
  642. async changeSub(subjectId, index) {
  643. // console.log('subjectId, index:', subjectId, index, 'this.courseId:', this.courseId, 'this.bankId:', this.bankId)
  644. this.subIndex = index
  645. this.courSubjectId = subjectId
  646. this.paramList[this.tabNum].pageNum = 1
  647. if (this.tabNum == 0) {
  648. this.list1 = []
  649. let list1 = await this.getGoodsList(this.courseId, 0, subjectId)
  650. this.list1.push(...list1)
  651. } else {
  652. this.list2 = []
  653. let list2 = await this.getGoodsList(this.bankId, 1, subjectId)
  654. this.list2.push(...list2)
  655. }
  656. },
  657. //课程
  658. courseLists() {
  659. // var param = this.paramList[0];
  660. // /app/common/goods/list
  661. this.$http({
  662. url: '/app/common/activity/recommend/list',
  663. method: 'get',
  664. data: {
  665. platform: 1,
  666. status: 1
  667. },
  668. noToken: true
  669. }).then(async (res) => {
  670. if (res.data.code == 200) {
  671. let list = res.data.rows || []
  672. //课程
  673. this.courseName = list.filter(x => x.type == 1).sort((a,b) => a.sort - b.sort).map(x => {
  674. return {
  675. name: x.name,
  676. recommendId: x.recommendId
  677. }
  678. });
  679. // console.log('couIndex', this.couIndex, this.courseName)
  680. //题库
  681. this.bankName = list.filter(x => x.type == 2).sort((a,b) => a.sort - b.sort).map(x => {
  682. return {
  683. name: x.name,
  684. recommendId: x.recommendId
  685. }
  686. });
  687. if (this.courseName.length) {
  688. let courseId = ''
  689. if (this.courseId) {
  690. courseId = this.courseId
  691. } else {
  692. courseId = this.courseName[0].recommendId
  693. this.courseId = this.courseName[0].recommendId
  694. }
  695. // console.log('courseId:', courseId)
  696. this.getSubjectList(courseId)
  697. let list1 = await this.getGoodsList(courseId, 0, '')
  698. this.list1.push(...list1)
  699. }
  700. if (this.bankName.length) {
  701. let bankId = ''
  702. if (this.bankId) {
  703. bankId = this.bankId
  704. } else {
  705. bankId = this.bankName[0].recommendId
  706. this.bankId = this.bankName[0].recommendId
  707. }
  708. let list2 = await this.getGoodsList(bankId, 1, '')
  709. this.list2.push(...list2)
  710. }
  711. }
  712. });
  713. },
  714. getGoodsList(recommendId, num, subjectId) {
  715. return new Promise((resolve, reject) => {
  716. let params = {
  717. pageNum: this.paramList[num].pageNum,
  718. pageSize: this.paramList[num].pageSize,
  719. recommendId: recommendId
  720. }
  721. subjectId && (params.subjectId = subjectId)
  722. // console.log('params:', params)
  723. this.$http({
  724. url: `/app/common/activity/recommend/goodsList`,
  725. method: 'get',
  726. data: params,
  727. noToken: true
  728. }).then((res) => {
  729. if (res.data.code == 200) {
  730. this.paramList[num].total = res.data.total
  731. resolve(res.data.rows)
  732. }
  733. })
  734. })
  735. },
  736. getSubjectList(recommendId) {
  737. this.$http({
  738. url: `/app/common/activity/recommend/subjectList`,
  739. method: 'get',
  740. data: {
  741. recommendId: recommendId
  742. },
  743. noToken: true
  744. }).then((res) => {
  745. if (res.data.code == 200) {
  746. let data = res.data.data || []
  747. this.subjectList = [{ id: '', subjectName: '全部'}, ...data]
  748. // console.log('this.subjectList:', this.subjectList)
  749. }
  750. })
  751. },
  752. /**
  753. * @param {Object} item
  754. * 跳转课程详情
  755. */
  756. async jumpGoodsDetail(item){
  757. uni.navigateTo({
  758. url:'/pages2/wd/class'
  759. })
  760. },
  761. /**
  762. * @param {Object} goodsId 商品id
  763. * 查询商品重修状态
  764. */
  765. courseGoodsRebuildStatus(goodsId,gradeId) {
  766. return new Promise(resolve => {
  767. this.$api.courseGoodsRebuildStatus({
  768. goodsId:goodsId,
  769. gradeId:gradeId
  770. }).then(res => {
  771. resolve(res.data.data)
  772. })
  773. })
  774. },
  775. preveItem() {
  776. if (this.goodsIndex > 0) {
  777. this.goodsIndex = this.goodsIndex - 1;
  778. this.planGoodsList =this.workList[this.goodsIndex].goodsVos
  779. this.goodsItem = this.planGoodsList[0];
  780. this.dealRL(this.workList[this.goodsIndex].calendarStudyVo)
  781. }
  782. },
  783. nextItem() {
  784. if (this.goodsIndex < this.workList.length - 1) {
  785. this.goodsIndex = this.goodsIndex + 1;
  786. this.planGoodsList =this.workList[this.goodsIndex].goodsVos
  787. this.goodsItem = this.planGoodsList[0];
  788. this.dealRL(this.workList[this.goodsIndex].calendarStudyVo)
  789. }
  790. },
  791. jumpPlan() {
  792. if (!this.$method.isLogin()) {
  793. this.$navTo.togo('/pages4/login/login');
  794. } else {
  795. this.$navTo.togo('/pages2/plan/index', {});
  796. }
  797. },
  798. async init() {
  799. if (!this.$method.isLogin()) {
  800. //未登录
  801. this.date_num = [];
  802. this.workList = [];
  803. this.planGoodsList = [];
  804. this.initDay();
  805. } else {
  806. this.date_num = [];
  807. this.workList = [];
  808. this.planGoodsList = [];
  809. await this.userPlanSeven();
  810. await this.getUserSubscribeRecentExam();
  811. }
  812. },
  813. getMonDate() {
  814. var d = new Date(),
  815. day = d.getDay(),
  816. date = d.getDate();
  817. if (day == 0) return d;
  818. else d.setDate(date - day);
  819. return d;
  820. },
  821. initDay() {
  822. // d是当前星期一的日期对象
  823. var d = this.getMonDate();
  824. var arr = [];
  825. let date = new Date();
  826. let num = date.getDate();
  827. this.date_num = []
  828. for (var i = 0; i < 7; i++) {
  829. let item = { date: d.getDate() };
  830. item.color = 0;
  831. if (d.getDate() == num) {
  832. item.color = 3;
  833. }
  834. this.date_num.push(item);
  835. d.setDate(d.getDate() + 1);
  836. }
  837. },
  838. dealRL(calendarStudyVo){
  839. let self = this
  840. self.date_num = []
  841. let date = new Date();
  842. let num = date.getDate();
  843. let month = date.getMonth() + 1;
  844. let list = [];
  845. for (let j = 0; j < calendarStudyVo.length; j++) {
  846. let item = calendarStudyVo[j];
  847. list = item.dayStudyList;
  848. for (let i = 0; i < list.length; i++) {
  849. let item = list[i];
  850. item.color = 0;
  851. if (item.date == num) {
  852. item.color = 3;
  853. }
  854. if (item.perform == 1) {
  855. item.color = 1;
  856. }
  857. if (item.perform == 2) {
  858. item.color = 2;
  859. }
  860. item.note = item.studyCourseKnob;
  861. if (item.note > 0) {
  862. item.dot = true;
  863. }
  864. self.date_num.push(item);
  865. }
  866. }
  867. },
  868. userPlanSeven() {
  869. return new Promise(resolve => {
  870. let self = this;
  871. this.$api.userPlanSeven().then(result => {
  872. if (result.data.data && result.data.data.length>0) {
  873. self.workList = result.data.data
  874. self.planGoodsList = self.workList[0].goodsVos;
  875. if (self.planGoodsList != null && self.planGoodsList.length > 0) {
  876. self.goodsItem = self.planGoodsList[0];
  877. }
  878. self.dealRL(result.data.data[0].calendarStudyVo)
  879. } else {
  880. self.initDay();
  881. }
  882. resolve()
  883. });
  884. })
  885. },
  886. swiperChange(e) {
  887. this.current = e.detail.current;
  888. },
  889. tab(e) {
  890. this.tabCurrent = e;
  891. this.tabNum = e
  892. this.paramList[this.tabNum].pageNum = 1
  893. if (e == 0) {
  894. this.list1 = []
  895. } else {
  896. this.list2 = []
  897. }
  898. this.courseLists()
  899. // let recommendId = e == 0 ? this.courseId : this.bankId
  900. // this.getSubjectList(recommendId)
  901. },
  902. updateHomePlan() {
  903. this.$refs.home.init();
  904. },
  905. beforeSwitch(index) {
  906. let that = this;
  907. if (index == 1) {
  908. this.isClick1 = true;
  909. }
  910. if (index == this.current) {
  911. return false;
  912. }
  913. if (!this.$method.isLogin()) {
  914. if (index == 0 || index == 1) {
  915. return true;
  916. } else {
  917. this.$navTo.togo('/pages4/login/login');
  918. return false;
  919. }
  920. } else {
  921. if (index == 2) {
  922. this.$refs.refMy.init();
  923. }
  924. return true;
  925. }
  926. }
  927. },
  928. };
  929. </script>
  930. <style>
  931. page {
  932. background: #eaeef1;
  933. }
  934. </style>
  935. <style lang="scss" scoped>
  936. @mixin threeDot {
  937. overflow: hidden;
  938. text-overflow:ellipsis;
  939. white-space: nowrap;
  940. }
  941. .index {
  942. .navbar {
  943. /deep/ .u-navbar-inner {
  944. margin-right:0!important;
  945. }
  946. .slot-wrap {
  947. width:100%;
  948. display: flex;
  949. align-items: center;
  950. justify-content: center;
  951. image {
  952. width: 178rpx;
  953. height: 31rpx;
  954. }
  955. }
  956. }
  957. .swiper {
  958. width:100%;
  959. position: relative;
  960. .dots {
  961. position:absolute;
  962. left:0;
  963. bottom:8rpx;
  964. width:100%;
  965. display: flex;
  966. justify-content: center;
  967. .dot {
  968. width: 8rpx;
  969. height: 8rpx;
  970. background: #FFFFFF;
  971. border-radius: 50%;
  972. margin:0 4rpx;
  973. transition: all 0.3s;
  974. &.active {
  975. width: 24rpx;
  976. height: 8rpx;
  977. background: #007AFF;
  978. border-radius: 4rpx;
  979. }
  980. }
  981. }
  982. image {
  983. width:100%;
  984. }
  985. }
  986. .content {
  987. overflow: hidden;
  988. padding:0 16rpx;
  989. background: rgba(234, 238, 241, 1);
  990. padding-bottom: 100rpx;
  991. .notice {
  992. background:#fff;
  993. border-radius: 16rpx;
  994. margin-top:32rpx;
  995. overflow: hidden;
  996. &__content {
  997. padding:0 8rpx;
  998. height: 56rpx;
  999. background: linear-gradient(-90deg, rgba(255, 209, 0, 0.3), rgba(255, 255, 255, 0.3));
  1000. display: flex;
  1001. align-items: center;
  1002. }
  1003. .icon {
  1004. width: 40rpx;
  1005. height: 40rpx;
  1006. margin-right: 8rpx;
  1007. }
  1008. .text {
  1009. flex:1;
  1010. font-size: 24rpx;
  1011. color: #333333;
  1012. position: relative;
  1013. }
  1014. .btn {
  1015. font-size: 24rpx;
  1016. color: #007AFF;
  1017. }
  1018. }
  1019. .date-list {
  1020. margin-top:16rpx;
  1021. width: 718rpx;
  1022. height: 330rpx;
  1023. background: #FFFFFF;
  1024. border-radius: 16rpx;
  1025. padding:18rpx 27rpx;
  1026. .title {
  1027. font-size: 30rpx;
  1028. font-weight: bold;
  1029. color: #007AFF;
  1030. }
  1031. .list {
  1032. margin-top:40rpx;
  1033. display: flex;
  1034. justify-content: space-around;
  1035. .item {
  1036. .top {
  1037. text-align: center;
  1038. font-size: 26rpx;
  1039. color: rgba(102, 102, 102, 0.6);
  1040. }
  1041. .bottom {
  1042. text-align: center;
  1043. line-height: 48rpx;
  1044. margin-top:30rpx;
  1045. width: 48rpx;
  1046. height: 48rpx;
  1047. border-radius: 50%;
  1048. color:rgba(51, 51, 51, 1);
  1049. font-size: 26rpx;
  1050. position:relative;
  1051. &.red {
  1052. color:#FF3B30;
  1053. }
  1054. &.green {
  1055. color:#36C75A;
  1056. }
  1057. &.blue {
  1058. background: #007AFF;
  1059. color:#fff;
  1060. }
  1061. .note {
  1062. width: 30rpx;
  1063. height: 30rpx;
  1064. border: 2rpx solid #FF9500;
  1065. border-radius: 50%;
  1066. position:absolute;
  1067. top:-20rpx;
  1068. right:-20rpx;
  1069. line-height: 28rpx;
  1070. text-align: center;
  1071. color:#FF9500;
  1072. font-size: 26rpx;
  1073. }
  1074. .point {
  1075. margin:0 auto;
  1076. width: 8rpx;
  1077. height: 8rpx;
  1078. background: #FF9500;
  1079. border-radius: 50%;
  1080. }
  1081. }
  1082. }
  1083. }
  1084. .btns {
  1085. margin-top:50rpx;
  1086. display: flex;
  1087. align-items: center;
  1088. justify-content: center;
  1089. .left,.right {
  1090. width: 40rpx;
  1091. height: 40rpx;
  1092. }
  1093. .center{
  1094. width: 440rpx;
  1095. height: 56rpx;
  1096. background: #FFFFFF;
  1097. box-shadow: 0px 0px 9rpx 1rpx rgba(47, 67, 121, 0.1);
  1098. border-radius: 28rpx;
  1099. color:rgba(255, 149, 0, 1);
  1100. line-height: 56rpx;
  1101. text-align: center;
  1102. font-size: 30rpx;
  1103. margin:0 30rpx;
  1104. }
  1105. }
  1106. }
  1107. .tabs {
  1108. width: 100%;
  1109. height: 78rpx;
  1110. display: flex;
  1111. align-items: center;
  1112. justify-content: space-between;
  1113. background-color: #F2F7FF;
  1114. border-radius: 38rpx;
  1115. margin: 34rpx 0rpx 24rpx 0rpx;
  1116. padding: 0rpx 5rpx;
  1117. .tab_item {
  1118. width: 345rpx;
  1119. height: 65rpx;
  1120. line-height: 65rpx;
  1121. font-size: 28rpx;
  1122. font-weight: bold;
  1123. border-radius: 32rpx;
  1124. text-align: center;
  1125. color: #333;
  1126. &.nactive {
  1127. color: #fff;
  1128. background-color: #3577E8;
  1129. }
  1130. }
  1131. }
  1132. .course-list {
  1133. box-shadow: 0px 10rpx 9rpx 1rpx rgba(165, 196, 239, 0.1);
  1134. .list_item {
  1135. padding: 24rpx;
  1136. // height: 278rpx;
  1137. background: #FFFFFF;
  1138. box-shadow: 0rpx 0rpx 20rpx 1rpx rgba(1,99,235,0.1000);
  1139. border-radius: 24rpx;
  1140. background:#fff;
  1141. margin-bottom: 32rpx;
  1142. display: flex;
  1143. align-items: center;
  1144. .c_title {
  1145. font-size: 32rpx;
  1146. font-weight: bold;
  1147. margin-bottom: 24rpx;
  1148. font-weight: bold;
  1149. color: #222222;
  1150. }
  1151. .c_downs {
  1152. display: flex;
  1153. }
  1154. .img {
  1155. position:relative;
  1156. margin-right: 24rpx;
  1157. border-radius: 16rpx ;
  1158. overflow: hidden;
  1159. width: 204rpx;
  1160. height: 120rpx;
  1161. image {
  1162. width:100%;
  1163. height:100%;
  1164. }
  1165. .time {
  1166. position:absolute;
  1167. bottom:0;
  1168. right:0;
  1169. width: 80rpx;
  1170. height: 32rpx;
  1171. background: rgba(1, 25, 45, 0.4);
  1172. color:#fff;
  1173. text-align: center;
  1174. line-height: 32rpx;
  1175. font-size: 24rpx;
  1176. border-radius: 10rpx 0px 10rpx 0px;
  1177. }
  1178. }
  1179. .text {
  1180. width: 440rpx;
  1181. position: relative;
  1182. display: flex;
  1183. flex-direction: column;
  1184. justify-content: space-between;
  1185. height: 120rpx;
  1186. .joins {
  1187. .people {
  1188. width: 160rpx;
  1189. font-size: 20rpx;
  1190. color: #999999;
  1191. padding: 0rpx 8rpx;
  1192. text-align: center;
  1193. height: 36rpx;
  1194. line-height: 36rpx;
  1195. background: #F6F7FB;
  1196. border-radius: 4px;
  1197. }
  1198. }
  1199. .desc {
  1200. margin-top: 10rpx;
  1201. display: flex;
  1202. align-items: center;
  1203. justify-content: space-between;
  1204. width: 100%;
  1205. .left {
  1206. flex:1;
  1207. color:#333;
  1208. font-size: 26rpx;
  1209. .mon_t {
  1210. font-weight: bold;
  1211. color: #FC3F3F;
  1212. font-size: 36rpx;
  1213. }
  1214. .free {
  1215. font-size: 24rpx;
  1216. }
  1217. .sale {
  1218. color: #999999;
  1219. font-size: 24rpx;
  1220. margin-left: 8rpx;
  1221. }
  1222. .price_line {
  1223. color: #999999;
  1224. font-size: 24rpx;
  1225. text-decoration:line-through;
  1226. font-weight: 400;
  1227. }
  1228. }
  1229. .right {
  1230. font-size: 24rpx;
  1231. font-weight: bold;
  1232. .regiser_row {
  1233. width: 144rpx;
  1234. height: 52rpx;
  1235. line-height: 52rpx;
  1236. text-align: center;
  1237. border-radius: 16rpx;
  1238. background-color: #FC3F3F;
  1239. color: #fff;
  1240. font-weight: 500;
  1241. font-size: 26rpx;
  1242. }
  1243. }
  1244. }
  1245. }
  1246. }
  1247. }
  1248. .filters {
  1249. width: 100%;
  1250. padding: 0rpx 16rpx;
  1251. margin-bottom: 32rpx;
  1252. display: flex;
  1253. align-items: center;
  1254. .scroll_view_H {
  1255. width: 100%;
  1256. overflow: hidden;
  1257. white-space: nowrap;
  1258. }
  1259. .filter_item {
  1260. display: inline-block;
  1261. margin-right: 16rpx;
  1262. .name {
  1263. font-size: 24rpx;
  1264. color: #666666;
  1265. padding: 12rpx 16rpx;
  1266. height: 56rpx;
  1267. text-align: center;
  1268. background: #FFFFFF;
  1269. border-radius: 8rpx;
  1270. &.nactive {
  1271. color: #3F8DFD;
  1272. }
  1273. }
  1274. }
  1275. }
  1276. }
  1277. .my-list {
  1278. margin:32rpx 0;
  1279. display:flex;
  1280. justify-content: space-between;
  1281. &__item {
  1282. width:351rpx;
  1283. height:96rpx;
  1284. position:relative;
  1285. padding:25rpx 0 0 25rpx;
  1286. font-size: 32rpx;
  1287. &--bank {
  1288. text {
  1289. position: relative;
  1290. z-index: 2;
  1291. color:#00998A;
  1292. }
  1293. }
  1294. &--course {
  1295. text {
  1296. position: relative;
  1297. z-index: 2;
  1298. color:#0062D9;
  1299. }
  1300. }
  1301. image {
  1302. width:100%;
  1303. height:100%;
  1304. left:0;
  1305. top:0;
  1306. position:absolute;
  1307. z-index: 1;
  1308. }
  1309. }
  1310. }
  1311. }
  1312. .date_dot {
  1313. width: 6rpx;
  1314. height: 6rpx;
  1315. background: #ffcc00;
  1316. border-radius: 50%;
  1317. margin: 0 auto;
  1318. }
  1319. .date_note {
  1320. border-radius: 50%;
  1321. width: 29rpx;
  1322. height: 29rpx;
  1323. border: 1px solid #ffcc00;
  1324. font-size: 18rpx;
  1325. color: #ffcc00;
  1326. text-align: center;
  1327. display: inline-block;
  1328. position: absolute;
  1329. top: -19rpx;
  1330. right: 9rpx;
  1331. }
  1332. .circle_num {
  1333. border-radius: 50%;
  1334. width: 29rpx;
  1335. height: 29rpx;
  1336. border: 1px solid #ffcc00;
  1337. font-size: 18rpx;
  1338. color: #ffcc00;
  1339. text-align: center;
  1340. display: inline-block;
  1341. margin: 5rpx;
  1342. }
  1343. .date_num {
  1344. width: 14%;
  1345. text-align: center;
  1346. position: relative;
  1347. display: inline-block;
  1348. margin-top: 20rpx;
  1349. .items {
  1350. width: 100%;
  1351. }
  1352. }
  1353. .course_title {
  1354. color: #2f4379;
  1355. box-shadow: 0rpx 0rpx 9rpx 1rpx rgba(47, 67, 121, 0.1);
  1356. border-radius: 28rpx;
  1357. width: 100%;
  1358. height: 48rpx;
  1359. line-height: 48rpx;
  1360. overflow: hidden;
  1361. text-overflow:ellipsis;
  1362. white-space: nowrap;
  1363. }
  1364. .arr-icon {
  1365. width: 40rpx;
  1366. height: 40rpx;
  1367. }
  1368. .date_num_color0 {
  1369. color: #32467b;
  1370. }
  1371. .date_num_color1 {
  1372. color: #34c759;
  1373. }
  1374. .date_num_color2 {
  1375. color: #ff3b30;
  1376. }
  1377. .date_num_color3 {
  1378. color: #ffffff;
  1379. background-color: #ffcc00;
  1380. border-radius: 50%;
  1381. width: 40rpx;
  1382. height: 40rpx;
  1383. display: inline-block;
  1384. }
  1385. .card_date {
  1386. width: 14%;
  1387. text-align: center;
  1388. color: #7f8caf;
  1389. }
  1390. .calendar_card {
  1391. width: 100%;
  1392. background: #ffffff;
  1393. box-shadow: 0rpx 0rpx 16rpx 4rpx rgba(47, 67, 121, 0.1);
  1394. border-radius: 22rpx;
  1395. margin-top: 16rpx;
  1396. padding-bottom: 15rpx;
  1397. }
  1398. .calendar_card .card_box {
  1399. height: 60rpx;
  1400. line-height: 60rpx;
  1401. margin-left: 20rpx;
  1402. }
  1403. .calendar_card .t1 {
  1404. color: #007AFF;
  1405. font-size: 24rpx;
  1406. }
  1407. .img_more {
  1408. width: 26rpx;
  1409. height: 26rpx;
  1410. }
  1411. .flex-d {
  1412. display: flex;
  1413. flex-direction: column;
  1414. justify-content: space-between;
  1415. height: 100%;
  1416. }
  1417. .contentZ {
  1418. flex: 1;
  1419. overflow-y: auto;
  1420. padding-left: 35rpx;
  1421. display: flex;
  1422. justify-content: space-around;
  1423. }
  1424. .contentZ::-webkit-scrollbar {
  1425. display: none;
  1426. }
  1427. .fots {
  1428. height: 100rpx;
  1429. display: flex;
  1430. align-items: center;
  1431. justify-content: space-around;
  1432. border-top: 1rpx solid #eee;
  1433. }
  1434. .leftBtns {
  1435. font-size: 30rpx;
  1436. color: #32467b;
  1437. font-weight: 500;
  1438. }
  1439. .right_Btns {
  1440. font-size: 30rpx;
  1441. color: #fff;
  1442. background-color: #32467b;
  1443. border-radius: 24rpx;
  1444. height: 60rpx;
  1445. line-height: 60rpx;
  1446. text-align: center;
  1447. padding: 0rpx 23rpx;
  1448. box-shadow: 0rpx 0rpx 16rpx 4rpx rgba(145, 156, 178, 0.1);
  1449. }
  1450. .lzs {
  1451. width: 31%;
  1452. margin: 0rpx 1%;
  1453. max-width: 31%;
  1454. }
  1455. .tylsz{
  1456. margin-top: 23rpx;
  1457. color: #666;
  1458. font-weight: 400;
  1459. font-size: 24rpx;
  1460. }
  1461. .tylsz:first-child{
  1462. text-align: center;
  1463. }
  1464. .activeStys{
  1465. font-weight: bold;
  1466. color: #32467B;
  1467. }
  1468. .officialsss {
  1469. position: fixed;
  1470. left: 0;
  1471. bottom: 100rpx;
  1472. width: 100%;
  1473. }
  1474. .officials {
  1475. width:100%;
  1476. height: 104rpx;
  1477. position:fixed;
  1478. bottom: 0;
  1479. left: 0;
  1480. z-index: 999;
  1481. display: flex;
  1482. align-items: center;
  1483. justify-content: center;
  1484. }
  1485. .weixin_official_account {
  1486. position: fixed;
  1487. bottom: 0;
  1488. left: 0;
  1489. display: flex;
  1490. align-items: center;
  1491. // justify-content: space-between;
  1492. width: 718rpx;
  1493. height: 104rpx;
  1494. padding: 0 32rpx;
  1495. margin-left: 16rpx;
  1496. background: #3A3F54;
  1497. border-radius: 16rpx;
  1498. .off_logo {
  1499. width: 48rpx;
  1500. height: 48rpx;
  1501. margin-right: 24rpx;
  1502. }
  1503. .one {
  1504. color: #fff;
  1505. font-size: 24rpx;
  1506. font-weight: 500;
  1507. }
  1508. .two {
  1509. color: #BCBEC7;
  1510. font-size: 20rpx;
  1511. }
  1512. .btn {
  1513. position: relative;
  1514. top: 0;
  1515. left: 35rpx;
  1516. width: 128rpx;
  1517. height: 56rpx;
  1518. line-height: 56rpx;
  1519. padding: 0;
  1520. background: linear-gradient(274deg, #408BF6 0%, #40B4F6 100%);
  1521. border-radius: 156rpx;
  1522. overflow: hidden;
  1523. text-align: center;
  1524. font-size: 24rpx;
  1525. color: #fff;
  1526. .official-account {
  1527. position: absolute;
  1528. z-index: 1000;
  1529. right: -9px;
  1530. top: -38px;
  1531. opacity: 0;
  1532. }
  1533. }
  1534. .close_icon {
  1535. width: 40rpx;
  1536. height: 40rpx;
  1537. background: #FFFFFF;
  1538. opacity: 0.2;
  1539. display: flex;
  1540. align-items: center;
  1541. position: absolute;
  1542. top: 0;
  1543. right: 0;
  1544. color: #fff;
  1545. border-radius: 0rpx 16rpx;
  1546. }
  1547. .icon-close {
  1548. display: flex;
  1549. align-items: center;
  1550. justify-content: center;
  1551. width: 50rpx;
  1552. height: 68rpx;
  1553. font-size: 22rpx;
  1554. color: #7B8284;
  1555. }
  1556. }
  1557. </style>