index.vue 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379
  1. <template>
  2. <NavHeader/>
  3. <bread-crumb/>
  4. <div class="w-1200px m-auto">
  5. <div class="relative -mt-40px flex justify-end">
  6. <button type="button" class="back-btn" @click="linkTo('process')">返回</button>
  7. </div>
  8. <div class="mt-10px w-full min-h-860px bg-hex-FFF pt-25px">
  9. <h3 class="text-18px text-center">附件出题</h3>
  10. <div class="mt-60px pl-250px">
  11. <el-form ref="ruleFormRef" :rules="rules" :model="createForm" label-width="140px" size="large" status-icon>
  12. <el-form-item label="学科" style="width: 620px">
  13. <h3 class="text-14px">{{createForm.xkmc}}</h3>
  14. </el-form-item>
  15. <el-form-item label="答题卡名称" prop="dtkmc" style="width: 620px">
  16. <el-input v-model="createForm.dtkmc" placeholder="请输入答题卡名称" />
  17. </el-form-item>
  18. <el-form-item label="答题卡别名" style="width: 620px">
  19. <el-input v-model="createForm.dtkbm" placeholder="请输入答题卡别名" />
  20. </el-form-item>
  21. <el-form-item label="及格分数" prop="jgfs" style="width: 620px">
  22. <el-input v-model="createForm.jgfs" placeholder="请输入及格分数" />
  23. </el-form-item>
  24. <el-form-item label="优秀分数" prop="yxfs" style="width: 620px">
  25. <el-input v-model="createForm.yxfs" placeholder="请输入优秀分数" />
  26. </el-form-item>
  27. <el-form-item label="流程类型" prop="lclx" style="width: 620px">
  28. <el-radio-group v-model="createForm.lclx">
  29. <el-radio v-for="item in lc_type_list" :label="item.value">{{item.label}}</el-radio>
  30. </el-radio-group>
  31. </el-form-item>
  32. <el-form-item label="阅卷流程" prop="yjlc" style="width: 620px">
  33. <el-radio-group v-model="createForm.yjlc">
  34. <el-radio v-for="item in yjlc" :label="item.value">{{item.label}}</el-radio>
  35. </el-radio-group>
  36. </el-form-item>
  37. <el-form-item>
  38. <div v-if="createForm.yjlc === '1'">
  39. <el-button type="primary" color="#003eee">
  40. <el-icon :size="24"><UploadFilled /></el-icon>
  41. <span>上传文件</span>
  42. </el-button>
  43. <span class="ml-10px text-13px text-hex-999999">上传文件格式支持 jpg,png,jpeg,docx,doc,mp4,pdf,ppt,pptx,xls,xlsx</span>
  44. </div>
  45. <div v-else-if="createForm.yjlc === '2'">
  46. <el-button type="primary" color="#003eee">
  47. <el-icon :size="24"><Promotion /></el-icon>
  48. <span>启动客户端</span>
  49. </el-button>
  50. </div>
  51. <div v-else>
  52. <el-button type="primary" color="#003eee" @click="dialogVisible = true">
  53. <el-icon :size="24"><Plus /></el-icon>
  54. <span>请选择答题卡</span>
  55. </el-button>
  56. </div>
  57. </el-form-item>
  58. <el-form-item v-if="createForm.yjlc === '2'" label="扫描文件展示列表"></el-form-item>
  59. <el-form-item>
  60. <div class="mt-50px pl-50px">
  61. <el-button class="mr-20px" @click="linkTo('process')"><span class="px-40px">取消</span></el-button>
  62. <el-button type="primary" color="#003eee" @click="handleSubmit(ruleFormRef)"><span class="px-40px">确定</span></el-button>
  63. </div>
  64. </el-form-item>
  65. </el-form>
  66. </div>
  67. </div>
  68. </div>
  69. <el-dialog
  70. v-model="dialogVisible"
  71. title="答题卡选择"
  72. width="980px"
  73. custom-class="dialogTrick"
  74. append-to-body
  75. >
  76. <el-form :inline="true" class="flex justify-between" size="large">
  77. <el-form-item label="考试时间筛选">
  78. <el-date-picker
  79. v-model="time"
  80. type="date"
  81. placeholder="请选择考试时间"
  82. />
  83. </el-form-item>
  84. <div>
  85. <el-form-item style="margin-right: 10px">
  86. <el-input v-model="keyword" placeholder="请输入关键字" clearable />
  87. </el-form-item>
  88. <el-form-item>
  89. <el-button color="#003eee" type="primary">搜索</el-button>
  90. </el-form-item>
  91. </div>
  92. </el-form>
  93. <ul class="card-list py-15px">
  94. <li class="relative py-15px" :class="chooseCheck.includes('1')?'selected':''">
  95. <div class="choose">
  96. <p class="set-check">
  97. <input type="checkbox" id="1" value="1" v-model="chooseCheck">
  98. <label :for="1"></label>
  99. </p>
  100. </div>
  101. <div class="w-162px h-108px m-auto overflow-hidden">
  102. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  103. </div>
  104. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  105. <button type="button" class="op-btn block m-auto">查看</button>
  106. </li>
  107. <li class="relative py-15px">
  108. <div class="choose">
  109. <p class="set-check">
  110. <input type="checkbox" id="2" value="2" v-model="chooseCheck">
  111. <label :for="2"></label>
  112. </p>
  113. </div>
  114. <div class="w-162px h-108px m-auto overflow-hidden">
  115. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  116. </div>
  117. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  118. <button type="button" class="op-btn block m-auto">查看</button>
  119. </li>
  120. <li class="relative py-15px">
  121. <div class="w-162px h-108px m-auto overflow-hidden">
  122. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  123. </div>
  124. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  125. <button type="button" class="op-btn block m-auto">查看</button>
  126. </li>
  127. <li class="relative py-15px">
  128. <div class="w-162px h-108px m-auto overflow-hidden">
  129. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  130. </div>
  131. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  132. <button type="button" class="op-btn block m-auto">查看</button>
  133. </li>
  134. <li class="relative py-15px">
  135. <div class="w-162px h-108px m-auto overflow-hidden">
  136. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  137. </div>
  138. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  139. <button type="button" class="op-btn block m-auto">查看</button>
  140. </li>
  141. <li class="relative py-15px">
  142. <div class="w-162px h-108px m-auto overflow-hidden">
  143. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  144. </div>
  145. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  146. <button type="button" class="op-btn block m-auto">查看</button>
  147. </li>
  148. <li class="relative py-15px">
  149. <div class="w-162px h-108px m-auto overflow-hidden">
  150. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  151. </div>
  152. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  153. <button type="button" class="op-btn block m-auto">查看</button>
  154. </li>
  155. <li class="relative py-15px">
  156. <div class="w-162px h-108px m-auto overflow-hidden">
  157. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  158. </div>
  159. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  160. <button type="button" class="op-btn block m-auto">查看</button>
  161. </li>
  162. <li class="relative py-15px">
  163. <div class="w-162px h-108px m-auto overflow-hidden">
  164. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  165. </div>
  166. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  167. <button type="button" class="op-btn block m-auto">查看</button>
  168. </li>
  169. <li class="relative py-15px">
  170. <div class="w-162px h-108px m-auto overflow-hidden">
  171. <img class="w-full" src="https://yzy.bozedu.net/data/upload/exam_package/20230329/1521/210900241/5-1521-210900241-4096-20230329101520/image_20230329101519044.jpg" alt="">
  172. </div>
  173. <h3 class="mt-10px mb-10px px-20px text-13px leading-20px truncate text-center">2023-11-12联考答题卡</h3>
  174. <button type="button" class="op-btn block m-auto">查看</button>
  175. </li>
  176. </ul>
  177. <template #footer>
  178. <span class="dialog-footer">
  179. <el-button @click="dialogVisible = false" class="mr-15px" size="large">
  180. <span class="px-10px">取消</span>
  181. </el-button>
  182. <el-button size="large" color="#003eee" type="primary" @click="dialogVisible = false">
  183. <span class="px-10px">确定</span>
  184. </el-button>
  185. </span>
  186. </template>
  187. </el-dialog>
  188. <commonFooter/>
  189. </template>
  190. <route lang="json">
  191. {
  192. "meta":{
  193. "title":"附件出题",
  194. "breadcrumb": true
  195. }
  196. }
  197. </route>
  198. <script setup>
  199. import { useRouter } from "vue-router";
  200. const router = useRouter();
  201. const linkTo = (name) => {
  202. router.push({ name });
  203. };
  204. const rules = $ref({
  205. dtkmc:[{ required: true, message: '请输入答题卡名称', trigger: 'blur' }],
  206. jgfs:[{ required: true, message: '请输入及格分数', trigger: 'blur' }],
  207. yxfs:[{ required: true, message: '请输入优秀分数', trigger: 'blur' }],
  208. lclx: [{required: true, message: '请选择流程类型', trigger: 'change'}],
  209. yjlc: [{required: true, message: '请选择阅卷流程', trigger: 'change'}],
  210. })
  211. const ruleFormRef = ref(null);
  212. let createForm = $ref({
  213. xkmc:'语文',
  214. dtkmc:'',
  215. dtkbm:'',
  216. jgfs:'',
  217. yxfs:'',
  218. lclx:'1',
  219. yjlc:'1'
  220. })
  221. let lc_type_list = [{
  222. value: '1',
  223. label: '常规'
  224. }, {
  225. value: '2',
  226. label: '自定义框选'
  227. }, {
  228. value: '3',
  229. label: '无定位点框选(第三方答题卡)'
  230. }]
  231. let yjlc = [{
  232. value: '1',
  233. label: '上传文件'
  234. }, {
  235. value: '2',
  236. label: '模板预扫描'
  237. }, {
  238. value: '3',
  239. label: '沿用答题卡'
  240. }]
  241. const handleCancel = () => {
  242. router.back();
  243. }
  244. const handleSubmit = async (formEl) => {
  245. if (!formEl) return;
  246. formEl.validate(async (valid, fields) => {
  247. if (valid) {
  248. } else {
  249. console.log("error submit!", fields);
  250. }
  251. });
  252. }
  253. let dialogVisible = $ref(false)
  254. let time = $ref('')
  255. let keyword = $ref('')
  256. let chooseCheck = $ref([]);
  257. </script>
  258. <style lang="scss">
  259. .dialogTrick .el-dialog__footer {
  260. text-align: center;
  261. }
  262. </style>
  263. <style lang="scss" scoped>
  264. .card-list{
  265. display: flex;
  266. flex-wrap: wrap;
  267. max-height: 480px;
  268. overflow-y:auto;
  269. li{
  270. width: 203px;
  271. background: #ffffff;
  272. border: 2px solid #cacaca;
  273. border-radius: 10px;
  274. margin-right: 40px;
  275. margin-bottom: 30px;
  276. &.selected{
  277. border-color:#003eee;
  278. }
  279. &:nth-child(4n) {
  280. margin-right: 0;
  281. }
  282. &:hover{
  283. .card-pop{
  284. display: flex;
  285. }
  286. }
  287. .card-title{
  288. width: 100%;
  289. font-size: 13px;
  290. line-height: 15px;
  291. }
  292. }
  293. .card-pop{
  294. position: absolute;
  295. left: 0;
  296. top: 0;
  297. width: 100%;
  298. height: 100%;
  299. border-radius: 10px;
  300. z-index: 30;
  301. background: rgba(0,0,0,.45);
  302. display: none;
  303. align-items: center;
  304. justify-content: center;
  305. }
  306. }
  307. .op-btn {
  308. width: 60px;
  309. height: 30px;
  310. background: #fff;
  311. border: 1px solid #003eee;
  312. border-radius: 2px;
  313. font-size: 14px;
  314. color: #003eee;
  315. text-align: center;
  316. }
  317. .choose{
  318. position: absolute;
  319. left: -12px;
  320. top:-12px;
  321. z-index: 50;
  322. }
  323. .set-check {
  324. position: relative;
  325. z-index: 40;
  326. width: 25px;
  327. height: 25px;
  328. label {
  329. position: absolute;
  330. left: 0;
  331. width: 25px;
  332. height: 25px;
  333. cursor: pointer;
  334. background: #fff;
  335. border-radius: 4px;
  336. box-shadow: 0 0 4px rgba(0,0,0,0.18);
  337. }
  338. input[type=checkbox] {
  339. width: 25px;
  340. height: 25px;
  341. opacity: 0;
  342. &:checked + label {
  343. background: #003eee;
  344. }
  345. &:checked + label:after {
  346. content: '';
  347. width: 16px;
  348. height: 10px;
  349. position: absolute;
  350. top: 5px;
  351. left: 4px;
  352. border: 3px solid #fff;
  353. border-top: none;
  354. border-right: none;
  355. -moz-transform: rotate(-45deg);
  356. -ms-transform: rotate(-45deg);
  357. -webkit-transform: rotate(-45deg);
  358. transform: rotate(-45deg);
  359. }
  360. }
  361. }
  362. </style>