|
@@ -24,7 +24,7 @@ export const innerRound = (num: number, length: number, decimal: number): number
|
|
|
export const roundForObj = (obj: string | number | undefined | null, decimal: number): number => {
|
|
export const roundForObj = (obj: string | number | undefined | null, decimal: number): number => {
|
|
|
let value;
|
|
let value;
|
|
|
if (obj === undefined || obj === null || isNaN(obj as number)) return 0;
|
|
if (obj === undefined || obj === null || isNaN(obj as number)) return 0;
|
|
|
- const length = decimal + 2;
|
|
|
|
|
|
|
+ const length = 6;
|
|
|
if (obj === +obj) {
|
|
if (obj === +obj) {
|
|
|
value = innerRound(obj, length, decimal);
|
|
value = innerRound(obj, length, decimal);
|
|
|
} else {
|
|
} else {
|