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

Add Option Group descriptions from templates/CRM/Admin/Page/Options.tpl #25143

Merged
merged 3 commits into from
Dec 14, 2022

Conversation

aydun
Copy link
Contributor

@aydun aydun commented Dec 9, 2022

Overview

Add Option Group descriptions from templates/CRM/Admin/Page/Options.tpl

Before

Description/help text is in smarty template

After

Descriptions in civicrm_option_group.description field, accessible to APIv4/SearchKit etc

Technical Details

'{ts escape="sql"}' copied from current tpl - not sure whether that is right here.

A few things to note compared to the tpl:

  • activity_type: has '{help id='id-activity-type'} - omitted here
  • accept_creditcard: 2 lines including html <br> Need to decide whether these are to be treated as html fields.
  • from_email_address: has {if $allowLoggedIn}, and embedded <em> &lt; Added the longer text
  • participant_status in smarty but is not an option_group

Could remove strings from tpl but we're trying to replace the admin pages where these are used, not improve them.

Comments

@colemanw

@civibot
Copy link

civibot bot commented Dec 9, 2022

(Standard links)

@civibot civibot bot added the master label Dec 9, 2022
@aydun aydun force-pushed the option_group_descriptions branch 2 times, most recently from 2d2bca4 to b74d5e0 Compare December 13, 2022 11:16
Add Option Group descriptions from templates/CRM/Admin/Page/Options.tpl
@aydun
Copy link
Contributor Author

aydun commented Dec 13, 2022

Hmm - failure is

"ALTER TABLE `civicrm_option_group_en_US` MODIFY COLUMN `description` TEXT [nativecode=1347 ** 'core2514343604civi_g5mny.civicrm_option_group_en_US' is not BASE TABLE]"]

But the upgrade doesn't directly attempt to modify a ..._en_US table. How do we get around that?

@aydun
Copy link
Contributor Author

aydun commented Dec 14, 2022

Thanks @colemanw !

@colemanw
Copy link
Member

That did the trick :)

@colemanw
Copy link
Member

Great one @aydun!

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.

2 participants