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

Proposal add ensureOptionGroupExists, ensureOptionValueExists to installer #174

Open
eileenmcnaughton opened this issue Feb 27, 2020 · 0 comments

Comments

@eileenmcnaughton
Copy link
Contributor

We have these 2 functions in core that are good to use on install - but they are not officially supported as an endpoint. I feel like copying them into civix makes sense -

Alternatively we could start to build out the concept of describing options & option groups as metadata (like we do with settings)

  public function install() {
    CRM_Core_BAO_OptionValue::ensureOptionValueExists([
        'option_group_id' => 'wysiwyg_editor',
        'label' => 'CKEditor5',
        'name' => 'CKEditor5',
      ]
    );
    return TRUE;
  }
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

No branches or pull requests

1 participant