index.vue 30 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216
  1. <template>
  2. <view class="sheduling">
  3. <!-- 添加排班 -->
  4. <u-popup v-model="teacher_show" mode="center" border-radius="19">
  5. <view class="pop_wrap">
  6. <view class="pop_top">
  7. <text class="title">请您确认排班时间</text>
  8. </view>
  9. <view class="pop_center">
  10. <text>上课日期:{{now_date}}</text>
  11. <text>上课时间:{{time.start_time}}-{{time.end_time}}</text>
  12. </view>
  13. <view class="pop_bootom">
  14. <button type="default" @click="sure_choose">确认</button>
  15. </view>
  16. </view>
  17. </u-popup>
  18. <!-- 取消排班 -->
  19. <u-popup v-model="cancel_show" mode="center" border-radius="19">
  20. <view class="pop_wrap">
  21. <view class="pop_top">
  22. <text class="title">您确定要取消如下排班吗</text>
  23. </view>
  24. <view class="pop_center">
  25. <text>上课日期:{{cancel_detail.day}}</text>
  26. <text>上课时间:{{cancel_detail.start_time}}-{{cancel_detail.end_time}}</text>
  27. </view>
  28. <view class="pop_bootom">
  29. <button type="default" @click="sure_cancel">确定取消</button>
  30. </view>
  31. </view>
  32. </u-popup>
  33. <u-popup v-model="stu_show" mode="center" border-radius="42" width="85%">
  34. <view class="student-show">
  35. <view class="stu-title">
  36. 预约学生基本信息
  37. </view>
  38. <view class="stu-mess">
  39. <image :src="stu_detail.student ? stu_detail.student.headimg : '../../static/images/avator.png'"
  40. mode="">
  41. </image>
  42. <view class="right">
  43. <view class="stu-text">
  44. 姓名:{{stu_detail.student?stu_detail.student.truename:'--'}}
  45. </view>
  46. <view class="stu-text">
  47. 学号:{{stu_detail.student?stu_detail.student.account:'--'}}
  48. </view>
  49. <view class="stu-text">
  50. 班级:{{stu_detail.student ? stu_detail.student.class :'--'}}
  51. </view>
  52. <view class="stu-text">
  53. 手机号:{{stu_detail.student ? stu_detail.student.mobile :'--'}}
  54. </view>
  55. </view>
  56. </view>
  57. <view class="e-mail">
  58. <u-icon name="email"></u-icon>:{{stu_detail.student ? stu_detail.student.email :'--'}}
  59. </view>
  60. <view class="remark-title">
  61. {{stu_detail.student?stu_detail.student.sex==2?"她":"他":'--'}}的备注
  62. </view>
  63. <view class="remark">
  64. {{stu_detail.remark?stu_detail.remark:'暂无'}}
  65. </view>
  66. </view>
  67. </u-popup>
  68. <view class="sheduling-top" v-if="notice.length>0">
  69. <image src="../../static/images/nock.png" mode=""></image>
  70. <view class="title">
  71. <u-notice-bar :volume-icon="false" type='none' color='#2B9155' :speed="120" :list="notice">
  72. </u-notice-bar>
  73. </view>
  74. </view>
  75. <view class="tab">
  76. <view v-for="(item,index) in tab_list" :key='index' :class="current_tab==index ? 'active-item' : 'item'"
  77. @click="changTab(index)">
  78. <view class="week">
  79. {{item}}
  80. </view>
  81. <text class="line" v-if="current_tab==index">
  82. </text>
  83. </view>
  84. </view>
  85. <view class="content">
  86. <view class="top">
  87. <view :class="current_date==index ? 'active-item':'item'" v-for="(item,index) in table_week"
  88. :key='index' @click="changeDate(index,item)">
  89. <view class="week">
  90. {{item.week}}
  91. </view>
  92. <view class="date">
  93. {{getDay(item.day)}}
  94. </view>
  95. </view>
  96. </view>
  97. <view class="shedule">
  98. <view class="left">
  99. <view class="left_1">
  100. <view :class="current_time==-1 ? 'active-item':'item'" @click="changeTime(-1)">
  101. <image class="all" v-if="current_time==-1" src="../../static/images/all.png" mode=""></image>
  102. 全部时间
  103. <image class="jian" v-if="current_time==-1" src="../../static/images/01.png" mode=""></image>
  104. </view>
  105. <view :class="current_time==index? 'active-item':'item'" v-for="(item,index) in time_list"
  106. :key='index' @click="changeTime(item,index)">
  107. {{item.start_time}}-{{item.end_time}}
  108. <image v-if="current_time==index" class="jian" src="../../static/images/01.png" mode="">
  109. <!-- <image v-if="current_time==item.id" class="jian" src="../../static/images/01.png" mode=""> -->
  110. </image>
  111. </view>
  112. </view>
  113. </view>
  114. <view class="right">
  115. <view class="" v-for="(item,index) in shedule_list" :key='index'>
  116. <view class="item" v-if="item.scheduling && index==current_time && index!=-1">
  117. <view class="item-left">
  118. <view class="image" :style="{backgroundImage:'url('+ (item.scheduling ? item.scheduling.teacher.headimg :'../../static/images/add.png') +')'}">
  119. </view>
  120. <!-- <image
  121. :src="item.scheduling ? item.scheduling.teacher.headimg :'../../static/images/add.png'"
  122. mode=""></image> -->
  123. <view class="name">
  124. {{item.scheduling ? item.scheduling.teacher.truename : ''}}
  125. </view>
  126. </view>
  127. <!-- {{item}} -->
  128. <view class="item-right">
  129. <view class="text">
  130. <view class="tips" v-if="item.scheduling.student"
  131. @click="stuDetail(item.scheduling)">
  132. 查看学生
  133. </view>
  134. <image src="../../static/images/icon-1.png" mode=""></image>
  135. <view class="time">
  136. {{item.scheduling.start_time}}-{{item.scheduling.end_time}}
  137. </view>
  138. </view>
  139. <view class="text">
  140. <image src="../../static/images/icon-2.png" mode=""></image>
  141. <view class="time">
  142. {{item.scheduling.day}}
  143. </view>
  144. </view>
  145. <view class="text">
  146. <image src="../../static/images/icon-3.png" mode=""></image>
  147. <view class="time">
  148. {{item.scheduling.student ? '有预约' :'无预约' }}
  149. </view>
  150. </view>
  151. </view>
  152. <view class="cancel" @click="cancelShedule(item)"
  153. v-if="item.is_del==true && item.is_me==true">
  154. 取消
  155. </view>
  156. <view class="" v-if="!item.scheduling">
  157. {{ item.is_scheduling == false ? '已过期' : '立即排班' }}
  158. </view>
  159. </view>
  160. <!-- 当时间未全部index==0 -->
  161. <view class="item" v-if="item.scheduling && current_time==-1">
  162. <view class="item-left">
  163. <view class="image" :style="{backgroundImage:'url('+ (item.scheduling ? item.scheduling.teacher.headimg :'../../static/images/add.png') +')'}">
  164. </view>
  165. <!-- <image
  166. :src="item.scheduling ? item.scheduling.teacher.headimg :'../../static/images/add.png'"
  167. mode=""></image> -->
  168. <view class="name">
  169. {{item.scheduling ? item.scheduling.teacher.truename : ''}}
  170. </view>
  171. </view>
  172. <!-- {{item}} -->
  173. <view class="item-right">
  174. <view class="text">
  175. <view class="tips" v-if="item.scheduling.student"
  176. @click="stuDetail(item.scheduling)">
  177. 查看学生
  178. </view>
  179. <image src="../../static/images/icon-1.png" mode=""></image>
  180. <view class="time">
  181. {{item.scheduling.start_time}}-{{item.scheduling.end_time}}
  182. </view>
  183. </view>
  184. <view class="text">
  185. <image src="../../static/images/icon-2.png" mode=""></image>
  186. <view class="time">
  187. {{item.scheduling.day}}
  188. </view>
  189. </view>
  190. <view class="text">
  191. <image src="../../static/images/icon-3.png" mode=""></image>
  192. <view class="time">
  193. {{item.scheduling.student ? '有预约' :'无预约' }}
  194. </view>
  195. </view>
  196. </view>
  197. <view class="cancel" @click="cancelShedule(item)"
  198. v-if="item.is_del==true && item.is_me==true">
  199. 取消
  200. </view>
  201. <view class="" v-if="!item.scheduling">
  202. {{ item.is_scheduling == false ? '已过期' : '立即排班' }}
  203. </view>
  204. </view>
  205. <view class="add add1" v-if=" item.is_scheduling == true && index == current_time">
  206. <image src="../../static/images/pass1.png" mode="widthFix"></image>
  207. <view class="add-buttom" v-if="current_time != -1" @click="teacher_show = true">
  208. <!-- <image src="../../static/images/add_duty.png" mode=""></image> -->
  209. 添加排班
  210. </view>
  211. </view>
  212. <view class="add"
  213. v-if="!item.scheduling &&item.is_scheduling == false && index == current_time ">
  214. <image src="../../static/images/pass1.png" mode="widthFix"></image>
  215. <view class="add-text">
  216. 已截止
  217. </view>
  218. </view>
  219. </view>
  220. <view class="add" v-if="getEmpty && current_time==-1">
  221. <image src="../../static/images/pass1.png" mode="widthFix"></image>
  222. <view class="add-text">
  223. 暂无排班
  224. </view>
  225. </view>
  226. </view>
  227. </view>
  228. <view class="table">
  229. <view class="title">
  230. 工作排班信息
  231. </view>
  232. <view class="table_1">
  233. <view class="table-week">
  234. <view class="table-item" v-for="(item,index) in table_week" :key='index'>
  235. <view>{{ item.week ? item.week.slice(1) : '--'}}</view>
  236. <view>{{getDay(item.day)}}</view>
  237. </view>
  238. </view>
  239. <view class="table-tr">
  240. <view class="table-time" v-for="(item1,index1) in table_list" :key='index1'>
  241. <view v-for="(item,index) in item1" :key='index'
  242. :class="item.scheduling && item.is_me==false ? 'active-time-item' :item.scheduling&&item.is_me==true ? 'me-item' : 'time-item'">
  243. <view class="" v-if="item.scheduling">
  244. <view class="teacher">
  245. {{getName(item.scheduling.teacher)}}
  246. </view>
  247. <view class="stu">
  248. {{getName(item.scheduling.student)}}
  249. </view>
  250. </view>
  251. </view>
  252. </view>
  253. </view>
  254. </view>
  255. <view class="tips">
  256. <view class="tip-item">
  257. <span class="yellow">*</span>第一行上面显示的是导师
  258. </view>
  259. <view class="tip-item">
  260. <span class="yellow">*</span>第二行下方显示的是学生
  261. </view>
  262. </view>
  263. </view>
  264. </view>
  265. </view>
  266. </template>
  267. <script>
  268. export default {
  269. data() {
  270. return {
  271. teacher_show: false,
  272. time_detail: '', //预约时间弹框
  273. stu_show: false, //学生信息弹框
  274. stu_detail: '', //查看学生详情
  275. date: [1, 1, 1, 1, 1, 1, 1],
  276. time_list: [1, 1, 1, 1, 1, 1],
  277. current_time: 0, //当前时间
  278. current_date: 0,
  279. current_tab: 0, //本周下周
  280. tab_list: ['本周', '下周'],
  281. table_week: 7,
  282. time_list: [],
  283. current_item: 0, //当前周索引
  284. now_date: '', //今天日期日期
  285. shedule_list: [], //排班列表
  286. teacher_id: '',
  287. time: '', //当前选中的时间段的内容--传参添加页面使用
  288. table_list: [], //表格列数
  289. day: '', //当天日期
  290. notice: '', //通知公告
  291. now_time: '',
  292. now_list: [],
  293. cancel_detail: '',
  294. cancel_show: false, //取消排班
  295. }
  296. },
  297. async onShow() {
  298. await this.getNowDate()
  299. await this.getSheuling()
  300. //await this.getList()
  301. },
  302. onLoad() {
  303. if (this.is_weixin()) {
  304. this.navTitle()
  305. }
  306. this.notice = []
  307. this.teacher_id = this.$store.state.vuex_user.type_id
  308. this.getNotice()
  309. },
  310. computed: {
  311. getEmpty() {
  312. let a = true
  313. for (let i in this.shedule_list) {
  314. console.log(i, this.shedule_list[i].scheduling, 'YYYYYYYY')
  315. // console.log(this.shedule_list[i-1], 'YYTTTTTTTT')
  316. if (this.shedule_list[i].scheduling != null) {
  317. a = false
  318. break
  319. }
  320. }
  321. return a
  322. },
  323. },
  324. methods: {
  325. //判断是否是微信
  326. is_weixin() {
  327. let ua = navigator.userAgent.toLowerCase();
  328. return ua.indexOf('micromessenger') != -1;
  329. },
  330. navTitle() {
  331. let navTitle = document.getElementsByTagName('uni-page-head');
  332. navTitle[0].style.display = 'none'
  333. },
  334. //取消排班
  335. cancelShedule(item) {
  336. console.log(item.scheduling, 'ppp')
  337. this.cancel_detail = item.scheduling
  338. this.cancel_show = true
  339. },
  340. sure_cancel() {
  341. let id = this.cancel_detail.id
  342. this.$u.delete('/mentor/scheduling/' + id).then(res => {
  343. console.log(res, 'ppp')
  344. if (res.code == 200) {
  345. uni.showToast({
  346. title: '取消排班成功',
  347. icon: 'none'
  348. })
  349. }
  350. this.cancel_show = false
  351. this.getSheuling()
  352. })
  353. },
  354. //获取通知公告
  355. getNotice() {
  356. this.$u.get('/notice').then(res => {
  357. console.log(res, 'pppppp')
  358. if (res.data.notice) {
  359. this.notice.push(res.data.notice)
  360. }
  361. })
  362. },
  363. //姓名截取 获取前三个字
  364. getName(name) {
  365. if (name) {
  366. return name.truename.substr(0, 3)
  367. } else {
  368. return '--'
  369. }
  370. },
  371. //日期截取
  372. getDay(day) {
  373. if (day) {
  374. return day.slice(5)
  375. }
  376. },
  377. //查看学生信息
  378. stuDetail(item) {
  379. console.log(item, 'item')
  380. this.stu_show = true
  381. this.stu_detail = item
  382. },
  383. //获取值班列表
  384. // async getList() {
  385. // console.log(this.current_tab, '当前时间')
  386. // if (this.current_tab == 1) {
  387. // if (this.current_date != 0) {
  388. // } else {
  389. // this.now_date = this.table_week[0].day
  390. // this.current_date = 0
  391. // }
  392. // }
  393. // console.log(this.now_date, '当前时间')
  394. // let data = {
  395. // day: this.now_date,
  396. // time_id: this.current_time == 0 ? '' : this.current_time,
  397. // }
  398. // await this.$u.get('/mentor/scheduling', data).then(res => {
  399. // console.log(res, '我的值班信息')
  400. // this.shedule_list = res.data.list
  401. // })
  402. // },
  403. //获取排班信息
  404. async getSheuling() {
  405. await this.$u.get('/mentor/scheduling-calendar', {
  406. type: this.current_tab
  407. }).then(res => {
  408. console.log(res, '排班信息')
  409. this.time_list = res.data.times
  410. this.table_list = res.data.list
  411. let table_week = res.data.days
  412. table_week.map((item, index) => {
  413. // if (this.current_tab == 0) {
  414. // this.now_date = this.day
  415. // }
  416. // this.now_date = this.table_week[this.current_date].day
  417. if (this.now_date == item.day) {
  418. this.current_date = index
  419. console.log(this.now_date, 'this.now_date---------')
  420. }
  421. console.log(this.current_date, 'this.now_date---------')
  422. switch (item.week) {
  423. case 0:
  424. item.week = '周日'
  425. break
  426. case 1:
  427. item.week = '周一'
  428. break
  429. case 2:
  430. item.week = '周二'
  431. break
  432. case 3:
  433. item.week = '周三'
  434. break
  435. case 4:
  436. item.week = '周四'
  437. break
  438. case 5:
  439. item.week = '周五'
  440. break
  441. case 6:
  442. item.week = '周六'
  443. break
  444. }
  445. return item
  446. })
  447. this.table_week = table_week
  448. this.now_date = this.table_week[this.current_date].day
  449. let data = res.data.list
  450. this.shedule_list = data[this.current_date]
  451. console.log(this.current_date, 'YYYYYYYYYYY')
  452. })
  453. },
  454. //获取当前年月日
  455. getNowDate() {
  456. //获取当前年月日
  457. let nowDate = new Date()
  458. let year = nowDate.getFullYear()
  459. let month = nowDate.getMonth() + 1
  460. let date = nowDate.getDate()
  461. month = month >= 10 ? month : '0' + month
  462. date = date >= 10 ? date : '0' + date
  463. this.day = this.now_date = year + '-' + month + '-' + date
  464. console.log(this.now_date, '09--25')
  465. },
  466. //选择日期
  467. changeDate(index, item) {
  468. console.log(index, 'index----')
  469. console.log(item, 'index----')
  470. this.current_date = index
  471. this.now_date = item.day
  472. this.getSheuling()
  473. },
  474. //选择时间段
  475. changeTime(item, index) {
  476. console.log(item,'llllllll')
  477. if (item.id) {
  478. this.current_time =index
  479. this.time = item
  480. } else {
  481. this.current_time = item
  482. }
  483. },
  484. //选择本周还是下周
  485. async changTab(index) {
  486. this.current_tab = index
  487. if (index == 0) {
  488. this.now_date = this.day
  489. }
  490. if (index == 1) {
  491. this.current_date = 0
  492. this.now_date = this.table_week[0].day
  493. console.log(this.now_date, 'pppp')
  494. }
  495. console.log(this.now_date, 'pppp')
  496. this.getSheuling();
  497. },
  498. // //添加排班
  499. // add() {
  500. // uni.navigateTo({
  501. // url: './add?time_id=' + this.current_time + '&day=' + this.now_date +
  502. // '&start_time=' + this
  503. // .time.start_time + '&end_time=' + this.time.end_time
  504. // })
  505. // },
  506. //确认添加排班
  507. sure_choose() {
  508. let data = {
  509. status: 1,
  510. teacher_id: this.$store.state.vuex_user.type_id,
  511. day: this.now_date,
  512. time_ids: this.time.id
  513. }
  514. this.$u.post('/mentor/scheduling', data).then(res => {
  515. console.log(res, '添加排班')
  516. if (res.code == 200) {
  517. uni.showToast({
  518. title: '添加成功',
  519. icon: 'none'
  520. })
  521. this.teacher_show = false
  522. this.getSheuling()
  523. } else {
  524. }
  525. })
  526. }
  527. }
  528. }
  529. </script>
  530. <style lang="scss" scoped>
  531. .sheduling {
  532. //添加排班弹框
  533. .pop_wrap {
  534. width: 290px;
  535. height: 250px;
  536. display: flex;
  537. flex-direction: column;
  538. align-items: center;
  539. .pop_top {
  540. margin-top: 32px;
  541. text {
  542. display: block;
  543. font-size: 13px;
  544. color: rgba(40, 40, 40, 0.5);
  545. text-align: center;
  546. line-height: 18px;
  547. }
  548. .title {
  549. font-size: 18px;
  550. font-weight: bold;
  551. color: #282828;
  552. line-height: 25px;
  553. margin-bottom: 2px;
  554. }
  555. }
  556. .pop_center {
  557. margin-top: 22px;
  558. text {
  559. font-size: 16px;
  560. font-family: PingFang SC;
  561. font-weight: 400;
  562. line-height: 20px;
  563. color: #353535;
  564. opacity: 0.79;
  565. display: block;
  566. margin-bottom: 6px;
  567. }
  568. }
  569. .pop_bootom {
  570. margin-top: 30px;
  571. button {
  572. border: 1px solid #FF5A26;
  573. width: 98px;
  574. // height: 36px;
  575. padding: 0 5px;
  576. line-height: 36px;
  577. background-color: #fff;
  578. color: #FF5A26;
  579. }
  580. }
  581. }
  582. //查看学生信息弹框
  583. .student-show {
  584. padding-bottom: 5px;
  585. .stu-title {
  586. font-size: 20px;
  587. font-family: PingFang SC;
  588. font-weight: bold;
  589. line-height: 20px;
  590. color: #282828;
  591. opacity: 1;
  592. text-align: center;
  593. padding: 20px 0 30px;
  594. }
  595. .stu-mess {
  596. display: flex;
  597. padding: 0 22px;
  598. image {
  599. height: 75px;
  600. width: 75px;
  601. margin-right: 14px;
  602. border-radius: 9px;
  603. }
  604. .right {
  605. flex: 1;
  606. .stu-text {
  607. font-size: 13px;
  608. font-family: PingFang SC;
  609. font-weight: 400;
  610. line-height: 20px;
  611. color: #282828;
  612. overflow: hidden;
  613. display: -webkit-box; //将对象作为弹性伸缩盒子模型显示;
  614. text-overflow: ellipsis; //溢出部分用省略号代替
  615. -webkit-line-clamp: 2; //设置文本显示两行
  616. -webkit-box-orient: vertical; //从上到下排列子元素;
  617. white-space: normal;
  618. }
  619. }
  620. }
  621. .e-mail {
  622. margin: 18px 22px 10px;
  623. height: 36px;
  624. line-height: 36px;
  625. font-size: 14px;
  626. font-family: PingFang SC;
  627. font-weight: bold;
  628. color: rgba(40, 40, 40, .78);
  629. border-bottom: 1px solid rgba(112, 112, 112, .06);
  630. }
  631. .remark-title {
  632. margin: 10px 22px 0px;
  633. padding: 5px;
  634. font-size: 13px;
  635. font-family: PingFang SC;
  636. font-weight: bold;
  637. line-height: 20px;
  638. color: #282828;
  639. opacity: 0.61;
  640. }
  641. .remark {
  642. margin: 0px 22px 22px;
  643. font-size: 12px;
  644. font-family: PingFang SC;
  645. font-weight: 400;
  646. line-height: 20px;
  647. color: #282828;
  648. opacity: 0.54;
  649. padding: 5px;
  650. overflow: hidden;
  651. display: -webkit-box; //将对象作为弹性伸缩盒子模型显示;
  652. text-overflow: ellipsis; //溢出部分用省略号代替
  653. -webkit-line-clamp: 3; //设置文本显示两行
  654. -webkit-box-orient: vertical; //从上到下排列子元素;
  655. white-space: normal;
  656. // border-bottom: 1px solid rgba(112, 112, 112, .06);
  657. }
  658. }
  659. .sheduling-top {
  660. display: flex;
  661. align-items: center;
  662. justify-items: center;
  663. height: 46px;
  664. background-color: #E6FFF0;
  665. padding: 0 30px;
  666. font-size: 13px;
  667. font-family: PingFang SC;
  668. font-weight: 400;
  669. color: #2B9155;
  670. image {
  671. height: 20px;
  672. width: 20px;
  673. margin-right: 9px;
  674. }
  675. .title {
  676. flex: 1;
  677. white-space: nowrap;
  678. /*设置不换行*/
  679. overflow: hidden;
  680. /*设置隐藏*/
  681. text-overflow: ellipsis;
  682. /*设置隐藏部分为省略号*/
  683. }
  684. }
  685. .tab {
  686. display: flex;
  687. align-items: center;
  688. width: 50%;
  689. margin: 0 auto;
  690. // background-color: #18B566;
  691. .item,
  692. .active-item {
  693. margin-top: 17px;
  694. view {
  695. display: block;
  696. }
  697. font-size: 18px;
  698. font-family: PingFang SC;
  699. font-weight: bold;
  700. line-height: 20px;
  701. color: rgba(113, 113, 113, .43);
  702. opacity: 0.43;
  703. opacity: 1;
  704. flex: 1;
  705. text-align: center;
  706. .week {
  707. padding-bottom: 12px;
  708. }
  709. .line {
  710. width: 25px;
  711. height: 4px;
  712. background: #3B7653;
  713. opacity: 1;
  714. border-radius: 1px;
  715. display: block;
  716. margin: 0 auto;
  717. }
  718. }
  719. .active-item {
  720. font-size: 18px;
  721. font-family: PingFang SC;
  722. font-weight: bold;
  723. line-height: 20px;
  724. color: #3B7653;
  725. .week {
  726. padding-bottom: 8px;
  727. }
  728. }
  729. }
  730. .content {
  731. padding: 17px;
  732. .top {
  733. display: flex;
  734. align-items: center;
  735. justify-items: center;
  736. background: rgba(238, 238, 238, .46);
  737. border-radius: 12px 12px 0 0;
  738. overflow: hidden;
  739. .item,
  740. .active-item {
  741. padding: 9px 0;
  742. flex: 1;
  743. text-align: center;
  744. .week {
  745. font-size: 14px;
  746. font-family: PingFang SC;
  747. font-weight: 500;
  748. line-height: 20px;
  749. color: #282828;
  750. opacity: 1;
  751. }
  752. .date {
  753. font-size: 12px;
  754. font-family: PingFang SC;
  755. font-weight: 400;
  756. line-height: 20px;
  757. color: #282828;
  758. opacity: 0.6;
  759. }
  760. }
  761. .active-item {
  762. background-color: rgba(59, 118, 83, 1);
  763. .week,
  764. .date {
  765. color: #fff;
  766. }
  767. }
  768. }
  769. .shedule {
  770. display: flex;
  771. position: relative;
  772. .add {
  773. display: flex;
  774. text-align: center;
  775. align-items: center;
  776. flex-direction: column;
  777. color: #FFFFFF;
  778. opacity: 1;
  779. image {
  780. width: 60%;
  781. margin-top: 25%;
  782. }
  783. .add-buttom {
  784. font-size: 14px;
  785. color: #292929;
  786. padding: 10px 20px;
  787. background-color: #3E7855;
  788. color: #fff;
  789. margin-top: 30px;
  790. border-radius: 10px;
  791. }
  792. .add-text {
  793. color: #3E7855;
  794. font-size: 14px;
  795. margin-top: 40px;
  796. }
  797. }
  798. .left {
  799. flex: 0 0 100px;
  800. height: 425px;
  801. opacity: 1;
  802. overflow-y: auto;
  803. border-radius: 0px 0px 0px 12px;
  804. .left_1 {
  805. height: 100%;
  806. width: 92px;
  807. background: #F7F7F7;
  808. }
  809. .item,
  810. .active-item {
  811. font-size: 13px;
  812. padding: 15px 0;
  813. text-align: center;
  814. display: flex;
  815. justify-content: center;
  816. align-items: center;
  817. position: relative;
  818. .all {
  819. height: 13px;
  820. width: 13px;
  821. margin-right: 6px;
  822. }
  823. .jian {
  824. position: absolute;
  825. height: 14px;
  826. width: 8px;
  827. right: -8px;
  828. }
  829. }
  830. .active-item {
  831. background-color: rgba(59, 118, 83, 1);
  832. color: #FFFFFF;
  833. }
  834. }
  835. .right {
  836. flex: 1;
  837. margin-left:3px;
  838. height: 425px;
  839. overflow-y: scroll;
  840. .item {
  841. display: flex;
  842. position: relative;
  843. align-items: center;
  844. padding: 10px;
  845. margin-top: 12px;
  846. font-size: 13px;
  847. background: rgba(234, 237, 242, .28);
  848. border-radius: 7px;
  849. .tips {
  850. position: absolute;
  851. width: 57px;
  852. height: 20px;
  853. background: #C1915A;
  854. line-height: 20px;
  855. font-size: 12px;
  856. font-family: PingFang SC;
  857. font-weight: 400;
  858. color: #FFFFFF;
  859. opacity: 1;
  860. opacity: 1;
  861. right: 12px;
  862. z-index: 2;
  863. top: 0;
  864. text-align: center;
  865. border-radius: 0px 0px 6px 6px;
  866. }
  867. .item-left {
  868. margin-right: 10px;
  869. .image {
  870. height: 42px;
  871. width: 42px;
  872. border: solid 1px;
  873. border-radius: 50%;
  874. background-position: center;
  875. background-repeat: no-repeat;
  876. background-size: cover;
  877. }
  878. .name {
  879. font-size: 10px;
  880. font-family: PingFang SC;
  881. font-weight: 400;
  882. text-align: center;
  883. line-height: 20px;
  884. color: #292929;
  885. opacity: 1;
  886. width: 50px;
  887. /*指定宽度*/
  888. word-break: keep-all;
  889. /* 不换行 */
  890. white-space: nowrap;
  891. /* 强制在同一行内显示所有文本,直到文本结束或者遭遇 br 对象。不换行 */
  892. overflow: hidden;
  893. /* 内容超出宽度时隐藏超出部分的内容 */
  894. text-overflow: ellipsis;
  895. /* IE 专有属性,当对象内文本溢出时显示省略标记(...) ;需与overflow:hidden;一起使用。*/
  896. }
  897. }
  898. .item-right {
  899. flex: 1;
  900. .text {
  901. line-height: 17px;
  902. font-size: 12px;
  903. font-family: PingFang SC;
  904. font-weight: 400;
  905. color: #282828;
  906. opacity: 1;
  907. image {
  908. height: 13px;
  909. width: 13px;
  910. display: inline-block;
  911. margin-right: 4px;
  912. }
  913. .time {
  914. font-family: PingFang SC;
  915. font-weight: 400;
  916. color: #282828;
  917. opacity: 1;
  918. display: inline-block;
  919. margin-top: 4px;
  920. }
  921. }
  922. }
  923. .cancel {
  924. width: 58px;
  925. height: 23px;
  926. line-height: 23px;
  927. border: 1px solid rgba(193, 145, 90, 0.44);
  928. border-radius: 12px;
  929. font-size: 12px;
  930. font-family: PingFang SC;
  931. font-weight: 500;
  932. line-height: 20px;
  933. color: #C1915A;
  934. opacity: 1;
  935. text-align: center;
  936. }
  937. }
  938. }
  939. }
  940. .table {
  941. .tips {
  942. display: flex;
  943. margin-top: 25px;
  944. .tip-item {
  945. flex: 1;
  946. font-size: 11px;
  947. font-family: PingFang SC;
  948. font-weight: 400;
  949. line-height: 20px;
  950. color: rgba(40, 40, 40, .56);
  951. opacity: 1;
  952. .yellow {
  953. color: #3E7855;
  954. }
  955. }
  956. }
  957. .title {
  958. font-size: 18px;
  959. font-family: PingFang SC;
  960. font-weight: bold;
  961. line-height: 20px;
  962. color: #282828;
  963. opacity: 1;
  964. margin: 30px 0
  965. }
  966. .table_1 {
  967. background-color: rgba(249, 250, 252, 1);
  968. .table-week {
  969. display: flex;
  970. align-items: center;
  971. justify-content: center;
  972. .table-item {
  973. display: flex;
  974. justify-content: center;
  975. flex-direction: column;
  976. height: 53px;
  977. // line-height: 53px;
  978. text-align: center;
  979. flex: 1;
  980. border-right: solid 1px rgba(112, 112, 112, .08);
  981. view:last-child {
  982. font-size: 10px;
  983. }
  984. }
  985. }
  986. .table-tr {
  987. display: flex;
  988. .table-time {
  989. flex: 1;
  990. .time-item {
  991. display: flex;
  992. justify-content: center;
  993. align-items: center;
  994. flex-flow: column;
  995. height: 53px;
  996. border-top: solid 1px rgba(112, 112, 112, .08);
  997. border-right: solid 1px rgba(112, 112, 112, .08);
  998. font-size: 10px;
  999. font-family: PingFang SC;
  1000. font-weight: 400;
  1001. color: #333;
  1002. opacity: 1;
  1003. }
  1004. .active-time-item {
  1005. display: flex;
  1006. justify-content: center;
  1007. align-items: center;
  1008. flex-flow: column;
  1009. height: 53px;
  1010. border-top: solid 1px rgba(255, 255, 255, .08);
  1011. border-right: solid 1px rgba(255, 255, 255, .08);
  1012. font-size: 10px;
  1013. font-family: PingFang SC;
  1014. font-weight: 400;
  1015. color: #333;
  1016. opacity: 1;
  1017. background-color: rgba(62, 120, 85, 1);
  1018. .teacher {
  1019. font-size: 10px;
  1020. font-family: PingFang SC;
  1021. font-weight: 500;
  1022. line-height: 20px;
  1023. color: #FFFFFF;
  1024. opacity: 1;
  1025. text-align: center;
  1026. white-space: nowrap;
  1027. /*设置不换行*/
  1028. overflow: hidden;
  1029. opacity: 1;
  1030. }
  1031. .stu {
  1032. text-align: center;
  1033. font-size: 10px;
  1034. font-family: PingFang SC;
  1035. font-weight: 400;
  1036. line-height: 20px;
  1037. color: #FEEF7E;
  1038. opacity: 1;
  1039. }
  1040. }
  1041. .me-item {
  1042. display: flex;
  1043. justify-content: center;
  1044. align-items: center;
  1045. flex-flow: column;
  1046. height: 53px;
  1047. border-top: solid 1px rgba(255, 255, 255, .08);
  1048. border-right: solid 1px rgba(255, 255, 255, .08);
  1049. font-size: 10px;
  1050. font-family: PingFang SC;
  1051. font-weight: 400;
  1052. color: #333;
  1053. opacity: 1;
  1054. background-color: rgba(193, 145, 90, 1);
  1055. .teacher {
  1056. font-size: 10px;
  1057. font-family: PingFang SC;
  1058. font-weight: 500;
  1059. line-height: 20px;
  1060. color: #FFFFFF;
  1061. opacity: 1;
  1062. }
  1063. .stu {
  1064. font-size: 10px;
  1065. font-family: PingFang SC;
  1066. font-weight: 400;
  1067. line-height: 20px;
  1068. color: #FEEF7E;
  1069. opacity: 1;
  1070. text-align: center;
  1071. }
  1072. }
  1073. }
  1074. }
  1075. }
  1076. }
  1077. }
  1078. }
  1079. </style>