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

Remove unneeded descriptions or replace with help text from Edit Contribution Page & Event #26257

Conversation

larssandergreen
Copy link
Contributor

Overview

The Edit Contribution Page and Edit Event Registration forms are pretty busy and cluttered. Many of the descriptions on those pages are either redundant, basically just putting the field name in a sentence which doesn't add anything, or would be better as help text, so that it can be found if needed, but doesn't overwhelm users with small grey text.

To hopefully make these pages a little easier to use and a little easier on the eyes, I've made a start on this, covering the main tabs on these pages. I will continue in another PR to cover the remaining tabs, and perhaps some other forms, as long as this PR is supported.

Before

For example:
image

After

image

Technical Details

On Contribution Page > Amounts I thought the little wrench icon that you can click to edit an Option Group would make sense to allow editing of Price Sets, since this is pretty similar. I don't think there is an automatic way to do this, so I've done it manually. I think it's better than Create or edit Price Sets here with a link.
The help text here should also be the only new translation string required (it needed updating anyways, as select -none- no longer makes sense with a select2).

Comments

I tried to clean up the formatting of the tpl files a little as I went, on the leave it better than you found it theory, so this looks like more change than it actually is. Some of this is just making the line breaks and indents for tr and td tags a little more consistent.

@civibot
Copy link

civibot bot commented May 18, 2023

(Standard links)

@civibot civibot bot added the master label May 18, 2023
@magnolia61
Copy link
Contributor

Nice!

@colemanw
Copy link
Member

I don't think there is an automatic way to do this, so I've done it manually.

Yes, there is an automatic way, which is to switch that element to be added via CRM_Core_Form::addSelect() instead of ::add(). I recommend that instead of hard-coding it in the tpl because then permissions will be checked (not every user has permission to edit price sets and those that don't would see a broken popup).

@larssandergreen larssandergreen force-pushed the Remove-unneeded-field-description-clutter branch from cfd1477 to c5f7933 Compare May 18, 2023 14:51
@larssandergreen
Copy link
Contributor Author

larssandergreen commented May 18, 2023

Thanks @colemanw. It wasn't working, but manually adding the option_url fixed it. I also removed the whole conditional that showed different text and a link if there weren't any price sets, which seemed unnecessary.

@colemanw
Copy link
Member

Nicely done @larssandergreen!

@colemanw colemanw merged commit f063ffd into civicrm:master May 18, 2023
@larssandergreen larssandergreen deleted the Remove-unneeded-field-description-clutter branch May 24, 2023 05:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants