7

Short answer: you need to update your extensions. Visit your extension admin page and apply all updates. Longer answer: There are incompatibilities between older and newer versions of the ContactLayout and Api4 extensions. The breaking change was introduced in ContactLayout 1.4 and Api4 4.3 (which were both released on the same day). Either both ...


6

I believe you cannot set id to a button using php however you can define your own class for the button and use JS to set the id for that class. Here is the snippet to add class for button $this->addButtons([[ 'type' => 'next', 'name' => E::ts('Next'), 'isDefault' => TRUE, 'class' => 'custom_class', //adding class for button )); HTH ...


6

There has been some work going on to support shoreditch for CiviCRM 5.13. The temporary solution(until a new release is available) is to make the Menu colour to white by navigating to CiviCRM >> Administer >> Customize Data and Screens >> Display Preferences. Update the form by changing the 'Menu Color' to white Cheers Pradeep


5

You could do something like CRM_Core_DAO::executeQuery("SELECT LAST_INSERT_ID()");. If your needs are simple that seems like the easiest. Probably to do it "right", you would use civix generate:entity. See https://docs.civicrm.org/dev/en/latest/extensions/civix/#generate-entity Then you could do things in an object-y way, like: $myclass = new MyClass(); $...


5

The ext dir that ships in the tarball is for extensions bundled directly with core like IATS. If you put other extensions in there they will get wiped when you upgrade, so it's common to put them somewhere outside the civicrm folder. See also https://docs.civicrm.org/sysadmin/en/latest/customize/extensions/#enabling-extensions


5

There are several things in play at different levels with regard to the CiviCRM extensions directory location. The concepts to be aware of are: CiviCRM shipping codebase Drupal multisite Drupal's files directory CiviCRM bundled extensions As @Demerit's answer states, sites/<sitename>/modules/civicrm/ext contains the extensions which ship with ...


4

The reason we do that with client sites is because I don’t think it’s a good idea to put code under /files. It belongs at the level of /modules. Permission requirements for code and /files are quite different. Another benefit is that it allows me to more easily put the code for a project in git.


3

its not dead! We are in the process of migrating it to a new physical platform, which we're hoping to complete this week.


3

Paul B, Its not necessary to have 2 separate tpl for View and edit, the logic can be added in one tpl or php file. But for convenience Civi tries to keep it separate. A good example for view and add form will be New/Update/ View Membership forms. The action for CRUD is registered here https://github.com/civicrm/civicrm-core/blob/master/CRM/Member/xml/Menu/...


3

Here is an example using the named parameter syntax: CRM_Utils_Hook::singleton()->invoke( ['pdf', 'pdf_variables', 'receipt'], $pdf, $pdf_variables, $receipt, CRM_Utils_Hook::$_nullObject, CRM_Utils_Hook::$_nullObject, CRM_Utils_Hook::$_nullObject, 'cdntaxreceipts_writeReceipt'); One advantage of this syntax, is that extension can then implement ...


3

The extension wouldn't update itself. If you have Detailed Logging enabled, you should be able to figure out who updated it by checking log_user_id in log_civicrm_extension. If you don't have that: Check the "last action" times in the Drupal "Users" list. Is there only one person who was active? Great! Check your web server logs for the URL that updates ...


3

Go to the extensions page (Administer > System Settings > Extensions) then click the arrow/triangle next to the extension name to expand the section. That will show Local path where the extension files are. Just removing the files won't remove the leftover bits of the extension from the database. If it is partially installed but doesn't offer the ...


3

It's hard to tell which version of the summary fields you are having issues with but I'm guessing it's 4.0.1 which was suppose to fix the exact same issue with 4.0.0. It obviously doesn't. I filed another issue on github for the newest problem. https://github.com/progressivetech/net.ourpowerbase.sumfields/issues/45 I think the fix is to change line 4 in ...


3

I'd like to build out more infrastructure for this. I've started an Extension Compatibility List which so far has the ability to blacklist an obsolete extension (my original use-case was for merging an extension into core), but it could be extended to blacklist a version of an extension with known bugs or security flaws.


3

For every table CiviCRM has api, you can use following method to retrieve data by specifying return in api params. 1 - Get - Returns one or more results and with N number of columns $result = civicrm_api3('Contact', 'get', [ 'return' => ["id", "display_name"], 'contact_sub_type' => "Parent", ]); 2 - GetValue - Returns only single result and ...


3

Its pretty simple to add it as a group of radio button, adding below snippet on how you can add (not tested) $choice = []; forach ($data as $id => $value) { $choice[$value[0]] = $form->createElement('radio', NULL, '', $value[1], $value[0]); } $form->addGroup($choice, 'element_name_of_radio_button', ts('label of radio button'));...


3

The developer updated the issue. There is a missing line in the code. They say they will release version 4.0.1 overnight. If you want to fix it yourself before that look at issue linked above in the comment.


3

You can use build kit to generate a repo including the civi "universe" https://docs.civicrm.org/dev/en/latest/tools/universe/ civibuild create universe or mkdir ~/src/universe fetch-universe ~/src/universe could be worth checking extension usage to see if there are any widely used ones that don't make the cut to get included. Happy grepping!


3

In hook_civicrm_pre, the params passed to your function include qfKey and entryURL — at least sometimes. The entry URL is in a format that's pretty obvious, but it seems like depending on URL parsing would make for brittle code. So what about qfKey? qfKey is a form key based on form name, the current user session ID, a private key unique to the ...


3

This isn't strictly a CiviCRM question in my opinion, but here goes anyway... members can open closed and public groups This is built in to BuddyPress - check the box labelled "Enable group creation for all users" in BuddyPress settings. groups have mailinglist functionality, ideally posts to the group can be created by email and send out by email (...


2

The fullcalendar is the plugin called "WP Calendar", if you have WordPress you install and activate it in the WordPress plugin area. For the other issue, you may want to either disable/reinstall the civicrm extension, (works for some people), or take a look at answer to How to use event calendar extension with civievents Also there is another step that you ...


2

WordPress/CiviCRM can have trouble resolving tokens like [civicrm.files] if you have a symlink in your path. If you're having resource URL issues, I recommend replacing the tokens with absolute paths (with no symlinks) in Administer » System Settings » Directories as well as checking Administer » System Settings » Resource URLs as Aidan suggests. It sounds ...


2

To debug this problem, it helps to turn on debugging and backtrace (Administer menu » System Settings » Debugging and Error Handling). This will give more detailed errors. You can also check the log in the ConfigAndLog folder. It also helps if you can post your code on Github with a link so folks can see problems. In your comments you say that you're ...


2

Sadly the fix in 4.0.1 didn't fix the issue. See Navigation Menu Lost for more details.


2

I had a closer look at all the folders and saw there was a symlink in the templates folder pointing to the templates folder! This must have been preventing the upgrade. I think the symlink was there because earlier we had had problems with mailings not finding the social icons and had created a symlink to solve that problem and then forgotten about it! Once ...


2

I don't know if this is the best answer but many of the core settings tpl's have the help text directly in the tpl, e.g. <span class="description">{ts}Here is the help text{/ts}</span>. Unless you want your users to be able to edit the help text, that seems like a good enough solution here(?), since your tpl is your own custom file to begin with. ...


2

In that case you will need to send api key of the logged in user who access is limited by ACL (also check_permission = 1 in api params).


2

Welcome to Stack Exchange OSRT! Yes, you can use Mosaico for designing newsletters. Whether it is easy to use is a matter of opinion, but probably most would agree it's pretty straightforward. You create your newsletter within CiviCRM using the Mosaico extension and then send it out from there. The main CiviCRM demo sites are not using that extension, but ...


2

git and composer aren't necessary to install civix. In the README it suggests multiple ways to install civix. The first one is a simple download: https://download.civicrm.org/civix/civix.phar.


2

You will need to Go into your extension dir and remove the civivolunteer code that was installed with your buildkit. Then git clone their master (to get the latest). Then go to the Manage Extensions page to check if there are any prompts for database updates. Then disable a small other extension and re-enable it. Or just enable another new extension via ...


Only top voted, non community-wiki answers of a minimum length are eligible