my_learn.vue 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293
  1. <template>
  2. <view class="safeArea">
  3. <view style="width: 100%;text-align: center;position: fixed;height: 96rpx;z-index: 999;">
  4. <u-tabs :list="list" sticky :current="current" @change="change" active-color="#333" inactive-color="#999"></u-tabs>
  5. </view>
  6. <view class="learnWrap">
  7. <template v-if="current === 0">
  8. <!-- <view class="noData">您暂无相关学时审核记录哦~</view> -->
  9. <view class="learnItem" v-for="(item, index) in listData" :key="index">
  10. <view class="title">{{ item.goodsName }}</view>
  11. <view class="status">
  12. <view class="label">审核状态:</view>
  13. <view
  14. class="val"
  15. :class="item.periodStatus === -1 || item.periodStatus === 3 ? 'red' : item.periodStatus === 1 ? 'green' : item.periodStatus === 2 ? 'blue' : ''"
  16. >
  17. <text>
  18. {{
  19. item.periodStatus === -1
  20. ? '不可审核'
  21. : item.periodStatus === 1
  22. ? '机构审核通过'
  23. : item.periodStatus === 2
  24. ? '等待审核'
  25. : item.periodStatus === 3
  26. ? '机构审核不通过'
  27. : ''
  28. }}
  29. </text>
  30. \n
  31. <view v-if="item.periodStatus === 3" style="font-size: 24rpx;color:#666;">
  32. <text style="color:#FF3B30;">{{ item.rebuild }}节</text>
  33. 需要重修
  34. </view>
  35. </view>
  36. </view>
  37. <view class="tip" v-if="item.periodStatus === 1">
  38. <view class="label">审核提示:</view>
  39. <view>
  40. 机构已审核通过,需等待注册中心复审后即可获得继续教育学时。审核时间约15个工作日,届时请前往官网申请证书延期。
  41. <view class="copySty" @tap="copyText">复制官网链接</view>
  42. </view>
  43. </view>
  44. <view class="tip" v-else>
  45. <view class="label">审核提示:</view>
  46. <view class="val color666" v-if="item.periodStatus === -1">您的学时还未修完,请尽快完成课程学习</view>
  47. <view class="val color666" v-if="item.periodStatus === 2">学习完成后7-15个工作日完成学时审核。</view>
  48. <view class="val color666" v-if="item.periodStatus === 3">请查看需重学记录,并及时重学对应课程,以免延误学时审核进度。</view>
  49. </view>
  50. <view v-if="item.periodStatus !== 2">
  51. <u-line color="#EEEEEE" />
  52. <view v-if="item.periodStatus === -1">
  53. <view class="btnBox"><view class="btn" @click="jumpPage(item, 1)">课程学习</view></view>
  54. </view>
  55. <view>
  56. <view v-if="item.periodStatus === 1 && item.applyStatus === 1">
  57. <view class="subTitle">{{ item.applyName }}</view>
  58. <view class="btnBox"><view class="btn" @click="jumpPage(item, 2)">预约考试</view></view>
  59. </view>
  60. <u-line color="#EEEEEE" v-if="item.periodStatus === 1 && item.applyStatus === 1" />
  61. <view v-if="item.periodStatus === 1 && item.beforeStatus === 1">
  62. <view class="subTitle">{{ item.beforeName }}</view>
  63. <view class="btnBox"><view class="btn" @click="jumpPage(item, 3)">进入刷题</view></view>
  64. </view>
  65. </view>
  66. <view v-if="item.periodStatus === 3 && item.rebuildStatus === 0">
  67. <view class="btnBox"><view class="btn" @click="jumpPage(item, 4)">查看详情</view></view>
  68. </view>
  69. <view v-if="item.periodStatus === 3 && item.rebuildStatus === 1">
  70. <view class="btnBox"><view class="btn" @click="jumpPage(item, 5)">重修目录</view></view>
  71. </view>
  72. </view>
  73. </view>
  74. </template>
  75. <template v-if="current === 1">
  76. <view class="noData">您暂无相关学习凭证记录哦~</view>
  77. <!-- <view class="learnItem">
  78. <view class="title">2020年二建建筑工程管理与实补这是商品名称</view>
  79. <view class="number">
  80. <text class="label">编号:</text>
  81. GZXY123456789
  82. </view>
  83. <view class="btnBox">
  84. <view class="btn">电子照片</view>
  85. <view class="btn">下载凭证</view>
  86. </view>
  87. </view> -->
  88. </template>
  89. </view>
  90. </view>
  91. </template>
  92. <script>
  93. import { mapGetters } from 'vuex';
  94. export default {
  95. components: {},
  96. data() {
  97. return {
  98. current: 0,
  99. list: [
  100. {
  101. name: '学时审核'
  102. },
  103. {
  104. name: '学习凭证'
  105. }
  106. ],
  107. listData: []
  108. };
  109. },
  110. onLoad(option) {},
  111. onShow() {
  112. this.getInfos();
  113. },
  114. methods: {
  115. copyText() {
  116. uni.setClipboardData({
  117. data: 'http://gdzczx.gdcic.net/',
  118. success: () => {
  119. //复制成功的回调函数
  120. uni.showToast({
  121. //提示
  122. title: '复制成功'
  123. });
  124. }
  125. });
  126. },
  127. jumpPage(v, int) {
  128. //int 1.课程学习 2.预约考试 3.进入刷题 4.查看详情 5.重修目录
  129. if (int === 1) {
  130. this.$navTo.togo(`/pages2/wd/course?id=${v.goodsId}&gid=${v.gradeId}`);
  131. }
  132. if (int === 2) {
  133. this.$navTo.togo(`/pages2/appointment/index?goodsId=${v.goodsId}&gradeId=${v.gradeId}`);
  134. }
  135. if (int === 3) {
  136. uni.showModal({
  137. content: '待开发',
  138. showCancel: false
  139. });
  140. }
  141. if (int === 4) {
  142. this.$navTo.togo(`/pages2/learn/details?goodsId=${v.goodsId}&gradeId=${v.gradeId}`);
  143. }
  144. if (int === 5) {
  145. this.$navTo.togo('/pages2/course/detail?id=' + v.goodsId);
  146. }
  147. },
  148. getInfos() {
  149. this.$api.getcourseperiodlistGoods().then(res => {
  150. if (res.data.code === 200) {
  151. this.listData = res.data.rows;
  152. }
  153. });
  154. },
  155. change(index) {
  156. this.current = index;
  157. }
  158. },
  159. onReachBottom() {},
  160. computed: { ...mapGetters(['userInfo']) }
  161. };
  162. </script>
  163. <style>
  164. page {
  165. background: #eaeef1;
  166. }
  167. </style>
  168. <style scoped lang="scss">
  169. .copySty {
  170. color: #007aff;
  171. text-decoration: underline;
  172. }
  173. .color666 {
  174. color: #666;
  175. }
  176. .learnWrap {
  177. padding: 98rpx 8rpx 8rpx;
  178. }
  179. .noData {
  180. font-size: 32rpx;
  181. font-family: PingFang SC;
  182. font-weight: 500;
  183. color: #999999;
  184. margin: 160rpx auto;
  185. text-align: center;
  186. }
  187. .learnItem {
  188. background: #ffffff;
  189. border-radius: 16rpx;
  190. padding: 32rpx 32rpx 0;
  191. font-family: PingFang SC;
  192. margin-bottom: 16rpx;
  193. overflow: hidden;
  194. .red {
  195. color: #ff3b30 !important;
  196. }
  197. .blue {
  198. color: #007aff !important;
  199. }
  200. .green {
  201. color: #34c759 !important;
  202. }
  203. .title {
  204. font-size: 30rpx;
  205. font-weight: bold;
  206. color: #333333;
  207. margin-bottom: 68rpx;
  208. }
  209. .status {
  210. font-size: 24rpx;
  211. font-weight: 500;
  212. color: #666666;
  213. margin-bottom: 26rpx;
  214. display: flex;
  215. }
  216. .number {
  217. font-size: 24rpx;
  218. font-weight: 500;
  219. color: #666666;
  220. margin-bottom: 26rpx;
  221. font-size: 30rpx;
  222. font-weight: bold;
  223. font-family: PingFang SC;
  224. color: #333;
  225. .label {
  226. font-size: 24rpx;
  227. font-weight: 500;
  228. color: #666666;
  229. }
  230. }
  231. .val {
  232. font-size: 30rpx;
  233. font-weight: bold;
  234. color: #333;
  235. .remark {
  236. font-size: 24rpx;
  237. font-family: PingFang SC;
  238. font-weight: 500;
  239. color: #666666;
  240. }
  241. .link {
  242. font-size: 30rpx;
  243. font-family: PingFang SC;
  244. font-weight: 500;
  245. text-decoration: underline;
  246. color: #007aff;
  247. margin-top: 36rpx;
  248. text-decoration: underline;
  249. }
  250. }
  251. .tip {
  252. font-size: 24rpx;
  253. font-weight: 500;
  254. color: #666666;
  255. margin: 30rpx 0 27rpx;
  256. display: flex;
  257. }
  258. .label {
  259. width: 120rpx;
  260. flex-shrink: 0;
  261. margin-top: 5rpx;
  262. }
  263. .subTitle {
  264. font-size: 30rpx;
  265. font-weight: bold;
  266. color: #333333;
  267. margin: 15rpx 0 40rpx;
  268. }
  269. .btnBox {
  270. height: 88rpx;
  271. display: flex;
  272. align-items: center;
  273. justify-content: flex-end;
  274. .btn {
  275. width: 224rpx;
  276. height: 56rpx;
  277. line-height: 56rpx;
  278. text-align: center;
  279. background: #007aff;
  280. border-radius: 16rpx;
  281. font-size: 30rpx;
  282. font-family: PingFang SC;
  283. font-weight: 500;
  284. color: #ffffff;
  285. margin-left: 16rpx;
  286. }
  287. }
  288. }
  289. </style>