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

fix: generic template questions for cloned proposal #157

Merged

Conversation

mutambaraf
Copy link
Contributor

@mutambaraf mutambaraf commented Jan 13, 2023

Description

When a user clone and update a proposal with generic sub templates the UI was clearing information in next steps on the proposal but information will still be in the database. This was being cause by generic template state update clearing information for next steps in the proposal.

Motivation and Context

When a user clone a proposal and then removed their sample(generic template), the old data was still present in the cloned proposal. This was affecting generic template type questions (samples, grants, publications).

How Has This Been Tested

  • e2e tests

Fixes

Closes: UserOfficeProject/issue-tracker#763

Changes

Files changed:

  • apps/user-office-frontend/src/components/proposal/ProposalContainer.tsx
  • apps/user-office-frontend/src/components/questionary/questionaryComponents/GenericTemplate/QuestionaryComponentGenericTemplate.tsx
  • apps/user-office-frontend/src/models/questionary/QuestionarySubmissionState.ts
  • apps/user-office-frontend-e2e/cypress/integration/generic_templates.ts
  • apps/user-office-frontend-e2e/cypress/support/template.ts
  • apps/user-office-frontend-e2e/cypress/types/template.d.ts

Depends on

Tests included/Docs Updated?

  • I have added tests to cover my changes.
  • All relevant doc has been updated

@mutambaraf mutambaraf requested review from a team, bashanlam and bolmsten and removed request for a team January 24, 2023 11:54
@mutambaraf mutambaraf marked this pull request as ready for review January 24, 2023 11:54
@mutambaraf mutambaraf requested a review from a team as a code owner January 24, 2023 11:54
@mutambaraf mutambaraf requested review from simonfernandes and removed request for a team January 24, 2023 11:54
Copy link
Contributor

@simonfernandes simonfernandes left a comment

Choose a reason for hiding this comment

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

My comments are just around naming, it looks good otherwise

@mutambaraf mutambaraf merged commit 43cb770 into develop Feb 8, 2023
@mutambaraf mutambaraf deleted the 763-fix-generic-template-questions-for-cloned-proposal branch February 8, 2023 12:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Removed sample retains values from cloned proposal
4 participants