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

Category Selector Field Bug Fix - Resolves #2455 #1346

Merged
merged 2 commits into from
Oct 9, 2019
Merged

Category Selector Field Bug Fix - Resolves #2455 #1346

merged 2 commits into from
Oct 9, 2019

Conversation

Guzzler
Copy link
Contributor

@Guzzler Guzzler commented Oct 7, 2019

This pull request makes the following changes:

  • Added an ng-if condition to the category selector html file to render only if categories.length > 0.

Fixes ushahidi/platform#2455 .

Ping @ushahidi/platform @rowasc

@ushbot
Copy link
Collaborator

ushbot commented Oct 7, 2019

Hey @Guzzler,
thank you for your Pull Request.

It looks like you haven't signed our Contributor License Agreement, yet.

The purpose of a CLA is to ensure that the guardian of a project's outputs has the necessary ownership or grants of rights over all contributions to allow them to distribute under the chosen licence.
Wikipedia

You can read and sign our full Contributor License Agreement here.

Once you've signed reply with [clabot:check] to prove it.

Appreciation of efforts,

clabot

@Guzzler
Copy link
Contributor Author

Guzzler commented Oct 7, 2019

[clabot:check]

@ushbot
Copy link
Collaborator

ushbot commented Oct 7, 2019

@rjmackay It looks like @Guzzler just signed our Contributor License Agreement. 👍

Always at your service,

clabot

@Angamanga
Copy link
Collaborator

@Guzzler Thank you so much for contributing 🎉 ! I will review this pr and get back to you shortly!

@Angamanga Angamanga self-requested a review October 8, 2019 13:48
@Angamanga
Copy link
Collaborator

@Guzzler This works fine and removes the "Select-all" checkbox 👍. Good job!

I would like us to remove the Label and the field from the add-post-view entirely, it is still visible (sorry we did not cover this in the instructions).

You can remove this by going to the file "app/main/posts/modify/post-value-edit.html". This file is quite complex, but you find the div for this at line 237 in the file. Doing another ng-if there and checking the length of the attribute.options-array there should solve this issue. There are also check-boxes and radio-buttons in this div, and I just realized they have the same problem. The attribute.options-array holds the values for each category, radio-button or check-box and if that array is empty, we don't need that field. Just reach out if you have any questions or get stuck! 🎉

@Guzzler
Copy link
Contributor Author

Guzzler commented Oct 8, 2019

Have pushed another commit doing the needful. Please let me know if you required something different. I think this should give the desired behavior required. Glad to help and would love to keep contributing! @Angamanga

Copy link
Collaborator

@Angamanga Angamanga left a comment

Choose a reason for hiding this comment

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

Thank you for quick reply @Guzzler! This looks good and works fine! 👍 You are absolutely welcome to continue contributing, reach out if you want help with selecting your next issue!

@Angamanga Angamanga merged commit d4d2670 into ushahidi:develop Oct 9, 2019
@Angamanga
Copy link
Collaborator

@all-contributors please add @Guzzler for code

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.

No category-field should be visible if the user doesnt have permissions to see any of the categories in it
3 participants