封装axios和接取项目选择与项目详情开始计时等,个人业务活期开户业务提交,个人客户信息建立提交功能

20240205
e 3 years ago
parent e032f0a6c0
commit dc6f9b1563
  1. 15
      package-lock.json
  2. 2
      package.json
  3. 87
      src/api/api.js
  4. 14
      src/api/http.js
  5. 309
      src/components/case/index.vue
  6. 2
      src/main.js
  7. 12
      src/pages/counter/list/index.vue
  8. 4
      src/pages/index/list/index.vue
  9. 79
      src/pages/manage/list/client/consumerClient.vue
  10. 130
      src/pages/manage/list/personal/currentAccount/openAccount.vue
  11. 2
      src/pages/manage/navbar/index.vue
  12. 22
      vue.config.js

15
package-lock.json generated

@ -2366,8 +2366,8 @@
},
"axios": {
"version": "0.18.1",
"resolved": "https://registry.npmjs.org/axios/-/axios-0.18.1.tgz",
"integrity": "sha512-0BfJq4NSfQXd+SkFdrvFbG7addhYSBA2mQwISr46pD6E5iqkWg02RAs8vyTT/j0RTnoYmeXauBuSv1qKwR179g==",
"resolved": "https://registry.npmmirror.com/axios/download/axios-0.18.1.tgz?cache=0&sync_timestamp=1634053173003&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Faxios%2Fdownload%2Faxios-0.18.1.tgz",
"integrity": "sha1-/z8N4ue10YDnV62YAA8Qgbh7zqM=",
"requires": {
"follow-redirects": "1.5.10",
"is-buffer": "^2.0.2"
@ -7621,9 +7621,9 @@
}
},
"is-buffer": {
"version": "2.0.4",
"resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz",
"integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A=="
"version": "2.0.5",
"resolved": "https://registry.npm.taobao.org/is-buffer/download/is-buffer-2.0.5.tgz?cache=0&sync_timestamp=1604429452232&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fis-buffer%2Fdownload%2Fis-buffer-2.0.5.tgz",
"integrity": "sha1-68JS5ADSL/jXf6CYiIIaJKZYwZE="
},
"is-callable": {
"version": "1.1.4",
@ -13754,11 +13754,6 @@
"integrity": "sha512-BXq3jwIagosjgNVae6tkHzzIk6a8MHFtzAdwhnV5VlvPTFxDCvIttgSiHWjdGoTJvXtmRu5HacExfdarRcFhog==",
"dev": true
},
"vue-i18n": {
"version": "8.15.1",
"resolved": "https://registry.npmjs.org/vue-i18n/-/vue-i18n-8.15.1.tgz",
"integrity": "sha512-GBbz8qYCu0U2LNu4IcuFLZiuyninG4k26knvhL7GZG5Ncp4RR2VKDEH6g8gQ6I+UUBCvH2MBQVPSdxWe4DBkPw=="
},
"vue-loader": {
"version": "15.7.2",
"resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-15.7.2.tgz",

@ -10,7 +10,7 @@
"dependencies": {
"@tailwindcss/postcss7-compat": "^2.2.7",
"autoprefixer": "^9.8.6",
"axios": "^0.18.0",
"axios": "^0.18.1",
"babel-polyfill": "^6.26.0",
"echarts": "^4.8.0",
"element-theme": "^2.0.1",

@ -0,0 +1,87 @@
import axios from 'axios';
import router from '../router';
// 创建axios实例
const service = axios.create({
baseURL: 'http://192.168.31.125:9000',
timeout: 30000 // 请求超时时间
})
// 添加request拦截器
service.interceptors.request.use(config => {
return config
}, error => {
Promise.reject(error)
})
// 添加respone拦截器
service.interceptors.response.use(
response => {
let res={};
res.status=response.status
res.data=response.data;
return res;
},
error => {
if(error.response && error.response.status == 404){
router.push('/blank.vue')
}
return Promise.reject(error.response)
}
)
export function get(url, params = {}) {
// params.t = new Date().getTime(); //get方法加一个时间参数,解决ie下可能缓存问题.
return service({
url: url,
method: 'get',
headers: {
token:'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1c2VyIiwiaWF0IjoxNjM1MjEyMTYyLCJleHAiOjE2MzUyNTUzNjIsImFjY291bnRJZCI6IjIifQ.KjuoWp27gQwILUl0KsfxiyOwO45lADTS6ODO-x2KdJI'
},
params
})
}
//封装post请求
export function post(url, data = {}) {
//默认配置
let sendObject={
url: url,
method: 'post',
headers: {
'Content-Type':'application/json;charset=UTF-8',
token:'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1c2VyIiwiaWF0IjoxNjM1MjEyMTYyLCJleHAiOjE2MzUyNTUzNjIsImFjY291bnRJZCI6IjIifQ.KjuoWp27gQwILUl0KsfxiyOwO45lADTS6ODO-x2KdJI'
},
data:data
};
sendObject.data=JSON.stringify(data);
return service(sendObject)
}
//封装put方法 (resfulAPI常用)
export function put(url,data = {}){
return service({
url: url,
method: 'put',
headers: {
'Content-Type':'application/json;charset=UTF-8',
token:'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1c2VyIiwiaWF0IjoxNjM1MjEyMTYyLCJleHAiOjE2MzUyNTUzNjIsImFjY291bnRJZCI6IjIifQ.KjuoWp27gQwILUl0KsfxiyOwO45lADTS6ODO-x2KdJI'
},
data:JSON.stringify(data)
})
}
//删除方法(resfulAPI常用)
export function deletes(url){
return service({
url: url,
method: 'delete',
headers: {
token:'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJ1c2VyIiwiaWF0IjoxNjM1MjEyMTYyLCJleHAiOjE2MzUyNTUzNjIsImFjY291bnRJZCI6IjIifQ.KjuoWp27gQwILUl0KsfxiyOwO45lADTS6ODO-x2KdJI'
}
})
}
//不要忘记export
export {
service
}

@ -0,0 +1,14 @@
// 引入封装好的axios
// ps:如果没有封装,正常引入axios即可
import {get, post,deletes,put} from './api.js'
// import axios from "./";
// /api为配置跨域的路径变量
export const getProjectBySystemId= (params) => {
return get( '/occupationlab/projectManage/getProjectBySystemId',params)
}
export const getProjectDetail= (params) => {
return get( '/occupationlab/projectManage/getProjectDetail',params)
}
export const submit= (params) => {
return post( '/bank/bank/submit',params)
}

@ -7,7 +7,7 @@
<p>实训项目</p>
<el-select v-model="projectId" placeholder="请选择" class="select" :disabled="projectPermissions != 0" @change="selectProject">
<el-option
v-for="item in value"
v-for="item in topicList"
:key="item.projectId"
:label="item.projectName"
:value="item.projectId"
@ -50,7 +50,8 @@
</div>
<div class="font_css">
<div class="experimentalGoal">
<div class="break-all" v-html="experimentalGoal"></div>
<div class="break-all" v-html="projectManage.experimentTarget">
</div>
</div>
</div>
</div>
@ -63,9 +64,10 @@
<el-row>
<el-col :span="24">
<el-card shadow="hover">
<el-table :data="tableData" :stripe="true" height="405">
<el-table :data="requires" stripe height="405">
<el-table-column type="index"></el-table-column>
<el-table-column prop="judgmentPointsName" label="判分标准" align="center"></el-table-column>
<el-table-column prop="name" label="判分标准" align="center" width="180">
</el-table-column>
<el-table-column prop="right" label="完成结果" align="center">
<template slot-scope="scope">
<i
@ -91,21 +93,19 @@
<el-main>
<el-tabs v-model="activeName" type="card">
<el-tab-pane label="案例" name="first">
<div class="break-all" v-html="caseDescription"></div>
<div class="break-all" v-html="projectManage.experimentDescription"></div>
</el-tab-pane>
<el-tab-pane label="实验要求" name="second">
<el-collapse v-model="activeNames">
<el-collapse-item v-for="(loop, index) in points" :key="index">
<template slot="title">
<i class="el-icon-s-ticket"></i>
<span style="font-size:16px">{{loop.judgmentPointsName}}</span>
</template>
<div class="break-all" v-html="loop.experimentalRequirements"></div>
<el-collapse v-model="activeNames" accordion>
<div v-for="(item,index) in requires">
<el-collapse-item :title="item.name" :name="item.id">
<div class="break-all" v-html="item.experimentalRequirements"></div>
</el-collapse-item>
</div>
</el-collapse>
</el-tab-pane>
<el-tab-pane label="实验提示" name="fifth" v-if="isstartexperimentSuggests">
<div class="break-all" v-html="experimentSuggests"></div>
<div class="break-all" v-html="projectManage.experimentHint"></div>
</el-tab-pane>
</el-tabs>
</el-main>
@ -125,6 +125,10 @@
<script>
import util from '@/libs/util'
import Setting from '@/setting'
//
import {getProjectBySystemId} from "@/api/http.js";
import {getProjectDetail} from "@/api/http.js";
import {submit} from "@/api/http.js";
export default {
data() {
return {
@ -143,10 +147,10 @@ export default {
millisecond: 0,
countVal: this.defaultVal, //
pauseTime: 0,
day: 0,
seconds: 0,
minutes: 0,
hour: 0,
day: '00',
seconds: '00',
minutes: '00',
hour: '00',
createTime: "", //
actEndTime: "", //
projectId: "", //
@ -164,7 +168,7 @@ export default {
schoolId: '',
studentId: "",
courseId: "",
projectId: "",
// projectId: "",
assessmentId: "",
projectPermissions: 0, //(0 1 2)
isSubmit: false,
@ -173,8 +177,11 @@ export default {
stopTime: '',
isSelected: false,
userId: '',
isstartexperimentSuggests: 1
};
isstartexperimentSuggests: 1,
topicList:[],
projectManage:{},
requires:[]
}
},
watch: {
countVal: {
@ -235,108 +242,186 @@ export default {
}
this.assessmentId && this.projectId && this.checkVer()
this.codeId && this.codeIds.push(this.codeId)
this.getData()
},
methods: {
checkVer() {
let data = {
userId: this.userId,
id: this.assessmentId
//
getData(){
let params = {
systemId:'11',
}
this.$get(this.api.qualifications,data).then(res => {
if(res.message == 'false'){
this.isSubmit = true;
// newmain.$emit("isSubmit", this.isSubmit);
getProjectBySystemId(params).then((data)=>{
if(data.status == 200){
this.topicList = data.data.projects
}
});
}).catch((error)=>{
})
},
//
reload() {
this.$post(this.api.DeleteCodes, this.codeIds).then(res => {
this.getClearTime()
this.grade = '00'
this.codeIds = []
this.isSubmit = false
this.startCountFn()
});
//
selectProject(){
let params = {
projectId:this.projectId,
}
getProjectDetail(params).then((data)=>{
if(data.status == 200){
this.projectManage = data.data.projectManage;
this.requires = data.data.projectJudgmentVos;
}
}).catch((error)=>{
})
//
let startTime = new Date().getTime();
sessionStorage.setItem('startTime', startTime)
this.day = '00';
this.hour = '00';
this.minutes = '00';
this.seconds = '00';
this.getClearTime();
this.startCountFn();
},
//
Submit() {
if(!this.codeIds.length) return this.$message.error('请先完成实验')
// if(!this.codeIds.length) return this.$message.error('')
this.$confirm("此操作将视为结束考试, 是否继续?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
center: true
})
.then(() => {
}).then(() => {
this.actEndTime = new Date().getTime();
console.log(this.actEndTime)
let ruleReqs = sessionStorage.getItem('ruleReqs')
let startTime = sessionStorage.getItem('startTime')
let ruleReqsList = JSON.parse(ruleReqs);
let lcld = []
for (var i=0;i<this.requires.length;i++){
lcld.push(this.requires[i].judgmentId)
}
let params = {
"accountId": 0,
"assessmentId": 0,
"classId": 0,
"endTime": this.actEndTime,
"lcId": lcld,
"projectId": 0,
"ruleReqs": ruleReqsList,
"startTime": +startTime,
"submitTime": this.actEndTime,
"systemId": 11,
"timeSum": 0
}
submit(params).then((data)=>{
if(data.status == 200){
this.topicList = data.data.projects
}
}).catch((error)=>{
})
this.getClearTime();
//
this.$post(this.api.Submit, {
// projectPermissions: 0,
createTime: this.startTime,
endTime: this.stopTime,
projectId: this.projectId,
projectPermissions: this.projectPermissions,
// assessmentId: 1,
assessmentId: this.assessmentId ? this.assessmentId : '',
codeIds: this.codeIds,
judgmentPointsIds: this.judgmentPointsIds,
// studentId: 54,
studentId: this.studentId,
record: {
courseId: 1,
// courseId: this.courseId,
projectId: this.projectId,
createTime: this.startTime,
endTime: this.stopTime,
startTime: this.entryTime
}
})
.then(res => {
this.isSubmit = true
// newmain.$emit("isSubmit", this.isSubmit);
this.tableData = res.message
//
var s = 0;
this.tableData.forEach(element => {
this.test = element.score;
s += this.test;
this.grade = s;
});
})
.catch(err => {});
})
.catch(() => {
// this.$post(this.api.Submit, {
// // projectPermissions: 0,
// createTime: this.startTime,
// endTime: this.stopTime,
// projectId: this.projectId,
// projectPermissions: this.projectPermissions,
// // assessmentId: 1,
// assessmentId: this.assessmentId ? this.assessmentId : '',
// codeIds: this.codeIds,
// judgmentPointsIds: this.judgmentPointsIds,
// // studentId: 54,
// studentId: this.studentId,
// record: {
// courseId: 1,
// // courseId: this.courseId,
// projectId: this.projectId,
// createTime: this.startTime,
// endTime: this.stopTime,
// startTime: this.entryTime
// }
// }).then(res => {
// this.isSubmit = true
// // newmain.$emit("isSubmit", this.isSubmit);
// this.tableData = res.message
// //
// var s = 0;
// this.tableData.forEach(element => {
// this.test = element.score;
// s += this.test;
// this.grade = s;
// });
// })
// .catch(err => {});
}).catch(() => {
this.$message({
type: "info",
message: "已取消提交"
});
});
},
//
timeFormat(param) {
return param < 10 ? "0" + param : param;
//
startCountFn() {
if (!this.isStart) {
this.countVal = this.countVal ? this.countVal : 0;
let timer = setInterval(() => {
this.counterFn(this.countVal++);
}, 1000);
this.globalTimer = timer;
this.isStart = true;
}
},
toggleCase() {
this.caseVisible = !this.caseVisible
counterFn(counterTime) {
let leave1 = counterTime % (24 * 3600 * 1); //
let leave2 = leave1 % (3600 * 1); //
let leave3 = leave2 % (60 * 1); //
let day = Math.floor(counterTime / (24 * 3600 * 1)); //
let hour = Math.floor(leave1 / (3600 * 1)); //
let minutes = Math.floor(leave2 / (60 * 1)); //
let seconds = Math.round(leave3 / 1); //
day = day >= 10 ? day : "0" + day;
hour = hour >= 10 ? hour : "0" + hour;
minutes = minutes >= 10 ? minutes : "0" + minutes;
seconds = seconds >= 10 ? seconds : "0" + seconds;
this.day = day;
this.hour = hour;
this.minutes = minutes;
this.seconds = seconds;
},
//
reload() {
this.getClearTime()
},
//
getClearTime() {
// clearInterval(this.globalTimer);
clearInterval(this.countVal);
this.globalTimer = "";
// if(this.projectPermissions != 0){
this.countVal = "";
this.day = "00";
this.seconds = "00";
this.minutes = "00";
this.hour = "00";
// }else{
// this.text = ''
// }
},
checkVer() {
let data = {
userId: this.userId,
id: this.assessmentId
}
this.$get(this.api.qualifications,data).then(res => {
if(res.message == 'false'){
this.isSubmit = true;
// newmain.$emit("isSubmit", this.isSubmit);
}
});
},
//
timeFormat(param) {
return param < 10 ? "0" + param : param;
},
toggleCase() {
this.caseVisible = !this.caseVisible
},
handleData(project,type){
if(!this.isSelected){
this.value = project;
@ -428,43 +513,8 @@ export default {
// this.handleData(res.message,2)
// }).catch(res => {});
},
selectProject(){
this.isSelected = true
this.assessmentId = ''
this.judgmentPointsIds = []
this.codeIds = []
this.getQueryProject(this.projectId)
this.isSubmit = false
this.countVal = 0
// newmain.$emit("isSubmit", this.isSubmit)
},
counterFn(counterTime) {
let leave1 = counterTime % (24 * 3600 * 1); //
let leave2 = leave1 % (3600 * 1); //
let leave3 = leave2 % (60 * 1); //
let day = Math.floor(counterTime / (24 * 3600 * 1)); //
let hour = Math.floor(leave1 / (3600 * 1)); //
let minutes = Math.floor(leave2 / (60 * 1)); //
let seconds = Math.round(leave3 / 1); //
day = day >= 10 ? day : "0" + day;
hour = hour >= 10 ? hour : "0" + hour;
minutes = minutes >= 10 ? minutes : "0" + minutes;
seconds = seconds >= 10 ? seconds : "0" + seconds;
this.day = day;
this.hour = hour;
this.minutes = minutes;
this.seconds = seconds;
},
collapse(){
startCountFn() {
if (!this.isStart) {
this.countVal = this.countVal ? this.countVal : 0;
let timer = setInterval(() => {
this.counterFn(this.countVal++);
}, 1000);
this.globalTimer = timer;
this.isStart = true;
}
},
passToParent(data) {
this.$emit("getDataFromChild", data);
@ -494,7 +544,8 @@ export default {
<style lang="scss" scoped>
/deep/.el-container {
height: 80%;
&.is-vertical{
&.is-vertical {
position: fixed;
top: 200px;
bottom: 20px;
@ -502,10 +553,13 @@ export default {
width: 85%;
height: 70%;
background-color: #f5f5f5;
z-index: 999;
}
.el-header{
.el-header {
color: #333;
padding: 0 12px 0 20px;
.el-button {
background-color: $main-color;
color: #fff;
@ -513,7 +567,8 @@ export default {
margin: 5px 0px 5px 5px;
font-size: 16px;
}
.submit-btn{
.submit-btn {
padding-left: 30px;
padding-right: 30px;
background: $main-color url(../../assets/img/case/btn.png) 0 0/100% 100% no-repeat;

@ -16,6 +16,8 @@ import "tailwindcss/tailwind.css"
// 插件
import plugins from '@/plugins';
import filters from '@/plugins/filters'
import axios from 'axios'
Vue.prototype.$axios = axios
Vue.directive('focus', {/* 聚焦事件 */
inserted: function (el, binding) {

@ -115,13 +115,13 @@
<p v-else-if="popText=='重要空白凭证箱'||popText=='普通凭证箱'" class="tips">- 请从以下物品中选取所需材料 -</p>
<p v-else class="tips">- 请从物品栏选中或拖拽所需材料 -</p>
<div v-if="popText==='密码器'" style="min-height:204;width:800px;padding-right:150px;padding-top:50px">
<div v-if="popText==='密码器'" style="width:800px;padding-right:150px;padding-top:80px">
<el-form :model="passwordForm" :rules="passwordRules" ref="form" label-width="180px">
<el-form-item label="密码" prop="password">
<el-input v-focus v-model="passwordForm.password" maxlength="6" onkeyup="this.value=this.value.replace(/[^19]/g,'')}else{this.value=this.value.replace(/\D/g,'')}" autocomplete="off"></el-input>
<el-input v-focus show-password v-model="passwordForm.password" maxlength="6" onkeyup="{this.value=this.value.replace(/\D/g,'')}" autocomplete="off"></el-input>
</el-form-item>
<el-form-item label="确认密码" prop="passwordAgain">
<el-input :disabled="!passwordForm.password||passwordForm.password.length!=6" v-model="passwordForm.passwordAgain" maxlength="6" onkeyup="this.value=this.value.replace(/[^19]/g,'')}else{this.value=this.value.replace(/\D/g,'')}" autocomplete="off"></el-input>
<el-input show-password :disabled="!passwordForm.password||passwordForm.password.length!=6" v-model="passwordForm.passwordAgain" maxlength="6" onkeyup="this.value=this.value.replace(/\D/g,'')" autocomplete="off"></el-input>
</el-form-item>
</el-form>
</div>
@ -877,7 +877,7 @@ export default {
width: 94px;
height: 200px;
cursor: pointer;
z-index: 9999;
z-index: 998;
background: url(../../../assets/img/sth-bg.png) 0 0 / cover no-repeat;
span {
width: 30px;
@ -944,7 +944,7 @@ export default {
}
&.active {
left: 0;
z-index: 9999;
z-index: 998;
}
img {
cursor: pointer;
@ -973,7 +973,7 @@ export default {
margin-top: 4vh !important;
background: #fff;
position: fixed;
top: 0%;
top: 7%;
left: 50%;
transform: translate(-50%, 0);
padding: 0 15px 15px;

@ -16,7 +16,9 @@
<div class="coming" :class="{active: comingVisible}">
<img src="@/assets/svg/coming.svg" alt="">
<div style="width: 20%;margin: auto">
<img style="width: 100%" src="@/assets/svg/coming.svg" alt="">
</div>
<p class="text">敬请期待</p>
</div>
</div>

@ -1,7 +1,7 @@
//
<template>
<div class="wrap">
<div class="flex mt-4 ml-12 text-xl">
<div class="flex mt-8 ml-12 text-xl">
<p>客户信息</p>
<i class="el-icon-arrow-right text-xl"></i>
<p>个人客户信息建立</p>
@ -11,7 +11,7 @@
<el-form ref="form" :model="form" label-width="140px">
<el-col :span="10" :offset="1">
<el-form-item label="证件类型">
<el-select v-model="form.x" placeholder="请选择">
<el-select v-model="form.idType" disabled placeholder="请选择">
<el-option
v-for="(item,index) in papers"
:key="index"
@ -21,17 +21,17 @@
</el-select>
</el-form-item>
<el-form-item label="客户姓名" required>
<el-input v-model="form.name"></el-input>
<el-input v-model="form.userName"></el-input>
</el-form-item>
<el-form-item label="出生日期" required>
<el-date-picker
v-model="form.value1"
v-model="form.birthday"
type="date"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
<el-form-item label="通讯地址">
<el-input v-model="form.name"></el-input>
<el-input v-model="form.mailbox"></el-input>
</el-form-item>
</el-col>
<el-col :span="10" :offset="1">
@ -41,7 +41,7 @@
</div>
</el-form-item>
<el-form-item label="性别" required>
<el-select v-model="form.x" placeholder="请选择">
<el-select v-model="form.sex" placeholder="请选择">
<el-option
v-for="(item,key) in gender"
:key="key"
@ -51,7 +51,7 @@
</el-select>
</el-form-item>
<el-form-item label="民族">
<el-select v-model="form.x" placeholder="请选择">
<el-select v-model="form.nationality" placeholder="请选择">
<el-option
v-for="(item,index) in nations"
:key="index"
@ -61,14 +61,14 @@
</el-select>
</el-form-item>
<el-form-item label="联系电话" required>
<el-input v-model="form.name"></el-input>
<el-input v-model="form.phone"></el-input>
</el-form-item>
</el-col>
</el-form>
</el-row>
</div>
<el-button @click="visible=true" type="primary" class="submitBtn">提交</el-button>
<el-button @click="submitForm" type="primary" class="submitBtn">提交</el-button>
<el-dialog
style="margin-top:10vh"
@ -113,7 +113,14 @@ export default {
data() {
return {
form:{
idType:1,//
idNumber:'',//
userName:'',//
sex:'',//
birthday:'',//
nationality:'',//
mailbox:'',//
phone:'',//
},
disForm:{name:'002009' ,pass:'123456'},
visible:false,//
@ -140,6 +147,58 @@ export default {
popUp(){//
this.$store.commit('system/changePop',{show:true,text:'身份证扫描仪'})
},
//
submitForm(){
if(this.form.idNumber && this.form.idNumber.userName && this.form.idNumber.sex && this.form.idNumber.birthday && this.form.idNumber.phone) {
this.visible = true;
let formList = [];
if(this.form.nationality){
formList.push({
"emptyOne": "",
"emptyTwo": "",
"operationIds": "5,25,33,45",
"type": ""
})
}
if(this.form.mailbox){
formList.push({
"emptyOne": "",
"emptyTwo": "",
"operationIds": "5,25,33,46",
"type": ""
})
}
formList.push({
"emptyOne": "",
"emptyTwo": "",
"operationIds": "5,25,33,40",
"type": ""
}, {
"emptyOne": "",
"emptyTwo": "",
"operationIds": "5,25,33,41,13",
"type": ""
}, {
"emptyOne": "",
"emptyTwo": "",
"operationIds": "5,25,33,42",
"type": ""
}, {
"emptyOne": "",
"emptyTwo": "",
"operationIds": "5,25,33,44",
"type": ""
}, {
"emptyOne": "",
"emptyTwo": "",
"operationIds": "5,25,33,47",
"type": ""
});
sessionStorage.setItem('ruleReqs', JSON.stringify(formList))
}else{
this.$message.error('有必填项为填哦~');
}
},
popSure(){
this.success&&(this.visible = false)
this.authorization&&(this.success=true)

@ -5,7 +5,7 @@
<el-form ref="form" :model="form" label-width="120px">
<el-col :span="10" :offset="2">
<el-form-item label="客户号">
<el-input v-model="form.num"></el-input>
<el-input v-model="form.userNumber"></el-input>
</el-form-item>
<el-form-item label="币种" required>
<el-select v-model="form.currency" placeholder="请选择">
@ -15,10 +15,10 @@
</el-col>
<el-col :span="10" :offset="1">
<el-form-item label="客户姓名" required>
<el-input v-model="form.name"></el-input>
<el-input v-model="form.userName"></el-input>
</el-form-item>
<el-form-item label="钞汇标识" required>
<el-select v-model="form.identification" placeholder="请选择">
<el-select v-model="form.goldLogo" placeholder="请选择">
<el-option label="钞户" value="钞户"> </el-option>
</el-select>
</el-form-item>
@ -30,25 +30,25 @@
<el-form ref="form" :model="form" label-width="120px">
<el-col :span="10" :offset="2">
<el-form-item label="账户性质">
<el-select v-model="form.nature" placeholder="请选择">
<el-select v-model="form.accountQuality" placeholder="请选择">
<el-option label="个人结算户" value="个人结算户"> </el-option>
</el-select>
</el-form-item>
<el-form-item label="账户类型" required>
<el-select v-model="form.x" placeholder="请选择">
<el-select v-model="form.accountType" placeholder="请选择">
<el-option label="一类户" value="一类户"> </el-option>
<el-option label="二类户" value="二类户"> </el-option>
</el-select>
</el-form-item>
<el-form-item label="支取方式" required>
<el-select v-model="form.x" placeholder="请选择">
<el-select v-model="form.drawWay" placeholder="请选择">
<el-option label="密码" value="密码"> </el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="10" :offset="1">
<el-form-item label="凭证类型" required>
<el-select v-model="form.x" placeholder="请选择">
<el-select v-model="form.voucherType" placeholder="请选择">
<el-option label="IC卡" value="IC卡"> </el-option>
</el-select>
</el-form-item>
@ -58,7 +58,7 @@
</div>
</el-form-item>
<el-form-item label="支取密码" required>
<div class="idCard" @click="popUp('密码器')">
<div class="idCard" @click="popUps('密码器')">
<p>请输入密码</p>
</div>
</el-form-item>
@ -68,56 +68,93 @@
</el-row>
</div>
<!-- 二级证件,最多三张逻辑上一张二级为填完信息不可添加第三张 v-for="(item,index) in second" :key="index" -->
<div class="add" v-for="(item, index) in second" :key="index">
<el-row :gutter="20" style="margin: 0; margin-top: 10px">
<div class="add" v-if="formto">
<el-row :gutter="20" style="margin: 0;z-index:9">
<el-form ref="form" :model="form" label-width="120px">
<el-col :span="10" :offset="2">
<el-form-item label="账户性质">
<el-input v-model="form.name"></el-input>
<el-select v-model="form.accountQualitys" placeholder="请选择">
<el-option label="个人结算户" value="个人结算户"> </el-option>
</el-select>
</el-form-item>
<el-form-item label="账户类型" required>
<el-select v-model="form.x" placeholder="请选择">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"> </el-option>
<el-select v-model="form.accountTypes" placeholder="请选择">
<el-option label="一类户" value="一类户"> </el-option>
<el-option label="二类户" value="二类户"> </el-option>
</el-select>
</el-form-item>
<el-form-item label="支取方式" required>
<el-select v-model="form.x" placeholder="请选择">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"> </el-option>
<el-select v-model="form.drawWays" placeholder="请选择">
<el-option label="密码" value="密码"> </el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="10" :offset="1">
<el-form-item label="凭证类型" required>
<el-select v-model="form.x" placeholder="请选择">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"> </el-option>
<el-select v-model="form.voucherTypes" placeholder="请选择">
<el-option label="IC卡" value="IC卡"> </el-option>
</el-select>
</el-form-item>
<el-form-item label="凭证号码" required>
<el-input v-model="form.name"></el-input>
<div class="idCard" @click="popUp('刷卡器')">
<p>请刷卡</p>
</div>
</el-form-item>
<el-form-item label="凭证号码" required>
<el-input v-model="form.name"></el-input>
<el-form-item label="支取密码" required>
<div class="idCard" @click="popUps('密码器')">
<p>请输入密码</p>
</div>
</el-form-item>
</el-col>
</el-form>
</el-row>
<el-button @click="deleteSecond(index)" class="addBtn" circle icon="el-icon-close"></el-button>
</el-row>
</div>
<el-button @click="formSubmit" type="primary" class="submitBtn">提交</el-button>
<el-dialog
style="margin-top:10vh"
:visible.sync="visible"
:modal="false"
width="40%"
:close-on-click-modal="false"
:show-close="false"
custom-class="data-dia"
>
<div slot="title" class="dia-header">
<div class="data-title">提交</div>
</div>
<el-button @click="visible = true" type="primary" class="submitBtn">提交</el-button>
<div class="popBody">
<h2>提交后将不可更改您确认提交吗</h2>
</div>
<div class="popBtns">
<el-button class="close btn" @click="visible = false"> </el-button>
<el-button class="sure btn" type="primary" @click="popSure"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
export default {
data(){
return{
form:{
userNumber:'',
},
second:[//
],
options:[]
second:[],//
options:[],
visible:false,
currency: '',
userName: '',
goldLogo: '',
accountQuality: '',
accountType: '',
drawWay: '',
voucherType: '',
accountQualitys: '',
accountTypes: '',
drawWays: '',
voucherTypes: '',
formto:false,
}
},
methods:{
@ -132,17 +169,35 @@ export default {
openAccount(){
if(this.second.length){/* 检测已有二级卡是否填写完整 */
return this.$message('请把已有的二级卡填写完整再执行新增操作!')
for (let i= 0; i< this.second.length; i++) {
if(!this.detectionObjKeys(e,[])){/* 写入定义的二级卡字段 */
return this.$message('请把已有的二级卡填写完整再执行新增操作!')
}
}
}
let obj = {/* 二级卡定义空属性 */
this.formto = true
// let obj = {}/* */
// this.second.push(obj)``
},
//
formSubmit(){
this.visible = true
},
//
popSure(){
this.visible = false
let formList = [];
if(this.form.userNumber){
formList.push({
"emptyOne": "6",
"emptyTwo": this.form.userNumber,
"operationIds": "26,57,62,68",
"type": "3"
})
sessionStorage.setItem('ruleReqs', JSON.stringify(formList))
}else{
this.$message.error('有必填项为填哦~');
}
this.second.push(obj)``
},
deleteSecond(index){
this.$confirm('此操作将删除该账户类型, 是否继续?', '提示', {
@ -150,7 +205,8 @@ export default {
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.second.splice(index,1)
this.formto = false
// this.second.splice(index,1)
this.$message({
type: 'success',
message: '删除成功!'
@ -161,7 +217,13 @@ export default {
message: '已取消删除'
});
});
}
},
popUp(){
this.$store.commit('system/changePop',{show:true,text:'凭证号码'})
},
popUps(){
this.$store.commit('system/changePop',{show:true,text:'密码器'})
},
}
};
</script>

@ -133,7 +133,7 @@ export default {
title: '重空现金',
children:[
{
index:"/counter/list/manage/dayEnd-tellerCash",
index:"/counter/list/manage/importantCash-cashRecipients",
title:'柜员现金扎帐'
},
{

@ -2,7 +2,27 @@ const Setting = require('./src/setting.env')
// 引入等比适配插件
const px2rem = require('postcss-px2rem')
module.exports = {
publicPath: './',
//配置跨域请求
devServer: {
open: true, //是否自动打开浏览器
https: false, //是否开启https
hotOnly: false,
proxy: { // 配置跨域
'/api': {
target: 'http://192.168.31.125:9000', //请求接口域名
ws: true,
secure: false,
changOrigin: true, //是否允许跨越
pathRewrite: {
'^/api': ''
}
}
},
before: app => { }
}
}
// 配置基本大小
const postcss = px2rem({
// 基准大小 baseSize,需要和rem.js中相同

Loading…
Cancel
Save