gristlabs_grist-core/test
Alex Hall bd52665f96 (core) Allow adding rows to widgets filtered by a link using a formula column
Summary:
When a widget `A` is selected by a widget `B` so that `A` is filtered, adding a new row to `A` uses the values in the selected row of `B` and the columns relevant to the linking as default values for the new row. This ensures that the new row matches the current linking filter and remains visible. However this would previously cause a sandbox error when one of the linking columns was a formula column, which doesn't allow setting values. This diff ignores formula columns when picking default values.

Since the value of the formula column in the new row typically won't match the linking filter, extra measures are needed to avoid the new row immediately disappearing. Regular filters already have a mechanism for this, but I didn't manage to extend it to also work for linking. Thanks @dsagal for creating `UnionRowSource` (originally in D4017) which is now used as the solution for temporarily exempting rows from both kinds of filtering.

While testing, I also came across another bug in linking summary tables that caused incorrect filtering, which I fixed with some changes to `DynamicQuerySet`.

Test Plan: Extended an nbrowser test, which both tests for the main change as well as the secondary bugfix.

Reviewers: georgegevoian

Reviewed By: georgegevoian

Subscribers: dsagal

Differential Revision: https://phab.getgrist.com/D4135
2023-12-18 20:28:41 +02:00
..
client (core) Allow adding rows to widgets filtered by a link using a formula column 2023-12-18 20:28:41 +02:00
client-harness (core) bump mocha version to allow parallel tests; move more tests to core 2023-06-27 02:55:34 -04:00
common getHostType: consider APP_DOC_INTERNAL_URL as native (#715) 2023-11-06 09:24:59 +01:00
deployment Adding new lines at the end 2022-09-30 17:00:38 +02:00
fixtures (core) Allow adding rows to widgets filtered by a link using a formula column 2023-12-18 20:28:41 +02:00
formula-dataset (core) updates from grist-core 2023-08-21 09:15:53 -04:00
gen-server Allow URLs with only a docID #768 (#771) 2023-11-29 15:13:29 -05:00
nbrowser (core) Allow adding rows to widgets filtered by a link using a formula column 2023-12-18 20:28:41 +02:00
server (core) Decode cell values to prevent working around rule using 'in' on lists 2023-12-04 23:34:08 +02:00
timings run grist-core test batches in parallel (#444) 2023-03-03 09:53:33 -05:00
.eslintrc.js Fixing all eslint's reported error 2023-01-03 17:22:58 +01:00
chai-as-promised.js (core) Faster builds all around. 2022-07-04 10:42:40 -04:00
declarations.d.ts (core) Update dependencies 2023-10-11 17:36:58 -04:00
init-mocha-webdriver.js (core) Update dependencies 2023-10-11 17:36:58 -04:00
report-why-tests-hang.js (core) bump mocha version to allow parallel tests; move more tests to core 2023-06-27 02:55:34 -04:00
setupPaths.js (core) bump mocha version to allow parallel tests; move more tests to core 2023-06-27 02:55:34 -04:00
split-tests.js (core) Update dependencies 2023-10-11 17:36:58 -04:00
test_under_docker.sh Force test:docker to run with English language (#788) 2023-12-15 07:43:54 -05:00
testUtils.ts (core) add missing tsconfig file that affects IDEs 2022-05-27 13:48:58 -04:00
tsconfig.json (core) Faster builds all around. 2022-07-04 10:42:40 -04:00
upgradeDocument add test/upgradeDocument utility 2023-01-17 16:14:15 -05:00
upgradeDocumentImpl.ts add test/upgradeDocument utility 2023-01-17 16:14:15 -05:00
utils.js (core) bump mocha version to allow parallel tests; move more tests to core 2023-06-27 02:55:34 -04:00
xunit-file.js (core) bump mocha version to allow parallel tests; move more tests to core 2023-06-27 02:55:34 -04:00