|
|
|
@ -31,7 +31,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
<view class="activityBox-row">
|
|
|
|
<view class="activityBox-row">
|
|
|
|
<text class="icon-renshu iconfont"></text>
|
|
|
|
<text class="icon-renshu iconfont"></text>
|
|
|
|
<text>人数限制:{{(list.form==2?10 : (numberlist.total==0?'不限':numberlist.total))}}</text>
|
|
|
|
<text>{{list.form==2?'起约人数':'人数限制'}}:{{(list.form==2?10 : (numberlist.total==0?'不限':numberlist.total))}}</text>
|
|
|
|
|
|
|
|
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="activityBox-row flex-row align-center" @click="tothere">
|
|
|
|
<view class="activityBox-row flex-row align-center" @click="tothere">
|
|
|
|
<text class="icon-ditu-dibiao iconfont"></text>
|
|
|
|
<text class="icon-ditu-dibiao iconfont"></text>
|
|
|
|
@ -44,27 +45,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<u--form labelPosition="left" :model="form" :rules="rules" ref="form">
|
|
|
|
<u--form labelPosition="left" :model="form" :rules="rules" ref="form">
|
|
|
|
<view class="box-card">
|
|
|
|
<view class="box-card" v-if="type=='team'">
|
|
|
|
<view class="box-card-title">
|
|
|
|
<view class="box-card-title">
|
|
|
|
参观人数
|
|
|
|
参加人数
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="box-card-content">
|
|
|
|
<view class="box-card-content">
|
|
|
|
<u-form-item v-if="type=='user'" label="人数" labelWidth="120" prop="total" ref="total">
|
|
|
|
<u-form-item label="人数" labelWidth="120" prop="total" ref="total" v-if="type=='team'">
|
|
|
|
<u-number-box slot="right" v-model="form.total" inputWidth="44" color="#EF9525"
|
|
|
|
<u-number-box slot="right" v-model="form.total" inputWidth="44" color="#EF9525"
|
|
|
|
bgColor="#FCF6E3" :min="(type=='user'?1:list.team_min_count)"
|
|
|
|
bgColor="#FCF6E3" :min="(list.form==2?10:(type=='user'?1:list.team_min_count))"
|
|
|
|
:max="(type=='user'?list.person_max_count:list.team_max_count)" class="plus">
|
|
|
|
:max="(type=='user'?list.person_max_count:list.team_max_count)" class="plus">
|
|
|
|
</u-number-box>
|
|
|
|
</u-number-box>
|
|
|
|
</u-form-item>
|
|
|
|
</u-form-item>
|
|
|
|
<u-form-item v-else label="人数" labelWidth="120" prop="total" ref="total">
|
|
|
|
<!-- <u-form-item v-else label="人数" labelWidth="120" prop="total" ref="total">
|
|
|
|
{{form.total}} 请添加参与名单
|
|
|
|
{{form.total}} 请添加参与名单
|
|
|
|
</u-form-item>
|
|
|
|
</u-form-item> -->
|
|
|
|
<view class="box-tips" v-if="type=='team'">
|
|
|
|
<!-- <view class="box-tips" v-if="type=='team'">
|
|
|
|
<text class="box-tips-txt"
|
|
|
|
<text class="box-tips-txt"
|
|
|
|
v-if="type=='user'">每单限购{{list.person_max_count}}张,同一身份证当天限购1张</text>
|
|
|
|
v-if="type=='user'">每单限购{{list.person_max_count}}张,同一身份证当天限购1张</text>
|
|
|
|
<text class="box-tips-txt"
|
|
|
|
<text class="box-tips-txt"
|
|
|
|
v-if="type=='team'">{{list.form==2?10:list.team_min_count}}人以上可团体预约<!-- ,一个团体最多{{list.team_max_count}}人 --></text>
|
|
|
|
v-if="type=='team'">{{list.form==2?10:list.team_min_count}}人以上可团体预约</text>
|
|
|
|
</view>
|
|
|
|
</view> -->
|
|
|
|
<view>
|
|
|
|
<!-- <view>
|
|
|
|
<view class="box-card-content">
|
|
|
|
<view class="box-card-content">
|
|
|
|
<view class="book-box" style="padding-top: 20rpx;">
|
|
|
|
<view class="book-box" style="padding-top: 20rpx;">
|
|
|
|
<view class="book-box-card">
|
|
|
|
<view class="book-box-card">
|
|
|
|
@ -83,7 +84,6 @@
|
|
|
|
</u-icon>
|
|
|
|
</u-icon>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view>{{item.name}}</view>
|
|
|
|
<view>{{item.name}}</view>
|
|
|
|
<!-- <view>{{item.datef}}</view> -->
|
|
|
|
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</block>
|
|
|
|
</block>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
@ -95,8 +95,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
|
|
|
|
|
|
|
|
</view>
|
|
|
|
</view> -->
|
|
|
|
<view class="box-visitor">
|
|
|
|
<!-- <view class="box-visitor">
|
|
|
|
<block v-for="(item,index) in form.details_list" :key="index">
|
|
|
|
<block v-for="(item,index) in form.details_list" :key="index">
|
|
|
|
<view class="box-visitor-item">
|
|
|
|
<view class="box-visitor-item">
|
|
|
|
<view class="box-visitor-item-left">
|
|
|
|
<view class="box-visitor-item-left">
|
|
|
|
@ -113,9 +113,9 @@
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</block>
|
|
|
|
</block>
|
|
|
|
</view>
|
|
|
|
</view> -->
|
|
|
|
|
|
|
|
|
|
|
|
<view class="box-footer">
|
|
|
|
<!-- <view class="box-footer">
|
|
|
|
<view class="box-footer-left">
|
|
|
|
<view class="box-footer-left">
|
|
|
|
<view class="box-button" @click="openAdd">
|
|
|
|
<view class="box-button" @click="openAdd">
|
|
|
|
<u-icon name="plus" color="#EF9525"></u-icon>
|
|
|
|
<u-icon name="plus" color="#EF9525"></u-icon>
|
|
|
|
@ -135,28 +135,24 @@
|
|
|
|
<u-icon name="question-circle-fill" color="#EF9525" size="40rpx"></u-icon>
|
|
|
|
<u-icon name="question-circle-fill" color="#EF9525" size="40rpx"></u-icon>
|
|
|
|
<text class="book-box-selectInfo-righttxt" style="margin-left: 20rpx;">批量导入说明</text>
|
|
|
|
<text class="book-box-selectInfo-righttxt" style="margin-left: 20rpx;">批量导入说明</text>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view> -->
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="box-card" v-if="type=='team'">
|
|
|
|
<!-- v-if="type=='team'" -->
|
|
|
|
|
|
|
|
<view class="box-card">
|
|
|
|
<view class="box-card-title">
|
|
|
|
<view class="box-card-title">
|
|
|
|
联系人信息
|
|
|
|
联系人信息
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="box-card-content">
|
|
|
|
<view class="box-card-content">
|
|
|
|
<u-form-item :label="(type=='team'?'领队人':'联系人')" labelWidth="80" prop="leader" ref="leader"
|
|
|
|
<u-form-item :label="(type=='team'?'领队人':'预约人')" labelWidth="80" prop="leader" ref="leader"
|
|
|
|
required>
|
|
|
|
required>
|
|
|
|
<u-input placeholder="请输入联系人" v-model="form.leader"></u-input>
|
|
|
|
<u-input :placeholder="`请输入${type=='team'?'领队人':'预约人'}`" v-model="form.leader"></u-input>
|
|
|
|
</u-form-item>
|
|
|
|
</u-form-item>
|
|
|
|
<block>
|
|
|
|
<block>
|
|
|
|
<u-form-item label="单位名称" labelWidth="80" prop="unit" required>
|
|
|
|
<u-form-item v-if="type=='team'" label="单位名称" labelWidth="80" prop="unit" required>
|
|
|
|
<u-input placeholder="请输入单位名称" v-model="form.unit"></u-input>
|
|
|
|
<u-input placeholder="请输入单位名称" v-model="form.unit"></u-input>
|
|
|
|
</u-form-item>
|
|
|
|
</u-form-item>
|
|
|
|
<u-form-item label="证件类型" labelWidth="80" prop="card_type1" required>
|
|
|
|
<!-- <u-form-item label="证件类型" labelWidth="80" prop="card_type1" required>
|
|
|
|
<!-- <u-radio-group v-model="form.card_type">
|
|
|
|
|
|
|
|
<u-radio width="50%" activeColor="#EF9525" v-for="(item, index) in cardType"
|
|
|
|
|
|
|
|
:key="index" :name=item.id :label="item.name">
|
|
|
|
|
|
|
|
</u-radio>
|
|
|
|
|
|
|
|
</u-radio-group> -->
|
|
|
|
|
|
|
|
<u-cell-group :border="false">
|
|
|
|
<u-cell-group :border="false">
|
|
|
|
<u-cell @click="showCards" :title="card_type_names" :isLink="true"
|
|
|
|
<u-cell @click="showCards" :title="card_type_names" :isLink="true"
|
|
|
|
arrow-direction="down"></u-cell>
|
|
|
|
arrow-direction="down"></u-cell>
|
|
|
|
@ -164,7 +160,7 @@
|
|
|
|
</u-form-item>
|
|
|
|
</u-form-item>
|
|
|
|
<u-form-item label="证件号码" labelWidth="80" prop="from.idcard" required>
|
|
|
|
<u-form-item label="证件号码" labelWidth="80" prop="from.idcard" required>
|
|
|
|
<u-input placeholder="请输入证件号码" v-model="form.idcard"></u-input>
|
|
|
|
<u-input placeholder="请输入证件号码" v-model="form.idcard"></u-input>
|
|
|
|
</u-form-item>
|
|
|
|
</u-form-item> -->
|
|
|
|
</block>
|
|
|
|
</block>
|
|
|
|
<u-form-item label="手机号" labelWidth="80" prop="mobile" ref="mobile" required>
|
|
|
|
<u-form-item label="手机号" labelWidth="80" prop="mobile" ref="mobile" required>
|
|
|
|
<u-input readonly placeholder="请输入手机号" v-model="form.mobile"></u-input>
|
|
|
|
<u-input readonly placeholder="请输入手机号" v-model="form.mobile"></u-input>
|
|
|
|
@ -567,20 +563,20 @@
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (that.formUser.card_type == 1) {
|
|
|
|
if (that.formUser.card_type == 1) {
|
|
|
|
if (this.util.isNull(this.formUser.idcard)) {
|
|
|
|
// if (this.util.isNull(this.formUser.idcard)) {
|
|
|
|
uni.showToast({
|
|
|
|
// uni.showToast({
|
|
|
|
icon: "none",
|
|
|
|
// icon: "none",
|
|
|
|
title: "请填写身份证号"
|
|
|
|
// title: "请填写身份证号"
|
|
|
|
})
|
|
|
|
// })
|
|
|
|
return false;
|
|
|
|
// return false;
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
if (!that.util.isValidCardID(that.formUser.idcard)) {
|
|
|
|
// if (!that.util.isValidCardID(that.formUser.idcard)) {
|
|
|
|
uni.showToast({
|
|
|
|
// uni.showToast({
|
|
|
|
icon: "none",
|
|
|
|
// icon: "none",
|
|
|
|
title: "请正确输入身份证号"
|
|
|
|
// title: "请正确输入身份证号"
|
|
|
|
})
|
|
|
|
// })
|
|
|
|
return false;
|
|
|
|
// return false;
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (that.isEdit) {
|
|
|
|
if (that.isEdit) {
|
|
|
|
that.form.details_list[that.isEditIndex] = that.formUser;
|
|
|
|
that.form.details_list[that.isEditIndex] = that.formUser;
|
|
|
|
@ -648,51 +644,51 @@
|
|
|
|
},
|
|
|
|
},
|
|
|
|
submitOrder() {
|
|
|
|
submitOrder() {
|
|
|
|
|
|
|
|
|
|
|
|
if (this.form.details_list.length != this.form.total) {
|
|
|
|
// if (this.form.details_list.length != this.form.total) {
|
|
|
|
uni.showToast({
|
|
|
|
// uni.showToast({
|
|
|
|
icon: "none",
|
|
|
|
// icon: "none",
|
|
|
|
title: "请正确添加观众数量"
|
|
|
|
// title: "请正确添加观众数量"
|
|
|
|
})
|
|
|
|
// })
|
|
|
|
return false;
|
|
|
|
// return false;
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
if (this.type != "user") {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// if (this.type != "user") {
|
|
|
|
if (this.util.isNull(this.form.leader)) {
|
|
|
|
if (this.util.isNull(this.form.leader)) {
|
|
|
|
uni.showToast({
|
|
|
|
uni.showToast({
|
|
|
|
icon: "none",
|
|
|
|
icon: "none",
|
|
|
|
title: "请填写领队姓名"
|
|
|
|
title: "请填写姓名"
|
|
|
|
})
|
|
|
|
})
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if(this.type != "user"){
|
|
|
|
if (this.util.isNull(this.form.unit)) {
|
|
|
|
if (this.util.isNull(this.form.unit)) {
|
|
|
|
uni.showToast({
|
|
|
|
|
|
|
|
icon: "none",
|
|
|
|
|
|
|
|
title: "请填写单位名称"
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
return false;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (this.util.isNull(this.form.idcard)) {
|
|
|
|
|
|
|
|
uni.showToast({
|
|
|
|
|
|
|
|
icon: "none",
|
|
|
|
|
|
|
|
title: "请填写证件号"
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
return false;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (this.form.card_type == 1) {
|
|
|
|
|
|
|
|
if (!this.util.isValidCardID(this.form.idcard)) {
|
|
|
|
|
|
|
|
uni.showToast({
|
|
|
|
uni.showToast({
|
|
|
|
icon: "none",
|
|
|
|
icon: "none",
|
|
|
|
title: "请正确输入身份证号"
|
|
|
|
title: "请填写单位名称"
|
|
|
|
})
|
|
|
|
})
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// if (this.util.isNull(this.form.idcard)) {
|
|
|
|
|
|
|
|
// uni.showToast({
|
|
|
|
|
|
|
|
// icon: "none",
|
|
|
|
|
|
|
|
// title: "请填写证件号"
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// return false;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// if (this.form.card_type == 1) {
|
|
|
|
|
|
|
|
// if (!this.util.isValidCardID(this.form.idcard)) {
|
|
|
|
|
|
|
|
// uni.showToast({
|
|
|
|
|
|
|
|
// icon: "none",
|
|
|
|
|
|
|
|
// title: "请正确输入身份证号"
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// return false;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
if (this.util.isNull(this.form.mobile)) {
|
|
|
|
if (this.util.isNull(this.form.mobile)) {
|
|
|
|
uni.showToast({
|
|
|
|
uni.showToast({
|
|
|
|
icon: "none",
|
|
|
|
icon: "none",
|
|
|
|
@ -706,9 +702,18 @@
|
|
|
|
})
|
|
|
|
})
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
if(this.type=='user'){
|
|
|
|
|
|
|
|
this.form.details_list.push({
|
|
|
|
|
|
|
|
name:this.form.leader,
|
|
|
|
|
|
|
|
mobile:this.form.mobile,
|
|
|
|
|
|
|
|
card_type:1,
|
|
|
|
|
|
|
|
idcard:''
|
|
|
|
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
console.log("this.form",this.form)
|
|
|
|
|
|
|
|
// return
|
|
|
|
var that = this;
|
|
|
|
var that = this;
|
|
|
|
this.util.request({
|
|
|
|
this.util.request({
|
|
|
|
api: '/api/mobile/activity/order',
|
|
|
|
api: '/api/mobile/activity/order',
|
|
|
|
|