日本免费高清视频-国产福利视频导航-黄色在线播放国产-天天操天天操天天操天天操|www.shdianci.com

學(xué)無先后,達(dá)者為師

網(wǎng)站首頁(yè) 編程語言 正文

el-input當(dāng)type=number時(shí)只能輸入數(shù)字

作者:布偶亂跑 更新時(shí)間: 2022-04-10 編程語言

在使用element過程中,遇到了輸入框需要加后綴,只能輸正整數(shù)的需求,搜索后找到方法:

 <el-input  type="number"
            min="0"
            max="999999"
            onKeypress="return (/[\d]/.test(String.fromCharCode(event.keyCode)))"
            v-model="value1">
    <template slot="append">.comtemplate>
 el-input>

原文鏈接:https://blog.csdn.net/weixin_44634372/article/details/113743335

欄目分類
最近更新