<van-field size="large" readonly bind:tap="openPicker" is-link required label="到达时间" error-message="{{arriveTimeError}}" model:value="{{arriveTime}}" bind:focus="arriveTimeFocus" bind:blur="arriveTimeRules"></van-field>
<van-action-sheet title="选择到达时间" show="{{ show }}" bind:close="onClose" >
<van-datetime-picker type="datetime" bind:cancel="onCancel"
bind:confirm="onConfirm" value="{{currentDate}}" />
</van-action-sheet>
data: {
arriveTime: '',
currentDate:new Date().getTime()
}
//关键点在currentDate:new Date().getTime()
//和 van-datetime-picker 的value="{{currentDate}}"这个属性
文章来源地址https://uudwc.com/A/R63me
文章来源:https://uudwc.com/A/R63me