Creation of a workflow manager to manage the next and previous button.
The idea is to be able navigate on the forms steps without loosing information.
Ex:
Step 1 : Create Article Node
Step 2 : Edit Article Node in Form Mode A
Step 3 : Create Document Node
Step 4 : Edit Article Node in Form Mode
Step 5 : Go back to Step 3 (we have here to be in edit mode as node already added)
Step 6 : Go back to Step 2 (we have to ensure that we are correctly editing the correct Article)
Step 7 : Go next to Step 3 (we have to ensure that we are editing the Document node)
Without this manager, we can't mix the node types on the same forms steps which is actually a limitation of this module.
@WIP
Comment | File | Size | Author |
---|---|---|---|
#7 | forms_steps-manager-2984440-12698309.patch | 50.69 KB | HakimR |
| |||
#4 | Issue_#2984440_by_HakimR.patch | 51.7 KB | HakimR |
Comments
Comment #2
HakimR CreditAttribution: HakimR as a volunteer commentedWork in progress in feature/FOST-2984440 branch
Ref: https://cgit.drupalcode.org/forms_steps/log/?h=feature/FOST-2984440
Comment #3
HakimR CreditAttribution: HakimR as a volunteer commentedWorkflows has been implemented but not used.
Branch is correctly working but need more work to close this feature.
- When on a form with required values, previous button is not working (stuck by navigator validation)- Remove Edit and Add mode from configuration (no more required)- Update the tests and add test for next/previous navigationComment #4
HakimR CreditAttribution: HakimR as a volunteer commentedWord done. Need review.
Comment #5
HakimR CreditAttribution: HakimR as a volunteer commentedComment #7
HakimR CreditAttribution: HakimR as a volunteer commentedNew patch supplied.
Comment #8
HakimR CreditAttribution: HakimR as a volunteer commentedComment #9
HakimR CreditAttribution: HakimR as a volunteer commentedAny update on the review @nicoloye ?
Comment #10
nicoloye CreditAttribution: nicoloye at Actency commentedI worked on it this week end a little bit, not completed yet, I'm still on it.
Comment #11
nicoloye CreditAttribution: nicoloye at Actency commentedHey Hakim,
Impressive work on this point !
I progressed in the code review, here is a small summary :
Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'node_field_data.field_forms_steps_id' in 'where clause': SELECT base_table.vid AS vid, base_table.nid AS nid FROM {node} base_table INNER JOIN {node_field_data} node_field_data ON node_field_data.nid = base_table.nid WHERE (node_field_data.field_forms_steps_id IN (:db_condition_placeholder_0)) AND (node_field_data.default_langcode IN (:db_condition_placeholder_1)); Array ( [:db_condition_placeholder_0] => [:db_condition_placeholder_1] => 1 ) in Drupal\Core\Entity\EntityStorageBase->loadByProperties() (line 504 of /var/www/html/web/core/lib/Drupal/Core/Entity/EntityStorageBase.php).
I had to fully uninstall the module and reinstall it to make it work. As we already have a few people using the module I think we should implement a hook_update_N() to make a proper transition for this branch, what do you think ?
Comment #12
HakimR CreditAttribution: HakimR as a volunteer commentedHi Nicolas,
I am not very confident to propose a hook_update for this new release as the difference is too huge and that the first version is not clean...
I am using an uuid per workflow and this uuid is not the one used by Drupal, it is an internal identifier.
Having the UUID in the url is a first stage, we can try to propose another solution afterward, not confident to propose it in a short delay...
Hakim
Comment #13
HakimR CreditAttribution: HakimR commentedComment #15
HakimR CreditAttribution: HakimR at Actency commentedMerged.
Comment #16
nicoloye CreditAttribution: nicoloye at Actency commented