提交 ad3d572e authored 作者: 王鹏飞's avatar 王鹏飞

refactor: 重构

上级 f545a1df
......@@ -32,22 +32,16 @@
<!-- <div class="welcome-button" @click="handleStart('2023 秋季班-电气工程MSEE')">
2023 秋季班-电气工程MSEE
</div> -->
<div class="welcome-button" @click="handleStart('2024 秋季班-电气工程MSEE')">
2024 秋季班-电气工程MSEE
</div>
<div class="welcome-button" @click="handleStart('2024 秋季班-电气工程MSEE')">2024 秋季班-电气工程MSEE</div>
<!-- <div class="welcome-button" @click="handleStart('2023 秋季班-计算机科学MSCS')">
2023 秋季班-计算机科学MSCS
</div> -->
<div class="welcome-button" @click="handleStart('2024 秋季班-计算机科学MSCS')">
2024 秋季班-计算机科学MSCS
</div>
<div class="welcome-button" @click="handleStart('2024 秋季班-计算机科学MSCS')">2024 秋季班-计算机科学MSCS</div>
<br />
<!-- <div class="welcome-button" @click="handleStart('2023 秋季班-计算机工程MSCE')">
2023 秋季班-计算机工程MSCE
</div> -->
<div class="welcome-button" @click="handleStart('2024 秋季班-电气工程MSCE')">
2024 秋季班-电气工程MSCE
</div>
<div class="welcome-button" @click="handleStart('2024 秋季班-电气工程MSCE')">2024 秋季班-电气工程MSCE</div>
<!-- <div class="welcome-button" @click="handleStart">马上开始</div> -->
</div>
</div>
......@@ -229,6 +223,7 @@ export default {
.card {
background: #fff;
border-radius: 5px;
margin: 0;
}
.card + .card {
margin-top: 10px;
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'admission_cjd',
......@@ -27,9 +27,9 @@ export default function(_this) {
},
form: {
next: { to: { query: { active: 'admission_tjx' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
hint: `
prepend: `
<p>已毕业学生需提交完整成绩单,未毕业学生提交现有成绩单,成绩单需要加盖学校公章</p>
<p>请将中英文成绩单原件扫描或者拍照后提交。</p>
<p>获取途径:联系大学时就读学校相关部门(档案馆/教务处)获取成绩单。</p>
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'admission_grcs',
......@@ -20,7 +20,7 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'admission_tjx' } } },
next: { to: { query: { active: 'admission_byzs' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
items: [
{
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'admission_tjx',
......@@ -43,11 +43,11 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'admission_cjd' } } },
next: { to: { query: { active: 'admission_grcs' } } },
hasButton: false,
hasSubmit: false,
// submitText: '申请面试',
// model: { submission_stage: 'INTERVIEW_APPLICATION' },
options: {},
hint: '请上传两封推荐人署名的推荐信原件照片或扫描件(英文)',
prepend: '请上传两封推荐人署名的推荐信原件照片或扫描件(英文)',
items: [
{
type: 'v-upload',
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'admission_xfjn',
......@@ -37,7 +37,7 @@ export default function(_this) {
// next: { to: { query: { active: 'admission_xy' } } },
submitText: '提交',
options: { 'label-position': 'top' },
// hint: `
// prepend: `
// <p><strong>一、对公收款银行信息:</strong></p>
// <p>户名:清控紫荆( 北京)教育科技股份有限公司</p>
// <p>帐号:694485289</p>
......
......@@ -17,7 +17,7 @@ export default {
form: {
prev: { to: { query: { active: 'admission_byzs' } } },
next: { to: { query: { active: 'admission_xy' } } },
hasButton: false,
hasSubmit: false,
options: {},
items: [
{
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
id: 'admission_yynl',
title: '语言能力证明',
......@@ -26,7 +26,7 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'admission_cjd' } } },
next: { to: { query: { active: 'admission_tjx' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
items: [
{
......
......@@ -7,11 +7,8 @@
@success="handleSuccess"
@error="handleError"
@back="$router.push('/my/account')"
@prev="handlePrev"
@next="handleNext"
@uploaded="getApplication"
v-if="detail"
>
v-if="detail">
<template #aside-append>
<div class="aside-payment"><a href="https://accounts.ezijing.com/payment" target="_blank">查看缴费记录</a></div>
<div class="aside-logout" @click="$store.dispatch('logout')"><span>退出登录</span></div>
......@@ -21,13 +18,7 @@
<app-xy />
</template> -->
</vue-form>
<el-dialog
title="办理入学资料提交成功"
:visible.sync="dialogVisible"
:center="true"
:close-on-click-modal="false"
width="348px"
>
<el-dialog title="办理入学资料提交成功" :visible.sync="dialogVisible" :center="true" :close-on-click-modal="false" width="348px">
<div class="dialog-tips">
<!-- <p>请确认是否已缴费,如未缴费点击下方缴费按钮 <br />(已缴费,请忽略)</p> -->
<div class="icon"><img src="https://webapp-pub.ezijing.com/project/application/images/icon_success.png" /></div>
......
......@@ -2,7 +2,7 @@
* 申请声明
*/
export default function(_this) {
export default function (_this) {
return {
id: 'application_declare',
title: '申请声明',
......
......@@ -2,7 +2,7 @@
* 工作经验
*/
export default function(_this) {
export default function (_this) {
return {
id: 'application_info_career',
title: '工作经验',
......@@ -22,15 +22,7 @@ export default function(_this) {
action: `${process.env.baseURL}/api/enrollment/v1.0/application-materials/${process.env.projectId}/put`,
beforeRequest(data) {
const careers = data.map(item => {
return [
'start_date',
'end_date',
'company_name_cn',
'industry',
'dept_cn',
'position_cn',
'job_desc_cn'
].reduce((result, key) => {
return ['start_date', 'end_date', 'company_name_cn', 'industry', 'dept_cn', 'position_cn', 'job_desc_cn'].reduce((result, key) => {
result[key] = item[key]
return result
}, {})
......@@ -43,7 +35,7 @@ export default function(_this) {
next: { to: { query: { active: 'application_info', tab: 'application_info_answer' } }, isSubmit: true },
hasAdd: true,
options: { labelWidth: '140px' },
hint: '<p style="color:#606266;padding-left:70px">无工作经验学生可不填写</p>',
prepend: '<p style="color:#606266;padding-left:70px">无工作经验学生可不填写</p>',
items: [
{
type: 'v-datepicker',
......
......@@ -2,7 +2,7 @@
* 个人信息
*/
export default function(_this) {
export default function (_this) {
return {
id: 'application_info_first',
title: '个人信息',
......@@ -13,11 +13,7 @@ export default function(_this) {
get: {
action: `${process.env.baseURL}/api/enrollment/v1.0/application-materials/${process.env.projectId}`,
callback(data) {
const {
basic_info: basicInfo = {},
attachments = [],
submission_stage: submissionStage = 'FILLING'
} = data.data.material
const { basic_info: basicInfo = {}, attachments = [], submission_stage: submissionStage = 'FILLING' } = data.data.material
this.form.options.disabled = submissionStage !== 'FILLING'
const attachment = attachments.reduce(
......@@ -47,8 +43,7 @@ export default function(_this) {
}
},
form: {
hasButton: false,
next: { to: { query: { active: 'application_info', tab: 'application_info_profile' } }, isSubmit: true },
submitText: '下一步',
options: { labelWidth: '140px' },
items: [
{
......
......@@ -4,7 +4,7 @@
import country from './country'
export default function(_this) {
export default function (_this) {
return {
id: 'application_info_profile',
title: '个人信息',
......@@ -15,11 +15,7 @@ export default function(_this) {
get: {
action: `${process.env.baseURL}/api/enrollment/v1.0/application-materials/${process.env.projectId}`,
callback(data) {
const {
basic_info: basicInfo = {},
attachments = [],
submission_stage: submissionStage = 'FILLING'
} = data.data.material
const { basic_info: basicInfo = {}, attachments = [], submission_stage: submissionStage = 'FILLING' } = data.data.material
this.form.options.disabled = submissionStage !== 'FILLING'
const attachment = attachments.reduce(
......@@ -85,7 +81,7 @@ export default function(_this) {
model: 'email',
attrs: { placeholder: '请输入邮箱' },
rules: [{ type: 'email', required: true, message: '请输入邮箱', trigger: 'blur' }],
hint: '(后续报名信息将发送至此邮箱,请认真填写)'
append: '(后续报名信息将发送至此邮箱,请认真填写)'
},
{
type: 'v-select',
......
export default function(_this) {
export default function (_this) {
return {
id: 'application_wfzzm',
title: '无犯罪证明',
......@@ -20,7 +20,7 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'application_tjx' } } },
next: { to: { query: { active: 'application_declare' } } },
hasButton: false,
hasSubmit: false,
options: {},
items: [
{
......
......@@ -9,10 +9,7 @@
@success="handleSuccess"
@error="handleError"
@back="$router.push('/my/account')"
@prev="handlePrev"
@next="handleNext"
v-if="detail"
>
v-if="detail">
<template #aside-append>
<div class="aside-preview" @click="dialogVisible = true" v-if="visible">预览全部</div>
<div class="aside-payment"><a href="https://accounts.ezijing.com/payment" target="_blank">查看缴费记录</a></div>
......@@ -75,10 +72,7 @@ export default {
const { data, error, message } = response
if (error.toString() === '0') {
this.detail = data
if (
!data.progress.FILLING.attachments ||
data.progress.FILLING.attachments.missed_required_list.ID_CARD_PHOTO
) {
if (!data.progress.FILLING.attachments || data.progress.FILLING.attachments.missed_required_list.ID_CARD_PHOTO) {
this.tabActive = 'application_info_first'
}
const { submission_stage: submissionStage = 'FILLING' } = data.material
......@@ -97,13 +91,16 @@ export default {
handlePageChange(value) {
this.currentActive = value
this.$router.push({ path: this.$route.path, query: { active: value } })
console.log('页面切换了', value)
},
handleTabChange(value) {
this.tabActive = value
const query = Object.assign({}, this.$route.query, { tab: value })
this.$router.push({ query })
console.log('Tab切换了', value)
},
handleSuccess(data) {
if (this.tabActive === 'application_info_first') this.tabActive = 'application_info_profile'
console.log('提交成功了', data)
this.$message({ type: 'success', message: '提交成功' })
},
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'interview_byzs',
......@@ -48,7 +48,7 @@ export default function(_this) {
prev: { to: { query: { active: 'interview_grcs' } }, isSubmit: true },
next: { to: { query: { active: 'application_pay' } }, isSubmit: true },
submitText: '提交申请',
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
items: [
{
......@@ -73,7 +73,8 @@ export default function(_this) {
data: { file_type: 'DIPLOMA_CN' }
},
rules: { required: true, message: '请上传毕业证书' },
append: '申请者需要将本科或以上毕业证书原件扫描或者拍照后提交。<br> 可上传多个文件,请确保证书号码清晰可辨。<br> 上传文件仅限“jpg,jpeg,png”格式,文件小于10MB。',
append:
'申请者需要将本科或以上毕业证书原件扫描或者拍照后提交。<br> 可上传多个文件,请确保证书号码清晰可辨。<br> 上传文件仅限“jpg,jpeg,png”格式,文件小于10MB。',
isShow(ruleForm) {
return ruleForm.learn_status === '已毕业'
}
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'interview_cjd',
......@@ -38,7 +38,7 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'interview_ywjl' } }, isSubmit: true },
next: { to: { query: { active: 'interview_yynl' } }, isSubmit: true },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
items: [
{
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'interview_grcs',
......@@ -19,7 +19,7 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'interview_tjx' } } },
next: { to: { query: { active: 'interview_byzs' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
items: [
{
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'interview_tjx',
......@@ -42,11 +42,11 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'interview_yynl' } } },
next: { to: { query: { active: 'interview_grcs' } } },
hasButton: false,
hasSubmit: false,
// submitText: '申请面试',
// model: { submission_stage: 'INTERVIEW_APPLICATION' },
options: {},
hint: '请上传两封推荐人署名的推荐信原件照片或扫描件(英文)',
prepend: '请上传两封推荐人署名的推荐信原件照片或扫描件(英文)',
items: [
{
type: 'v-upload',
......
......@@ -18,7 +18,7 @@ export default {
form: {
prev: { to: { query: { active: 'interview_byzs' } } },
next: { to: { query: { active: 'interview_ywjl' } } },
hasButton: false,
hasSubmit: false,
options: {},
items: [
{
......@@ -30,8 +30,7 @@ export default {
deleteAction: `${process.env.baseURL}/api/enrollment/v1.0/application-materials/attachments/${process.env.projectId}/delete`,
data: { file_type: 'DEGREE_CERT_CN' }
},
append:
'申请者需要将学位证书原件扫描或者拍照后提交。<br>可上传多个文件,请确保证书号码清晰可辨。<br>上传文件仅限“jpg,jpeg,png”格式,文件小于10MB。'
append: '申请者需要将学位证书原件扫描或者拍照后提交。<br>可上传多个文件,请确保证书号码清晰可辨。<br>上传文件仅限“jpg,jpeg,png”格式,文件小于10MB。'
}
]
}
......
......@@ -18,7 +18,7 @@ export default {
form: {
prev: { to: { query: { active: 'interview_xwzs' } } },
next: { to: { query: { active: 'interview_ywjl' } } },
hasButton: false,
hasSubmit: false,
options: {},
items: [
{
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
id: 'interview_ywcjd',
title: '英文成绩单',
......@@ -25,9 +25,9 @@ export default function(_this) {
},
form: {
next: { to: { query: { active: 'interview_tjx' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
hint: `
prepend: `
<p>已毕业学生需提交完整成绩单,未毕业学生提交现有成绩单,成绩单需要加盖学校公章</p>
<p>请将英文成绩单原件扫描或者拍照后提交。</p>
<p>获取途径:联系大学时就读学校相关部门(档案馆/教务处)获取成绩单。</p>
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'interview_ywjl',
......@@ -19,7 +19,7 @@ export default function(_this) {
form: {
// prev: { to: { query: { active: 'interview_byzs' } } },
next: { to: { query: { active: 'interview_cjd' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
items: [
{
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'interview_yynl',
......@@ -41,7 +41,7 @@ export default function(_this) {
prev: { to: { query: { active: 'interview_cjd' } }, isSubmit: true },
next: { to: { query: { active: 'interview_tjx' } }, isSubmit: true },
submitText: '保存',
// hasButton: false,
// hasSubmit: false,
model: { submission_stage: 'INTERVIEW_APPLICATION' },
options: { 'label-position': 'top' },
items: [
......
......@@ -6,10 +6,7 @@
@page-change="handlePageChange"
@success="handleSuccess"
@error="handleError"
@back="$router.push('/my/account')"
@prev="handlePrev"
@next="handleNext"
>
@back="$router.push('/my/account')">
<template #aside-append>
<div class="aside-payment"><a href="https://accounts.ezijing.com/payment" target="_blank">查看缴费记录</a></div>
<div class="aside-logout" @click="$store.dispatch('logout')"><span>退出登录</span></div>
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'admission_cjd',
......@@ -29,9 +29,9 @@ export default function(_this) {
},
form: {
next: { to: { query: { active: 'admission_tjx' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
hint: `
prepend: `
<p>已毕业学生需提交完整成绩单,未毕业学生提交现有成绩单,成绩单需要加盖学校公章</p>
<p>请将中英文成绩单原件扫描或者拍照后提交。</p>
<p>获取途径:联系大学时就读学校相关部门(档案馆/教务处)获取成绩单。</p>
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'admission_grcs',
......@@ -22,7 +22,7 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'admission_tjx' } } },
next: { to: { query: { active: 'admission_byzs' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
items: [
{
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'admission_tjx',
......@@ -45,11 +45,11 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'admission_cjd' } } },
next: { to: { query: { active: 'admission_grcs' } } },
hasButton: false,
hasSubmit: false,
// submitText: '申请面试',
// model: { submission_stage: 'INTERVIEW_APPLICATION' },
options: {},
hint: '请上传两封推荐人署名的推荐信原件照片或扫描件(英文)',
prepend: '请上传两封推荐人署名的推荐信原件照片或扫描件(英文)',
items: [
{
type: 'v-upload',
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
required: true,
id: 'admission_xfjn',
......@@ -21,9 +21,9 @@ export default function(_this) {
},
form: {
prev: { to: { query: { active: 'admission_byzs' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
hint: `
prepend: `
<p><strong>一、对公收款银行信息:</strong></p>
<p>户名:清控紫荆( 北京)教育科技股份有限公司</p>
<p>帐号:694485289</p>
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
id: 'admission_xy',
title: '入学协议',
......
......@@ -18,7 +18,7 @@ export default {
form: {
prev: { to: { query: { active: 'admission_byzs' } } },
next: { to: { query: { active: 'admission_xy' } } },
hasButton: false,
hasSubmit: false,
options: {},
items: [
{
......
import { STAGE_LIST } from '../../index'
export default function(_this) {
export default function (_this) {
return {
id: 'admission_yynl',
title: '语言能力证明',
......@@ -26,7 +26,7 @@ export default function(_this) {
form: {
prev: { to: { query: { active: 'admission_cjd' } } },
next: { to: { query: { active: 'admission_tjx' } } },
hasButton: false,
hasSubmit: false,
options: { 'label-position': 'top' },
items: [
{
......
......@@ -7,11 +7,8 @@
@success="handleSuccess"
@error="handleError"
@back="$router.push('/my/account')"
@prev="handlePrev"
@next="handleNext"
@uploaded="getApplication"
v-if="detail"
>
v-if="detail">
<template #aside-append>
<div class="aside-payment"><a href="https://accounts.ezijing.com/payment" target="_blank">查看缴费记录</a></div>
<div class="aside-logout" @click="$store.dispatch('logout')"><span>退出登录</span></div>
......
......@@ -38,7 +38,7 @@ export default {
]
},
// Global CSS: https://go.nuxtjs.dev/config-css
css: ['vant/lib/index.css', '@ezijing/vue-form/dist/vue-form.css', 'assets/theme/index.css', 'assets/css/base.css'],
css: ['vant/lib/index.css', '@ezijing/vue-form/style.css', 'assets/theme/index.css', 'assets/css/base.css'],
// Plugins to run before rendering page: https://go.nuxtjs.dev/config-plugins
plugins: [
......
差异被折叠。
......@@ -10,12 +10,12 @@
"generate": "nuxt generate"
},
"dependencies": {
"@ezijing/vue-form": "^2.3.15",
"axios": "^0.21.1",
"@ezijing/vue-form": "^2.5.31",
"axios": "^0.21.4",
"cookie-universal-nuxt": "^2.1.4",
"core-js": "^3.9.1",
"core-js": "^3.36.0",
"driver.js": "^0.9.8",
"element-ui": "^2.15.1",
"element-ui": "^2.15.14",
"file-saver": "^2.0.5",
"lodash": "^4.17.21",
"nuxt": "^2.17.3",
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论