1. Only positive and negative integers are allowed in the input box/ (? < =.) \-|[^\d\-]/g
@input="val=val.replace(/(? < =.) \-|[^\d\-]/g, '')Copy the code