improve default profile behavior

This commit is contained in:
Marc Michalsky 2023-08-03 14:55:57 +02:00
parent 0c1493f47b
commit 57b61d06c6
Signed by untrusted user who does not match committer: marc.koch
GPG key ID: 12406554CFB028B9
4 changed files with 41 additions and 16 deletions

View file

@ -23,6 +23,7 @@ class CRM_Twingle_Page_Profiles extends CRM_Core_Page {
foreach (CRM_Twingle_Profile::getProfiles() as $profile_id => $profile) {
$profiles[$profile_id]['id'] = $profile_id;
$profiles[$profile_id]['name'] = $profile->getName();
$profiles[$profile_id]['is_default'] = $profile->is_default();
foreach (CRM_Twingle_Profile::allowedAttributes() as $attribute) {
$profiles[$profile_id][$attribute] = $profile->getAttribute($attribute);
}