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

[4 of 5] Add custom validations to the person form #177

Conversation

raul-fuentes
Copy link
Contributor

@raul-fuentes raul-fuentes commented May 16, 2018

Where

What

  • Add 2 custom validations to the person form
  • One checks the activities declaration tab, if any input is filled and the declaration date isn't selected it prevents the form to be submitted
  • The other check the party select, if 'Councillor' is selected on the job select then any party must be selected

How

  • Add custom validations for the abide plugin

Screenshots

  • Activity declaration validation
    screenshot from 2018-06-25 09-32-57

  • Main validation
    screenshot from 2018-06-25 09-38-39

Test

  • Added test to cover all the new features and changes, but there are some problems with foundation abide plugin. When the abide plugin its enabled on each form header (on edit and new) capybara fails to submit the form; it becomes empy and the validations prevents the form to be submitted and the test fails (I'm still working on it but the written test are those that should work in the final version)

Deployment

  • No

Warnings

  • ⚠️ This PR shouldn't be merged, its only the four one of five and each one will be built form the previous one. It's intended to split and clarify the total solution for the issue wich is pretty big and complicated to be in a single PR ⚠️

@coveralls
Copy link

coveralls commented May 16, 2018

Coverage Status

Coverage increased (+0.6%) to 92.005% when pulling 9cb7c0b2070baeb83c779f9b85320db3c4b9aea3 on wairbut-m2c:add_more_validations_to_the_person_form into 1e0ffeb30d1bb8db07b2daa6278927e91bda9c72 on AyuntamientoMadrid:master.

@raul-fuentes raul-fuentes changed the title [WIP] [4 of 5] Add custom validations to the person form [4 of 5] Add custom validations to the person form May 17, 2018
@raul-fuentes raul-fuentes force-pushed the add_more_validations_to_the_person_form branch from 9a694a9 to 585114c Compare May 18, 2018 12:17
@raul-fuentes raul-fuentes force-pushed the add_more_validations_to_the_person_form branch 4 times, most recently from 3d7aa12 to 9cb7c0b Compare June 25, 2018 08:17
@javierm
Copy link
Contributor

javierm commented Nov 2, 2018

Merged as part of #178.

@javierm javierm closed this Nov 2, 2018
@aitbw aitbw deleted the add_more_validations_to_the_person_form branch November 2, 2018 19:23
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.

None yet

3 participants