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

Containers "clear" button clear all the fields #23457

Closed
Tracked by #23140
fmontes opened this issue Nov 29, 2022 · 3 comments
Closed
Tracked by #23140

Containers "clear" button clear all the fields #23457

fmontes opened this issue Nov 29, 2022 · 3 comments

Comments

@fmontes
Copy link
Member

fmontes commented Nov 29, 2022

Describe the bug

When you have custom content type, preloop and postloop, and you click the "clear" button is clearing ALL THE FORM.

To Reproduce

Steps to reproduce the behavior:

  1. Create or edit a content type
  2. Add max contentlets and add content types and code
  3. Save...
  4. Click the "clear" button
  5. See how all the form is clear, title, description, etc...

Expected behavior

It should only clear pre-postloop and code and tabs, the name, description should not be cleared.

Acceptance criteria

  • User should be able to clear the content types and all the code related, but keeps all the other container information
@zulqarnainvd zulqarnainvd self-assigned this Dec 1, 2022
zulqarnainvd added a commit that referenced this issue Dec 8, 2022
zulqarnainvd added a commit that referenced this issue Dec 8, 2022
fmontes added a commit that referenced this issue Dec 13, 2022
* #23335 add values as form control

* #23335 change archictecture of dot-container-code component

* #23335 add test cases

* #23335 update test cases and changes according to PR

* #23335 update test case

* #23335 update test cases and remove global message

* #23457 clear only content type and code field

* #23335 fixed errors and add test case

* #23457 add test case and working on save button issue

* #23457 add test case and fixed save btn issue

* #23457 update test cases

* #23457 add doc

* #23457 fix broken API link and refactor code according to PR

* refactor code

Co-authored-by: Freddy Montes <751424+fmontes@users.noreply.github.com>
@fmontes
Copy link
Member Author

fmontes commented Dec 13, 2022

Missing messages keys
image

@fmontes
Copy link
Member Author

fmontes commented Dec 13, 2022

Clear the input to 0 as well.

@jcastro-dotcms
Copy link
Contributor

INTERNAL QA: PASSED

  • Docker Image: master_e37e2c7f

After clicking the CLEAR button, only the Pre-Loop, Post-Loop and Content Type Code fields are cleared. Also, the Max Contents field is set to zero.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants