Tips.vue 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243
  1. <template>
  2. <section class="content">
  3. <div class=""><img src="./tips.png" /></div>
  4. <div class="text">
  5. <div v-for="(menu1, index) in instructions" :key="index" class="menu1">
  6. <h4 v-if="menu1.menu2.filter(m => m.canAccess).length > 0">
  7. {{ menu1.menu1Name }}
  8. </h4>
  9. <div v-for="(menu2, index) in menu1.menu2" :key="index" class="menu1">
  10. <span v-if="menu2.canAccess">
  11. <router-link :to="menu2.link" class="link">
  12. {{ menu2.name }}
  13. </router-link>
  14. {{ menu2.detail }}
  15. </span>
  16. </div>
  17. </div>
  18. </div>
  19. </section>
  20. </template>
  21. <script>
  22. const ALL_INSTRUCTIONS = {
  23. "/basic/tips": [
  24. {
  25. menu1Name: "学习中心查询",
  26. menu2: [
  27. {
  28. name: "机构管理——中心列表",
  29. link: "/basic/campus",
  30. detail:
  31. "查询学校下属所有学习中心编码及名称,可按学习中心设置学习中心平台权限,即A学习中心只能查询A中心的相关考试数据。"
  32. }
  33. ]
  34. },
  35. {
  36. menu1Name: "课程查询",
  37. menu2: [
  38. {
  39. name: "课程管理——课程列表",
  40. link: "/basic/course",
  41. detail:
  42. "查看所有课程名称及代码,如一门课程即有专科又有本科,课程对应在的教材、试卷不一样时,需要建立专科课程及本科课程。"
  43. }
  44. ]
  45. },
  46. {
  47. menu1Name: "用户查询",
  48. menu2: [
  49. {
  50. name: "用户管理——普通用户管理",
  51. link: "/basic/user",
  52. detail:
  53. "添加、查询、禁用管理平台用户,并可以针对不同用户设置不同的平台模块权限。"
  54. }
  55. ]
  56. }
  57. ],
  58. "/examwork/tips": [
  59. {
  60. menu1Name: "安排考试",
  61. menu2: [
  62. {
  63. name: "考试管理——考试信息",
  64. link: "/examwork/examInfo",
  65. detail: "安排一场在线考试,设置考试开启、结束时间。"
  66. }
  67. ]
  68. },
  69. {
  70. menu1Name: "考试课程",
  71. menu2: [
  72. {
  73. name: "考试管理——考生信息",
  74. // link: "/basic/campus",
  75. detail: "新增或导入考生报考的相关课程。"
  76. }
  77. ]
  78. },
  79. {
  80. menu1Name: "学生档案",
  81. menu2: [
  82. {
  83. name: "学生管理——学生信息",
  84. // link: "/basic/campus",
  85. detail: "更新学生的登录名、密码、相片。"
  86. }
  87. ]
  88. }
  89. ],
  90. "/questions/tips": [
  91. {
  92. menu1Name: "导入试卷",
  93. menu2: [
  94. {
  95. name: "题库管理——导入试卷管理",
  96. // link: "/basic/campus",
  97. detail: "可以将word版试卷导入题库,由题库按课程、题型形成题库。"
  98. }
  99. ]
  100. },
  101. {
  102. menu1Name: "卷库组卷",
  103. menu2: [
  104. {
  105. name: "卷库管理——考试试卷管理",
  106. // link: "/basic/campus",
  107. detail:
  108. "可按需求将XX课程的所有试题,按分数、题量、题型结构、章节等多种方式进行随机组合,生成若干套试卷。"
  109. }
  110. ]
  111. },
  112. {
  113. menu1Name: "考试用卷绑定",
  114. menu2: [
  115. {
  116. name: "考试管理——调卷规则",
  117. // link: "/basic/campus",
  118. detail: "来指定在本次考试中使用卷库中的哪一套试卷,及抽卷的比例。"
  119. }
  120. ]
  121. }
  122. ],
  123. "/oe/tips": [
  124. {
  125. menu1Name: "考试过程监考",
  126. menu2: [
  127. {
  128. name: "网考管理——监考待审",
  129. // link: "/oe/campus",
  130. detail: "列出所有考生考试过程中的数据,并提示出违纪数据审核。"
  131. }
  132. ]
  133. },
  134. {
  135. menu1Name: "考试明细查询",
  136. menu2: [
  137. {
  138. name: "统计报表——考试明细",
  139. // link: "/oe/campus",
  140. detail:
  141. "需要查询学生所有作答的试卷,可以在考试明细中输入学生信息进行查询考试时间、违纪情况、客观题得分、答卷等。"
  142. }
  143. ]
  144. },
  145. {
  146. menu1Name: "考试完成进度查询",
  147. menu2: [
  148. {
  149. name: "考试进度——考试概览",
  150. // link: "/oe/campus",
  151. detail: "可以查看按考试、学习中心、课程数来查看考试完成的进度。"
  152. }
  153. ]
  154. },
  155. {
  156. menu1Name: "考试完成进度查询",
  157. menu2: [
  158. {
  159. name: "考试进度——考试进度详情",
  160. // link: "/oe/campus",
  161. detail: "可以查看按考试的人数、学习中心、查看考生的完成情况。"
  162. }
  163. ]
  164. }
  165. ],
  166. "/print/tips": [
  167. {
  168. menu1Name: "项目管理",
  169. menu2: [
  170. {
  171. name: "项目管理——项目列表",
  172. link: "/print/project/list",
  173. detail:
  174. "查询学校下传统考试的统计概况信息,如考生人数,试卷数、试卷印刷数量等相关数据。"
  175. }
  176. ]
  177. }
  178. ]
  179. };
  180. import { mapState } from "vuex";
  181. export default {
  182. name: "Tips",
  183. data() {
  184. return {
  185. instructions: []
  186. };
  187. },
  188. computed: { ...mapState({ menuList: state => state.menuList }) },
  189. methods: {},
  190. created() {
  191. this.instructions = ALL_INSTRUCTIONS[this.$route.path];
  192. },
  193. watch: {
  194. menuList() {
  195. const tipsLink = this.menuList.map(m => m.ext5);
  196. this.instructions.map(menu => {
  197. menu.menu2 = menu.menu2.map(m => {
  198. if (tipsLink.includes(m.link)) {
  199. m.canAccess = true;
  200. } else {
  201. m.canAccess = false;
  202. }
  203. return m;
  204. });
  205. return menu;
  206. });
  207. }
  208. }
  209. };
  210. </script>
  211. <style scoped>
  212. .content {
  213. display: flex;
  214. align-items: center;
  215. justify-content: center;
  216. height: 100%;
  217. width: 100%;
  218. /* margin: 100px; */
  219. }
  220. .text {
  221. max-width: 600px;
  222. margin: 0 20px;
  223. }
  224. .menu1 {
  225. margin-bottom: 20px;
  226. }
  227. .link {
  228. padding: 0em 1em;
  229. background-color: #dbe7ef;
  230. border-radius: 12px;
  231. color: #3c8dbd;
  232. }
  233. </style>