<picker :end="endDate" start="1900-01-01" mode="date" :value="form.birthday" @change="bindPickerDateChange">
<input class="input-size" type="text" v-model="form.birthday" disabled placeholder="请选择出生年月">
<uni-icons class="open-icon" type="arrowright" size="15"></uni-icons>
</picker>
选择日期之后使用change事件打印e.detail.value的值为NaN-0NaN-0NaN,因此将value值赋给form.birthday拿到的值也为NaN-0NaN-0NaN
1 个回复
h***@163.com (作者)
组件使用的代码是
<picker :end="endDate" start="1900-01-01" mode="date" :value="form.birthday" @change="bindPickerDateChange">
<input class="input-size" type="text" v-model="form.birthday" disabled
placeholder="请选择出生年月">
<uni-icons class="open-icon" type="arrowright" size="15"></uni-icons>
</picker>