报名逻辑修改
This commit is contained in:
+137
-60
@@ -10,7 +10,7 @@
|
||||
<section class="content">
|
||||
<div class="main-content">
|
||||
<section class="main-content-title">
|
||||
<img src="../../assets/signUpImg/meetingInfo.png" /> 会议信息
|
||||
<img src="../../assets/signUpImg/meetingInfo.png"/> 会议信息
|
||||
</section>
|
||||
<section class="main-content-info">
|
||||
<a-row :gutter="24">
|
||||
@@ -46,7 +46,7 @@
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<label>召开时间:</label>
|
||||
<span>{{holdtime}}</span>
|
||||
<span>{{ holdtime }}</span>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<label>会议内容:</label>
|
||||
@@ -56,12 +56,12 @@
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<label>召开地点:</label>
|
||||
<span>{{holdAddress}}</span>
|
||||
<span>{{ holdAddress }}</span>
|
||||
</a-col>
|
||||
<!-- <a-col :span="12">-->
|
||||
<!-- <label>备注:</label>-->
|
||||
<!-- <span>{{ currentMeetingInfo.remark }}</span>-->
|
||||
<!-- </a-col>-->
|
||||
<!-- <a-col :span="12">-->
|
||||
<!-- <label>备注:</label>-->
|
||||
<!-- <span>{{ currentMeetingInfo.remark }}</span>-->
|
||||
<!-- </a-col>-->
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
@@ -85,7 +85,7 @@
|
||||
</a-row>
|
||||
</section>
|
||||
<section class="main-content-title mt-10">
|
||||
<img src="../../assets/signUpImg/signUpInfo.png" /> 报名信息
|
||||
<img src="../../assets/signUpImg/signUpInfo.png"/> 报名信息
|
||||
</section>
|
||||
<a-spin :spinning="confirmLoading">
|
||||
<a-form :form="form">
|
||||
@@ -143,8 +143,8 @@
|
||||
validatorRules.email]"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
||||
<a-col :xxl="8" :xl="12" :sm="24">
|
||||
<!--非国际研讨会-->
|
||||
<a-col :xxl="8" :xl="12" :sm="24" v-if="meetingType !== '3' ">
|
||||
<a-form-item label="身份" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-radio-group v-decorator="['identity',validatorRules.identify]" @change="changeIdentify">
|
||||
<a-radio :value="1">嘉宾</a-radio>
|
||||
@@ -153,34 +153,56 @@
|
||||
</a-radio-group>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
||||
<!--身份选择嘉宾并且是研讨会议出现且必填-->
|
||||
<a-col :xxl="8" :xl="12" :sm="24" v-if="identifyType === 1 && meetingType === '3' ">
|
||||
<a-form-item label="嘉宾类型" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-radio-group v-decorator="['guestType',validatorRules.guestType]" @change="changeGuestType">
|
||||
<a-radio :value="1">VIP</a-radio>
|
||||
<a-radio :value="2">演讲嘉宾</a-radio>
|
||||
<a-radio :value="3">特邀嘉宾</a-radio>
|
||||
<a-radio :value="4">合作伙伴</a-radio>
|
||||
<a-col :xxl="8" :xl="12" :sm="24">
|
||||
<a-form-item label="是否有邀请码" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-radio-group v-decorator="['inviteCode',validatorRules.inviteCode]" @change="changeInviteCode">
|
||||
<a-radio :value="1">是</a-radio>
|
||||
<a-radio :value="0">否</a-radio>
|
||||
</a-radio-group>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
||||
<!--邀请码选择是出现填写邀请码 否选择身份-->
|
||||
<a-col :xxl="8" :xl="12" :sm="24" v-if="meetingType === '3' && !inviteCodeBool ">
|
||||
<a-form-item label="身份" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-radio-group v-decorator="['identity',validatorRules.identify]" @change="changeIdentify">
|
||||
<a-radio :value="2">参会人</a-radio>
|
||||
<a-radio :value="3">内部企业</a-radio>
|
||||
</a-radio-group>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
||||
<a-col :xxl="8" :xl="12" :sm="24" v-if="inviteCodeBool">
|
||||
<a-form-item label="邀请码" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<a-input placeholder="请输入邀请码"
|
||||
:maxLength='50'
|
||||
v-decorator="[ 'code',
|
||||
validatorRules.code]"></a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<!--邀请码选择是才出现-->
|
||||
<a-row :gutter="24" class="center" v-if="inviteCodeBool">
|
||||
<a-button @click="nextSetp" type="primary">下一步</a-button>
|
||||
</a-row>
|
||||
<!--个人信息end-->
|
||||
<!--除开国际研讨会的其他会议的显示-->
|
||||
<template v-if="meetingType !== '3' ">
|
||||
<other-meeting-form ref="formother" :selected-company="selectedCompany" :meeting-cost-bool="meetingCostBool"
|
||||
<other-meeting-form ref="formother" :selected-company="selectedCompany"
|
||||
:meeting-cost-bool="meetingCostBool"
|
||||
:identify-type="identifyType" @formData="getFormData"></other-meeting-form>
|
||||
</template>
|
||||
|
||||
<!--国际研讨会参会人与内部企业的显示 默认不展示 -->
|
||||
<template v-if="meetingType === '3' && identifyType !== 1 && identifyType !== null ">
|
||||
<other-meeting-form ref="formother" :meeting-type="meetingType" :selected-company="selectedCompany" :meeting-cost-bool="meetingCostBool"
|
||||
<other-meeting-form ref="formother" :meeting-type="meetingType" :selected-company="selectedCompany"
|
||||
:meeting-cost-bool="meetingCostBool"
|
||||
:identify-type="identifyType" @formData="getFormData"></other-meeting-form>
|
||||
</template>
|
||||
<!-- 国际研讨会身份选择嘉宾 并且是VIP-->
|
||||
<template v-if="identifyType === 1 && guestType === 1">
|
||||
<seminar-vip-form ref="seminarVipForm" @formData="getFormData" :identify-type="identifyType" :guest-type="guestType"></seminar-vip-form>
|
||||
<seminar-vip-form ref="seminarVipForm" @formData="getFormData" :identify-type="identifyType"
|
||||
:guest-type="guestType"></seminar-vip-form>
|
||||
</template>
|
||||
<!-- 国际研讨会身份选择嘉宾 并且是演讲嘉宾-->
|
||||
<template v-if="identifyType === 1 && guestType === 2">
|
||||
@@ -195,7 +217,7 @@
|
||||
<seminar-partner-form ref="seminarPartnerForm" @formData="getFormData"></seminar-partner-form>
|
||||
</template>
|
||||
<section class="meetingCost">
|
||||
费用合计:{{meetingCostSum}} 元
|
||||
费用合计:{{ meetingCostSum }} 元
|
||||
</section>
|
||||
<div class="action">
|
||||
<a-button class="submit" type="primary" @click="handleOk" v-preventclick>确定</a-button>
|
||||
@@ -240,13 +262,13 @@ export default {
|
||||
// 会议费用
|
||||
meetingMoney: '',
|
||||
// 召开时间
|
||||
holdtime:'',
|
||||
holdtime: '',
|
||||
// 召开地点
|
||||
holdAddress:'',
|
||||
confirmLoading:false,
|
||||
holdAddress: '',
|
||||
confirmLoading: false,
|
||||
form: this.$form.createForm(this),
|
||||
formData:{},
|
||||
model:{},
|
||||
formData: {},
|
||||
model: {},
|
||||
labelCol: {
|
||||
xs: {span: 24},
|
||||
sm: {span: 6}
|
||||
@@ -268,6 +290,14 @@ export default {
|
||||
rules: [{required: true, message: '请选择参会企业'}],
|
||||
validateTrigger: 'change'
|
||||
},
|
||||
inviteCode: {
|
||||
rules: [{required: true, message: '请选择是否有邀请码'}],
|
||||
validateTrigger: 'change'
|
||||
},
|
||||
code: {
|
||||
rules: [{required: true, message: '请输入邀请码'}],
|
||||
validateTrigger: 'blur'
|
||||
},
|
||||
companyContactId: {
|
||||
rules: [{required: true, message: '请选择参会人'}],
|
||||
validateTrigger: 'change'
|
||||
@@ -284,11 +314,10 @@ export default {
|
||||
rules: [{required: true, message: '请选择身份'}],
|
||||
validateTrigger: 'change'
|
||||
},
|
||||
guestType:{
|
||||
guestType: {
|
||||
rules: [{required: true, message: '请选择嘉宾类型'}],
|
||||
validateTrigger: 'change'
|
||||
}
|
||||
|
||||
},
|
||||
// 身份类型
|
||||
identifyType: null,
|
||||
@@ -296,15 +325,17 @@ export default {
|
||||
guestType: null,
|
||||
selectedCompany: null,
|
||||
// 会议类型
|
||||
meetingType:'',
|
||||
meetingType: '',
|
||||
// 会议id
|
||||
meetingId:'',
|
||||
meetingId: '',
|
||||
// 会议费用合计
|
||||
meetingCostSum:'',
|
||||
meetingCostSum: '',
|
||||
// 会议费用是否为0
|
||||
meetingCostBool:false,
|
||||
url:{
|
||||
add:'/meeting/payMeetingSituation/signUp'
|
||||
meetingCostBool: false,
|
||||
// 是否有邀请码
|
||||
inviteCodeBool: false,
|
||||
url: {
|
||||
add: '/meeting/payMeetingSituation/signUp'
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -313,7 +344,7 @@ export default {
|
||||
// 获取会议id
|
||||
let id = this.GetQueryString('id')
|
||||
this.meetingId = id
|
||||
if(id){
|
||||
if (id) {
|
||||
this.getMeetingInfo(id)
|
||||
}
|
||||
},
|
||||
@@ -337,15 +368,15 @@ export default {
|
||||
this.meetingCostSum = Number(this.currentMeetingInfo.meetingCosts)
|
||||
}
|
||||
// 初始化召开时间
|
||||
if(this.currentMeetingInfo.startTime){
|
||||
if (this.currentMeetingInfo.startTime) {
|
||||
this.holdtime = this.currentMeetingInfo.startTime + '~' + this.currentMeetingInfo.endTime
|
||||
}
|
||||
// 初始化召开地点
|
||||
if(this.currentMeetingInfo.venue){
|
||||
if (this.currentMeetingInfo.venue) {
|
||||
this.holdAddress = this.currentMeetingInfo.venue + '/' + this.currentMeetingInfo.address
|
||||
}
|
||||
// 计算会议费用 会议费用为0 报名信息不显示邮寄信息与缴费信息 标协会议
|
||||
if(this.currentMeetingInfo.meetingType === '2' && this.currentMeetingInfo.meetingCostsVip){
|
||||
if (this.currentMeetingInfo.meetingType === '2' && this.currentMeetingInfo.meetingCostsVip) {
|
||||
// 标协会员的费用
|
||||
let vipCost = this.currentMeetingInfo.meetingCostsVip
|
||||
// 判断标协会员的费用是否是0
|
||||
@@ -353,21 +384,21 @@ export default {
|
||||
let cost = this.currentMeetingInfo.meetingCosts
|
||||
// 判断普通会员的费用是否是0
|
||||
let flag = cost === 0 || cost === '0.00'
|
||||
if(flag && flagVip){
|
||||
if (flag && flagVip) {
|
||||
// 说明会议费用为0
|
||||
this.meetingCostBool = true
|
||||
}else {
|
||||
} else {
|
||||
this.meetingCostBool = false
|
||||
}
|
||||
// 其他会议值判断一个费用
|
||||
}else if(this.currentMeetingInfo.meetingCosts){
|
||||
} else if (this.currentMeetingInfo.meetingCosts) {
|
||||
// 判断其他会议
|
||||
let cost = this.currentMeetingInfo.meetingCosts
|
||||
// 判断普通会员的费用是否是0
|
||||
let flag = cost === 0 || cost === '0.00'
|
||||
if(flag){
|
||||
if (flag) {
|
||||
this.meetingCostBool = true
|
||||
}else {
|
||||
} else {
|
||||
this.meetingCostBool = false
|
||||
}
|
||||
}
|
||||
@@ -413,24 +444,24 @@ export default {
|
||||
handleOk() {
|
||||
const that = this
|
||||
// 其他会议的表单验证
|
||||
if( this.$refs.formother !== undefined ){
|
||||
if (this.$refs.formother !== undefined) {
|
||||
this.$refs.formother.handleOk()
|
||||
}
|
||||
// 国际研讨会 VIP 演讲嘉宾 特邀嘉宾 的表单验证
|
||||
if( this.$refs.seminarVipForm !== undefined ){
|
||||
if (this.$refs.seminarVipForm !== undefined) {
|
||||
this.$refs.seminarVipForm.handleOk()
|
||||
}
|
||||
// 国际研讨会的合作伙伴的表单验证
|
||||
if( this.$refs.seminarPartnerForm !== undefined ){
|
||||
if (this.$refs.seminarPartnerForm !== undefined) {
|
||||
this.$refs.seminarPartnerForm.handleOk()
|
||||
}
|
||||
if(this.formData.stop){
|
||||
if (this.formData.stop) {
|
||||
return
|
||||
}
|
||||
this.form.validateFields((err, values) => {
|
||||
if (!err) {
|
||||
this.confirmLoading = true
|
||||
let submitData = Object.assign({},values,this.formData)
|
||||
let submitData = Object.assign({}, values, this.formData)
|
||||
submitData.companyId = values.companyId.id
|
||||
// 会议id
|
||||
submitData.meetingId = this.meetingId
|
||||
@@ -439,16 +470,16 @@ export default {
|
||||
console.log(submitData)
|
||||
let url = this.url.add
|
||||
let method = 'post'
|
||||
httpAction(url,submitData,method).then(res => {
|
||||
if(res.success){
|
||||
httpAction(url, submitData, method).then(res => {
|
||||
if (res.success) {
|
||||
that.$emit('ok')
|
||||
that.handleCancel()
|
||||
that.$message.success(res.message)
|
||||
that.confirmLoading = false
|
||||
}else {
|
||||
} else {
|
||||
that.$message.warn(res.message)
|
||||
}
|
||||
}).finally( () => {
|
||||
}).finally(() => {
|
||||
that.confirmLoading = false
|
||||
})
|
||||
}
|
||||
@@ -457,8 +488,8 @@ export default {
|
||||
/*
|
||||
* 获取表单的值
|
||||
* */
|
||||
getFormData(value){
|
||||
this.formData = Object.assign({},value)
|
||||
getFormData(value) {
|
||||
this.formData = Object.assign({}, value)
|
||||
},
|
||||
/*
|
||||
* 改变身份
|
||||
@@ -494,17 +525,59 @@ export default {
|
||||
that.form.setFieldsValue(pick(model, 'phone', 'email', 'post'))
|
||||
}
|
||||
// 设置邮寄联系人和地址
|
||||
if(this.$refs.formother !== undefined){
|
||||
if (this.$refs.formother !== undefined) {
|
||||
this.$refs.formother.setAddressVal(res.result)
|
||||
}
|
||||
})
|
||||
},
|
||||
/*
|
||||
* 是否有邀请码
|
||||
* */
|
||||
changeInviteCode(e) {
|
||||
if (e.target.value === 1) {
|
||||
// 选择是说明身份是嘉宾
|
||||
this.identifyType = 1
|
||||
this.inviteCodeBool = true
|
||||
} else if (e.target.value === 0) {
|
||||
this.inviteCodeBool = false
|
||||
}
|
||||
},
|
||||
/*
|
||||
* 取消
|
||||
* */
|
||||
handleCancel() {
|
||||
this.$router.go(-1)
|
||||
},
|
||||
/*
|
||||
* 下一步
|
||||
* */
|
||||
nextSetp() {
|
||||
console.log(this.currentMeetingInfo)
|
||||
// 获取邀请码
|
||||
let code = this.form.getFieldValue('code')
|
||||
console.log(code)
|
||||
console.log(this.currentMeetingInfo.cooperativeInvitationCode === code)
|
||||
switch (code) {
|
||||
// 合作伙伴
|
||||
case this.currentMeetingInfo.cooperativeInvitationCode:
|
||||
this.guestType = 4
|
||||
break
|
||||
// 演讲嘉宾
|
||||
case this.currentMeetingInfo.speakerInvitationCode:
|
||||
this.guestType = 2
|
||||
break
|
||||
// 特邀嘉宾
|
||||
case this.currentMeetingInfo.guestInvitationCode:
|
||||
this.guestType = 3
|
||||
break
|
||||
// vip
|
||||
case this.currentMeetingInfo.vipInvitationCode:
|
||||
this.guestType = 1
|
||||
break
|
||||
default :this.guestType = null
|
||||
}
|
||||
console.log(this.guestType)
|
||||
},
|
||||
addContactsOk() {
|
||||
this.$refs.selectContacts.getContactsList()
|
||||
}
|
||||
@@ -517,9 +590,6 @@ export default {
|
||||
text-align: center;
|
||||
position: relative;
|
||||
user-select: none;
|
||||
-webkit-user-seletct: none;
|
||||
-moz-user-seletct: none;
|
||||
-ms-user-seletct: none;
|
||||
|
||||
.header-img {
|
||||
width: 100%;
|
||||
@@ -588,6 +658,7 @@ export default {
|
||||
.mt-10 {
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.action {
|
||||
text-align: right;
|
||||
|
||||
@@ -595,6 +666,7 @@ export default {
|
||||
margin-right: 8px;
|
||||
}
|
||||
}
|
||||
|
||||
.meetingCost {
|
||||
text-align: right;
|
||||
padding-right: 20px;
|
||||
@@ -608,6 +680,7 @@ export default {
|
||||
line-height: 50px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.item-title {
|
||||
padding-left: 40px;
|
||||
box-sizing: border-box;
|
||||
@@ -629,4 +702,8 @@ export default {
|
||||
left: 15px;
|
||||
}
|
||||
}
|
||||
.center {
|
||||
text-align: center;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user