Administrator
2021-11-04 24445581c6bef5afa0d1b127aca3610080e6f1f5
成绩修改管理修改
4 files modified
165 ■■■■■ changed files
src/api/examapi/modifiedGrades.js 36 ●●●●● patch | view | raw | blame | history
src/views/accreditationRecords/accreditationRecords.vue 61 ●●●● patch | view | raw | blame | history
src/views/securityGuard/securityCertificate.vue 44 ●●●● patch | view | raw | blame | history
src/views/trainExam/modifiedGrades.vue 24 ●●●● patch | view | raw | blame | history
src/api/examapi/modifiedGrades.js
@@ -1,21 +1,29 @@
import request from '@/router/axios';
export const getList = (current, size, params) => {
  return request({
    url: '/api/scoreAuditRecords/page',
    method: 'get',
    params: {
      ...params,
      current,
      size
    }
  })
    return request({
        url: '/api/scoreAuditRecords/page',
        method: 'get',
        params: {
            ...params,
            current,
            size
        }
    })
}
export const update = (row) => {
  return request({
    url: '/api/scoreAuditRecords/update',
    method: 'post',
    data: row
  })
    return request({
        url: '/api/scoreAuditRecords/update',
        method: 'post',
        data: row
    })
}
export const applyAudit = (row) => {
    return request({
        url: '/api/scoreAuditRecords/applyAudit',
        method: 'post',
        data: row
    })
}
src/views/accreditationRecords/accreditationRecords.vue
@@ -126,7 +126,7 @@
        dialogClickModal: false,
        column: [
          {
            label: "通知时间",
            label: "申请时间",
            prop: "releaseTimeRange",
            type: "datetime",
            format: "yyyy-MM-dd",
@@ -141,7 +141,7 @@
            rules: [
              {
                required: true,
                message: "请输入通知时间",
                message: "请输入申请时间",
                trigger: "blur",
              },
            ],
@@ -187,6 +187,7 @@
              slot: true,
              searchSpan: 5,
              search: true,
              overHidden: true,
              minWidth: 200
          },
          {
@@ -208,6 +209,12 @@
            prop: "age",
          },
          {
            label: "照片",
            prop: "avatar",
            type: "upload",
            listType: "picture-img",
          },
          {
            label: "保安证编号",
            prop: "securityNumber",
            search: true,
@@ -218,6 +225,7 @@
            editDisplay: false,
            // hide: true,
          },
          // {
          //   label: "申请人",
          //   prop: "createUser",
@@ -239,6 +247,33 @@
            addDisplay: false,
            editDisplay: false,
            // hide: true,
          },
          {
            label: "有无照片",
            prop: "isAvatar",
            type: "select",
            search:true,
            searchLabelWidth: 90,
            minWidth: 105,
            searchSpan: 3,
            addDisplay: false,
            editDisplay: false,
            hide: true,
            display: false,
            dicData:[
              {
                label:"全部",
                value:3
              },
              {
                label:"有",
                value:1
              },
              {
                label:"无",
                value:2
              }
            ]
          },
        ],
      },
@@ -454,7 +489,7 @@
        type: "warning",
      }).then(() => {
        //获取查询条件
        console.log(this.questionBankSearch, 456);
        // console.log(this.questionBankSearch, 456);
        const { releaseTimeRange } = this.questionBankSearch;
        if (releaseTimeRange) {
            this.questionBankSearch['startTime'] = releaseTimeRange[0];
@@ -465,22 +500,22 @@
          idCardNo: this.questionBankSearch.idCardNo,
          realName: this.questionBankSearch.realName,
          securityNumber: this.questionBankSearch.securityNumber,
          startTime: this.questionBankSearch.securityName,
          endTime: this.questionBankSearch.examName,
          startTime: this.questionBankSearch.startTime,
          endTime: this.questionBankSearch.endTime,
        };
        //导出
        if (
          this.userInfo.role_name == "保安公司管理员" ||
          this.userInfo.role_name == "保安"
        ) {
          //如果是保安公司管理员
          data["deptId"] = this.userInfo.dept_id;
        }
        // if (
        //   this.userInfo.role_name == "保安公司管理员" ||
        //   this.userInfo.role_name == "保安"
        // ) {
        //   //如果是保安公司管理员
        //   data["deptId"] = this.userInfo.dept_id;
        // }
        if (this.userInfo.role_name == "培训公司管理员") {
          //如果是培训公司管理员
          data["trainUnitId"] = this.userInfo.dept_id;
        }
        data["examType"] = 2;
        // data["examType"] = 2;
        //序列号url形式,用&拼接
        data = Qs.stringify(data);
        window.open(`/api/accreditationRecords/export-security-paper?` + data);
src/views/securityGuard/securityCertificate.vue
@@ -61,6 +61,9 @@
<script>
import { mapGetters } from "vuex";
import dictVertical from "../util/demo/dict-vertical.vue";
import {
  update
} from "@/api/system/user";
export default {
    data () {
        return {
@@ -84,6 +87,8 @@
                this.$message({ message: '请完善住址信息', type: 'warning' })
                return
            }
            //更新发证时间
            this.updateUserInfo();
            var printDom = document.getElementById("securityCertificate");
            printDom.style.position = "fixed";
            printDom.style.top = "-28.5%";
@@ -109,6 +114,21 @@
             */
            return [oneHoursAgoY, oneHoursAgoM]
        },
        //更新用户发证时间
        updateUserInfo(){
            var nowTime = new Date()
            var oneHoursAgo = new Date(new Date(nowTime).getTime() - 1 * 60 * 60 * 1000)
            var oneHoursAgoY = oneHoursAgo.getFullYear()
            var oneHoursAgoM = oneHoursAgo.getMonth() + 1 < 10 ? '0' + (oneHoursAgo.getMonth() + 1) : oneHoursAgo.getMonth() + 1
            var day = oneHoursAgo.getDay();
            var date = oneHoursAgoY + "-" + oneHoursAgoM + "-" + day;
            const data = {
                id:this.data.id,
                rtime:this.data.rtime,
                paperTime:date
            }
            update(data);
        }
    },
};
</script>
@@ -151,8 +171,8 @@
//发证公安机关&nbsp;(印章)
.security_m_l_center {
    position: absolute;
    top: $downTop;
    left: 15px;
    top: 270px;
    left: 30px;
    line-height: 40px;
}
//证件编号 &nbsp;
@@ -197,7 +217,7 @@
//公民身份证
.security_m_r_d {
    position: absolute;
    top: $downTop + $lineHigeht * 4;
    top: 363px;
    left: $rightLeft;
    width: $rightWidth;
    text-align: justify;
@@ -228,19 +248,19 @@
    letter-spacing: 3px;
}
//发证时间
$timeTop: 299px; //整体高度
$timeTop: 309px; //整体高度
//年
.security_m_l_titlepaperTimenian {
    position: absolute;
    top: $timeTop;
    left: 95px;
    left: 110px;
    line-height: 40px;
}
//月
.security_m_l_titlepaperTimeyue {
    position: absolute;
    top: $timeTop;
    left: 154px;
    left: 169px;
    line-height: 40px;
}
//日
@@ -254,29 +274,29 @@
.security_m_l_downsecuritynumber {
    position: absolute;
    top: 379px; //整体高度
    left: 125px;
    left: 145px;
}
//内容
// 姓名
$centerLeft: 450px;
$centerLeft: 458px;
.security_m_r_o_right {
    position: absolute;
    top: $downTop + $lineHigeht*0+ 0px;
    top: $downTop + $lineHigeht*0-2px;
    left: $centerLeft;
    // width: $rightWidth;
}
// 生日
.security_m_r_o_rightbirthday {
    position: absolute;
    top: $downTop + $lineHigeht * 1-2px;
    top: $downTop + $lineHigeht * 1-4px;
    left: $centerLeft;
    // width: $rightWidth;
}
// 地址
.security_m_r_o_rightaddress {
    position: absolute;
    top: $downTop + $lineHigeht * 2 -4px;
    top: $downTop + $lineHigeht * 2 -6px;
    left: $centerLeft;
    width: 160px;
    font: bold 16px 'SimSun' !important;
@@ -284,7 +304,7 @@
// 身份证
.security_m_r_o_rightcardid {
    position: absolute;
    top: $downTop + $lineHigeht * 4 +6px;
    top: $downTop + $lineHigeht * 4 -12px;
    left: $centerLeft;
    // width: $rightWidth;
}
src/views/trainExam/modifiedGrades.vue
@@ -3,7 +3,7 @@
 * @Date: 2021-07-05 16:31:54
 * @Last Modified by: Morpheus
 * @Last Modified time: 2021-11-04 18:54:44
 * menu-name 成绩管理
 * menu-name 成绩修改管理
 */
<template>
    <el-row class="morpheus-box">
@@ -52,7 +52,7 @@
                            <el-button :type="type"
                                       :size="size"
                                       icon="el-icon-folder-checked"
                                       v-if="permission.trainExam_check"
                                       v-if="permission.score_audit_check"
                                       @click="handleAudit(row)">审核
                            </el-button>
                        </template>
@@ -79,7 +79,7 @@
</template>
<script>
import { getList, update } from "@/api/examapi/modifiedGrades";
import { getList, update,applyAudit } from "@/api/examapi/modifiedGrades";
import { mapGetters } from "vuex";
import { getRoleDetail } from "@/api/system/role";
export default {
@@ -315,7 +315,7 @@
                    },
                    {
                        label: "现理论成绩",
                        label: "修改后理论成绩",
                        prop: "newScore",
                        slot: true,
                        // 表单新增时是否禁止
@@ -476,16 +476,12 @@
            return {
                addBtn: this.vaildData(null, false),
                viewBtn: this.vaildData(
                    this.permission.trainExam_performance_view,
                    this.permission.score_audit_view,
                    false
                ),
                delBtn: this.vaildData(null, false),
                editBtn: this.vaildData(
                    this.permission.trainExam_performance_edit,
                    false
                ),
                excelBtn: this.vaildData(
                    this.permission.trainExam_performance_export,
                    this.permission.score_audit_edit,
                    false
                ),
            };
@@ -517,8 +513,14 @@
        submit (row, done, loading) {
            row.auditTime = this.getNewTime()
            const data  = {
                id:row.id,
                status:row.status,
                auditDetail:row.auditDetail,
                auditUser:this.userInfo.Id
            }
            update(row).then(
            applyAudit(data).then(
                () => {
                    this.dialogFormVisible = false;
                    this.questionBankOnLoad(this.questionBankPage);