index.28cd52fa.js 9.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299
  1. import {
  2. d as u,
  3. a_ as i,
  4. b as d,
  5. c as t,
  6. F as n,
  7. O as p,
  8. b1 as h,
  9. a as m,
  10. aB as g,
  11. aC as l
  12. } from './index.1d0cc84f.js'
  13. import { C as r } from './index.b42087f4.js'
  14. import { P as c } from './index.cf4d47ea.js'
  15. import { I as v } from './index.37658c21.js'
  16. import { E as f, a as s } from './index2.07a0e1bf.js'
  17. import './index2.ba9e0a49.js'
  18. import './index2.6b7eb987.js'
  19. const S = '_liveClass_w1fih_1'
  20. var I = { liveClass: S },
  21. o = u({
  22. name: 'list',
  23. props: { auditStatus: { type: String, default: '' } },
  24. data() {
  25. return {
  26. pageInfo: { limit: 9, page: 1, total: 0, page_size: [10, 20, 40, 50] },
  27. list: [],
  28. loading: !0,
  29. dataShow: !1
  30. }
  31. },
  32. mounted() {
  33. var e
  34. ;(e = i.user.data) != null && e.entryFlag && this.getList()
  35. },
  36. methods: {
  37. async getList() {
  38. var e
  39. this.loading = !0
  40. try {
  41. const { data: a } = await d.post(
  42. '/api-website/videoLessonGroup/page',
  43. {
  44. data: {
  45. auditStatus: this.auditStatus,
  46. page: this.pageInfo.page,
  47. rows: this.pageInfo.limit,
  48. teacherId: (e = i.user.data) == null ? void 0 : e.userId
  49. }
  50. }
  51. )
  52. ;(this.list = a.rows || []),
  53. (this.pageInfo.total = a.total),
  54. a.total <= 0 && (this.dataShow = !0)
  55. } catch {}
  56. this.dataShow
  57. ? (this.loading = !1)
  58. : setTimeout(() => {
  59. this.loading = !1
  60. }, 200)
  61. },
  62. onDetail(e) {
  63. if (this.auditStatus === 'UNPASS') {
  64. this.$router.push({
  65. path: '/userInfo/videoOperation',
  66. query: { type: 'edit', groupId: e.id }
  67. })
  68. return
  69. }
  70. }
  71. },
  72. render() {
  73. var e
  74. return t(n, null, [
  75. (e = i.user.data) != null && e.entryFlag
  76. ? t(n, null, [
  77. t('div', { class: 'flex flex-wrap px-10' }, [
  78. t(
  79. f,
  80. {
  81. loading: this.loading,
  82. animated: !0,
  83. class: 'flex',
  84. count: 3
  85. },
  86. {
  87. default: () => [
  88. this.list.map(a =>
  89. t(
  90. 'div',
  91. {
  92. class: 'w-1/3 pt-8',
  93. onClick: () => this.onDetail(a)
  94. },
  95. [
  96. t(
  97. v,
  98. {
  99. item: {
  100. backgroundPic: a.lessonCoverUrl,
  101. courseGroupName: a.lessonName,
  102. studentCount: a.countStudent,
  103. avatar: a.avatar,
  104. teacherName: a.username,
  105. coursePrice: a.lessonPrice,
  106. courseNum: a.lessonCount
  107. }
  108. },
  109. null
  110. )
  111. ]
  112. )
  113. )
  114. ],
  115. template: () =>
  116. t('div', { class: 'w-1/3' }, [
  117. t(
  118. 'div',
  119. { class: 'flex flex-col pt-8 w-[262px] m-auto' },
  120. [
  121. t(
  122. s,
  123. {
  124. variant: 'image',
  125. style: { width: '100%', height: '175px' }
  126. },
  127. null
  128. ),
  129. t(
  130. 'div',
  131. {
  132. class:
  133. 'mx-2.5 py-3.5 border-b border-b-[#F2F2F2]'
  134. },
  135. [
  136. t(
  137. 'div',
  138. {
  139. class:
  140. 'text-lg leading-none font-semibold whitespace-nowrap overflow-hidden text-ellipsis'
  141. },
  142. [t(s, { variant: 'h3' }, null)]
  143. ),
  144. t(
  145. 'div',
  146. { class: 'text-sm text-[#999] pt-2.5' },
  147. [
  148. t(
  149. s,
  150. { variant: 'p', style: { width: '50%' } },
  151. null
  152. )
  153. ]
  154. )
  155. ]
  156. ),
  157. t(
  158. 'div',
  159. { class: 'mx-2.5 py-4 flex items-center' },
  160. [
  161. t(
  162. s,
  163. {
  164. variant: 'circle',
  165. style: {
  166. width: '22px',
  167. height: '22px',
  168. marginRight: '5px'
  169. }
  170. },
  171. null
  172. ),
  173. t(
  174. s,
  175. { variant: 'p', style: { width: '20%' } },
  176. null
  177. ),
  178. t('p', { style: { width: '45%' } }, null),
  179. t(
  180. s,
  181. { variant: 'p', style: { width: '20%' } },
  182. null
  183. )
  184. ]
  185. )
  186. ]
  187. )
  188. ])
  189. }
  190. )
  191. ]),
  192. t(
  193. c,
  194. {
  195. total: this.pageInfo.total,
  196. page: this.pageInfo.page,
  197. 'onUpdate:page': a => (this.pageInfo.page = a),
  198. limit: this.pageInfo.limit,
  199. 'onUpdate:limit': a => (this.pageInfo.limit = a),
  200. pageSizes: this.pageInfo.page_size,
  201. pagination: this.getList
  202. },
  203. null
  204. ),
  205. this.dataShow && t(r, null, null)
  206. ])
  207. : t(
  208. r,
  209. {
  210. type: 'teacherCert',
  211. message:
  212. '\u60A8\u8FD8\u672A\u5B8C\u6210\u8FBE\u4EBA\u8BA4\u8BC1\uFF0C\u8BA4\u8BC1\u540E\u624D\u53EF\u521B\u5EFA\u89C6\u9891\u8BFE\u54E6~',
  213. buttonVisibility: !0,
  214. buttonText: '\u53BB\u8BA4\u8BC1',
  215. onDetail: () => {
  216. this.$router.push('/teacherAuth')
  217. }
  218. },
  219. null
  220. )
  221. ])
  222. }
  223. }),
  224. A = u({
  225. name: 'video-class',
  226. data() {
  227. const e = sessionStorage.getItem('videoActiveName')
  228. return (
  229. sessionStorage.removeItem('videoActiveName'),
  230. { activeName: e || 'PASS' }
  231. )
  232. },
  233. render() {
  234. return t('div', { class: [I.liveClass, 'relative'] }, [
  235. t(
  236. p,
  237. {
  238. round: !0,
  239. type: 'primary',
  240. class: 'absolute right-11 top-4 z-10',
  241. onClick: () => {
  242. var e
  243. if ((e = i.user.data) != null && e.entryFlag)
  244. this.$router.push('/userInfo/videoOperation')
  245. else {
  246. h.error(
  247. '\u60A8\u8FD8\u672A\u5B8C\u6210\u8FBE\u4EBA\u8BA4\u8BC1\uFF0C\u8BA4\u8BC1\u540E\u624D\u53EF\u521B\u5EFA\u89C6\u9891\u8BFE'
  248. )
  249. return
  250. }
  251. }
  252. },
  253. { default: () => [m('\u65B0\u5EFA\u89C6\u9891\u8BFE')] }
  254. ),
  255. t(
  256. g,
  257. {
  258. modelValue: this.activeName,
  259. 'onUpdate:modelValue': e => (this.activeName = e)
  260. },
  261. {
  262. default: () => [
  263. t(
  264. l,
  265. { label: '\u5DF2\u4E0A\u67B6', name: 'PASS' },
  266. {
  267. default: () => [
  268. this.activeName === 'PASS' &&
  269. t(o, { auditStatus: 'PASS' }, null)
  270. ]
  271. }
  272. ),
  273. t(
  274. l,
  275. { label: '\u5BA1\u6838\u4E2D', name: 'DOING' },
  276. {
  277. default: () => [
  278. this.activeName === 'DOING' &&
  279. t(o, { auditStatus: 'DOING' }, null)
  280. ]
  281. }
  282. ),
  283. t(
  284. l,
  285. { label: '\u5BA1\u6838\u5931\u8D25', name: 'UNPASS' },
  286. {
  287. default: () => [
  288. this.activeName === 'UNPASS' &&
  289. t(o, { auditStatus: 'UNPASS' }, null)
  290. ]
  291. }
  292. )
  293. ]
  294. }
  295. )
  296. ])
  297. }
  298. })
  299. export { A as default }