【bug】国际研讨会的校验
This commit is contained in:
@@ -56,7 +56,6 @@ Page({
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
debugger
|
|
||||||
if(this.data.singInPersonInfo.payMode === 2 && (this.data.ordeCode === '' || this.data.ordeCode === undefined || this.data.ordeCode === null) ){
|
if(this.data.singInPersonInfo.payMode === 2 && (this.data.ordeCode === '' || this.data.ordeCode === undefined || this.data.ordeCode === null) ){
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请输入缴费订单号后四位数',
|
title: '请输入缴费订单号后四位数',
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
|
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<text class="item-label flex-1 validate">手机号:</text>
|
<text class="item-label flex-1 validate">手机号:</text>
|
||||||
<input placeholder-class="text-right" bindblur="validatePhone" data-type="phone" data-message='请输入手机号' data-errmsg='请输入正确的手机号' type="number" maxlength="11" name="phone" bindinput="bindInputPhone" value="{{phone}}" placeholder="请输入手机号" />
|
<input placeholder-class="text-right" disabled bindblur="validatePhone" data-type="phone" data-message='请输入手机号' data-errmsg='请输入正确的手机号' type="number" maxlength="11" name="phone" bindinput="bindInputPhone" value="{{phone}}" placeholder="请输入手机号" />
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="form-item-radio">
|
<view class="form-item-radio">
|
||||||
|
|||||||
@@ -166,21 +166,26 @@ Page({
|
|||||||
needHotel(e) {
|
needHotel(e) {
|
||||||
let value = e.detail.value
|
let value = e.detail.value
|
||||||
this.setData({
|
this.setData({
|
||||||
needHotel: value
|
needHotel: value,
|
||||||
|
inHotelTime:'请选择入住酒店时间',
|
||||||
|
outHotelTime:'请选择离店时间'
|
||||||
})
|
})
|
||||||
|
|
||||||
},
|
},
|
||||||
// 是否接站
|
// 是否接站
|
||||||
needPick(e) {
|
needPick(e) {
|
||||||
let value = e.detail.value
|
let value = e.detail.value
|
||||||
this.setData({
|
this.setData({
|
||||||
needPick: value
|
needPick: value,
|
||||||
|
arrivalTime:'请选择抵达时间'
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 是否送站
|
// 是否送站
|
||||||
needSend(e) {
|
needSend(e) {
|
||||||
let value = e.detail.value
|
let value = e.detail.value
|
||||||
this.setData({
|
this.setData({
|
||||||
needSend: value
|
needSend: value,
|
||||||
|
departureTime:'请选择离开时间'
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 缴费方式选择
|
// 缴费方式选择
|
||||||
@@ -214,6 +219,13 @@ Page({
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
// 是否住酒店 参会人与内部企业 清除抵达时间 离开时间
|
||||||
|
needHotelNot(){
|
||||||
|
this.setData({
|
||||||
|
arrivalTime:'请选择抵达时间',
|
||||||
|
departureTime:'请选择离开时间'
|
||||||
|
})
|
||||||
|
},
|
||||||
// 选择参会单位
|
// 选择参会单位
|
||||||
selectCompany(e) {
|
selectCompany(e) {
|
||||||
if (this.data.nolimitBool) {
|
if (this.data.nolimitBool) {
|
||||||
@@ -299,7 +311,11 @@ Page({
|
|||||||
});
|
});
|
||||||
console.log(validateArr[0].type);
|
console.log(validateArr[0].type);
|
||||||
this.setData({
|
this.setData({
|
||||||
guestType: validateArr[0].type
|
guestType: validateArr[0].type,
|
||||||
|
haveMeals:'',
|
||||||
|
needHotel:'',
|
||||||
|
needPick:'',
|
||||||
|
needSend:''
|
||||||
})
|
})
|
||||||
switch (validateArr[0].type) {
|
switch (validateArr[0].type) {
|
||||||
case '1':
|
case '1':
|
||||||
@@ -498,14 +514,6 @@ Page({
|
|||||||
// 确定
|
// 确定
|
||||||
formSubmit(e) {
|
formSubmit(e) {
|
||||||
const formData = Object.assign({}, e.detail.value)
|
const formData = Object.assign({}, e.detail.value)
|
||||||
if (this.data.flag) {
|
|
||||||
wx.showToast({
|
|
||||||
title: '信息输入有误',
|
|
||||||
icon: 'error',
|
|
||||||
duration: 2000
|
|
||||||
})
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (!this.data.selectedCompany.id) {
|
if (!this.data.selectedCompany.id) {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请选择参会单位',
|
title: '请选择参会单位',
|
||||||
@@ -559,7 +567,8 @@ Page({
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (formData.identity == '2' && this.data.selectedPostPerson.id == -'' || this.data.selectedPostPerson.id === undefined) {
|
// 不需要发票不校验
|
||||||
|
if (formData.identity == '2' && (this.data.selectedPostPerson.id == -'' || this.data.selectedPostPerson.id === undefined) && formData.needInvoice !== '0') {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请选择邮寄联系人',
|
title: '请选择邮寄联系人',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -568,7 +577,7 @@ Page({
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
// 邮寄地址
|
// 邮寄地址
|
||||||
if (formData.postContactAddress === '' && this.data.guestType !== '1') {
|
if (formData.postContactAddress === '' && this.data.guestType !== '1' && formData.needInvoice !== '0') {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请输入邮寄地址',
|
title: '请输入邮寄地址',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -577,7 +586,7 @@ Page({
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
// 邮编
|
// 邮编
|
||||||
if (formData.postCode === '' && this.data.guestType !== '1') {
|
if (formData.postCode === '' && this.data.guestType !== '1' && formData.needInvoice !== '0') {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请输入邮编',
|
title: '请输入邮编',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -615,7 +624,7 @@ Page({
|
|||||||
}
|
}
|
||||||
// 入住酒店时间
|
// 入住酒店时间
|
||||||
|
|
||||||
if (formData.inHotelTime === '' && this.data.needHotel === '1' && this.data.this.data.guestType === '1') {
|
if ((formData.inHotelTime === '' || formData.inHotelTime === null || formData.inHotelTime === undefined) && this.data.needHotel === '1' && this.data.guestType === '1') {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请选择入住酒店时间',
|
title: '请选择入住酒店时间',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -626,7 +635,7 @@ Page({
|
|||||||
|
|
||||||
// 离店时间
|
// 离店时间
|
||||||
|
|
||||||
if (formData.outHotelTime === '' && this.data.needHotel === '1' && this.data.this.data.guestType === '1') {
|
if ((formData.outHotelTime === '' || formData.outHotelTime === null || formData.outHotelTime === undefined ) && this.data.needHotel === '1' && this.data.guestType === '1') {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请选择离店时间',
|
title: '请选择离店时间',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -636,7 +645,7 @@ Page({
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 房型
|
// 房型
|
||||||
if (formData.roomLayout === '' && this.data.needHotel === '1' && this.data.this.data.guestType === '1') {
|
if (formData.roomLayout === '' && this.data.needHotel === '1' && this.data.guestType === '1') {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请输入房型',
|
title: '请输入房型',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -655,7 +664,7 @@ Page({
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
// 抵达时间
|
// 抵达时间
|
||||||
if (this.data.identity === '1' && this.data.needPick === '1' && this.data.guestType !== '4' && formData.arrivalTime === '') {
|
if (this.data.identity === '1' && this.data.needPick === '1' && this.data.guestType !== '4' && (formData.arrivalTime === '' || formData.arrivalTime === null || formData.arrivalTime === undefined )) {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请选择抵达时间',
|
title: '请选择抵达时间',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -693,7 +702,7 @@ Page({
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 离开时间
|
// 离开时间
|
||||||
if (this.data.identity === '1' && this.data.needSend === '1' && this.data.guestType !== '4' && formData.departureTime === '') {
|
if (this.data.identity === '1' && this.data.needSend === '1' && this.data.guestType !== '4' && (formData.departureTime === '' || formData.departureTime === null || formData.departureTime === undefined) ) {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请选择离开时间',
|
title: '请选择离开时间',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -739,6 +748,8 @@ Page({
|
|||||||
formData.companyId = this.data.selectedCompany.id
|
formData.companyId = this.data.selectedCompany.id
|
||||||
// 嘉宾身份类型
|
// 嘉宾身份类型
|
||||||
formData.guestType = this.data.guestType
|
formData.guestType = this.data.guestType
|
||||||
|
// 参会身份
|
||||||
|
formData.identity = this.data.identity
|
||||||
// 国际研讨会嘉宾上传的照片id
|
// 国际研讨会嘉宾上传的照片id
|
||||||
formData.photo = this.data.imageIds
|
formData.photo = this.data.imageIds
|
||||||
// 国际研讨会嘉宾上传的ppt
|
// 国际研讨会嘉宾上传的ppt
|
||||||
@@ -783,7 +794,19 @@ Page({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
}else{
|
||||||
|
wx.showToast({
|
||||||
|
title: res.message,
|
||||||
|
icon:'none',
|
||||||
|
duration:2000
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
}).catch(err => {
|
||||||
|
wx.showToast({
|
||||||
|
title: err.message,
|
||||||
|
icon:'none',
|
||||||
|
duration:2000
|
||||||
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
@@ -794,7 +817,7 @@ Page({
|
|||||||
if (options.meetingId) {
|
if (options.meetingId) {
|
||||||
this.queryMeetingDetail(options.meetingId)
|
this.queryMeetingDetail(options.meetingId)
|
||||||
}
|
}
|
||||||
// this.queryMeetingDetail('1455716624649428994')
|
// this.queryMeetingDetail('1456069163911823361')
|
||||||
if (options.nolimit) {
|
if (options.nolimit) {
|
||||||
this.setData({
|
this.setData({
|
||||||
nolimitBool: true
|
nolimitBool: true
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<text class="item-label flex-1 validate">手机号:</text>
|
<text class="item-label flex-1 validate">手机号:</text>
|
||||||
<input placeholder-class="text-right" bindblur="validatePhone" data-type="phone" data-message='请输入手机号'
|
<input placeholder-class="text-right" bindblur="validatePhone" data-type="phone" data-message='请输入手机号'
|
||||||
data-errmsg='请输入正确的手机号' type="number" maxlength="11" name="phone" bindinput="bindInputPhone" value="{{phone}}"
|
data-errmsg='请输入正确的手机号' disabled type="number" maxlength="11" name="phone" bindinput="bindInputPhone" value="{{phone}}"
|
||||||
placeholder="请输入手机号" />
|
placeholder="请输入手机号" />
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@@ -112,7 +112,7 @@
|
|||||||
<text class="item-label flex-1">是否住酒店:</text>
|
<text class="item-label flex-1">是否住酒店:</text>
|
||||||
</view>
|
</view>
|
||||||
<view>
|
<view>
|
||||||
<radio-group name='checkInHotel'>
|
<radio-group name='checkInHotel' bindchange="needHotelNot">
|
||||||
<label class="radio radio-item" wx:for="{{need}}" wx:key="item">
|
<label class="radio radio-item" wx:for="{{need}}" wx:key="item">
|
||||||
<radio class="radio-scale" value="{{item.value}}" color="#069F99"/>{{item.name}}
|
<radio class="radio-scale" value="{{item.value}}" color="#069F99"/>{{item.name}}
|
||||||
</label>
|
</label>
|
||||||
|
|||||||
Reference in New Issue
Block a user