123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596 |
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <title>云阅卷本地代理工具</title>
- <meta name="viewport"
- content="width=device-width,initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no" />
- <link rel="stylesheet" href="css/style.css">
- </head>
- <body>
- <div class="wp">
- <div class="hd">
- <div class="logo"><img src="img/logo.png" /></div>
- <span class="y"> 欢迎您,<span id="user-name"></span>
- <span class="pipe">|</span><a href="login.html">退出</a>
- </span>
- </div>
- <div class="cont">
- <div class="title cl">
- <span class="y"><a href="index.html">返回考试主页</a></span>
- <h2>图片检查</h2>
- </div>
- <div class="picture cl">
- <table cellpadding="0" cellspacing="0" width="100%">
- <tr>
- <th>结果保存目录:</th>
- <td>
- <input id="path-text" type="text" style="width: 400px" class="filetext" />
- <a href="##" id="path-select" class="filebtn">选择</a>
- </td>
- </tr>
- <tr>
- <th>并发数:</th>
- <td><input id="concurrent-input" type="text" style="width: 100px" value="1" /></td>
- </tr>
- <tr id="message-tr" style="display: none">
- <th></th>
- <td>
- <p class="error-tetx" id="message-text"></p>
- </td>
- </tr>
- <tr>
- <th></th>
- <td><a id="run-button" href="##" class="start-btn"><span>开始检查</span></a></td>
- </tr>
- </table>
- </div>
- </div>
- <div class="ft">Copyright © 2011-2020 www.qmth.com.cn, All Rights Reserved</div>
- </div>
- <script>
- const $ = require('jquery')
- const env = require('../lib/env.js')
- const config = require('../lib/config.js')
- const {
- dialog
- } = require('electron').remote
- $(document).ready(() => {
- env.merge(JSON.parse(window.localStorage.getItem('env')))
- $('#user-name').html(env.user.userName)
- $('#path-select').click(() => {
- dialog.showOpenDialog({
- title: '请选择保存目录',
- properties: ['openDirectory']
- }, filePaths => {
- $('#path-text').val(filePaths[0])
- })
- })
- $('#run-button').click(() => {
- let dir = $('#path-text').val()
- let concurrent = $('#concurrent-input').val()
- if (dir == undefined || dir == '') {
- alert('请选择保存目录')
- return false
- }
- if (concurrent == undefined || concurrent == '') {
- alert('请填写并发数')
- return false
- }
- window.localStorage.setItem('check-config', JSON.stringify({
- dir: dir.trim(),
- concurrent: parseInt(concurrent)
- }))
- window.location.href = 'image-check.html'
- })
- })
- </script>
- </body>
- </html>
|