|
@@ -43,7 +43,6 @@
|
|
<view class="c-row b-b">
|
|
<view class="c-row b-b">
|
|
<text class="tit">价格类型</text>
|
|
<text class="tit">价格类型</text>
|
|
<view class="con-list">
|
|
<view class="con-list">
|
|
- <!-- <input placeholder="请填写价格类型" name="input" v-model="deptList.priceType"></input> -->
|
|
|
|
{{deptList.priceType}}
|
|
{{deptList.priceType}}
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
@@ -72,11 +71,21 @@
|
|
<input placeholder="请输入买方手机号" name="input" v-model="deptList.buyerPhone"></input>
|
|
<input placeholder="请输入买方手机号" name="input" v-model="deptList.buyerPhone"></input>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
- <view class="c-row ">
|
|
|
|
|
|
+ <!-- <view class="c-row ">
|
|
<text class="validate">获取验证码</text>
|
|
<text class="validate">获取验证码</text>
|
|
<view class="con-list">
|
|
<view class="con-list">
|
|
<input placeholder="请填写6位短信验证码" name="input" v-model="deptList.title1"></input>
|
|
<input placeholder="请填写6位短信验证码" name="input" v-model="deptList.title1"></input>
|
|
</view>
|
|
</view>
|
|
|
|
+ </view> -->
|
|
|
|
+
|
|
|
|
+ <view style='width:100%;border-bottom:1px solid #E8E9ED;position:relative;padding:10px;' class="flex">
|
|
|
|
+ <button :class='codestatus&&!sendDisabled?"active":""' @click='getcode'
|
|
|
|
+ class='getcode'>{{sendText}}</button>
|
|
|
|
+ <view style='width:70%;position:relative;margin-left: 200px;'>
|
|
|
|
+ <view class="con-list">
|
|
|
|
+ <input v-model='verifyCode' placeholder="请输入验证码" type="text">
|
|
|
|
+ </view>
|
|
|
|
+ </view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="buylow">
|
|
<view class="buylow">
|
|
@@ -235,7 +244,13 @@
|
|
baoIndex: 0,
|
|
baoIndex: 0,
|
|
baoType: ['不限(默认)', '散装', '大袋', '小袋'],
|
|
baoType: ['不限(默认)', '散装', '大袋', '小袋'],
|
|
chengIndex: -1,
|
|
chengIndex: -1,
|
|
- chengType: ['可议', '买方承担', '卖方承担']
|
|
|
|
|
|
+ chengType: ['可议', '买方承担', '卖方承担'],
|
|
|
|
+ codestatus: false,
|
|
|
|
+ sendDisabled: false,
|
|
|
|
+ sendText: '获取验证码',
|
|
|
|
+ verifyCode:"",
|
|
|
|
+ verification:true,
|
|
|
|
+ // DriverViewInfo:{},
|
|
}
|
|
}
|
|
},
|
|
},
|
|
computed: {
|
|
computed: {
|
|
@@ -263,6 +278,79 @@
|
|
})
|
|
})
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
|
|
+ async amendprice() {
|
|
|
|
+ var that = this
|
|
|
|
+ this.$api.doRequest('get', '/commonUser/loginVerifyCode', {
|
|
|
|
+ phone: this.deptList.buyerPhone,
|
|
|
|
+ verifyCode: this.verifyCode
|
|
|
|
+ }).then(res => {
|
|
|
|
+ if (res.data.code == 200) {
|
|
|
|
+
|
|
|
|
+ } else {
|
|
|
|
+ that.verification = false
|
|
|
|
+ console.log(that.verification,"1")
|
|
|
|
+ uni.showToast({
|
|
|
|
+ title: res.data.message,
|
|
|
|
+ icon: 'none',
|
|
|
|
+ duration: 2000
|
|
|
|
+ })
|
|
|
|
+ return false
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ .catch(res => {
|
|
|
|
+ that.verification = false
|
|
|
|
+ console.log(that.verification,"2")
|
|
|
|
+ uni.showToast({
|
|
|
|
+ title: res.data.message,
|
|
|
|
+ icon: 'none',
|
|
|
|
+ duration: 2000
|
|
|
|
+ })
|
|
|
|
+ return false
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ getcode() {
|
|
|
|
+ var that = this
|
|
|
|
+ if (/^0?1[3|4|5|6|7|8][0-9]\d{8}$/.test(that.deptList.buyerPhone)) {
|
|
|
|
+ this.$api.doRequest('get', '/commonUser/sendVerifyCode', {
|
|
|
|
+ phone: that.deptList.buyerPhone
|
|
|
|
+ }).then(res => {
|
|
|
|
+ if (res.data.code == 200) {
|
|
|
|
+ that.sendDisabled = true
|
|
|
|
+ let sec = 60
|
|
|
|
+ let interval = setInterval(() => {
|
|
|
|
+ sec--;
|
|
|
|
+ that.sendText = sec + 's后重发'
|
|
|
|
+ if (sec <= 0) {
|
|
|
|
+ that.sendDisabled = false
|
|
|
|
+ that.sendText = "获取验证码"
|
|
|
|
+ clearInterval(interval)
|
|
|
|
+ }
|
|
|
|
+ }, 1000)
|
|
|
|
+ } else {
|
|
|
|
+ uni.showToast({
|
|
|
|
+ title: res.data.message,
|
|
|
|
+ icon: 'none',
|
|
|
|
+ duration: 2000
|
|
|
|
+ })
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ .catch(res => {
|
|
|
|
+ uni.showToast({
|
|
|
|
+ title: res.data.message,
|
|
|
|
+ icon: 'none',
|
|
|
|
+ duration: 2000
|
|
|
|
+ })
|
|
|
|
+ return
|
|
|
|
+ });
|
|
|
|
+ } else {
|
|
|
|
+ uni.showToast({
|
|
|
|
+ title: '请输入正确的手机号',
|
|
|
|
+ icon: 'none',
|
|
|
|
+ duration: 2000
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ },
|
|
regionpicker(e) {
|
|
regionpicker(e) {
|
|
this.deptList.receivePrivate = e.province.label
|
|
this.deptList.receivePrivate = e.province.label
|
|
this.deptList.receiveCity = e.city.label
|
|
this.deptList.receiveCity = e.city.label
|
|
@@ -461,6 +549,10 @@
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+ if(this.amendprice() == false){
|
|
|
|
+ this.$api.msg('验证码输入有误!')
|
|
|
|
+ return
|
|
|
|
+ }
|
|
this.insertProcurementPlanInfo = this.deptList
|
|
this.insertProcurementPlanInfo = this.deptList
|
|
this.insertProcurementPlanInfo.basisPrice = -this.insertProcurementPlanInfo.basisPrice
|
|
this.insertProcurementPlanInfo.basisPrice = -this.insertProcurementPlanInfo.basisPrice
|
|
this.insertProcurementPlanInfo.commonId = this.userInfo.id
|
|
this.insertProcurementPlanInfo.commonId = this.userInfo.id
|
|
@@ -594,4 +686,23 @@
|
|
text-align: center;
|
|
text-align: center;
|
|
line-height: 30px;
|
|
line-height: 30px;
|
|
}
|
|
}
|
|
|
|
+ .getcode {
|
|
|
|
+ font-size: 14px;
|
|
|
|
+ position: absolute;
|
|
|
|
+ top: 50%;
|
|
|
|
+ transform: translateY(-50%);
|
|
|
|
+ color: #AFB3BF;
|
|
|
|
+ background: #F5F6F9;
|
|
|
|
+ height: 30px;
|
|
|
|
+ line-height: 30px;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ .getcode.active {
|
|
|
|
+ border: none;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ .getcode.active {
|
|
|
|
+ background: #22C572;
|
|
|
|
+ color: #fff;
|
|
|
|
+ }
|
|
</style>
|
|
</style>
|