| | |
| | | :previewFullImage="true"> |
| | | </u-upload> |
| | | </u-form-item> |
| | | <u-form-item prop="startTime" |
| | | label="运输证开始时间" |
| | | labelWidth="20%" |
| | | borderBottom> |
| | | <uni-datetime-picker v-model="tranSportForm.startTime" type="date" :start="minDate" /> |
| | | </u-form-item> |
| | | <u-form-item prop="expirationTime" |
| | | label="运输证过期时间" |
| | | labelWidth="20%" |
| | | borderBottom> |
| | | <uni-datetime-picker v-model="tranSportForm.expirationTime" type="datetime" :start="minDate" /> |
| | | <uni-datetime-picker v-model="tranSportForm.expirationTime" type="date" :start="minDate" /> |
| | | </u-form-item> |
| | | <view class="adddelete"> |
| | | <u-button text="添加驾驶员" |
| | |
| | | message: '请选择运输证过期时间', |
| | | trigger: ['blur', 'change'] |
| | | }, |
| | | startTime:{ |
| | | type: 'string', |
| | | required: true, |
| | | message: '请选择运输证过期时间', |
| | | trigger: ['blur', 'change'] |
| | | }, |
| | | carNo: [{ |
| | | type: 'string', |
| | | required: true, |
| | |
| | | let year = now.getFullYear(); |
| | | let month = this.padStart(now.getMonth() + 1); // 月份是从0开始的 |
| | | let day = this.padStart(now.getDate()); |
| | | let hour = this.padStart(now.getHours()); |
| | | let minute = this.padStart(now.getMinutes()); |
| | | let second = this.padStart(now.getSeconds()); |
| | | return `${year}-${month}-${day} ${hour}:${minute}:${second}`; |
| | | return `${year}-${month}-${day}`; |
| | | }, |
| | | padStart(value) { |
| | | return value.toString().padStart(2, '0'); |
| | |
| | | supercargoInfo = this.supercargoList.map((item, index) => { |
| | | return item.driverName+ '|'+item.driverIdcard+"|"+item.driverPhone |
| | | }).join(","); |
| | | if(this.tranSportForm.startTime){ |
| | | this.tranSportForm.startTime=this.tranSportForm.startTime+" 00:01" |
| | | } |
| | | if(this.tranSportForm.expirationTime){ |
| | | this.tranSportForm.expirationTime=this.tranSportForm.expirationTime.slice(0,16) |
| | | this.tranSportForm.expirationTime=this.tranSportForm.expirationTime+" 23:55" |
| | | } |
| | | this.$reqPost('addJcroadtransport', { |
| | | userId:this.userInfo.userId, |
| | |
| | | }, 'json').then(res => { |
| | | if (res.code == 0) { |
| | | this.editTranShow = false; |
| | | this.$u.toast('修改成功'); |
| | | this.$u.toast('提交成功'); |
| | | this.init(); |
| | | } else { |
| | | uni.showToast({ |