...
|
...
|
@@ -14,6 +14,7 @@ Page({ |
|
|
title:'',
|
|
|
content:'',
|
|
|
min_num:'',
|
|
|
max_num:'',
|
|
|
date:'',
|
|
|
time:'',
|
|
|
address:'',
|
...
|
...
|
@@ -44,7 +45,15 @@ Page({ |
|
|
},
|
|
|
//输入最高人数
|
|
|
inputMaxNum(e) {
|
|
|
this.setData({max_num:e.detail.value})
|
|
|
this.setData({max_num:e.detail.value});
|
|
|
},
|
|
|
//输入最高人数失去焦点时
|
|
|
maxNumBlur() {
|
|
|
console.log('最低人数-最高人数',+this.data.min_num, +this.data.max_num,this.data.min_num>this.data.max_num,+this.data.min_num>+this.data.max_num);
|
|
|
if(+this.data.min_num>+this.data.max_num) {
|
|
|
wx.showToast({title:'最低人数不能高于最高人数',icon:'none'});
|
|
|
this.setData({max_num:''});
|
|
|
}
|
|
|
},
|
|
|
//输入地点
|
|
|
inputAddress(e) {
|
...
|
...
|
@@ -96,6 +105,8 @@ Page({ |
|
|
wx.showToast({title:'请上传图片',icon:'none'})
|
|
|
}else if (this.data.min_num === '') {
|
|
|
wx.showToast({title:'请填写最低人数',icon:'none'})
|
|
|
}else if (this.data.max_num === '') {
|
|
|
wx.showToast({title:'请填写最高人数',icon:'none'})
|
|
|
}else if(this.data.current_type === undefined) {
|
|
|
wx.showToast({title:'请选择类别',icon:'none'})
|
|
|
}else if(this.data.date === '') {
|
...
|
...
|
@@ -128,6 +139,7 @@ Page({ |
|
|
content:this.data.content,
|
|
|
pic: images_params,
|
|
|
number:this.data.min_num,
|
|
|
max_number:this.data.max_num,
|
|
|
select_id: this.data.type_id,//类别
|
|
|
time: this.data.date + ' ' + this.data.time,
|
|
|
name: this.data.address,
|
...
|
...
|
|