| @ -0,0 +1,9 @@ | |||
| import request from '@/utils/request' | |||
| export function home_count(query) { | |||
| return request({ | |||
| url: '/system/business/home/count', | |||
| method: 'get', | |||
| params: query | |||
| }) | |||
| } | |||
| @ -0,0 +1,9 @@ | |||
| export default { | |||
| jrxzbd: 'Recent Record', | |||
| ytjbd: 'Submitted', | |||
| dtjbd: 'Saved', | |||
| bzxzsy: 'Weekly New Study', | |||
| ywcsy: 'Completed Study', | |||
| xttz: 'Notification' | |||
| } | |||
| @ -1,32 +1,32 @@ | |||
| export default { | |||
| ysbh: 'Locker', | |||
| jyr: 'Key User', | |||
| zt: 'Status', | |||
| jyz: 'In Use', | |||
| wjy: 'Not in Use', | |||
| plgh: 'Batch Return', | |||
| zcg: 'Locker', | |||
| ys1jyr: 'Key 1 User', | |||
| ys2jyr: 'Key 2 User', | |||
| glyj: 'Contained Substance', | |||
| ysff: 'Issue Key', | |||
| gh: 'Return', | |||
| ysgh: 'Return Key', | |||
| ysghts:'请确认是否归还以下钥匙', | |||
| ghr1Id:'Key 1 Returner', | |||
| ghr1mm:'Key 1 Returner Password', | |||
| ghr2Id:'Key 2 Returner', | |||
| ghr2mm:'Key 2 Returner Password', | |||
| jsr:'接收人', | |||
| jsrmm:'接收人密码', | |||
| qmyy:'Purpose', | |||
| remark:'Comment', | |||
| lqr1Id:'Key 1 Recipient', | |||
| lqr1mm:'Key 1 Recipient Password', | |||
| lqr2Id:'Key 2 Recipient', | |||
| lqr2mm:'Key 2 Recipient Password', | |||
| ffr:'Issuer', | |||
| ffrmm:'Issuer Password', | |||
| qysff:'Key Distribution', | |||
| qysgh:'Return Key' | |||
| } | |||
| ysbh: 'Locker', | |||
| jyr: 'Key User', | |||
| zt: 'Status', | |||
| jyz: 'In Use', | |||
| wjy: 'Not in Use', | |||
| plgh: 'Batch Return', | |||
| zcg: 'Locker', | |||
| ys1jyr: 'Key 1 User', | |||
| ys2jyr: 'Key 2 User', | |||
| glyj: 'Contained Substance', | |||
| ysff: 'Issue Key', | |||
| gh: 'Return', | |||
| ysgh: 'Return Key', | |||
| ysghts: '请确认是否归还以下钥匙', | |||
| ghr1Id: 'Key 1 Returner', | |||
| ghr1mm: 'Key 1 Returner Password', | |||
| ghr2Id: 'Key 2 Returner', | |||
| ghr2mm: 'Key 2 Returner Password', | |||
| jsr: '接收人', | |||
| jsrmm: '接收人密码', | |||
| qmyy: 'Meaning of Signature', | |||
| remark: 'Comment', | |||
| lqr1Id: 'Key 1 Recipient', | |||
| lqr1mm: 'Key 1 Recipient Password', | |||
| lqr2Id: 'Key 2 Recipient', | |||
| lqr2mm: 'Key 2 Recipient Password', | |||
| ffr: 'Issuer', | |||
| ffrmm: 'Issuer Password', | |||
| qysff: 'Key Distribution', | |||
| qysgh: 'Return Key' | |||
| } | |||
| @ -1,20 +1,20 @@ | |||
| export default { | |||
| ffmc: 'Name', | |||
| cjr: 'Creator', | |||
| cjsj: 'Creation Date', | |||
| scff: 'Upload', | |||
| scwj: 'Upload File', | |||
| wjm:'Allowed Format: .pdf', | |||
| zt: 'Status', | |||
| yuedu: 'Read', | |||
| daochu: 'Download', | |||
| mc: 'Name', | |||
| ff: 'Method', | |||
| qmhz: '签名汇总', | |||
| yidu: 'Read', | |||
| weidu: 'Unread', | |||
| qmr: 'Signed By', | |||
| qmsj: 'Date', | |||
| qmyy: 'Purpose', | |||
| remark: 'Comment', | |||
| } | |||
| ffmc: 'Name', | |||
| cjr: 'Creator', | |||
| cjsj: 'Creation Date', | |||
| scff: 'Upload', | |||
| scwj: 'Upload File', | |||
| wjm: 'Allowed Format: .pdf', | |||
| zt: 'Status', | |||
| yuedu: 'Read', | |||
| daochu: 'Download', | |||
| mc: 'Name', | |||
| ff: 'Method', | |||
| qmhz: '签名汇总', | |||
| yidu: 'Read', | |||
| weidu: 'Unread', | |||
| qmr: 'Signed By', | |||
| qmsj: 'Date', | |||
| qmyy: 'Meaning of Signature', | |||
| remark: 'Comment' | |||
| } | |||
| @ -0,0 +1,9 @@ | |||
| export default { | |||
| jrxzbd: '今日新增表单', | |||
| ytjbd: '已提交表单', | |||
| dtjbd: '待提交表单', | |||
| bzxzsy: '本周新增试验', | |||
| ywcsy: '已完成试验', | |||
| xttz: '系统通知' | |||
| } | |||
| @ -0,0 +1,36 @@ | |||
| const CRYPTOJSKEY = '7LrjnqHv2mS5Qr5s' | |||
| import CryptoJS from 'crypto-js' | |||
| export function encrypt(plaintText) { | |||
| var plaintText = plaintText | |||
| var options = { | |||
| mode: CryptoJS.mode.ECB, | |||
| padding: CryptoJS.pad.Pkcs7 | |||
| } | |||
| var key = CryptoJS.enc.Utf8.parse(CRYPTOJSKEY) | |||
| var encryptedData = CryptoJS.AES.encrypt(plaintText, key, options) | |||
| var encryptedBase64Str = encryptedData.toString().replace(/\//g, '_') | |||
| encryptedBase64Str = encryptedBase64Str.replace(/\+/g, '-') | |||
| return encryptedBase64Str | |||
| } | |||
| export function decrypt(encryptedText) { | |||
| // 还原 URL 安全字符 | |||
| let encryptedBase64Str = encryptedText | |||
| .replace(/_/g, '/') // 还原 _ | |||
| .replace(/-/g, '+') // 还原 - | |||
| // 补充末尾的 =(如果需要) | |||
| const mod4 = encryptedBase64Str.length % 4 | |||
| if (mod4) { | |||
| encryptedBase64Str += '='.repeat(4 - mod4) | |||
| } | |||
| try { | |||
| const key = CryptoJS.enc.Utf8.parse(CRYPTOJSKEY) | |||
| const decrypt = CryptoJS.AES.decrypt(encryptedBase64Str, key, { | |||
| mode: CryptoJS.mode.ECB, | |||
| padding: CryptoJS.pad.Pkcs7 | |||
| }) | |||
| return CryptoJS.enc.Utf8.stringify(decrypt).toString() | |||
| } catch (e) { | |||
| console.error('解密失败:', e) | |||
| return null | |||
| } | |||
| } | |||
| @ -0,0 +1,116 @@ | |||
| <template> | |||
| <div> | |||
| <el-dialog :title="$t('page.business.study.studyFormPre.sqgb')" :visible.sync="open" width="500px" append-to-body | |||
| :close-on-click-modal="false"> | |||
| <el-form ref="form" :model="form" :rules="rules" label-width="120px"> | |||
| <div class="sbzdtcma"> <input type="text"> <input type="password"> </div> | |||
| <el-row> | |||
| <el-col :span="24"> | |||
| <el-form-item :label="$t('form.qmyy')" prop="qmyy"> | |||
| <el-input type="text" :value="form.qmyy" maxlength="50" disabled | |||
| :placeholder="$t('form.placeholderInput')" /> | |||
| </el-form-item> | |||
| </el-col> | |||
| </el-row> | |||
| <el-row> | |||
| <el-col :span="24"> | |||
| <el-form-item :label="$t('form.reason')" prop="remark"> | |||
| <el-input type="textarea" v-model="form.remark" :rows="5" maxlength="500" | |||
| :placeholder="$t('form.placeholderInput')"> | |||
| </el-input> | |||
| </el-form-item> | |||
| </el-col> | |||
| </el-row> | |||
| <el-row> | |||
| <el-col :span="24"> | |||
| <el-form-item :label="$t('form.signer')"> | |||
| <el-input type="text" v-model="nickName" maxlength="50" disabled | |||
| :placeholder="$t('form.placeholderInput')" /> | |||
| </el-form-item> | |||
| </el-col> | |||
| </el-row> | |||
| <el-row> | |||
| <el-col :span="24"> | |||
| <el-form-item :label="$t('form.password')" prop="qmrmm"> | |||
| <el-input type="password" v-model="form.qmrmm" maxlength="20" | |||
| :placeholder="$t('form.placeholderInput')" /> | |||
| </el-form-item> | |||
| </el-col> | |||
| </el-row> | |||
| </el-form> | |||
| <div slot="footer" class="dialog-footer"> | |||
| <el-button type="primary" @click="save">{{ $t('form.confirm') }}</el-button> | |||
| <el-button @click="cancel">{{ $t('form.cancel') }}</el-button> | |||
| </div> | |||
| </el-dialog> | |||
| </div> | |||
| </template> | |||
| <script> | |||
| import { studyFormPre_sqgb } from "@/api/business/study/studyFormPre" | |||
| import { mapGetters } from 'vuex' | |||
| export default { | |||
| name: "Sqgb", | |||
| components: {}, | |||
| data() { | |||
| return { | |||
| isBatch: false, | |||
| ids: [], | |||
| selectList: [], | |||
| open: false, | |||
| form: {}, | |||
| rules: { | |||
| qmrmm: [{ | |||
| required: true, | |||
| message: ' ', | |||
| trigger: 'blur' | |||
| }], | |||
| remark: [{ | |||
| required: true, | |||
| message: ' ', | |||
| trigger: 'blur' | |||
| }], | |||
| } | |||
| } | |||
| }, | |||
| computed: { | |||
| ...mapGetters([ | |||
| 'nickName','name' | |||
| ]), | |||
| }, | |||
| created() { | |||
| }, | |||
| methods: { | |||
| cancel() { | |||
| this.open = false | |||
| }, | |||
| reset() { | |||
| this.form = { | |||
| id: null, | |||
| qmyy: this.$t('page.business.study.studyFormPre.sqgb'), | |||
| remark: null, | |||
| qmrmm: null | |||
| } | |||
| this.resetForm("form") | |||
| }, | |||
| show(row) { | |||
| this.reset() | |||
| this.form.id = row.id | |||
| this.open = true | |||
| }, | |||
| save() { | |||
| this.$refs["form"].validate(valid => { | |||
| if (valid) { | |||
| studyFormPre_sqgb(this.form).then(response => { | |||
| this.open = false | |||
| this.$emit('callback') | |||
| }).finally(() => { | |||
| this.$modal.closeLoading() | |||
| }) | |||
| } | |||
| }) | |||
| } | |||
| } | |||
| } | |||
| </script> | |||
| @ -0,0 +1,132 @@ | |||
| <template> | |||
| <div> | |||
| <el-dialog :title="$t('page.business.study.studyFormPre.qrgb')" :visible.sync="open" width="500px" append-to-body | |||
| :close-on-click-modal="false"> | |||
| <el-form ref="form" :model="form" :rules="rules" label-width="120px"> | |||
| <div class="sbzdtcma"> <input type="text"> <input type="password"> </div> | |||
| <el-row> | |||
| <el-col :span="24"> | |||
| <el-form-item :label="$t('form.qmyy')" prop="qmyy"> | |||
| <el-input type="text" :value="form.qmyy" maxlength="50" disabled | |||
| :placeholder="$t('form.placeholderInput')" /> | |||
| </el-form-item> | |||
| </el-col> | |||
| </el-row> | |||
| <el-row> | |||
| <el-col :span="24"> | |||
| <el-form-item :label="$t('form.reason')" prop="remark"> | |||
| <el-input type="textarea" v-model="form.remark" :rows="5" maxlength="500" | |||
| :placeholder="$t('form.placeholderInput')"> | |||
| </el-input> | |||
| </el-form-item> | |||
| </el-col> | |||
| </el-row> | |||
| <el-row> | |||
| <el-col :span="24"> | |||
| <el-form-item :label="$t('form.signer')"> | |||
| <el-input type="text" v-model="nickName" maxlength="50" disabled | |||
| :placeholder="$t('form.placeholderInput')" /> | |||
| </el-form-item> | |||
| </el-col> | |||
| </el-row> | |||
| <el-row> | |||
| <el-col :span="24"> | |||
| <el-form-item :label="$t('form.password')" prop="qmrmm"> | |||
| <el-input type="password" v-model="form.qmrmm" maxlength="20" | |||
| :placeholder="$t('form.placeholderInput')" /> | |||
| </el-form-item> | |||
| </el-col> | |||
| </el-row> | |||
| </el-form> | |||
| <div slot="footer" class="dialog-footer" style="text-align: center !important;"> | |||
| <el-button type="danger" @click="reject">{{ $t('page.business.study.studyFormPre.reject') }}</el-button> | |||
| <el-button type="primary" @click="approve">{{ $t('page.business.study.studyFormPre.approve') }}</el-button> | |||
| </div> | |||
| </el-dialog> | |||
| </div> | |||
| </template> | |||
| <script> | |||
| import { studyFormPre_tygb,studyFormPre_jjgb } from "@/api/business/study/studyFormPre" | |||
| import { mapGetters } from 'vuex' | |||
| export default { | |||
| name: "Qrfz", | |||
| components: {}, | |||
| data() { | |||
| return { | |||
| isBatch: false, | |||
| ids: [], | |||
| selectList: [], | |||
| open: false, | |||
| form: {}, | |||
| rules: { | |||
| qmrmm: [{ | |||
| required: true, | |||
| message: ' ', | |||
| trigger: 'blur' | |||
| }], | |||
| remark: [{ | |||
| required: true, | |||
| message: ' ', | |||
| trigger: 'blur' | |||
| }], | |||
| } | |||
| } | |||
| }, | |||
| computed: { | |||
| ...mapGetters([ | |||
| 'nickName','name' | |||
| ]), | |||
| }, | |||
| created() { | |||
| }, | |||
| methods: { | |||
| cancel() { | |||
| this.open = false | |||
| }, | |||
| reset() { | |||
| this.form = { | |||
| id: null, | |||
| qmyy: this.$t('page.business.study.studyFormPre.gbtgjj'), | |||
| remark: null, | |||
| qmrmm: null | |||
| } | |||
| this.resetForm("form") | |||
| }, | |||
| show(row) { | |||
| this.reset() | |||
| this.form.id = row.id | |||
| this.open = true | |||
| }, | |||
| reject() { | |||
| this.$refs["form"].validate(valid => { | |||
| if (valid) { | |||
| this.$modal.loading() | |||
| studyFormPre_jjgb(this.form).then(response => { | |||
| this.open = false | |||
| this.$emit('callback') | |||
| this.$modal.closeLoading() | |||
| }).finally(() => { | |||
| this.$modal.closeLoading() | |||
| }) | |||
| } | |||
| }) | |||
| }, | |||
| approve() { | |||
| this.$refs["form"].validate(valid => { | |||
| if (valid) { | |||
| this.$modal.loading() | |||
| studyFormPre_tygb(this.form).then(response => { | |||
| this.open = false | |||
| this.$emit('callback') | |||
| this.$modal.closeLoading() | |||
| }).finally(() => { | |||
| this.$modal.closeLoading() | |||
| }) | |||
| } | |||
| }) | |||
| } | |||
| } | |||
| } | |||
| </script> | |||
| @ -1,21 +1,137 @@ | |||
| <template> | |||
| <div class="app-container home"> | |||
| <h1>{{ $t('system.title') }}</h1> | |||
| <el-card class="box-card home-top"> | |||
| <div class="count-box"> | |||
| <div class="count-item"> | |||
| <div class="count-left"> | |||
| <img src="@/assets/images/home-icon1.jpg" /> | |||
| </div> | |||
| <div class="count-right"> | |||
| <div class="count-count">{{count.formTodayCount}}</div> | |||
| <div class="count-tip">{{$t('page.business.home.jrxzbd')}}</div> | |||
| </div> | |||
| </div> | |||
| <div class="count-item"> | |||
| <div class="count-left"> | |||
| <img src="@/assets/images/home-icon1.jpg" /> | |||
| </div> | |||
| <div class="count-right"> | |||
| <div class="count-count">{{count.formYtjCount}}</div> | |||
| <div class="count-tip">{{$t('page.business.home.ytjbd')}}</div> | |||
| </div> | |||
| </div> | |||
| <div class="count-item"> | |||
| <div class="count-left"> | |||
| <img src="@/assets/images/home-icon1.jpg" /> | |||
| </div> | |||
| <div class="count-right"> | |||
| <div class="count-count">{{count.formTbzCount}}</div> | |||
| <div class="count-tip">{{$t('page.business.home.dtjbd')}}</div> | |||
| </div> | |||
| </div> | |||
| <div class="count-item"> | |||
| <div class="count-left"> | |||
| <img src="@/assets/images/home-icon1.jpg" /> | |||
| </div> | |||
| <div class="count-right"> | |||
| <div class="count-count">{{count.studyFinishCount}}</div> | |||
| <div class="count-tip">{{$t('page.business.home.bzxzsy')}}</div> | |||
| </div> | |||
| </div> | |||
| <div class="count-item"> | |||
| <div class="count-left"> | |||
| <img src="@/assets/images/home-icon1.jpg" /> | |||
| </div> | |||
| <div class="count-right"> | |||
| <div class="count-count">{{count.studyWeekCount}}</div> | |||
| <div class="count-tip">{{$t('page.business.home.ywcsy')}}</div> | |||
| </div> | |||
| </div> | |||
| </div> | |||
| </el-card> | |||
| <el-card class="box-card home-content"> | |||
| </el-card> | |||
| </div> | |||
| </template> | |||
| <script> | |||
| import { home_count} from "@/api/business/home/home"; | |||
| export default { | |||
| name: "Index", | |||
| data() { | |||
| return { | |||
| count:{ | |||
| formTodayCount:'', | |||
| formYtjCount:'', | |||
| formTbzCount:'', | |||
| studyFinishCount:'', | |||
| studyWeekCount:'', | |||
| }, | |||
| } | |||
| }, | |||
| created(){ | |||
| this.getCount() | |||
| }, | |||
| methods: { | |||
| getCount(){ | |||
| this.count = { | |||
| formTodayCount:'', | |||
| formYtjCount:'', | |||
| formTbzCount:'', | |||
| studyFinishCount:'', | |||
| studyWeekCount:'', | |||
| } | |||
| this.$modal.loading() | |||
| home_count().then(response => { | |||
| this.count = response.data | |||
| }) | |||
| .finally(() => { | |||
| this.$modal.closeLoading() | |||
| }) | |||
| } | |||
| } | |||
| } | |||
| </script> | |||
| <style scoped lang="scss"> | |||
| .home{ | |||
| .home-top{ | |||
| margin-bottom: 20px; | |||
| .count-box{ | |||
| display: flex; | |||
| flex-direction: row; | |||
| align-items: center; | |||
| .count-item{ | |||
| flex-shrink: 0; | |||
| width: 20%; | |||
| display: flex; | |||
| flex-direction: row; | |||
| align-items: center; | |||
| .count-left{ | |||
| flex-shrink: 0; | |||
| img{ | |||
| width: 60px; | |||
| } | |||
| } | |||
| .count-right{ | |||
| flex-grow: 1; | |||
| margin-left: 20px; | |||
| .count-count{ | |||
| font-size: 20px; | |||
| font-weight: bold; | |||
| } | |||
| .count-tip{ | |||
| margin-top: 10px; | |||
| } | |||
| } | |||
| } | |||
| } | |||
| } | |||
| .home-content{ | |||
| min-height: 400px; | |||
| } | |||
| } | |||
| </style> | |||