Skip to content

Commit

Permalink
Fixed compatibility with civicrm > 5.3: 'Error in call to CustomField…
Browse files Browse the repository at this point in the history
…_get : 'AdvMulti-Select' is not a valid option for field html_type'
  • Loading branch information
jaapjansma committed Sep 10, 2018
1 parent 74db8b8 commit 4211f31
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion api/v3/VolunteerUtil.php
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ function civicrm_api3_volunteer_util_getcountries($params) {
* @return array
*/
function civicrm_api3_volunteer_util_getcustomfields($params) {
$allowedCustomFieldTypes = array('AdvMulti-Select', 'Autocomplete-Select',
$allowedCustomFieldTypes = array('Autocomplete-Select',
'CheckBox', 'Multi-Select', 'Radio', 'Select', 'Text');

$customGroupAPI = civicrm_api3('CustomGroup', 'getsingle', array(
Expand Down
4 changes: 2 additions & 2 deletions js/backbone/apps/search/search_views.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,11 @@
*/
var typeMap = {
checkRadio: ['CheckBox', 'Radio'],
select: ['AdvMulti-Select', 'Autocomplete-Select', 'Multi-Select', 'Select'],
select: ['Autocomplete-Select', 'Multi-Select', 'Select'],
text: ['Text']
};
// html_types which allow the user to select multiple values
var typeMulti = ['AdvMulti-Select', 'CheckBox', 'Multi-Select'];
var typeMulti = ['CheckBox', 'Multi-Select'];

var html_type = this.model.get('html_type');
var type = _.findKey(typeMap, function(group) {
Expand Down

0 comments on commit 4211f31

Please sign in to comment.