File tree Expand file tree Collapse file tree
packages/vtable-plugins/src/filter Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -105,7 +105,7 @@ export class ValueFilter {
105105 // 空行不做处理
106106 if ( isValid ( record ) ) {
107107 const originalValue = record [ fieldId ] ;
108- const formattedValue = formatFn ( record ) ;
108+ const formattedValue = formatFn ( record ) ?? '(空白)' ;
109109 if ( formattedValue !== undefined && formattedValue !== null ) {
110110 countMap . set ( formattedValue , ( countMap . get ( formattedValue ) || 0 ) + 1 ) ;
111111
@@ -155,7 +155,7 @@ export class ValueFilter {
155155 // 空行不做处理
156156 if ( isValid ( record ) ) {
157157 const originalValue = record [ candidateField ] ;
158- const formattedValue = formatFn ( record ) ;
158+ const formattedValue = formatFn ( record ) ?? '(空白)' ;
159159 countMap . set ( formattedValue , ( countMap . get ( formattedValue ) || 0 ) + 1 ) ;
160160 if ( formattedValue !== undefined && formattedValue !== null ) {
161161 const unformattedSet = toUnformatted . get ( formattedValue ) ;
You can’t perform that action at this time.
0 commit comments