|
|
@@ -105,13 +105,13 @@ export default {
|
|
|
* 点击提现
|
|
|
*/
|
|
|
async doGet() {
|
|
|
- if(!this.coins.trim()) {
|
|
|
+ if(!(this.coins + '').replace(/[^\d\.]/g, '')) {
|
|
|
this.$message('请输入提现金额')
|
|
|
return
|
|
|
}
|
|
|
// 错误处理
|
|
|
- let coinsNum = +this.coins.trim()
|
|
|
- if(!coinsNum || this.coins.match(/\./) || coinsNum < 0 ) {
|
|
|
+ let coinsNum = +(this.coins + '').replace(/[^\d\.]/g, '')
|
|
|
+ if(!coinsNum || !(this.coins + '').match(/^\d+(\.\d{1,2}){0,1}$/) || coinsNum <= 1 ) {
|
|
|
this.$message('请输入正确的提现金额')
|
|
|
return
|
|
|
}
|