push
github
2100 of 3363 branches covered (62.44%)
282 of 757 new or added lines in 74 files covered. (37.25%)
14879 existing lines in 182 files now uncovered.25574 of 98035 relevant lines covered (26.09%)
5.17 hits per line
1 |
import { NumberFieldCore } from '@teable/core'; |
1✔ |
2 |
import type { IFieldBase } from '../field-base'; |
1✔ |
3 |
|
1✔ |
4 |
export class NumberFieldDto extends NumberFieldCore implements IFieldBase { |
1✔ |
5 |
convertCellValue2DBValue(value: unknown): unknown { |
1✔ |
UNCOV
6
|
if (this.isMultipleCellValue) { |
× |
UNCOV
7
|
return value == null ? value : JSON.stringify(value);
|
× |
UNCOV
8
|
} |
× |
UNCOV
9
|
return value;
|
× |
UNCOV
10
|
} |
× |
11 |
|
1✔ |
12 |
convertDBValue2CellValue(value: unknown): unknown { |
1✔ |
UNCOV
13
|
if (this.isMultipleCellValue) { |
× |
UNCOV
14
|
return value == null || typeof value === 'object' ? value : JSON.parse(value as string); |
× |
UNCOV
15
|
} |
× |
UNCOV
16
|
return value;
|
× |
UNCOV
17
|
} |
× |
18 |
} |
1✔ |