detail.vue 35 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408
  1. <template>
  2. <view>
  3. <view style="position: fixed;width: 100%;z-index: 999;background: #FFFFFF;top: 0;" id="top">
  4. <view class="video_box" v-if="!startStatus">
  5. <image :src="$method.splitImgHost(detail.coverUrl)" style="width: 100%;height: 460rpx;"></image>
  6. <image v-if="false" class="video_play" src="/static/play.png" @click="startVideo"></image>
  7. </view>
  8. <view v-else class="video_box" style="width: 100%;height: 460rpx;">
  9. <polyv-player
  10. id="playerVideo"
  11. playerId="playerVideo"
  12. height="460rpx"
  13. :vid="vid"
  14. :showSettingBtn="true"
  15. :enablePlayGesture="true"
  16. @statechange="onStateChange"
  17. :autoplay="autoplay"
  18. :isAllowSeek="isAllowSeek"
  19. :playbackRate="playbackRate"
  20. :startTime="startTime"
  21. ></polyv-player>
  22. </view>
  23. <view>
  24. <u-row>
  25. <u-col span="10">
  26. <view class="video_t1">{{ detail.courseName }}</view>
  27. </u-col>
  28. <u-col span="2">
  29. <view class="video_t1_t" @click="openJY">
  30. <image src="/static/icon/jy_icon.png" style="width: 40rpx;height: 40rpx;"></image>
  31. 讲义
  32. </view>
  33. </u-col>
  34. </u-row>
  35. </view>
  36. <u-line color="#D6D6DB" />
  37. <view style="display: flex;justify-content: center;">
  38. <view><u-tabs :list="list" font-size="24" bar-width="80" :current="current" @change="change" active-color="#007AFF"></u-tabs></view>
  39. </view>
  40. <u-line color="#D6D6DB" />
  41. </view>
  42. <view class="box">
  43. <!--目录 -->
  44. <view v-show="current == 0">
  45. <view class="menuBox" v-for="(item, index) in menuList" :key="index">
  46. <!--模块 -->
  47. <view v-if="item.type == 1"><courseModule :courseId="courseId" :goodsId="goodsId" :gradeId="gradeId" :isBuy="true" :menuItem="item" :levelId="item.menuId"></courseModule></view>
  48. <!--章 -->
  49. <view v-if="item.type == 2"><courseChapter :courseId="courseId" :goodsId="goodsId" :gradeId="gradeId" :isBuy="true" :menuItem="item" :levelId="'0-' + item.menuId"></courseChapter></view>
  50. <!--节 -->
  51. <view v-if="item.type == 3"><courseSection :courseId="courseId" :goodsId="goodsId" :gradeId="gradeId" :isBuy="true" :menuItem="item" :levelId="'0-0-' + item.menuId"></courseSection></view>
  52. </view>
  53. </view>
  54. <!--笔记 -->
  55. <view v-show="current == 1">
  56. <view v-if="noteList.length == 0" style="text-align: center;">暂无笔记</view>
  57. <view class="inputBottom">
  58. <view style="width: 10%;"><image src="/static/icon/note3.png" style="width: 39rpx;height: 39rpx;margin:0 29rpx;"></image></view>
  59. <view style="width: 73%;height: 88rpx;margin-bottom: 15rpx;">
  60. <u-input class="input" fixed="true" placeholder="您可以在这里输入笔记内容" type="textarea" :custom-style="inputStyle" v-model="noteValue" />
  61. </view>
  62. <view style="color: #007AFF;font-size: 30rpx;font-weight: bold;width: 15%;text-align: center;" @click="postNote">提交</view>
  63. </view>
  64. <view v-for="(item, index) in noteList" :key="index">
  65. <view class="dateBox">{{ $method.timestampToTime(item.dateNote) }}</view>
  66. <view class="noteBox">
  67. <view v-for="(item1, index1) in item.userNotes" :key="index1" style="margin-top: 30rpx;" @click="jumpNote(item1)">
  68. <view style="display: flex;">
  69. <view>
  70. <view>
  71. <image src="/static/icon/note2.png" v-if="noteId != item1.noteId" style="width: 39rpx;height: 39rpx;margin:0 29rpx;"></image>
  72. <image src="/static/icon/note1.png" v-if="noteId == item1.noteId" style="width: 39rpx;height: 39rpx;margin:0 29rpx;"></image>
  73. </view>
  74. <view class="title" style="width: 39rpx;height: 39rpx;margin:0 29rpx;">{{ $method.secondToDate(item1.noteSecond) }}</view>
  75. </view>
  76. <view style="margin-left: 10rpx;">
  77. <view class="t2Content leftPadding">{{ item1.sectionName }}</view>
  78. <view class="tBox2">{{ item1.noteText }}</view>
  79. </view>
  80. </view>
  81. </view>
  82. </view>
  83. </view>
  84. </view>
  85. <!--答疑 -->
  86. <view v-show="current == 2">
  87. <view class="inputBottom">
  88. <view class="flex_auto">
  89. <u-input height="60" fixed="true" :placeholder="placeholder" type="textarea" :custom-style="inputStyle" v-model="ctxValue" />
  90. </view>
  91. <view class="btn" @click="postContent">提交</view>
  92. </view>
  93. <view v-for="(item, index) in answerList" :key="index" style="background-color: #FFFFFF;margin-bottom: 20rpx;">
  94. <view class="chat_box" @click.stop="clearCtx">
  95. <view style="display: flex;">
  96. <view><image :src="$method.splitImgHost(item.avatar)" style="width: 64rpx;height: 64rpx;"></image></view>
  97. <view style="margin-left: 15rpx;">
  98. <view class="chat1">{{ item.realname }}</view>
  99. <view class="chat2">{{ $method.timestampToTime(item.createTime) }}</view>
  100. <view class="chat3">
  101. <text v-if="item.assignUserId > 0">回复</text>
  102. <text v-if="item.assignUserId > 0" style="color: #007AFF;">@{{ item.assignRealname }}</text>
  103. {{ item.answerText }}
  104. </view>
  105. </view>
  106. </view>
  107. <view class="btnReply" @click.stop="replyContent(item)" v-if="item.userId != userInfo.userId">回复</view>
  108. <view v-else class="btnDel" @click.stop="delContent(item)">删除</view>
  109. </view>
  110. <u-line color="#D6D6DB" />
  111. </view>
  112. <view v-if="answerList.length == 0" style="text-align: center;">暂无记录</view>
  113. </view>
  114. <!--目录 -->
  115. <view v-show="current == 3" >
  116. <view class="menuBox" v-for="(item, index) in reMenuList" :key="index">
  117. <!--模块 -->
  118. <view v-if="item.type == 1"><courseModule :courseId="courseId" :gradeId="gradeId" :isRebuild="true" :isBuy="true" :menuItem="item" :levelId="item.menuId"></courseModule></view>
  119. <!--章 -->
  120. <view v-if="item.type == 2">
  121. <courseChapter :courseId="courseId" :gradeId="gradeId" :isRebuild="true" :isBuy="true" :menuItem="item" :levelId="'0-' + item.menuId"></courseChapter>
  122. </view>
  123. <!--节 -->
  124. <view v-if="item.type == 3">
  125. <courseSection :courseId="courseId" :gradeId="gradeId" :isRebuild="true" :isBuy="true" :menuItem="item" :levelId="'0-0-' + item.menuId"></courseSection>
  126. </view>
  127. </view>
  128. </view>
  129. </view>
  130. <!-- 播放前拍照end -->
  131. <u-popup v-model="showSet" :mask-close-able="false" mode="center" border-radius="24">
  132. <view style="align-items:center;padding: 0 40rpx;display: flex;flex-direction: column;justify-content:center;">
  133. <view style="font-weight: bold;color: #333333;font-size: 30rpx;margin-top: 30rpx;">温馨提示</view>
  134. <view style="width: 457rpx;color: #666666;font-size: 30rpx;margin-top: 30rpx;">学习过程中需要拍照验证学员身份,
  135. 拍照功能需要使用您的相机。
  136. 是否授权使用?</view>
  137. <view style="margin: 30rpx 0;">
  138. <button open-type="openSetting" @bindopensetting="openSetting" class="btnSet">去授权</button>
  139. </view>
  140. </view>
  141. </u-popup>
  142. <u-mask :show="photoPopup" >
  143. <!-- 播放前拍照start -->
  144. <view v-if="photoPopup" :mask-close-able="false" style="bottom: 0;position: fixed;width: 100%;z-index: 999;">
  145. <view class="photoBox">
  146. <view class="photoTop">
  147. <view class="sqzz" v-if="false"><u-icon name="close" color="#333333" size="30" @click="closePhoto"></u-icon></view>
  148. <view class="centersq">请正视手机屏幕</view>
  149. <view class="sqzz"></view>
  150. </view>
  151. <view class="photoCenter">
  152. <view style="width: 100%; height: 979rpx;position: fixed;" v-if="photoPopup">
  153. <camera device-position="front" flash="off" @error="error" style="width: 100%; height: 100%;" ></camera>
  154. </view>
  155. <view class="custom"><image src="@/pages2/static/zhezhao.png" mode=""></image></view>
  156. </view>
  157. <view class="btnResult" @click="takePhoto">拍照</view>
  158. </view>
  159. </view>
  160. </u-mask>
  161. </view>
  162. </template>
  163. <script>
  164. import courseModule from '@/components/course/courseModule.vue';
  165. import courseChapter from '@/components/course/courseChapter.vue';
  166. import courseSection from '@/components/course/courseSection.vue';
  167. import { mapGetters } from 'vuex';
  168. export default {
  169. components: {
  170. courseModule,
  171. courseChapter,
  172. courseSection
  173. },
  174. data() {
  175. return {
  176. showSet:false,
  177. startStatus: false,
  178. detail: {},
  179. courseId: 0,
  180. placeholder: '您可以在这里输入笔记内容\n还可以点击左侧图标为笔记加上时间标记',
  181. inputStyle: {
  182. background: 'rgba(244, 244, 244, 0.98)',
  183. borderRadius: '24rpx',
  184. padding: '8rpx',
  185. marginBottom: '10rpx'
  186. },
  187. playbackRate: [0.5, 0.8, 1.0],
  188. list: [
  189. {
  190. name: '目录'
  191. },
  192. {
  193. name: '笔记'
  194. },
  195. {
  196. name: '答疑'
  197. }
  198. ],
  199. menuList: [],
  200. current: 0,
  201. vid: '',
  202. goodsId: 0,
  203. goodsData: {},
  204. photoPopup: false,
  205. goodsPlayConfig: null,
  206. autoplay: false,
  207. isAllowSeek: 'no',
  208. playbackRate: [1.0],
  209. timer: null,
  210. goodsPhotographConfig: null,
  211. intervalTimeList: [], // 间隔拍照时长
  212. intervalTimeIndex: 0, //当前处于哪个时间段拍照
  213. playTime: 0, //页面播放时长,不含暂停
  214. currentTime: 0,
  215. avatarUrl: '',
  216. ossAvatarUrl: '',
  217. studyDuration: 0, // 当前视频时长
  218. gradeId: 0,
  219. chapterId: 0,
  220. moduleId: 0,
  221. reMenuList: [],
  222. answerList: [],
  223. assignUserId: 0,
  224. placeholder: '您可以在这里输入答疑内容',
  225. ctxValue: '',
  226. noteList: [],
  227. noteValue: '',
  228. noteId: 0,
  229. recordObj: 0,
  230. needSeek: false //第一次播放是否需要跳转
  231. };
  232. },
  233. computed: { ...mapGetters(['userInfo', 'playSectionId']) },
  234. onLoad(option) {
  235. this.courseId = Number(option.id);
  236. this.goodsId = Number(option.goodsId);
  237. this.courseDetail();
  238. this.getGoodsDetail();
  239. this.getAnswerList();
  240. let noteSecond = Number(option.noteSecond);
  241. if(noteSecond>0){
  242. //我的消息跳过来,播放节
  243. let item = {
  244. sectionId:Number(option.sectionId),
  245. recordingUrl:option.recordingUrl,
  246. noteSecond:noteSecond
  247. }
  248. this.$store.commit('setPlaySectionId', {playSectionId :item.sectionId});
  249. this.playNoteVideo(item);
  250. }
  251. },
  252. onShow() {
  253. var self = this;
  254. //相机授权
  255. this.getCameraSetting()
  256. this.$api.getbaseprofiletplists({ goodsId: self.goodsId }).then(res => {
  257. if (res.data.code === 200 && res.data.rows.length) {
  258. if (res.data.rows[0].keyValue) {
  259. self.$api.getbaseprofiletpgetInfo({ goodsId: self.goodsId }).then(result => {
  260. if (result.data.code === 200) {
  261. if (!result.data.data || (result.data.data.status === 3 && result.data.data.changeStatus === 1)) {
  262. if (!result.data.data) {
  263. uni.showModal({
  264. content: '请前往填写资料',
  265. cancelText: '返回',
  266. success: function(resultst) {
  267. if (resultst.confirm) {
  268. self.$navTo.togo('/pages2/verify/input', {
  269. id: self.goodsId
  270. });
  271. }
  272. if (resultst.cancel) {
  273. uni.navigateBack();
  274. }
  275. }
  276. });
  277. } else {
  278. uni.showModal({
  279. content: '资料审核不通过,请前往重新填写',
  280. cancelText: '返回',
  281. success: function(resultst) {
  282. if (resultst.confirm) {
  283. self.$navTo.togo('/pages2/verify/input', {
  284. id: self.goodsId
  285. });
  286. }
  287. if (resultst.cancel) {
  288. uni.navigateBack();
  289. }
  290. }
  291. });
  292. }
  293. } else if (result.data.data.status === 1 && res.data.rows[0].keyValue2) {
  294. self.$api.getbaseprofileStampgetInfo({ goodsId: self.goodsId }).then(k => {
  295. if (k.data.code === 200) {
  296. if (!k.data.data || (k.data.data.status === 3 && k.data.data.changeStatus === 1)) {
  297. if (!k.data.data) {
  298. uni.showModal({
  299. cancelText: '返回',
  300. content: '请前往填写盖章资料',
  301. success: function(resultst) {
  302. if (resultst.confirm) {
  303. self.$navTo.togo('/pages2/verify/input2', {
  304. id: self.goodsId
  305. });
  306. }
  307. if (resultst.cancel) {
  308. uni.navigateBack();
  309. }
  310. }
  311. });
  312. } else {
  313. uni.showModal({
  314. cancelText: '返回',
  315. content: '资料盖章审核不通过,请前往重新填写',
  316. success: function(resultst) {
  317. if (resultst.confirm) {
  318. self.$navTo.togo('/pages2/verify/input2', {
  319. id: self.goodsId
  320. });
  321. }
  322. if (resultst.cancel) {
  323. uni.navigateBack();
  324. }
  325. }
  326. });
  327. }
  328. }
  329. }
  330. });
  331. }
  332. }
  333. });
  334. }
  335. }
  336. });
  337. },
  338. onUnload() {
  339. if (this.playSectionId > 0) {
  340. //退出提交记录
  341. this.ossAvatarUrl = '';
  342. this.postStudyRecord();
  343. //清除正在播放的节ID
  344. this.$store.commit('setPlaySectionId', { playSectionId: 0 });
  345. //移除所有的事件监听器
  346. uni.$off();
  347. }
  348. },
  349. mounted() {
  350. uni.$on('changeSection', oldSectionId => {
  351. this.postStudyRecord(0, oldSectionId);
  352. });
  353. uni.$on('getSection', item => {
  354. this.playVideo(item);
  355. });
  356. uni.$on('levelId', item => {
  357. let arr = item.split('-');
  358. //点击节获取的各层级ID
  359. this.moduleId = arr[0];
  360. this.chapterId = arr[1];
  361. });
  362. },
  363. methods: {
  364. openSetting(res){
  365. console.log(res,98)
  366. },
  367. getCameraSetting () {
  368. const self = this
  369. wx.getSetting({
  370. success: res => {
  371. if (res.authSetting['scope.camera']) {
  372. // 用户已经授权
  373. self.showSet = false
  374. } else {
  375. // 用户还没有授权,向用户发起授权请求
  376. wx.authorize({
  377. scope: 'scope.camera',
  378. success() { // 用户同意授权
  379. self.showSet = false
  380. },
  381. fail() { // 用户不同意授权
  382. self.showSet = true
  383. /* wx.showToast({
  384. title: '摄像头授权失败',
  385. icon: 'none',
  386. duration: 3000
  387. }) */
  388. }
  389. })
  390. }
  391. },
  392. fail: res => {
  393. }
  394. })
  395. },
  396. openJY(){
  397. this.$u.toast('此功能正在开发中');
  398. },
  399. //播放笔记视频
  400. async playNoteVideo(item) {
  401. if (this.timer) {
  402. clearInterval(this.timer);
  403. }
  404. if (this.vid) {
  405. //切换视频
  406. var polyvPlayerContext = this.selectComponent('#playerVideo');
  407. polyvPlayerContext.changeVid(item.recordingUrl);
  408. } else {
  409. this.vid = item.recordingUrl;
  410. }
  411. this.recordObj = {studyDuration:item.noteSecond}
  412. if (this.recordObj.studyDuration) {
  413. this.needSeek = true; //需要跳转到播放记录
  414. }
  415. this.startStatus = true;
  416. //获取节笔记
  417. this.getNoteList();
  418. },
  419. //正常播放视频
  420. async playVideo(item) {
  421. if (this.timer) {
  422. clearInterval(this.timer);
  423. }
  424. if (this.vid) {
  425. //切换视频
  426. var polyvPlayerContext = this.selectComponent('#playerVideo');
  427. polyvPlayerContext.changeVid(item.recordingUrl);
  428. } else {
  429. this.vid = item.recordingUrl;
  430. }
  431. this.recordObj = await this.getRecordLast();
  432. if (this.recordObj.studyDuration) {
  433. this.needSeek = true; //需要跳转到播放记录
  434. }
  435. console.log(this.startTime, 789);
  436. this.startStatus = true;
  437. //获取节笔记
  438. this.getNoteList();
  439. },
  440. getRecordLast() {
  441. let self = this;
  442. return new Promise(resolve => {
  443. let data = {
  444. gradeId: Number(self.gradeId),
  445. goodsId: Number(self.goodsId),
  446. sectionId: Number(self.playSectionId),
  447. courseId: Number(self.courseId)
  448. };
  449. self.$api.recordLast(data).then(res => {
  450. resolve(res.data.data);
  451. });
  452. });
  453. },
  454. jumpNote(item) {
  455. this.noteId = item.noteId;
  456. //没视频播放
  457. if(this.playSectionId==0){
  458. this.$u.toast('即将跳到笔记位置');
  459. this.$store.commit('setPlaySectionId', {playSectionId :item.sectionId});
  460. this.playNoteVideo(item);
  461. }else{
  462. //正在看当前笔记视频
  463. this.$u.toast('即将跳到笔记位置');
  464. //跳到笔记时刻
  465. var polyvPlayerContext = this.selectComponent('#playerVideo');
  466. polyvPlayerContext.seek(item.noteSecond);
  467. polyvPlayerContext.play();
  468. }
  469. },
  470. postNote() {
  471. let self = this;
  472. if (!(this.playSectionId > 0)) {
  473. this.$u.toast('目前无播放视频');
  474. return;
  475. }
  476. if (!this.noteValue) {
  477. this.$u.toast('请输入内容');
  478. return;
  479. }
  480. var polyvPlayerContext = this.selectComponent('#playerVideo');
  481. let noteDate = this.$method.getZeroTime();
  482. let noteSecond = polyvPlayerContext.getCurrentTime();
  483. console.log(noteSecond,698)
  484. if (!noteSecond) {
  485. if(noteSecond==0){
  486. //播放结束
  487. noteSecond = polyvPlayerContext.getDuration();
  488. console.log(noteSecond,63398)
  489. }
  490. if(!noteSecond){
  491. this.$u.toast('视频暂未开始');
  492. return;
  493. }
  494. }
  495. let data = {
  496. gradeId: this.gradeId,
  497. goodsId: this.goodsId,
  498. sectionId: this.playSectionId,
  499. courseId: this.courseId,
  500. noteText: this.noteValue,
  501. noteDate: noteDate,
  502. noteSecond: noteSecond
  503. };
  504. this.$api.postNote(data).then(res => {
  505. if (res.data.code == 200) {
  506. this.$u.toast('发布成功');
  507. self.getNoteList();
  508. this.noteValue = '';
  509. }
  510. });
  511. },
  512. getNoteList() {
  513. let self = this;
  514. self.noteList = [];
  515. let data = { courseId: this.courseId, gradeId: this.gradeId, goodsId: this.goodsId }
  516. if(this.playSectionId>0){
  517. data.sectionId = this.playSectionId
  518. }
  519. this.$api.noteList(data).then(res => {
  520. if (res.data.code == 200) {
  521. self.noteList = res.data.rows;
  522. }
  523. });
  524. },
  525. delAnswer(answerId) {
  526. let self = this;
  527. let data = { answerId: answerId, status: -1 };
  528. this.$api.delAnswer(data).then(res => {
  529. if (res.data.code == 200) {
  530. self.getAnswerList();
  531. }
  532. });
  533. },
  534. clearCtx() {
  535. console.log(4234);
  536. this.placeholder = '您可以在这里输入答疑内容';
  537. this.ctxValue = '';
  538. this.assignUserId = 0;
  539. },
  540. replyContent(item) {
  541. this.assignUserId = item.userId;
  542. this.placeholder = '@' + item.realname;
  543. },
  544. delContent(item) {
  545. this.delAnswer(item.answerId);
  546. },
  547. postAnswer() {
  548. let self = this;
  549. let data = { courseId: this.courseId, answerText: this.ctxValue };
  550. if (this.assignUserId > 0) {
  551. data.assignUserId = this.assignUserId;
  552. }
  553. this.$api.postAnswer(data).then(res => {
  554. if (res.data.code == 200) {
  555. this.$u.toast('发布成功');
  556. self.getAnswerList();
  557. this.placeholder = '您可以在这里输入答疑内容';
  558. this.ctxValue = '';
  559. this.assignUserId = 0;
  560. }
  561. });
  562. },
  563. postContent() {
  564. if (!this.ctxValue||this.ctxValue=='') {
  565. this.$u.toast('请输入内容');
  566. return
  567. }
  568. this.postAnswer();
  569. },
  570. postStudyRecord(status = 0, sectionId = this.playSectionId) {
  571. let currentTime = 0;
  572. var polyvPlayerContext = this.selectComponent('#playerVideo');
  573. if (polyvPlayerContext) {
  574. currentTime = polyvPlayerContext.getCurrentTime();
  575. }
  576. let self = this;
  577. console.log(self.ossAvatarUrl,"准备提交,照片地址")
  578. let data = {
  579. photo: self.ossAvatarUrl,
  580. sectionId: parseInt(sectionId),
  581. goodsId: parseInt(self.goodsId),
  582. courseId: parseInt(self.courseId),
  583. studyDuration: parseInt(currentTime > 0 ? currentTime : self.studyDuration),
  584. gradeId: parseInt(self.gradeId),
  585. chapterId: parseInt(self.chapterId),
  586. moduleId: parseInt(self.moduleId)
  587. };
  588. if (data.studyDuration <= 5) {
  589. //5秒内不上传记录
  590. return;
  591. }
  592. if (status > 0) {
  593. data.status = status;
  594. }
  595. console.log('提交接口', data);
  596. this.$api.studyRecord(data).then(res => {
  597. self.ossAvatarUrl = ''
  598. console.log(res);
  599. });
  600. },
  601. uploadFile(options, int) {
  602. var self = this;
  603. return new Promise((resolve, reject) => {
  604. var data = {
  605. imageStatus: int
  606. };
  607. self.$api.aliyunpolicy(data).then(res => {
  608. if (res.data.code != 200) {
  609. self.$method.showToast('签名错误' + JSON.stringify(res.data));
  610. return;
  611. }
  612. var ossToken = res.data.data.resultContent;
  613. if (ossToken.host == null || ossToken.host == undefined) {
  614. self.$method.showToast('上传路径报错' + JSON.stringify(res.data));
  615. return;
  616. }
  617. uni.uploadFile({
  618. url: ossToken.host,
  619. name: 'file',
  620. filePath: options,
  621. fileType: 'image',
  622. header: {
  623. AuthorizationToken: 'WX ' + uni.getStorageSync('token')
  624. },
  625. formData: {
  626. key: ossToken.dir,
  627. OSSAccessKeyId: ossToken.accessid,
  628. policy: ossToken.policy,
  629. Signature: ossToken.signature,
  630. callback: ossToken.callback,
  631. success_action_status: 200
  632. },
  633. success: result => {
  634. if (result.statusCode === 200) {
  635. self.ossAvatarUrl = ossToken.dir;
  636. resolve();
  637. } else {
  638. uni.showToast({
  639. title: '上传失败',
  640. icon: 'none'
  641. });
  642. return;
  643. }
  644. },
  645. fail: error => {
  646. uni.showToast({
  647. title: '上传接口报错' + error,
  648. icon: 'none'
  649. });
  650. return;
  651. }
  652. });
  653. });
  654. });
  655. },
  656. imageInfos() {
  657. var self = this;
  658. return new Promise((resolve, reject) => {
  659. uni.getImageInfo({
  660. src: self.avatarUrl,
  661. success: async res => {
  662. let canvasWidth = res.width; //图片原始长宽
  663. let canvasHeight = res.height;
  664. if (canvasWidth > 1000 || canvasHeight > 1000) {
  665. uni.compressImage({
  666. src: self.avatarUrl,
  667. quality: 75,
  668. width: '50%',
  669. height: '50%',
  670. success: async rest => {
  671. const waitUpload = await self.uploadFile(rest.tempFilePath, 0);
  672. resolve();
  673. }
  674. });
  675. } else {
  676. console.log('无需压缩');
  677. const waitUpload = await self.uploadFile(self.avatarUrl, 0);
  678. resolve();
  679. }
  680. }
  681. });
  682. });
  683. },
  684. timeEvent() {
  685. let self = this;
  686. var polyvPlayerContext = this.selectComponent('#playerVideo');
  687. if (polyvPlayerContext != null) {
  688. let PlayCurrentTime = polyvPlayerContext.getVideoPlayDuration();
  689. this.studyDuration = PlayCurrentTime;
  690. if (this.currentTime < PlayCurrentTime) {
  691. this.playTime += PlayCurrentTime - this.currentTime;
  692. this.currentTime = PlayCurrentTime;
  693. } else {
  694. this.currentTime = PlayCurrentTime;
  695. }
  696. //判断是否需要拍照
  697. if (this.intervalTimeList.length > this.intervalTimeIndex) {
  698. let photoTime = Number(this.intervalTimeList[this.intervalTimeIndex]) * 60; //获取拍照秒数
  699. if (photoTime < this.playTime) {
  700. //启动拍照
  701. //暂停
  702. polyvPlayerContext.exitFullScreen();
  703. polyvPlayerContext.pause();
  704. this.openPhoto();
  705. this.intervalTimeIndex++;
  706. }
  707. }
  708. }
  709. },
  710. onStateChange(newstate, oldstate) {
  711. if (newstate.detail.newstate == 'playing') {
  712. if (this.needSeek) {
  713. var polyvPlayerContext = this.selectComponent('#playerVideo');
  714. polyvPlayerContext.seek(this.recordObj.studyDuration);
  715. polyvPlayerContext.play();
  716. this.needSeek = false;
  717. }
  718. //开始播放
  719. if (this.timer) {
  720. clearInterval(this.timer);
  721. }
  722. this.timer = setInterval(this.timeEvent, 1500); //定时器
  723. }
  724. if (newstate.detail.newstate == 'pause') {
  725. //暂停提交记录
  726. /* this.ossAvatarUrl = ""
  727. this.postStudyRecord() */
  728. }
  729. if (newstate.detail.newstate == 'ended') {
  730. this.postStudyRecord(1);
  731. }
  732. },
  733. //拍照
  734. openPhoto() {
  735. this.photoPopup = true;
  736. uni.authorize({
  737. scope: 'scope.camera',
  738. success() {
  739. }
  740. })
  741. },
  742. async submit() {
  743. const waitYS = await this.imageInfos();
  744. this.postStudyRecord(); //提交记录
  745. //恢复播放
  746. var polyvPlayerContext = this.selectComponent('#playerVideo');
  747. if (polyvPlayerContext != null) {
  748. polyvPlayerContext.play();
  749. }
  750. console.log(this.ossAvatarUrl, '拍照完成456');
  751. },
  752. //确认拍照
  753. takePhoto() {
  754. var self = this;
  755. const ctx = uni.createCameraContext();
  756. ctx.takePhoto({
  757. quality: 'high',
  758. success: res => {
  759. console.log(res.tempImagePath);
  760. self.avatarUrl = res.tempImagePath;
  761. self.submit();
  762. self.photoPopup = false;
  763. },
  764. fail: err => {
  765. console.log(err);
  766. }
  767. });
  768. },
  769. //拍照报错
  770. error(e) {
  771. console.log(e.detail);
  772. },
  773. //关闭相机
  774. closePhoto() {
  775. this.photoPopup = false;
  776. },
  777. getGoodsDetail() {
  778. let self = this;
  779. this.$api.goodsDetail(this.goodsId).then(res => {
  780. self.goodsData = res.data.data;
  781. self.gradeId = self.goodsData.gradeId;
  782. console.log(self.gradeId, 698);
  783. self.getMenuList();
  784. self.getReMenuList(); //获取重修目录
  785. //获取节笔记
  786. this.getNoteList();
  787. if (self.goodsData.goodsPlayConfig) {
  788. self.goodsPlayConfig = JSON.parse(self.goodsData.goodsPlayConfig);
  789. if (self.goodsPlayConfig.autoPlay > 0) {
  790. self.autoplay = true;
  791. }
  792. if (self.goodsPlayConfig.drag > 0) {
  793. self.isAllowSeek = 'yes';
  794. }
  795. if (self.goodsPlayConfig.speed > 0) {
  796. self.playbackRate = [0.5, 0.8, 1.0, 1.25, 1.5, 2.0];
  797. }
  798. }
  799. if (self.goodsData.goodsPhotographConfig) {
  800. self.goodsPhotographConfig = JSON.parse(self.goodsData.goodsPhotographConfig);
  801. if (self.goodsPhotographConfig.intervalTime) {
  802. self.intervalTimeList = self.goodsPhotographConfig.intervalTime.split(',');
  803. }
  804. }
  805. });
  806. },
  807. startVideo() {
  808. this.startStatus = true;
  809. },
  810. getAnswerList() {
  811. let self = this;
  812. this.$api.answerList({ courseId: this.courseId }).then(res => {
  813. if (res.data.code == 200) {
  814. self.answerList = res.data.rows;
  815. }
  816. });
  817. },
  818. getReMenuList() {
  819. let self = this;
  820. this.$api.reMenuList({ courseId: this.courseId, rebuild: 1, gradeId: this.gradeId }).then(res => {
  821. if (res.data.code == 200) {
  822. for (let i = 0; i < res.data.rows.length; i++) {
  823. let item = res.data.rows[i];
  824. item.down = true;
  825. item.id = item.menuId;
  826. item.name = item.menuName;
  827. }
  828. self.reMenuList = res.data.rows;
  829. if(self.reMenuList.length>0){
  830. self.list.push({name:'重修目录'})
  831. }
  832. }
  833. });
  834. },
  835. getMenuList() {
  836. let self = this;
  837. this.$api.reMenuList({ courseId: this.courseId, gradeId: this.gradeId }).then(res => {
  838. if (res.data.code == 200) {
  839. for (let i = 0; i < res.data.rows.length; i++) {
  840. let item = res.data.rows[i];
  841. item.down = true;
  842. item.id = item.menuId;
  843. item.name = item.menuName;
  844. }
  845. self.menuList = res.data.rows;
  846. }
  847. });
  848. },
  849. courseDetail() {
  850. let self = this;
  851. this.$api.courseDetail(this.courseId).then(res => {
  852. if (res.data.code == 200) {
  853. self.detail = res.data.data;
  854. self.gradeId = self.detail.gradeId;
  855. }
  856. });
  857. },
  858. open(item) {
  859. item.showChildren = !item.showChildren;
  860. },
  861. change(index) {
  862. this.current = index;
  863. }
  864. }
  865. };
  866. </script>
  867. <style lang="scss" scope>
  868. .btnSet{
  869. height: 50px;
  870. width: 400rpx;
  871. background: #007AFF;
  872. border-radius: 25rpx;
  873. color: #FFFFFF;
  874. font-size: 28rpx;
  875. line-height: 50px;
  876. }
  877. .btnReply {
  878. width: 80rpx;
  879. height: 40rpx;
  880. background: #e3f0ff;
  881. border-radius: 16rpx;
  882. text-align: center;
  883. color: #007aff;
  884. }
  885. .btnDel {
  886. width: 80rpx;
  887. height: 40rpx;
  888. background: #ffedf0;
  889. border-radius: 16rpx;
  890. text-align: center;
  891. color: #ff2d55;
  892. }
  893. .btnReply {
  894. width: 80rpx;
  895. height: 40rpx;
  896. background: #e3f0ff;
  897. border-radius: 16rpx;
  898. font-size: 24rpx;
  899. }
  900. .photoBox {
  901. background-color: #FFFFFF;
  902. border-radius: 32px 32px 0px 0px;
  903. .photoTop {
  904. height: 74upx;
  905. display: flex;
  906. align-items: center;
  907. justify-content: space-between;
  908. padding: 0upx 38upx;
  909. .sqzz {
  910. width: 28upx;
  911. height: 28upx;
  912. display: flex;
  913. align-items: center;
  914. justify-content: center;
  915. }
  916. .centersq {
  917. color: #333;
  918. font-size: 30upx;
  919. font-weight: 500;
  920. }
  921. }
  922. .photoCenter {
  923. width: 750upx;
  924. height: 979upx;
  925. position: relative;
  926. .custom {
  927. width: 750upx;
  928. height: 979upx;
  929. position: absolute;
  930. z-index: 1000;
  931. top: 0;
  932. left: 0;
  933. image {
  934. width: 100%;
  935. height: 100%;
  936. }
  937. }
  938. }
  939. .btnResult {
  940. height: 100rpx;
  941. width: 100%;
  942. background-color: #07c160;
  943. text-align: center;
  944. line-height: 100upx;
  945. color: #fff;
  946. font-size: 32upx;
  947. font-weight: bold;
  948. }
  949. }
  950. .chat_box {
  951. display: flex;
  952. padding: 20rpx;
  953. justify-content: space-between;
  954. }
  955. .chat3 {
  956. font-size: 30rpx;
  957. font-family: PingFang SC;
  958. font-weight: 500;
  959. color: #666666;
  960. margin-top: 10rpx;
  961. }
  962. .chat2 {
  963. font-size: 20rpx;
  964. font-family: PingFang SC;
  965. font-weight: 500;
  966. color: #999999;
  967. margin-top: 10rpx;
  968. }
  969. .chat1 {
  970. font-size: 24rpx;
  971. font-family: PingFang SC;
  972. font-weight: 500;
  973. color: #333333;
  974. }
  975. .leftPadding {
  976. margin-left: 8rpx;
  977. }
  978. .t2Content {
  979. font-size: 28rpx;
  980. font-family: PingFang SC;
  981. font-weight: bold;
  982. color: #999999;
  983. line-height: 48rpx;
  984. }
  985. .tBox2 {
  986. display: flex;
  987. padding-top: 10rpx;
  988. color: #333333;
  989. font-size: 30rpx;
  990. }
  991. .tBox {
  992. display: flex;
  993. align-items: center;
  994. padding-top: 10rpx;
  995. }
  996. .title {
  997. font-size: 24rpx;
  998. color: #999999;
  999. }
  1000. page {
  1001. padding-top: 10px;
  1002. padding-top: constant(safe-area-inset-top);
  1003. padding-top: env(safe-area-inset-top);
  1004. }
  1005. .inputBottom {
  1006. position: fixed;
  1007. left: 0;
  1008. bottom: 0;
  1009. background: #ffffff;
  1010. height: 98rpx;
  1011. display: flex;
  1012. align-items: center;
  1013. width: 100%;
  1014. .flex_auto {
  1015. flex:1;
  1016. margin-left: 10% ;
  1017. .input {
  1018. height:60rpx;
  1019. }
  1020. }
  1021. .btn {
  1022. color: #007AFF;font-size: 30rpx;font-weight: bold;width: 15%;text-align: center;
  1023. }
  1024. }
  1025. .noteBox {
  1026. width: 100%;
  1027. background: #ffffff;
  1028. padding: 10rpx;
  1029. border-radius: 16rpx;
  1030. }
  1031. .dateBox {
  1032. width: 216rpx;
  1033. height: 48rpx;
  1034. background: #ffffff;
  1035. border-radius: 24rpx;
  1036. font-size: 24rpx;
  1037. color: #666666;
  1038. text-align: center;
  1039. line-height: 48rpx;
  1040. margin: 20rpx 0;
  1041. }
  1042. .t_content1 {
  1043. color: #007aff;
  1044. margin-left: 10rpx;
  1045. }
  1046. .tag1 {
  1047. border: 2rpx solid #007aff;
  1048. border-radius: 8rpx;
  1049. font-size: 20rpx;
  1050. color: #007aff;
  1051. padding: 5rpx;
  1052. }
  1053. .b_title {
  1054. color: #333333;
  1055. font-size: 30rpx;
  1056. font-weight: bold;
  1057. }
  1058. page {
  1059. background: #eaeef1;
  1060. }
  1061. .menuBox {
  1062. width: 100%;
  1063. background: #ffffff;
  1064. border-radius: 16rpx;
  1065. padding: 20rpx;
  1066. margin-bottom: 20rpx;
  1067. }
  1068. .btnspric {
  1069. border-top: 1rpx solid #eee;
  1070. display: flex;
  1071. align-items: center;
  1072. justify-content: space-between;
  1073. height: 108rpx;
  1074. padding-left: 43rpx;
  1075. padding-right: 32rpx;
  1076. }
  1077. .btnspric > .lefprL {
  1078. font-size: 36rpx;
  1079. color: #0c141f;
  1080. font-weight: bold;
  1081. }
  1082. .btnspric > .lefprR {
  1083. padding: 0rpx 24rpx;
  1084. height: 60rpx;
  1085. line-height: 60rpx;
  1086. text-align: center;
  1087. color: #fff;
  1088. background: #32467b;
  1089. border-radius: 24rpx;
  1090. box-shadow: 0rpx 0rpx 16rpx 4rpx rgba(145, 156, 178, 0.1);
  1091. }
  1092. .yhj,
  1093. .hdyhj {
  1094. padding: 24rpx 29rpx 24rpx 34rpx;
  1095. }
  1096. .yhj {
  1097. border-bottom: 16rpx solid #f9f9f9;
  1098. }
  1099. .yhjtit {
  1100. font-size: 30rpx;
  1101. color: #0c141f;
  1102. font-weight: 500;
  1103. margin-bottom: 14rpx;
  1104. }
  1105. .yhjList {
  1106. display: flex;
  1107. align-items: center;
  1108. justify-content: space-between;
  1109. margin-bottom: 14rpx;
  1110. }
  1111. .yhjList > .yhjLefts {
  1112. display: flex;
  1113. align-items: center;
  1114. }
  1115. .yhjLefts > .yhl {
  1116. color: #32467b;
  1117. font-size: 30rpx;
  1118. margin-right: 31rpx;
  1119. }
  1120. .yhjLefts > .yhbq {
  1121. font-size: 24rpx;
  1122. color: #ff9500;
  1123. border-radius: 18rpx;
  1124. background-color: rgba(255, 149, 0, 0.2);
  1125. border: 2rpx solid #ff9500;
  1126. height: 38rpx;
  1127. line-height: 38rpx;
  1128. padding: 0rpx 16rpx;
  1129. }
  1130. .ts {
  1131. font-size: 24rpx;
  1132. color: #999;
  1133. margin: 14rpx 0rpx;
  1134. padding-right: 29rpx;
  1135. padding-left: 34rpx;
  1136. }
  1137. .yh {
  1138. padding-top: 20rpx;
  1139. }
  1140. .yh > .yhtitle {
  1141. display: flex;
  1142. align-items: center;
  1143. justify-content: space-between;
  1144. padding-right: 29rpx;
  1145. padding-left: 34rpx;
  1146. }
  1147. .priceBxs {
  1148. display: flex;
  1149. align-items: center;
  1150. }
  1151. .priceBxs > .pricleft {
  1152. border-radius: 24rpx;
  1153. border: 1rpx solid #e91313;
  1154. background-color: rgba(233, 19, 19, 0.1);
  1155. padding: 0rpx 18rpx;
  1156. height: 49rpx;
  1157. line-height: 49rpx;
  1158. text-align: center;
  1159. font-size: 30rpx;
  1160. font-weight: 500;
  1161. color: #e91313;
  1162. margin-right: 13rpx;
  1163. }
  1164. .topBox {
  1165. padding: 32rpx 32rpx 24rpx;
  1166. border-bottom: 1rpx solid #eeeeee;
  1167. }
  1168. .topBox > .boldFonstType {
  1169. font-weight: 500;
  1170. font-size: 30rpx;
  1171. margin: 16rpx 0rpx 23rpx;
  1172. }
  1173. .topBox > .firstTopL {
  1174. display: flex;
  1175. align-items: center;
  1176. }
  1177. .topBox > .firstTopL > .imageBs {
  1178. width: 331rpx;
  1179. height: 160rpx;
  1180. border-radius: 6rpx;
  1181. overflow: hidden;
  1182. margin-right: 8rpx;
  1183. box-shadow: 0rpx 6rpx 6rpx 0rpx rgba(47, 67, 121, 0.08);
  1184. }
  1185. .topBox > .firstTopL > .imageBs > image {
  1186. width: 100%;
  1187. height: 100%;
  1188. }
  1189. .topBox > .firstTopL > .textBs {
  1190. font-size: 30rpx;
  1191. font-weight: bold;
  1192. color: #0c141f;
  1193. }
  1194. .content {
  1195. padding: 24rpx;
  1196. text-align: left;
  1197. }
  1198. .catalogBox {
  1199. display: flex;
  1200. align-items: center;
  1201. flex-wrap: nowrap;
  1202. overflow-x: auto;
  1203. padding-left: 38rpx;
  1204. max-height: 305rpx;
  1205. overflow-y: auto;
  1206. transition: all 0.4s;
  1207. }
  1208. .catalogBox > .catalogA {
  1209. min-width: 200rpx;
  1210. height: 48rpx;
  1211. line-height: 48rpx;
  1212. // text-align: center;
  1213. border: 2rpx solid transparent;
  1214. white-space: nowrap;
  1215. text-overflow: ellipsis;
  1216. overflow: hidden;
  1217. word-break: break-all;
  1218. border-radius: 10rpx;
  1219. background: rgba(22, 119, 255, 0.05);
  1220. padding-left: 19rpx;
  1221. box-sizing: border-box;
  1222. padding-right: 15rpx;
  1223. margin-right: 16rpx;
  1224. margin-bottom: 20rpx;
  1225. margin-top: 15rpx;
  1226. font-size: 24rpx;
  1227. color: #666;
  1228. }
  1229. .catalogBox > .activesq {
  1230. border-color: #1677ff;
  1231. }
  1232. .changeCatalogBox {
  1233. display: block;
  1234. }
  1235. .catalogBox::-webkit-scrollbar {
  1236. display: none; /* Chrome Safari */
  1237. }
  1238. .box {
  1239. position: relative;
  1240. top: 650rpx;
  1241. padding-bottom: 88rpx;
  1242. margin: 20rpx;
  1243. }
  1244. .price_t2 {
  1245. font-size: 18rpx;
  1246. font-family: PingFang SC;
  1247. font-weight: 500;
  1248. text-decoration: line-through;
  1249. color: #999999;
  1250. }
  1251. .price_t1 {
  1252. font-size: 33rpx;
  1253. font-family: PingFang SC;
  1254. font-weight: bold;
  1255. color: #e91313;
  1256. }
  1257. .sc_t {
  1258. font-size: 22rpx;
  1259. color: #000000;
  1260. }
  1261. .sc {
  1262. width: 29rpx;
  1263. height: 29rpx;
  1264. }
  1265. .buy {
  1266. width: 138rpx;
  1267. height: 48rpx;
  1268. line-height: 48rpx;
  1269. background: #32467b;
  1270. border-radius: 10rpx;
  1271. color: #ffffff;
  1272. font-size: 28rpx;
  1273. text-align: center;
  1274. vertical-align: middle;
  1275. position: absolute;
  1276. right: 30rpx;
  1277. }
  1278. .video_body {
  1279. padding-bottom: 96rpx;
  1280. }
  1281. .footer_tab {
  1282. position: fixed;
  1283. bottom: 0;
  1284. height: 96rpx;
  1285. width: 100%;
  1286. background-color: #ffffff;
  1287. }
  1288. .tj_box {
  1289. width: 50%;
  1290. display: inline-block;
  1291. text-align: center;
  1292. margin: 10rpx 0;
  1293. }
  1294. .teacher_t {
  1295. font-size: 24rpx;
  1296. font-family: PingFang SC;
  1297. font-weight: 400;
  1298. color: #666666;
  1299. line-height: 36rpx;
  1300. margin-left: 15rpx;
  1301. }
  1302. .teacher_img {
  1303. width: 87rpx;
  1304. height: 129rpx;
  1305. }
  1306. .t2 {
  1307. font-size: 24rpx;
  1308. font-family: PingFang SC;
  1309. color: #666666;
  1310. line-height: 36rpx;
  1311. margin: 15rpx;
  1312. }
  1313. .r_t2 {
  1314. width: 201rpx;
  1315. height: 49rpx;
  1316. background: rgba(22, 119, 255, 0.05);
  1317. border: 1rpx solid #32467b;
  1318. border-radius: 16rpx;
  1319. color: #666666;
  1320. font-size: 23rpx;
  1321. text-align: center;
  1322. display: flex;
  1323. align-items: center;
  1324. padding: 5rpx;
  1325. }
  1326. .scroll_box {
  1327. width: 100%;
  1328. height: 60rpx;
  1329. background: #ffffff;
  1330. box-shadow: 0rpx 0rpx 16rpx 4rpx rgba(145, 156, 178, 0.1);
  1331. white-space: nowrap;
  1332. overflow: hidden;
  1333. margin: 15rpx 0;
  1334. }
  1335. .r_sliper {
  1336. padding: 0 20rpx;
  1337. }
  1338. .top_line {
  1339. width: 6rpx;
  1340. height: 22rpx;
  1341. background: #32467b;
  1342. margin-right: 10rpx;
  1343. }
  1344. .video_t2 {
  1345. font-size: 24rpx;
  1346. font-family: PingFang SC;
  1347. font-weight: 500;
  1348. color: #666666;
  1349. }
  1350. .video_t1 {
  1351. height: 80rpx;
  1352. color: #333333;
  1353. line-height: 80rpx;
  1354. font-size: 30rpx;
  1355. font-family: PingFang SC;
  1356. font-weight: bold;
  1357. color: #333333;
  1358. overflow: hidden;
  1359. text-overflow: ellipsis;
  1360. white-space: nowrap;
  1361. }
  1362. .video_t1_t {
  1363. display: flex;
  1364. flex-direction: column;
  1365. height: 80rpx;
  1366. color: #333333;
  1367. text-align: center;
  1368. align-items: center;
  1369. border-left: solid 1px #d6d6db;
  1370. }
  1371. .video_play {
  1372. position: absolute;
  1373. width: 95rpx;
  1374. height: 95rpx;
  1375. top: 0;
  1376. left: 0;
  1377. right: 0;
  1378. bottom: 0;
  1379. margin: auto;
  1380. }
  1381. .video_box {
  1382. position: relative;
  1383. }
  1384. .rotoct {
  1385. transform: rotate(90deg);
  1386. }
  1387. </style>