docassemble

Is there a way to use [FIELD variable_name] with an already gathered list?


I am just reading the documents, getting prepared to write some list-gathering questions.

I have looked at the docs about groups, and specifically I'm looking at the documentation about editing already gathered lists (https://docassemble.org/docs/groups.html#editing).

I also notice, however, that docassemble supports "embedding fields within a paragraph." (https://docassemble.org/docs/groups.html#editing).

I'm just thinking how useful it might be to combine these two concepts -- rather than have the user hit the "edit" button and go through redefining the whole row, perhaps there is a way to pre-populate the fields (eg. with a default) and then save any updated information upon the press of continue / save, using [FIELD variable_name]?

There's also that add another functionality for lists, which might also be interesting to combine with the same screen that lists the editable information using [FIELD].

I suppose a similar set of functionality might be achieved by a question of this sort (https://docassemble.org/docs/groups.html#list%20collect), and a review screen where (presumably) any click on an edit button would take you back to the big list?

Any template / best-practices / comments on the possibility of this sort of thing?


Solution

  • The [FIELD ...] feature cannot be used with variable names that contain a ].

    Your best bet is to use a list collect interface, which allows the user to edit all of the rows on one screen.