Browse Source

Merge pull request #4599 from nocodb/fix/formula-column-with-space

fix(nocodb-sdk): include node.value for literal case
pull/4609/head
Raju Udava 2 years ago committed by GitHub
parent
commit
d809524a68
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      packages/nocodb-sdk/src/lib/formulaHelpers.ts

5
packages/nocodb-sdk/src/lib/formulaHelpers.ts

@ -19,7 +19,10 @@ export const jsepCurlyHook = {
context.index += 1; context.index += 1;
env.node = { env.node = {
type: jsep.IDENTIFIER, type: jsep.IDENTIFIER,
name: nodes.map((node) => node.name).join(' '), // column name with space would break it down to jsep.IDENTIFIER + jsep.LITERAL
// either take node.name for jsep.IDENTIFIER
// or take node.value for jsep.LITERAL
name: nodes.map((node) => node.name || node.value).join(' '),
}; };
return env.node; return env.node;
} else { } else {

Loading…
Cancel
Save