Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DMN configuration improvements #4282

Merged
merged 11 commits into from
May 10, 2024
Merged

Conversation

sergei-maertens
Copy link
Member

@sergei-maertens sergei-maertens commented May 8, 2024

Closes #4269

Changes

  • Updates to new django-camunda version
  • Added FEEL parsing on the client-side for better input var mapping
  • Improved accessibility

Checklist

Check off the items that are completed or not relevant.

  • Impact on features

  • Release management

    • I have labelled the PR as "needs-backport" accordingly
  • I have updated the translations assets (you do NOT need to provide translations)

    • Ran ./bin/makemessages.sh
    • Ran ./bin/compilemessages_js.sh
  • Commit hygiene

    • Commit messages refer to the relevant Github issue
    • Commit messages explain the "why" of change, not the how

Copy link

codecov bot commented May 8, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.12%. Comparing base (dd9ef26) to head (e8d591b).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #4282   +/-   ##
=======================================
  Coverage   96.12%   96.12%           
=======================================
  Files         730      730           
  Lines       23502    23502           
  Branches     2757     2757           
=======================================
  Hits        22591    22591           
  Misses        645      645           
  Partials      266      266           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sergei-maertens sergei-maertens changed the title Feature/4269 dmn improvements DMN configuration improvements May 8, 2024
@sergei-maertens sergei-maertens force-pushed the feature/4269-dmn-improvements branch from 1a926be to 0306362 Compare May 8, 2024 16:36
@sergei-maertens sergei-maertens added the needs-backport Fix must be backported to stable release branch label May 8, 2024
@sergei-maertens sergei-maertens marked this pull request as ready for review May 8, 2024 16:39
@sergei-maertens sergei-maertens requested a review from vaszig May 8, 2024 16:45
@sergei-maertens sergei-maertens force-pushed the feature/4269-dmn-improvements branch from 0306362 to 70e51dc Compare May 8, 2024 16:48
The input expressions require additional parsing to properly extract
the required input variables for a decision table.
This should help form builders configure DMN tables to see
which input expressions are expected by the decision engine.
Input expressions can be complex with the actual requested variable buried
deep inside. We leverage the 'feelin' library to parse FEEL expressions
so that we can extract the actual (likely) expected variables and
combine this information with our retrieved input clauses.

This result is used to build a list of DMN variables for input
mapping - this list is ordered to put labeled literal variables
at the top, followed by the extracted unlabeled variables, and
finally the legal identifiers that are labeled but likely
complex/edge cases.

This implements the DMN 1.3 FEEL identifier specification to
select candidates.
Use the existing VariableSelection component to render a
dropdown of available Open Forms variables.

Added an accessible label to the dropdowns in the mapping
tables.
Updated the assertions for the existing stories so that the
interaction tests pass again.

Added a story for the complex expression cases.
This has the correct input dependency resolution implementation.
@sergei-maertens sergei-maertens force-pushed the feature/4269-dmn-improvements branch from 70e51dc to e8d591b Compare May 8, 2024 16:52
Copy link
Contributor

@vaszig vaszig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I only have to mention a small thing concerning the styling. Other than that I can't find something weird as far as I can say concerning DMN.


@include bem.element('mapping') {
display: flex;
flex-direction: column;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see a difference in the display here between the storybook and the admin, is it only on my end?

storybook

admin

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I noticed it too while developing - I think it may be because of some pages in the admin loading additional stylesheets (bootstrap) that aren't included in Storybook.

@sergei-maertens sergei-maertens merged commit fdb19fd into master May 10, 2024
28 checks passed
@sergei-maertens sergei-maertens deleted the feature/4269-dmn-improvements branch May 10, 2024 08:36
@sergei-maertens
Copy link
Member Author

Backported to 2.6.x with 116214c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-backport Fix must be backported to stable release branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DMN improvements for demo
2 participants