From 73540751644474dc282a7fc98e29a9931bcbf4d0 Mon Sep 17 00:00:00 2001 From: huliyong <2783385703@qq.com> Date: Sat, 21 Dec 2024 23:13:17 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/api.js | 3 +- api/model/examination.js | 12 + pages/index/consult.vue | 13 +- pages_order/work/postConsult - 副本.vue | 469 ++++++++++++++++++++++++++++++ pages_order/work/postConsult.vue | 376 +++++------------------- 5 files changed, 556 insertions(+), 317 deletions(-) create mode 100644 api/model/examination.js create mode 100644 pages_order/work/postConsult - 副本.vue diff --git a/api/api.js b/api/api.js index 5a9c814..5e3d8b8 100644 --- a/api/api.js +++ b/api/api.js @@ -7,7 +7,8 @@ let debounce = {} const models = [ 'score', 'boss', 'login', 'vip', 'company', 'work','index-lzx', 'resume', - 'config' + 'config', + 'examination', ] const config = { diff --git a/api/model/examination.js b/api/model/examination.js new file mode 100644 index 0000000..32e7f16 --- /dev/null +++ b/api/model/examination.js @@ -0,0 +1,12 @@ + +// 考证咨询 + +const api = { + // 考证咨询-根据id查询证书详情 + queryCertById: { + url: '/employ/examination/queryCertById', + method: 'GET', + }, +} + +export default api \ No newline at end of file diff --git a/pages/index/consult.vue b/pages/index/consult.vue index bcff105..450eb89 100644 --- a/pages/index/consult.vue +++ b/pages/index/consult.vue @@ -6,9 +6,10 @@ + @click="$utils.navigateTo('/pages_order/work/postConsult?id=' + item.id)"> + class="image" + mode="widthFix"> @@ -71,18 +72,20 @@ .list{ .item{ display: flex; + margin: 30rpx; .image{ width: 200rpx; - height: 100%; min-height: 300rpx; border-radius: 20rpx; + margin-right: 20rpx; } .info{ .title{ - + font-weight: 900; } .text{ - + font-size: 26rpx; + color: #777; } } } diff --git a/pages_order/work/postConsult - 副本.vue b/pages_order/work/postConsult - 副本.vue new file mode 100644 index 0000000..0d19c76 --- /dev/null +++ b/pages_order/work/postConsult - 副本.vue @@ -0,0 +1,469 @@ + + + + + diff --git a/pages_order/work/postConsult.vue b/pages_order/work/postConsult.vue index 0d19c76..3900a61 100644 --- a/pages_order/work/postConsult.vue +++ b/pages_order/work/postConsult.vue @@ -7,294 +7,26 @@ /> - - - - - - - 真实姓名 - - - - - - - - - 手机号 - - - - - - - - - 身份证号码 - - - - - - + - 工作单位 + {{ item.title }}{{ item.descrip }} - + + + :placeholder="'请输入' + item.title" + v-model="form[item.keyName]"/> - - - - - - 个人信息(用于下载学时证明、考试使用) - - - - - - 个人免冠照(白底彩照1张) - - - - - - - - - - - - - - - - 身份证正面 - - - - - - - - - - - - - - - - - 身份证反面 - - - - - - - - - - - - - - - - - 申请表电子表格(申请表电子表格填写完打印出来,本人签字及日期,单位右边加盖公章1份) - - - - - - - - - - - - - - - - - 初中以上学历证书(或户口本本人那页复印件1份) - - - - - - - - - - - - - - - - - 营业执照复印件1份 - - - - - - - - - - - - - - - - - 个人健康书面承诺1份 - - + + - - + + - + 提交 @@ -327,11 +63,10 @@ 联系客服 - - - 如有疑问请联系客服 - + + 如有疑问请联系客服 @@ -347,44 +82,41 @@ data() { return { form : { - name : '' }, - fileList : [],//个人免冠照 - fileFrontList : [],//身份证正面 - fileReverseList : [],//身份证反面 - fileApplicationList : [],//申请表电子表格 - fileEducationalList : [],//初中以上学历证书 - fileBusinessList : [],//营业执照复印件1份 - filePromiseList : [],//个人健康书面承诺1 + fileMapList : {}, + formList : [], + id : 0, + verification : {}, } }, + onLoad({id}) { + this.id = id + this.queryCertById() + }, methods: { deleteImage(e){ - this[e.name].splice(e.index, 1) + this.fileMapList[e.name].splice(e.index, 1) }, afterRead(e){ let self = this e.file.forEach(file => { self.$Oss.ossUpload(file.url).then(url => { - self[e.name].push({ + self.fileMapList[e.name].push({ url }) }) }) - }, addMaterial(){ - this.form.imageCardFront = this.fileFrontList.map((item) => item.url).join(",") - this.form.imageCardfBack = this.fileReverseList.map((item) => item.url).join(",") + this.formList.forEach(n => { + if(n.type == 1){ + this.form[n.keyName] = this.fileMapList[n.keyName] + .map((item) => item.url).join(",") + } + }) - if(this.$utils.verificationAll(this.form,{ - name:'请输入用户名称', - phone:'请输入电话', - imageCardFront:'请选择身份证正面照复印件', - imageCardfBack:'请选择身份证反面照复印件' - - })) { + if(this.$utils.verificationAll(this.form, this.verification)) { return } this.$api('addMaterial',this.form, res =>{ @@ -392,7 +124,29 @@ uni.showToast({ title:'提交成功!等待审核', icon: 'none' - }) + }) + setTimeout(uni.navigateBack, 1000, -1) + } + }) + }, + queryCertById(){ + this.$api('queryCertById', { + cerId : this.id, + }, res => { + if(res.code == 200){ + this.formList = res.result.employMaterialList + + res.result.employMaterialList.forEach(n => { + if(n.type == 0){ + this.verification[n.keyName] = '请输入' + n.title + this.form[n.keyName] = '' + }else{ + this.verification[n.keyName] = '请上传' + n.title + // this.fileMapList[n.keyName] = [] + this.$set(this.fileMapList, n.keyName, []) + } + }) + } }) },