| | |
| | | </el-table-column> |
| | | </el-table> |
| | | |
| | | <pagination v-show="total>0" :total="total" :page.sync="searchForm.pageIndex" |
| | | <pagination v-show="total>0" :total="total" :page.sync="searchForm.currentPage" |
| | | :limit.sync="searchForm.pageSize" |
| | | @pagination="page"/> |
| | | <el-dialog |
| | |
| | | :title="title" |
| | | :visible.sync="open" |
| | | width="700px" |
| | | :before-close="handleClose"> |
| | | :before-close="handleClose" |
| | | :close-on-click-modal="false"> |
| | | <el-form :model="form" :rules="rules" ref="form" label-width="100px" class="demo-ruleForm"> |
| | | <el-form-item label="班级名称" prop="className"> |
| | | <el-input v-model="form.className" size="small"></el-input> |
| | |
| | | status: '', |
| | | subject: null, |
| | | pageSize: 10, |
| | | pageNum: 1 |
| | | currentPage: 1 |
| | | }, |
| | | form: { |
| | | id: null, |
| | |
| | | this.form = row |
| | | this.open = true |
| | | }, |
| | | handleClose () { |
| | | handleClose (done) { |
| | | this.open = false |
| | | this.resetForm() |
| | | done() |
| | | }, |
| | | handlerAdd () { |
| | | this.open = true |
| | |
| | | class="block" |
| | | style="display: flex; margin-top: 40px;" |
| | | > |
| | | <pagination v-show="total>0" :total="total" :page.sync="searchForm.pageNum" |
| | | <pagination v-show="total>0" :total="total" :page.sync="searchForm.currentPage" |
| | | :limit.sync="searchForm.pageSize" |
| | | @pagination="page"/> |
| | | </div> |
| | |
| | | :title="studentTitle" |
| | | :visible.sync="addOpen" |
| | | width="700px" |
| | | :before-close="handleAddClose"> |
| | | :before-close="handleAddClose" |
| | | :close-on-click-modal="false"> |
| | | <el-form :model="studentForm" :rules="studentRules" ref="studentForm" label-width="100px" class="demo-ruleForm"> |
| | | <el-form-item label="学号" prop="id" v-show="false"/> |
| | | <el-form-item label="姓名" prop="realName"> |
| | | <el-input v-model="studentForm.realName"></el-input> |
| | | </el-form-item> |
| | |
| | | <script> |
| | | // 引入彈出窗口組件 |
| | | import UserApi from '@/api/user' |
| | | import { updateClassesUser, getClassesUsers, deleteClassesUserById, addClassesUser, edit } from '@/api/classesUser' |
| | | import { |
| | | updateClassesUser, |
| | | getClassesUsers, |
| | | deleteClassesUserById, |
| | | addClassesUser, |
| | | edit, |
| | | editClassesUser |
| | | } from '@/api/classesUser' |
| | | import Pagination from '@/components/Pagination' |
| | | |
| | | export default { |
| | |
| | | data () { |
| | | return { |
| | | studentForm: { |
| | | id: null, |
| | | realName: '', |
| | | sex: 1, |
| | | phone: '', |
| | |
| | | searchForm: { |
| | | studentName: '', |
| | | pageSize: 10, |
| | | pageNum: 1, |
| | | currentPage: 1, |
| | | classesId: null |
| | | }, |
| | | classes: { |
| | |
| | | }, |
| | | submitStudentForm () { |
| | | this.$refs['studentForm'].validate((valid) => { |
| | | console.log(this.studentForm) |
| | | if (valid) { |
| | | this.studentForm.classesId = this.classes.id |
| | | if (this.studentForm.id) { |
| | | edit(this.studentForm).then(res => { |
| | | editClassesUser(this.studentForm).then(res => { |
| | | this.addOpen = false |
| | | this.$message.success(res.data.message) |
| | | this.page() |
| | | this.resetStudentForm() |
| | | }) |
| | | }else { |
| | | addClassesUser(this.studentForm).then(res => { |
| | | this.addOpen = false |
| | | this.$message.success(res.data.message) |
| | | this.page() |
| | | this.resetStudentForm() |
| | | }) |
| | | } |
| | | addClassesUser(this.studentForm).then(res => { |
| | | this.addOpen = false |
| | | this.$message.success(res.data.message) |
| | | this.page() |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | |
| | | this.searchForm.classesId = this.classes.id |
| | | getClassesUsers(this.searchForm).then(res => { |
| | | this.tableData = res.data.data |
| | | this.total = res.data.total |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | submitForm () { |
| | |
| | | </template> |
| | | </el-table-column> --> |
| | | </el-table> |
| | | <pagination v-show="total > 0" :total="total" :page.sync="queryParam.pageIndex" :limit.sync="queryParam.pageSize" |
| | | <pagination v-show="total > 0" :total="total" :page.sync="queryParam.currentPage" :limit.sync="queryParam.pageSize" |
| | | @pagination="search" /> |
| | | |
| | | <el-dialog :visible.sync="visible" width="400px"> |
| | |
| | | listLoading: true, |
| | | queryParam: { |
| | | name: '', |
| | | pageIndex: 1, |
| | | currentPage: 1, |
| | | pageSize: 10 |
| | | }, |
| | | formLoading: false, |
| | |
| | | this.$message.success('删除成功') |
| | | this.ids = [] |
| | | } |
| | | this.page() |
| | | }) |
| | | } |
| | | }, |
| | |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | | <el-table v-loading="listLoading" :data="tableData" border fit highlight-current-row style="width: 100%"> |
| | | <el-table v-loading="listLoading" :data="tableData" border fit highlight-current-row style="width: 100%"> |
| | | <el-table-column align="center" prop="name" label="名称" show-overflow-tooltip /> |
| | | <el-table-column align="center" prop="itemOrder" label="排序" /> |
| | | <el-table-column align="center" prop="createTime" label="创建时间" /> |
| | |
| | | <pagination v-show="total > 0" :total="total" :page.sync="queryParam.pageIndex" :limit.sync="queryParam.pageSize" |
| | | @pagination="search" /> |
| | | |
| | | <el-dialog :visible.sync="visible" width="400px"> |
| | | <el-dialog :visible.sync="visible" :close-on-click-modal="false" width="400px"> |
| | | <el-form :model="form" ref="form" label-width="100px" v-loading="formLoading" :rules="rules"> |
| | | <el-form-item label="名称:" prop="name" required> |
| | | <el-input v-model="form.name" maxlength="10" show-word-limit /> |
| | |
| | | if (re.code === 1) { |
| | | this.form = re.data; |
| | | this.visible = true; |
| | | this.resetForm(); |
| | | } else { |
| | | this.$message.error(re.message) |
| | | } |
| | |
| | | } else { |
| | | this.getItemOrder(); |
| | | this.visible = true; |
| | | this.resetForm(); |
| | | } |
| | | }, |
| | | status(row) { |
| | |
| | | <el-button v-if="scope.row.status === 'finished'" type="success" size="small" @click="markPaper(scope.row)"> |
| | | 阅卷 |
| | | </el-button> |
| | | <el-button type="danger" size="small" @click="deleteExam(scope.row)">删除</el-button> |
| | | <el-button type="warning" size="small" @click="monitor(scope.row)">监控</el-button> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | > |
| | | <el-table-column |
| | | align="center" |
| | | prop="id" |
| | | prop="userId" |
| | | label="学号" |
| | | > |
| | | </el-table-column> |
| | |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <pagination v-show="total > 0" :total="total" :page.sync="queryParam.pageIndex" :limit.sync="queryParam.pageSize" |
| | | <pagination v-show="total > 0" :total="total" :page.sync="queryParam.currentPage" :limit.sync="queryParam.pageSize" |
| | | @pagination="search"/> |
| | | |
| | | <el-dialog :visible.sync="visible" width="400px"> |
| | |
| | | listLoading: true, |
| | | queryParam: { |
| | | examId: '', |
| | | pageIndex: 1, |
| | | currentPage: 1, |
| | | pageSize: 10 |
| | | }, |
| | | formLoading: false, |
| | |
| | | <el-form-item label="用户Id:"> |
| | | <el-input v-model="queryParam.userId"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="用户名:"> |
| | | <el-input v-model="queryParam.userName"></el-input> |
| | | <el-form-item label="真实姓名:"> |
| | | <el-input v-model="queryParam.realName"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" @click="submitForm">查询</el-button> |
| | |
| | | userId: null, |
| | | userName: null, |
| | | pageIndex: 1, |
| | | pageSize: 10 |
| | | pageSize: 10, |
| | | realName: null |
| | | }, |
| | | listLoading: true, |
| | | tableData: [], |
| | |
| | | <el-form-item label="登录账号:" prop="userName" required> |
| | | <el-input v-model="form.userName" autocomplete="off"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="登录密码:" prop="password" required> |
| | | <el-form-item label="登录密码:" prop="password" v-if="form.id === null" required> |
| | | <el-input v-model="form.password" show-password autocomplete="off"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="年龄:"> |
| | |
| | | <router-link :to="{path:'/user/student/edit'}" class="link-left"> |
| | | <el-button type="primary">添加</el-button> |
| | | </router-link> |
| | | <el-button class="link-left" type="success" @click="exportExcel">导入模板</el-button> |
| | | <el-button class="link-left" type="danger" @click="exportExcel">下载模板</el-button> |
| | | <el-upload |
| | | class="link-left" |
| | | style="display: inline;" |