Cascader
<Cascader v-model="category" v-if="clinicLexiconWords"
:data="clinicLexiconWords" placeholder="請選擇話術(shù)分類"
trigger="hover" filterable change-on-select
@on-change="(value, selectedData) => selectChange(value, selectedData)"></Cascader>
- change-on-select(可選擇任意一級)
- change事件傳參
@on-change="(value, selectedData) => test(value, selectedData, index)
https://blog.csdn.net/qq_40313245/article/details/86494682
Scroll
<Scroll :on-reach-bottom="handleReachBottom"
:distance-to-edge="Number(10)"
loading-text="更多內(nèi)容加載中..."
:height="scrollHeight">
<Card dis-hover v-for="(item, index) in checkList" :key="index">
<p>{{item.name}}</p>
<p>{{item.content}}</p>
</Card>
</Scroll>
handleReachBottom () {
return new Promise(resolve => {
setTimeout(() => {
this.page++
this.getList(this.page)
resolve();
}, 2000);
});
}
https://ithelp.ithome.com.tw/articles/10208999
https://blog.csdn.net/weixin_30596735/article/details/96721974
form表單驗證
<DatePicker format="yyyy-MM-dd" type="date" v-model="date"
@on-change="search.date = formatDate(date);getMovePraiseList(1);" placeholder="日期"></DatePicker>
- dataPicker v-model失效
必須on-change返回并賦值才能實現(xiàn)數(shù)據(jù)綁定腺劣,否則:value無法捕捉日期的而選擇變動
https://blog.csdn.net/sinat_31231955/article/details/82344273
loading
<Button :loading="addLoading" @click.native="boastAdd('AddForm')">新建</Button>