fix(editable_champ): can enter negative decimal number
This commit is contained in:
parent
c53b0a1c9e
commit
ff700b19bb
2 changed files with 6 additions and 1 deletions
|
@ -54,6 +54,6 @@ export class FormatController extends ApplicationController {
|
|||
const decimalSeparator =
|
||||
value.lastIndexOf(',') > value.lastIndexOf('.') ? ',' : '.';
|
||||
|
||||
return value.replace(new RegExp(`[^\\d${decimalSeparator}]`, 'g'), '');
|
||||
return value.replace(new RegExp(`[^-?\\d${decimalSeparator}]`, 'g'), '');
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue