| | |
| | | <view class="list-item"> |
| | | <view class="list-item-label">联系电话</view> |
| | | <view class="list-item-input"> |
| | | <input type="text" placeholder="请输入联系电话" v-model="form.phone" /> |
| | | <input type="text" placeholder="请输入联系电话" v-model="form.phone" maxlength="11" /> |
| | | </view> |
| | | </view> |
| | | <view class="list-item" @click="show = true"> |
| | |
| | | chooseLocation() { |
| | | uni.chooseLocation({ |
| | | success: (res) => { |
| | | this.form.addr = res.name |
| | | console.log(res,"============================") |
| | | this.form.addr = res.address |
| | | this.form.latitude = res.latitude |
| | | this.form.longitude = res.longitude |
| | | }, |
| | |
| | | title: '联系电话不能为空!', |
| | | icon: 'none' |
| | | }) |
| | | const phoneReg = /^1\d{10}$/ |
| | | if (!phoneReg.test(this.form.phone)) { |
| | | return uni.showToast({ |
| | | title: '请输入正确的手机号格式', |
| | | icon: 'none' |
| | | }) |
| | | } |
| | | if (!this.form.areaName) return uni.showToast({ |
| | | title: '所在地区不能为空!', |
| | | icon: 'none' |