CRM-12334 set assignee notification in smarty
authorBrian Shaughnessy <brian@lcdservices.biz>
Fri, 12 Apr 2013 17:07:50 +0000 (13:07 -0400)
committerBrian Shaughnessy <brian@lcdservices.biz>
Fri, 12 Apr 2013 17:07:50 +0000 (13:07 -0400)
CRM/Activity/Form/Activity.php
templates/CRM/Activity/Form/Activity.tpl
templates/CRM/Case/Form/Activity.tpl

index d8f8a61da679b92cacbdfef22d8ef99215de9fcf..4134a50179c26d05e0ce3a9483d170779be89851 100644 (file)
@@ -885,6 +885,12 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task {
     }
 
     $this->addFormRule(array('CRM_Activity_Form_Activity', 'formRule'), $this);
+
+    if ( CRM_Core_BAO_Setting::getItem(CRM_Core_BAO_Setting::SYSTEM_PREFERENCES_NAME,
+      'activity_assignee_notification' )
+    ) {
+      $this->assign('activityAssigneeNotification', true);
+    }
   }
 
   /**
index 31f3445c652dc81d69e7b1566d552daec581f232..e5f74493ab59c59249fae74716704cbd04ae2f98 100644 (file)
       <td>{$form.assignee_contact_id.html}
         {edit}
           <span class="description">{ts}You can optionally assign this activity to someone. Assigned activities will appear in their Activities listing at CiviCRM Home.{/ts}
-          {if $config->activityAssigneeNotification}
+          {if $activityAssigneeNotification}
             <br />{ts}A copy of this activity will be emailed to each Assignee.{/ts}
           {/if}
           </span>
index ba6d3e278da4342ec6d7dfb04825cc30e2372791..8ec7d73b21aa552fb5e7c7329a51abc4fdf8e493 100644 (file)
         {edit}
           <span class="description">
           {ts}You can optionally assign this activity to someone.{/ts}
-          {if $config->activityAssigneeNotification}
+          {if $activityAssigneeNotification}
             <br />{ts}A copy of this activity will be emailed to each Assignee.{/ts}
           {/if}
           </span>