<el-form-item label="付款金额:">
<el-input
v-model="payformInline.paid_money"
clearable
@input="changes"
maxlength="8" oninput = "value=value.replace(/[^\d.]/g,'')"
placeholder="请输入付款金额"
></el-input>
</el-form-item>
oninput = "value=value.replace(/[^\d.]/g,'')"
是用来限制只能输入数字的
changes(value){
if(value > this.max) {
this.payformInline.paid_money = this.max;
}
this.max就是限制输入的最大值