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

Add payment component by default in addLayoutSet endpoint when adding a payment layoutset #13102

Merged

Conversation

standeren
Copy link
Contributor

@standeren standeren commented Jul 5, 2024

Description

Pass the taskType from frontend in addition to the actual layoutSetConfig when adding a task in the processEditor.
Check in the AddLayoutSet endpoint in backend if the taskType is payment and add a default component in the new default layout if so.

Related Issue(s)

Verification

  • Your code builds clean without any errors or warnings
  • Manual testing done (required)
  • Relevant automated test added (if you find this hard, leave it and we'll help out)

@github-actions github-actions bot added area/process Area: Related to app process (e.g. signing, receipt, fill inn, payment, etc). solution/studio/designer Issues related to the Altinn Studio Designer solution. quality/testing Tests that are missing, needs to be created or could be improved. labels Jul 5, 2024
@standeren standeren linked an issue Jul 5, 2024 that may be closed by this pull request
6 tasks
@standeren standeren marked this pull request as ready for review July 5, 2024 11:21
@standeren standeren force-pushed the add-payment-component-by-default-when-adding-payment-task branch 2 times, most recently from a21798b to c47128a Compare July 5, 2024 11:23
Copy link

codecov bot commented Jul 5, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.88%. Comparing base (d3b425e) to head (c47128a).

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #13102   +/-   ##
=======================================
  Coverage   91.88%   91.88%           
=======================================
  Files        1426     1426           
  Lines       19957    19958    +1     
  Branches     2389     2389           
=======================================
+ Hits        18338    18339    +1     
  Misses       1360     1360           
  Partials      259      259           

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

Copy link
Contributor

@lassopicasso lassopicasso left a comment

Choose a reason for hiding this comment

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

The frontend part looks good 🙂👍

@standeren standeren force-pushed the add-payment-component-by-default-when-adding-payment-task branch 2 times, most recently from 2d098f6 to f34bd70 Compare July 10, 2024 13:07
Copy link
Collaborator

@mirkoSekulic mirkoSekulic left a comment

Choose a reason for hiding this comment

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

"payment" is used multiple times. It would be nice to create constants for TaskType?

@standeren standeren force-pushed the add-payment-component-by-default-when-adding-payment-task branch from f34bd70 to 751c2a9 Compare July 11, 2024 08:08
@standeren standeren merged commit 8f7cdec into main Jul 11, 2024
10 checks passed
@standeren standeren deleted the add-payment-component-by-default-when-adding-payment-task branch July 11, 2024 12:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/process Area: Related to app process (e.g. signing, receipt, fill inn, payment, etc). quality/testing Tests that are missing, needs to be created or could be improved. solution/studio/designer Issues related to the Altinn Studio Designer solution.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Automatically add layoutset when adding a payment task in Studio
3 participants