Transfer responsibility for page title from tpl to php.
Add setPageTitle helper method to CRM_Core_Form.
And a bit of misc form/tpl cleanup
public function buildQuickForm() {
parent::buildQuickForm();
+ $this->setPageTitle(ts('ACL'));
+
if ($this->_action & CRM_Core_Action::DELETE) {
return;
}
CRM_ACL_BAO_ACL::create($params);
}
}
+
}
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
-
$this->_action = CRM_Utils_Request::retrieve('action', 'String', $this, FALSE, 'browse');
$this->assign('action', $this->_action);
}
/**
- * This function sets the default values for the form. MobileProvider that in edit/view mode
+ * This function sets the default values for the form. Note that in edit/view mode
* the default values are retrieved from the database
*
* @access public
* @access public
*/
public function buildQuickForm() {
- if ($this->_action & CRM_Core_Action::VIEW) {
+ if ($this->_action & CRM_Core_Action::VIEW || $this->_action & CRM_Core_Action::PREVIEW) {
$this->addButtons(array(
array(
'type' => 'cancel',
*/
public function buildQuickForm() {
parent::buildQuickForm();
+ $this->setPageTitle(ts('Contact Type'));
+
if ($this->_action & CRM_Core_Action::DELETE) {
return;
}
array(1 => $contactType->label)
), ts('Saved'), 'success');
}
+
}
* @access public
*/
public function buildQuickForm() {
-
parent::buildQuickForm();
+ $this->setPageTitle(ts('Location Type'));
if ($this->_action & CRM_Core_Action::DELETE) {
return;
'variable'
);
- $this->add('text', 'display_name', ts('Display Name'), CRM_Core_DAO::getAttribute('CRM_Core_DAO_LocationType', 'display_name'));
+ $this->add('text', 'display_name', ts('Display Name'), CRM_Core_DAO::getAttribute('CRM_Core_DAO_LocationType', 'display_name'), TRUE);
$this->add('text', 'vcard_name', ts('vCard Name'), CRM_Core_DAO::getAttribute('CRM_Core_DAO_LocationType', 'vcard_name'));
$this->add('text', 'description', ts('Description'), CRM_Core_DAO::getAttribute('CRM_Core_DAO_LocationType', 'description'));
array(1 => $locationType->name)
), ts('Saved'), 'success');
}
+
}
*/
public function buildQuickForm() {
parent::buildQuickForm();
+ $this->setPageTitle(ts('Mail Account'));
if ($this->_action & CRM_Core_Action::DELETE) {
return;
CRM_Core_Session::setStatus("", ts('Changes Not Saved.'), "info");
}
}
+
}
public function buildQuickForm() {
parent::buildQuickForm();
+ $this->setPageTitle(ts('Field Mapping'));
+
if ($this->_action == CRM_Core_Action::DELETE) {
return;
}
CRM_Core_BAO_Mapping::add($params);
}
}
- //end of function
+
}
*/
public function buildQuickForm() {
parent::buildQuickForm();
+ $this->setPageTitle(ts('%1 Option', array(1 => $this->_gLabel)));
+
if ($this->_action & CRM_Core_Action::DELETE) {
return;
}
CRM_Core_Session::setStatus(ts('The %1 \'%2\' has been saved.', array(1 => $this->_gLabel, 2 => $optionValue->label)), ts('Saved'), 'success');
}
}
+
}
*/
public function buildQuickForm() {
parent::buildQuickForm();
+ $this->setPageTitle(ts('Relationship Type'));
if ($this->_action & CRM_Core_Action::DELETE) {
-
return;
}
CRM_Core_Session::setStatus(ts('The Relationship Type has been saved.'), ts('Saved'), 'success');
}
}
- //end of function
+
}
* @access public
*/
public function buildQuickForm() {
+ $this->setPageTitle($this->_isTagSet ? ts('Tag Set') : ts('Tag'));
+
if ($this->_action == CRM_Core_Action::DELETE) {
if ($this->_id && $tag = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_Tag', $this->_id, 'name', 'parent_id')) {
- CRM_Core_Session::setStatus(ts("This tag cannot be deleted. You must delete all its child tags ('%1', etc) prior to deleting this tag.", array(1 => $tag)), ts('Sorry'), 'error');
$url = CRM_Utils_System::url('civicrm/admin/tag', "reset=1");
- CRM_Utils_System::redirect($url);
- return TRUE;
+ CRM_Core_Error::statusBounce(ts("This tag cannot be deleted. You must delete all its child tags ('%1', etc) prior to deleting this tag.", array(1 => $tag)), $url);
}
}
else {
$this->_isTagSet = TRUE;
}
- $allTag = array('' => '- ' . ts('select') . ' -') + CRM_Core_BAO_Tag::getTagsNotInTagset();
+ $allTag = array('' => ts('- select -')) + CRM_Core_BAO_Tag::getTagsNotInTagset();
if ($this->_id) {
unset($allTag[$this->_id]);
);
//@lobo haven't a clue why the checkbox isn't displayed (it should be checked by default
- $this->add('checkbox', 'is_selectable', ts("If it's a tag or a category"));
+ $this->add('checkbox', 'is_selectable');
$isReserved = $this->add('checkbox', 'is_reserved', ts('Reserved?'));
CRM_Core_Session::setStatus(ts('The tag \'%1\' has been saved.', array(1 => $tag->name)), ts('Saved'), 'success');
}
}
- //end of function
+
}
*/
class CRM_Admin_Page_Mapping extends CRM_Core_Page_Basic {
+ public $useLivePageJS = TRUE;
+
/**
* The action links that we need to display for the browse screen
*
else {
CRM_Contact_Page_View::checkUserPermission($this);
}
-
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
}
else {
if ($this->_action & CRM_Core_Action::VIEW) {
*
* @param int $contactId contact id.
*
- * @return true if present else false.
+ * @return bool true if present else false.
* @access public
* @static
*/
*
* @access public
*
- * @return void
+ * @return array
*/
function setDefaultValues() {
$defaults = array();
$this->_context = CRM_Utils_Request::retrieve('context', 'String', $this);
$cid = CRM_Utils_Request::retrieve('cid', 'Positive', $this, FALSE);
- if ($cid) {
- CRM_Contact_Page_View::setTitle($cid);
- }
CRM_Contact_Form_Task_SMSCommon::preProcessProvider($this);
$this->assign('title', $title);
// Check if this is default domain contact CRM-10482
- if (CRM_Contact_BAO_Contact::checkDomainContact($contactId)) {
- $this->assign('domainContact', TRUE);
- } else {
- $this->assign('domainContact', FALSE);
- }
+ $this->assign('domainContact', CRM_Contact_BAO_Contact::checkDomainContact($contactId));
// check logged in user permission
CRM_Contact_Page_View::checkUserPermission($this, $contactId);
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
-
$displayName = CRM_Contact_BAO_Contact::displayName($this->_contactId);
CRM_Utils_System::setTitle(ts('Notes for') . ' ' . $displayName);
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
-
$this->_action = CRM_Utils_Request::retrieve('action', 'String', $this, FALSE, 'browse');
$this->assign('action', $this->_action);
}
$this->assign('lineItem', empty($this->_lineItems) ? FALSE : $this->_lineItems);
// Set title
- if ($this->_contactID) {
- $displayName = CRM_Contact_BAO_Contact::displayName($this->_contactID);
-
- // Check if this is default domain contact CRM-10482
- if (CRM_Contact_BAO_Contact::checkDomainContact($this->_contactID)) {
- $displayName .= ' (' . ts('default organization') . ')';
- }
-
- // omitting contactImage from title for now since the summary overlay css doesn't work outside of our crm-container
- CRM_Utils_System::setTitle(ts('Contribution from') . ' ' . $displayName);
+ if ($this->_mode) {
+ $this->setPageTitle($this->_ppID ? ts('Credit Card Pledge Payment') : ts('Credit Card Contribution'));
+ }
+ else {
+ $this->setPageTitle($this->_ppID ? ts('Pledge Payment') : ts('Contribution'));
}
if ($this->_id) {
* @access public
*/
public function buildQuickForm() {
- //parent::buildQuickForm( );
+ parent::buildQuickForm( );
+ $this->setPageTitle(ts('Premium Product'));
if ($this->_action & CRM_Core_Action::PREVIEW) {
CRM_Contribute_BAO_Premium::buildPremiumPreviewBlock($this, $this->_id);
-
- $this->addButtons(array(
- array(
- 'type' => 'next',
- 'name' => ts('Done with Preview'),
- 'isDefault' => TRUE,
- ),
- )
- );
-
return;
}
if ($this->_action & CRM_Core_Action::DELETE) {
- $this->addButtons(array(
- array(
- 'type' => 'next',
- 'name' => ts('Delete'),
- 'isDefault' => TRUE,
- ),
- array(
- 'type' => 'cancel',
- 'name' => ts('Cancel'),
- ),
- )
- );
return;
}
$this->addFormRule(array('CRM_Contribute_Form_ManagePremiums', 'formRule'));
- $this->addButtons(array(
- array(
- 'type' => 'upload',
- 'name' => ts('Save'),
- 'isDefault' => TRUE,
- ),
- array(
- 'type' => 'cancel',
- 'name' => ts('Cancel'),
- ),
- )
- );
-
$this->assign('productId', $this->_id);
}
$config = CRM_Core_Config::singleton();
return $config->imageUploadURL.basename($newFilename);
}
+
}
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
-
$this->assign('action', $this->_action);
if ($this->_permission == CRM_Core_Permission::EDIT && !CRM_Core_Permission::check('edit contributions')) {
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
-
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
}
$this->assign('action', $this->_action);
function allowAjaxSubmit() {
$this->removeAttribute('data-no-ajax-submit');
}
+
+ /**
+ * Sets page title based on entity and action
+ * @param string $entityLabel
+ */
+ function setPageTitle($entityLabel) {
+ switch ($this->_action) {
+ case CRM_Core_Action::ADD:
+ CRM_Utils_System::setTitle(ts('New %1', array(1 => $entityLabel)));
+ break;
+ case CRM_Core_Action::UPDATE:
+ CRM_Utils_System::setTitle(ts('Edit %1', array(1 => $entityLabel)));
+ break;
+ case CRM_Core_Action::VIEW:
+ case CRM_Core_Action::PREVIEW:
+ CRM_Utils_System::setTitle(ts('View %1', array(1 => $entityLabel)));
+ break;
+ case CRM_Core_Action::DELETE:
+ CRM_Utils_System::setTitle(ts('Delete %1', array(1 => $entityLabel)));
+ break;
+ }
+ }
}
CRM_Core_BAO_CustomField::retrieve($params, $defaults);
$this->_title = CRM_Utils_Array::value('label', $defaults);
- $this->assign('title', $this->_title);
- CRM_Utils_System::setTitle(ts('Confirm Custom Field Delete'));
+ CRM_Utils_System::setTitle(ts('Delete %1', array(1 => $this->_title)));
}
/**
public function buildQuickForm() {
if ($this->_gid) {
$this->_title = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_CustomGroup', $this->_gid, 'title');
- CRM_Utils_System::setTitle($this->_title . ' - ' . ($this->_id ? ts('Edit Field') : ts('Add Field')));
+ CRM_Utils_System::setTitle($this->_title . ' - ' . ($this->_id ? ts('Edit Field') : ts('New Field')));
$this->assign('gid', $this->_gid);
}
$groupTitle = CRM_Core_BAO_CustomGroup::getTitle($this->_gid);
$this->assign('gid', $this->_gid);
$this->assign('groupTitle', $groupTitle);
- CRM_Utils_System::setTitle(ts('%1 - Custom Fields', array(1 => $groupTitle)));
+ if ($action & CRM_Core_Action::BROWSE) {
+ CRM_Utils_System::setTitle(ts('%1 - Custom Fields', array(1 => $groupTitle)));
+ }
}
// assign vars to templates
if ($this->_contactId) {
$displayName = CRM_Contact_BAO_Contact::displayName($this->_contactId);
$this->assign('displayName', $displayName);
- // omitting contactImage from title for now since the summary overlay css doesn't work outside of our crm-container
- CRM_Utils_System::setTitle(ts('Event Registration for') . ' ' . $displayName);
+ $this->setPageTitle(ts('Event Registration for %1', array(1 => $displayName)));
+ }
+ else {
+ $this->setPageTitle(ts('Event Registration'));
}
// check the current path, if search based, then dont get participantID
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
-
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
}
$this->assign('action', $this->_action);
$this->_isARFlag = TRUE;
if ($this->_action & CRM_Core_Action::DELETE) {
$msg = ts("The selected financial account cannot be deleted because at least one Accounts Receivable type account is required (to ensure that accounting transactions are in balance).");
- if (CRM_Utils_Array::value('snippet', $_REQUEST) == 'json') {
- CRM_Core_Page_AJAX::returnJsonResponse($msg);
- }
- CRM_Core_Session::setStatus($msg, '', 'error');
- CRM_Utils_System::redirect(CRM_Utils_System::url('civicrm/admin/financial/financialAccount',
- "reset=1&action=browse"));
+ CRM_Core_Error::statusBounce($msg);
}
}
}
*/
public function buildQuickForm( ) {
parent::buildQuickForm( );
+ $this->setPageTitle(ts('Financial Account'));
if ($this->_action & CRM_Core_Action::DELETE) {
return;
CRM_Core_Session::setStatus(ts('The Financial Account \'%1\' has been saved.', array(1 => $contributionType->name)));
}
}
+
}
*/
public function buildQuickForm() {
parent::buildQuickForm();
+ $this->setPageTitle(ts('Financial Batch'));
+
if (isset( $this->_id)) {
$this->_title = CRM_Core_DAO::getFieldValue('CRM_Batch_DAO_Batch', $this->_id, 'title');
CRM_Utils_System::setTitle($this->_title .' - '.ts( 'Accounting Batch'));
CRM_Core_Error::statusBounce(ts('You dont have permission to %1 this batch'), array(1 => $actionName));
}
}
+
}
*/
public function buildQuickForm() {
parent::buildQuickForm();
+ $this->setPageTitle(ts('Financial Type'));
$this->_id = CRM_Utils_Request::retrieve('id' , 'Positive', $this);
if ($this->_id) {
$this->_title = CRM_Core_DAO::getFieldValue('CRM_Financial_DAO_FinancialType', $this->_id, 'name');
- CRM_Utils_System::setTitle($this->_title . ' - ' . ts( 'Financial Type'));
}
if ($this->_action & CRM_Core_Action::DELETE) {
return;
$session->replaceUserContext($url);
}
}
+
}
* @access public
*/
public function buildQuickForm() {
+ parent::buildQuickForm();
+ $this->setPageTitle(ts('Financial Type Account')););
+
if ($this->_action & CRM_Core_Action::DELETE) {
- $this->addButtons(array(
- array(
- 'type' => 'next',
- 'name' => ts('Delete Financial Account Type'),
- 'spacing' => ' ',
- 'isDefault' => TRUE
- ),
- array(
- 'type' => 'cancel',
- 'name' => ts('Cancel'))
- )
- );
return;
}
- parent::buildQuickForm();
-
if (isset($this->_id)) {
$params = array('id' => $this->_id);
CRM_Financial_BAO_FinancialTypeAccount::retrieve($params, $defaults);
"reset=1&action=browse&aid={$this->_aid}"));
}
}
+
}
CRM_Core_Error::fatal(ts('You do not have permission to access this page'));
}
+ $this->setPageTitle(ts('Grant'));
+
if ($this->_action & CRM_Core_Action::DELETE) {
return;
}
return CRM_Custom_Form_CustomData::setDefaultValues($this);
}
- $defaults = array();
$defaults = parent::setDefaultValues();
if ($this->_action & CRM_Core_Action::DELETE) {
CRM_Core_BAO_CustomGroup::buildCustomDataView($this, $groupTree);
$this->assign('id', $this->_id);
+
+ $this->setPageTitle(ts('Grant'));
}
/**
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
-
- // set page title
- CRM_Utils_System::setTitle(ts('Grant by') . ' ' . $displayName);
}
$this->assign('action', $this->_action);
);
if ($cid) {
- $deleteExtra = ts('Are you sure you want to delete this grant?');
-
$delLink = array(
CRM_Core_Action::DELETE => array('name' => ts('Delete'),
'url' => 'civicrm/contact/view/grant',
'qs' => 'action=delete&reset=1&cid=%%cid%%&id=%%id%%&selectedChild=grant' . $extraParams,
- 'extra' => 'onclick = "if (confirm(\'' . $deleteExtra . '\') ) this.href+=\'&confirmed=1\'; else return false;"',
'title' => ts('Delete Grant'),
),
);
}
return self::$_links;
}
- //end of function
/**
* getter for array of the parameters required for creating pager.
$this->assign('onlinePendingContributionId', $this->_onlinePendingContributionId);
$this->_fromEmails = CRM_Core_BAO_Email::getFromEmail();
- // Set title
- if ($this->_contactID) {
- $displayName = CRM_Contact_BAO_Contact::displayName($this->_contactID);
-
- // Check if this is default domain contact CRM-10482
- if (CRM_Contact_BAO_Contact::checkDomainContact($this->_contactID)) {
- $displayName .= ' (' . ts('default organization') . ')';
- }
+ $this->setPageTitle(ts('Membership'));
- // omitting contactImage from title for now since the summary overlay css doesn't work outside of our crm-container
- CRM_Utils_System::setTitle(ts('Membership for') . ' ' . $displayName);
- }
parent::preProcess();
}
}
$this->_fromEmails = CRM_Core_BAO_Email::getFromEmail();
+
+ CRM_Utils_System::setTitle(ts('Renew Membership'));
+
parent::preProcess();
}
$session = CRM_Core_Session::singleton();
$url = CRM_Utils_System::url('civicrm/admin/member/membershipType', 'reset=1');
$session->pushUserContext($url);
+
+ $this->setPageTitle(ts('Membership Type'));
}
/**
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
-
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
}
$this->assign('action', $this->_action);
if ($this->_id && CRM_Core_BAO_Note::getNotePrivacyHidden($this->_id)) {
CRM_Core_Error::statusBounce(ts('You do not have access to this note.'));
}
-
- // set title to "Note - " + Contact Name
- $displayName = CRM_Core_DAO::getFieldValue('CRM_Contact_DAO_Contact', $this->_entityId, 'display_name');
- $pageTitle = 'Note - ' . $displayName;
- $this->assign('pageTitle', $pageTitle);
+ $this->setPageTitle($this->_parentId ? ts('Comment') : ts('Note'));
}
/**
}
$this->_id = CRM_Utils_Request::retrieve('ppId', 'Positive', $this);
+
+ CRM_Utils_System::setTitle(ts('Edit Scheduled Pledge Payment'));
}
/**
$this->userEmail
) = CRM_Contact_BAO_Contact_Location::getEmailDetails($this->_contactID);
$this->assign('displayName', $this->userDisplayName);
-
- // set title to "Pledge - "+Contact Name
- $displayName = $this->userDisplayName;
- $pageTitle = ts('Pledge by'). ' ' . $displayName;
- $this->assign('pageTitle', $pageTitle);
- CRM_Utils_System::setTitle($pageTitle);
}
+ $this->setPageTitle(ts('Pledge'));
+
//build custom data
CRM_Custom_Form_CustomData::preProcess($this, NULL, NULL, 1, 'Pledge', $this->_id);
$this->_values = array();
if ($this->_action & CRM_Core_Action::UPDATE) {
$this->edit();
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
}
else {
$pledgeId = CRM_Utils_Request::retrieve('pledgeId', 'Positive', $this);
// check logged in url permission
CRM_Contact_Page_View::checkUserPermission($this);
-
- // set page title
- CRM_Contact_Page_View::setTitle($this->_contactId);
}
$this->assign('action', $this->_action);
CRM_Utils_System::appendBreadCrumb($breadCrumb);
- switch ($this->_action) {
- case CRM_Core_Action::ADD:
- CRM_Utils_System::setTitle(ts('Add Price Field'));
- break;
- case CRM_Core_Action::UPDATE:
- CRM_Utils_System::setTitle(ts('Edit Price Field'));
- break;
- case CRM_Core_Action::DELETE:
- CRM_Utils_System::setTitle(ts('Delete Price Field'));
- break;
- }
+ $this->setPageTitle(ts('Price Field'));
}
/**
$this->_id = $this->get('id');
- CRM_Utils_System::setTitle(ts('Manage - SMS Providers'));
+ $this->setPageTitle(ts('SMS Provider'));
if ($this->_id) {
$refreshURL = CRM_Utils_System::url('civicrm/admin/sms/provider',
$this->_id = CRM_Utils_Request::retrieve('id', 'Positive', $this);
if ($this->_gid) {
$this->_title = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_UFGroup', $this->_gid, 'title');
- switch ($this->_action) {
- case CRM_Core_Action::ADD:
- CRM_Utils_System::setTitle(ts('Add Profile Field'));
- break;
- case CRM_Core_Action::UPDATE:
- CRM_Utils_System::setTitle(ts('Edit Profile Field'));
- break;
- case CRM_Core_Action::DELETE:
- CRM_Utils_System::setTitle(ts('Delete Profile Field'));
- break;
- }
+
+ $this->setPageTitle(ts('Profile Field'));
$url = CRM_Utils_System::url('civicrm/admin/uf/group/field',
"reset=1&action=browse&gid={$this->_gid}"
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing ACL *}
-<h3>{if $action eq 1}{ts}New ACL{/ts}{elseif $action eq 2}{ts}Edit ACL{/ts}{else}{ts}Delete ACL{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-acl-form-block">
{if $action eq 8}
<div class="messages status no-popup">
*}
{* this template is used for adding/editing Contact Type *}
-<h3>{if $action eq 1}{ts}New Contact Type{/ts}{elseif $action eq 2}{ts}Edit Contact Type{/ts}{else}{ts}Delete Contact Type{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-contact-type-form-block">
{if $action eq 8}
<div class="messages status no-popup">
{/if}
</tr>
<tr class="crm-contact-type-form-block-image_URL">
- <td class="label">{$form.image_URL.label}</td>
- <td>{$form.image_URL.html|crmAddClass:'huge40'}{help id="id-image_URL"}</td>
+ <td class="label">{$form.image_URL.label} {help id="id-image_URL"}</td>
+ <td>{$form.image_URL.html|crmAddClass:'huge40'}</td>
</tr>
<tr class="crm-contact-type-form-block-description">
<td class="label">{$form.description.label}
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing location type *}
-<h3>{if $action eq 1}{ts}New Location Type{/ts}{elseif $action eq 2}{ts}Edit Location Type{/ts}{else}{ts}Delete Location Type{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-location-type-form-block">
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
{if $action eq 8}
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing email settings. *}
-<h3>{if $action eq 1}{ts}New Email Settings{/ts}{elseif $action eq 2}{ts}Edit Email Settings{/ts}{else}{ts}Delete Email Settings{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-mail-settings-form-block">
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
{if $action eq 8}
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing a saved mapping *}
-<h3>{if $action eq 1}{ts}New Tag{/ts}{elseif $action eq 2}{ts}Edit Mapping{/ts}{else}{ts}Delete Mapping{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-mapping-form-block">
{if $action eq 1 or $action eq 2 }
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
*}
-{* this template is used for adding/editing/deleting activity type *}
<h3>{if $action eq 1}{ts}New Option Group{/ts}{elseif $action eq 2}{ts}Edit Option Group{/ts}{else}{ts}Delete Option Group{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-admin-optiongroup-form-block">
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing options *}
-<h3>{if $action eq 1}{ts 1=$gLabel}New %1 Option{/ts}{elseif $action eq 8}{ts 1=$gLabel}Delete %1 Option{/ts}{else}{ts 1=$gLabel}Edit %1 Option{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-admin-options-form-block">
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
{if $action eq 8}
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing relationship types *}
-<h3>{if $action eq 1}{ts}New Relationship Type{/ts}{elseif $action eq 2}{ts}Edit Relationship Type{/ts}{elseif $action eq 8}{ts}Delete Relationship Type{/ts}{else}{ts}View Relationship Type{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-relationship-type-form-block">
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
{if $action eq 8}
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing a tag (admin) *}
-<h3>{if $action eq 1}{ts}New Tag {if $isTagSet}Set{/if}{/ts}{elseif $action eq 2}{ts}Edit Tag {if $isTagSet}Set{/if}{/ts}{else}{ts}Delete Tag {if $isTagSet}Set{/if}{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-tag-form-block">
{if $action eq 1 or $action eq 2 }
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
*}
-<div id="help">
- {ts}CiviCRM comes with 3 basic (built-in) contact types: Individual, Household, and Organization. You can create additional contact types based on these types to further differentiate contacts (for example you might create Student, Parent, Staff, and /or Volunteer types from the basic Individual type...).{/ts} {help id="id-contactSubtype-intro"}
-</div>
-
{if $action eq 1 or $action eq 2 or $action eq 8}
{include file="CRM/Admin/Form/ContactType.tpl"}
{else}
+ <div id="help">
+ {ts}CiviCRM comes with 3 basic (built-in) contact types: Individual, Household, and Organization. You can create additional contact types based on these types to further differentiate contacts (for example you might create Student, Parent, Staff, and /or Volunteer types from the basic Individual type...).{/ts} {help id="id-contactSubtype-intro"}
+ </div>
{if $rows}
<div>
{strip}
{/foreach}
</table>
{/strip}
- {if $action ne 1 and $action ne 2}
- <div class="action-link">
- <a href="{crmURL q="action=add&reset=1"}" class="button"><span><div class="icon add-icon"></div>{ts}Add Contact Type{/ts}</span></a>
- </div>
- {/if}
-</div>
-{else}
+ </div>
+ {else}
<div class="messages status no-popup">
- <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
- {capture assign=crmURL}{crmURL p='civicrm/admin/ContactType' q="action=add&reset=1"}{/capture}
- {ts 1=$crmURL}There are currently no Contact Types entered. You can <a href='%1'>add one</a>.{/ts}
+ <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
+ {ts}None found.{/ts}
</div>
-{/if}
+ {/if}
+ <div class="action-link">
+ <a href="{crmURL q="action=add&reset=1"}" class="button"><span><div class="icon add-icon"></div>{ts}Add Contact Type{/ts}</span></a>
+ </div>
{/if}
{ts}Location types provide convenient labels to differentiate contacts' location(s). Administrators may define as many additional types as appropriate for your constituents (examples might be Main Office, School, Vacation Home...).{/ts}
</div>
-{if $rows}
-<div id="ltype">
+ {if $rows}
+ <div id="ltype">
{strip}
{* handle enable/disable actions*}
{include file="CRM/common/enableDisableApi.tpl"}
</thead>
{foreach from=$rows item=row}
<tr id="location_type-{$row.id}" class="{cycle values="odd-row,even-row"} {$row.class} crm-entity {if NOT $row.is_active} disabled{/if}">
- <td class="crm-locationType-name">{$row.name}</td>
- <td class="crm-locationType-display_name">{$row.display_name}</td>
- <td class="crm-locationType-vcard_name">{$row.vcard_name}</td>
- <td class="crm-locationType-description">{$row.description}</td>
- <td id="row_{$row.id}_status" class="crm-locationType-is_active">{if $row.is_active eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}</td>
- <td class="crm-locationType-is_default" >{if $row.is_default eq 1}<img src="{$config->resourceBase}i/check.gif" alt="{ts}Default{/ts}" />{/if} </td>
+ <td class="crmf-name">{$row.name}</td>
+ <td class="crmf-display_name crm-editable">{$row.display_name}</td>
+ <td class="crmf-vcard_name">{$row.vcard_name}</td>
+ <td class="crmf-description crm-editable">{$row.description}</td>
+ <td id="row_{$row.id}_status" class="crmf-is_active">{if $row.is_active eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}</td>
+ <td class="crmf-is_default" >{if $row.is_default eq 1}<img src="{$config->resourceBase}i/check.gif" alt="{ts}Default{/ts}" />{/if} </td>
<td>{$row.action|replace:'xx':$row.id}</td>
</tr>
{/foreach}
</table>
{/strip}
-
- {if $action ne 1 and $action ne 2}
- <div class="action-link">
- <a href="{crmURL q="action=add&reset=1"}" id="newLocationType" class="button"><span>» {ts}New Location Type{/ts}</span></a>
- </div>
- {/if}
-</div>
-{else}
+ </div>
+ {else}
<div class="messages status no-popup">
- <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
- {capture assign=crmURL}{crmURL p='civicrm/admin/locationType' q="action=add&reset=1"}{/capture}
- {ts 1=$crmURL}There are no Location Types entered for this Contact. You can <a href='%1'>add one</a>.{/ts}
+ <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
+ {ts}None found.{/ts}
</div>
-{/if}
+ {/if}
+ <div class="action-link">
+ <a href="{crmURL q="action=add&reset=1"}" id="newLocationType" class="button"><span><div class="icon add-icon"></div>{ts}Add Location Type{/ts}</span></a>
+ </div>
{/if}
</table>
{/strip}
- {if $action ne 1 and $action ne 2}
- <div class="action-link">
- <a href="{crmURL q="action=add&reset=1"}" id="newMailSettings" class="button"><span><div class="icon add-icon"></div>{ts}Add Mail Account{/ts}</span></a>
- </div>
- {/if}
</div>
</div>
{else}
<div class="messages status no-popup">
- <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
- {capture assign=crmURL}{crmURL p='civicrm/admin/mailSettings' q="action=add&reset=1"}{/capture}
- {ts 1=$crmURL}There are no Mail Settings present. You can <a href='%1'>add one</a>.{/ts}
+ <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
+ {ts}None found.{/ts}
</div>
{/if}
+ <div class="action-link">
+ <a href="{crmURL q="action=add&reset=1"}" id="newMailSettings" class="button"><span><div class="icon add-icon"></div>{ts}Add Mail Account{/ts}</span></a>
+ </div>
{/if}
<div class="crm-content-block crm-block">
{if $rows}
-{if $action ne 1 and $action ne 2 and $isLocked ne 1}
+{if $isLocked ne 1}
<div class="action-link">
<a href="{crmURL p="civicrm/admin/options/$gName" q='action=add&reset=1'}" class="button new-option"><span><div class="icon add-icon"></div>{ts 1=$gLabel}Add %1{/ts}</span></a>
</div>
{include file="CRM/common/crmeditable.tpl"}
{/strip}
- {if $action ne 1 and $action ne 2 and $isLocked ne 1}
- <div class="action-link">
- <a href="{crmURL p="civicrm/admin/options/$gName" q='action=add&reset=1'}" class="button new-option"><span><div class="icon add-icon"></div>{ts 1=$gLabel}Add %1{/ts}</span></a>
- </div>
- {/if}
</div>
{else}
<div class="messages status no-popup">
- <div class="icon inform-icon"></div>
- {capture assign=link}class="action-item" href="{crmURL p="civicrm/admin/options/$gName" q='action=add&reset=1'}"{/capture}
- {ts 1=$link}There are no option values entered. You can <a %1>add one</a>.{/ts}
+ <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
+ {ts}None found.{/ts}
</div>
{/if}
+ {if $isLocked ne 1}
+ <div class="action-link">
+ <a href="{crmURL p="civicrm/admin/options/$gName" q='action=add&reset=1'}" class="button new-option"><span><div class="icon add-icon"></div>{ts 1=$gLabel}Add %1{/ts}</span></a>
+ </div>
+ {/if}
</div>
{/if}
</table>
{/strip}
- {if !($action eq 1 and $action eq 2)}
- <div class="action-link">
- <a href="{crmURL q="action=add&reset=1"}" class="button newRelationshipType"><span><div class="icon add-icon"></div>{ts}Add Relationship Type{/ts}</span></a>
- </div>
- {/if}
</div>
{else}
<div class="messages status no-popup">
- <div class="icon inform-icon"></div>
- {capture assign=crmURL}{crmURL p='civicrm/admin/reltype' q="action=add&reset=1"}{/capture}
- {ts 1=$crmURL}There are no relationship types present. You can <a href='%1'>add one</a>.{/ts}
+ <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
+ {ts}None found.{/ts}
</div>
{/if}
+ <div class="action-link">
+ <a href="{crmURL q="action=add&reset=1"}" class="button newRelationshipType"><span><div class="icon add-icon"></div>{ts}Add Relationship Type{/ts}</span></a>
+ </div>
{/if}
<div class="view-content">
{if $action eq 4}{* when action is view *}
{if $notes}
- <h3>{ts}View Note{/ts}</h3>
<div class="crm-block crm-content-block crm-note-view-block">
<table class="crm-info-panel">
<tr><td class="label">{ts}Subject{/ts}</td><td>{$note.subject}</td></tr>
</div>
{/if}
{elseif $action eq 1 or $action eq 2} {* action is add or update *}
- <h3>
- {if $parentId}
- {if $action eq 1}{ts}New Comment{/ts}{else}{ts}Edit Comment{/ts}{/if}
- {else}
- {if $action eq 1}{ts}New Note{/ts}{else}{ts}Edit Note{/ts}{/if}
- {/if}
- </h3>
<div class="crm-block crm-form-block crm-note-form-block">
<div class="content crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
<table class="form-layout">
</div>
{/if}
{if ($action eq 8)}
-<fieldset><legend>{ts}Delete Note{/ts}</legend>
<div class=status>{ts 1=$notes.$id.note}Are you sure you want to delete the note '%1'?{/ts}</div>
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl"}</div>
-</fieldset>
{/if}
{include file="CRM/Contribute/Form/AdditionalInfo/$formType.tpl"}
{else}
- {if $contributionMode}
- <h3>{if $ppID}{ts}Credit Card Pledge Payment{/ts}{else}{ts}Credit Card Contribution{/ts}{/if}</h3>
- {elseif $context NEQ 'standalone'}
- <h3>{if $action eq 1 or $action eq 1024}{if $ppID}{ts}Pledge Payment{/ts}{else}{ts}New Contribution{/ts}{/if}{elseif $action eq 8}{ts}Delete Contribution{/ts}{else}{ts}Edit Contribution{/ts}{/if}</h3>
- {/if}
-
<div class="crm-block crm-form-block crm-contribution-form-block">
{if $contributionMode == 'test' }
{else}
{capture assign=ccModeLink}{crmURL p='civicrm/contact/view/contribution' q="reset=1&action=add&context=standalone&mode=live"}{/capture}
{/if}
- <span class="action-link crm-link-credit-card-mode"> <a class="open-inline crm-hover-button" href="{$ccModeLink}">» {ts}submit credit card contribution{/ts}</a></span>
+ <span class="action-link crm-link-credit-card-mode"> <a class="open-inline crm-hover-button action-item" href="{$ccModeLink}">» {ts}submit credit card contribution{/ts}</a></span>
{/if}
</div>
{if $isOnline}{assign var=valueStyle value=" class='view-value'"}{else}{assign var=valueStyle value=""}{/if}
+--------------------------------------------------------------------+
*}
<div class="crm-block crm-content-block crm-contribution-view-form-block">
-<h3>{ts}View Contribution{/ts}</h3>
-
<div class="action-link">
<div class="crm-submit-buttons">
{if call_user_func(array('CRM_Core_Permission','check'), 'edit contributions')}
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing/deleting premium *}
-<h3>{if $action eq 1}{ts}New Premium{/ts}{elseif $action eq 2}{ts}Edit Premium{/ts}{elseif $action eq 1024}{ts}Preview a Premium{/ts}{else}{ts}Delete Premium Product{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-contribution-manage_premiums-form-block">
-<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
{if $action eq 8}
<div class="messages status no-popup">
<div class="icon inform-icon"></div>
{elseif $action eq 1024}
{include file="CRM/Contribute/Form/Contribution/PremiumBlock.tpl" context="previewPremium"}
{else}
+ <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
<table class="form-layout-compressed">
<tr class="crm-contribution-form-block-name">
<td class="label">{$form.name.label} {if $action == 2}{include file='CRM/Core/I18n/Dialog.tpl' table='civicrm_product' field='name' id=$productId}{/if}
+--------------------------------------------------------------------+
*}
{* this template is used for confirmation of delete for a Fields *}
-<h3>{ts}Delete Custom Field{/ts} - {$title}</h3>
<div class="crm-block crm-form-block crm-custom-deletefield-form-block">
<div class="messages status no-popup">
<div class="icon inform-icon"></div>
{elseif $participantMode == 'live'}
{assign var=registerMode value="LIVE"}
{/if}
- <h3>{if $action eq 1}{ts}New Event Registration{/ts}{elseif $action eq 8}{ts}Delete Event Registration{/ts}{else}{ts}Edit Event Registration{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-participant-form-block">
<div class="view-content">
{if $participantMode}
{/if}
{if $action eq 8} {* If action is Delete *}
- <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
<div class="crm-participant-form-block-delete messages status no-popup">
<div class="crm-content">
<div class="icon inform-icon"></div>
*}
{* View existing event registration record. *}
<div class="crm-block crm-content-block crm-event-participant-view-form-block">
- <h3>{ts}View Participant{/ts}</h3>
<div class="action-link">
<div class="crm-submit-buttons">
{if call_user_func(array('CRM_Core_Permission','check'), 'edit event participants')}
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing/deleting financial type *}
-<h3>{if $action eq 1}{ts}New Financial Account{/ts}{elseif $action eq 2}{ts}Edit Financial Account{/ts}{else}{ts}Delete Financial Account{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-contribution_type-form-block crm-financial_type-form-block">
{if $action eq 8}
<div class="messages status no-popup">
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing/deleting financial batch *}
-<h3>{if $action eq 8}
- {ts}Delete Batch{/ts} - {$batchTitle}
- {elseif $action eq 1}
- {ts}Add New Batch{/ts}
- {elseif $action eq 2}
- {ts}Edit Batch{/ts} - {$batchTitle}
- {/if}
-</h3>
<div class="crm-block crm-form-block crm-financial_type-form-block">
{if $action eq 8}
<div class="messages status">
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing/deleting financial type *}
-<h3>{if $action eq 1}{ts}New Financial Type{/ts}{elseif $action eq 2}{ts}Edit Financial Type{/ts}{else}{ts}Delete Financial Type{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-financial_type-form-block">
{if $action eq 8}
<div class="messages status">
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing/deleting financial type *}
-<h3>{if $action eq 8}{ts}Delete Financial Type Account{/ts}{elseif $action eq 1}{ts}Add New Financial Type Account{/ts}{elseif $action eq 2}{ts}Edit Financial Type Account{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-financial_type-form-block">
{if $action eq 8}
<div class="messages status">
{include file="CRM/Custom/Form/CustomData.tpl"}
{else}
-{if $action eq 1 and $context ne 'standalone'}
- <h3>{ts}New Grant{/ts}</h3>
-{elseif $action eq 2}
- <h3>{ts}Edit Grant{/ts}</h3>
-{elseif $action eq 8}
- <h3>{ts}Delete Grant{/ts}</h3>
-{/if}
-
<div class="crm-block crm-form-block crm-grant-form-block">
{if $action eq 8}
<div class="messages status">
+--------------------------------------------------------------------+
*}
{* this template is used for viewing grants *}
-<h3>{ts}View Grant{/ts}</h3>
<div class="crm-block crm-content-block crm-grant-view-block">
<div class="crm-submit-buttons">
{if call_user_func(array('CRM_Core_Permission','check'), 'edit grants')}
<p>{ts}You will not be able to send an automatic email receipt for this Membership because there is no email address recorded for this contact. If you want a receipt to be sent when this Membership is recorded, click Cancel and then click Edit from the Summary tab to add an email address before recording the Membership.{/ts}</p>
</div>
{/if}
- {if $context NEQ 'standalone'}
- <h3>{if $action eq 1}{ts}New Membership{/ts}{elseif $action eq 2}{ts}Edit Membership{/ts}{else}{ts}Delete Membership{/ts}{/if}</h3>
- {/if}
{if $membershipMode}
<div id="help">
{ts 1=$displayName 2=$registerMode}Use this form to submit Membership Record on behalf of %1. <strong>A %2 transaction will be submitted</strong> using the selected payment processor.{/ts}
if you want to cancel the automatic renewal option.{/ts}</p>
</div>
{/if}
- <h3>{ts}Renew Membership{/ts}</h3>
{/if}
<div class="crm-block crm-form-block crm-member-membershiprenew-form-block">
<div id="help" class="description">
+--------------------------------------------------------------------+
*}
{* this template is used for adding/editing/deleting membership type *}
-<h3>{if $action eq 1}{ts}New Membership Type{/ts}{elseif $action eq 2}{ts}Edit Membership Type{/ts}{else}{ts}Delete Membership Type{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-membership-type-form-block">
- <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
<div class="form-item" id="membership_type_form">
{if $action eq 8}
<div class="messages status no-popup">
</div>
<div> {include file="CRM/common/formButtons.tpl"}</div>
{else}
+ <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
<table class="form-layout-compressed">
<tr class="crm-membership-type-form-block-name">
<td class="label">{$form.name.label} {if $action == 2}{include file='CRM/Core/I18n/Dialog.tpl' table='civicrm_membership_type' field='name' id=$membershipTypeId}{/if}
*}
{* View existing membership record. *}
<div class="crm-block crm-content-block crm-membership-view-form-block">
- <h3>{ts}View Membership{/ts}</h3>
<div class="crm-submit-buttons">
{* Check permissions and make sure this is not an inherited membership (edit and delete not allowed for inherited memberships) *}
{if ! $owner_contact_id AND call_user_func(array('CRM_Core_Permission','check'), 'edit memberships') }
+--------------------------------------------------------------------+
*}
{* this template is used for updating pledge payment*}
-<h3>{ts}Edit Scheduled Pledge Payment{/ts}</h3>
<div class="crm-block crm-form-block crm-pledge-payment-form-block">
<table class="form-layout-compressed">
<tr><td class="label">{ts}Status{/ts}</td><td class="form-layout">{$status}</td></tr>
<p>{ts}You will not be able to send an acknowledgment for this pledge because there is no email address recorded for this contact. If you want a acknowledgment to be sent when this pledge is recorded, click Cancel and then click Edit from the Summary tab to add an email address before recording the pledge.{/ts}</p>
</div>
{/if}
-{if $action EQ 1}
- <h3>{ts}New Pledge{/ts}</h3>
-{elseif $action EQ 2}
- <h3>{ts}Edit Pledge{/ts}</h3>
+{if $action EQ 2}
{* Check if current Total Pledge Amount is different from original pledge amount. *}
{math equation="x / y" x=$amount y=$installments format="%.2f" assign="currentInstallment"}
{* Check if current Total Pledge Amount is different from original pledge amount. *}
{if $currentInstallment NEQ $eachPaymentAmount}
{assign var=originalPledgeAmount value=`$installments*$eachPaymentAmount`}
{/if}
-{elseif $action EQ 8}
- <h3>{ts}Delete Pledge{/ts}</h3>
{/if}
<div class="crm-block crm-form-block crm-pledge-form-block">
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
{assign var=originalPledgeAmount value=`$installments*$original_installment_amount`}
{/if}
-<h3>{ts}View Pledge{/ts}</h3>
<div class="crm-block crm-content-block crm-pledge-view-block">
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
<table class="crm-info-panel">
<td {if ! ($permission EQ 'edit' and ($row.status eq 'Pending' or $row.status eq 'Overdue' or $row.status eq 'Completed')) } colspan="2"{/if} >{$row.label}</td>
{if $context neq user}
{if $permission EQ 'edit' and ($row.status eq 'Pending' or $row.status eq 'Overdue' or $row.status eq 'Completed') }
- <td>
+ <td class="nowrap">
{if $row.status eq 'Completed'} {* Link to view contribution record for completed payment.*}
{capture assign=viewContribURL}{crmURL p="civicrm/contact/view/contribution" q="reset=1&id=`$row.contribution_id`&cid=`$contactId`&action=view&context=`$context`"}{/capture}
- {ts 1=$viewContribURL}<a href='%1'>View Payment</a>{/ts}
+ <a class="crm-hover-button action-item" href="{$viewContribURL}">{ts}View Payment{/ts}</a>
{else} {* Links to record / submit a payment. *}
{capture assign=newContribURL}{crmURL p="civicrm/contact/view/contribution" q="reset=1&action=add&cid=`$contactId`&context=`$context`&ppid=`$row.id`"}{/capture}
- {ts 1=$newContribURL}<a href='%1'>Record Payment (Check, Cash, EFT ...)</a>{/ts}
+ <a class="crm-hover-button action-item" href="{$newContribURL}">{ts}Record Payment{/ts}</a>
{if $newCredit}
- <br/>
{capture assign=newCreditURL}{crmURL p="civicrm/contact/view/contribution" q="reset=1&action=add&cid=`$contactId`&ppid=`$row.id`&context=`$context`&mode=live"}{/capture}
- {ts 1=$newCreditURL}<a href='%1'>Submit Credit Card Payment</a>{/ts}
+ <a class="crm-hover-button action-item" href="{$newCreditURL}">{ts}Credit Card Payment{/ts}</a>
{/if}
- <br/>
{capture assign=editURL}{crmURL p="civicrm/pledge/payment" q="reset=1&action=update&cid=`$contactId`&context=`$context`&ppId=`$row.id`"}{/capture}
- {ts 1=$editURL}<a href='%1'>Edit Scheduled Payment</a>{/ts}
+ <a class="crm-hover-button action-item" href="{$editURL}">{ts}Edit Scheduled Payment{/ts}</a>
{/if}
</td>
{/if}
+--------------------------------------------------------------------+
*}
{* This template is used for adding/configuring SMS Providers *}
-<h3>{if $action eq 1}{ts}New Provider{/ts}{elseif $action eq 2}{ts}Edit Provider{/ts}{else}{ts}Delete Provider{/ts}{/if}</h3>
<div class="crm-block crm-form-block crm-job-form-block">
<div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
*}
-{capture assign=wikiLink}{docURL page="Setting up a SMS Provider for CiviSMS" text="(How to add a SMS Provider)" resource="wiki"}{/capture}
-<div id="help">
- {ts}You can configure one or more SMS Providers for your CiviCRM installation. To learn more about the procedure to install SMS extension and Provider, refer{/ts} {$wikiLink}
-</div>
{if $action eq 1 or $action eq 2 or $action eq 8}
{include file="CRM/SMS/Form/Provider.tpl"}
{else}
+ {capture assign=wikiLink}{docURL page="Setting up a SMS Provider for CiviSMS" text="(How to add a SMS Provider)" resource="wiki"}{/capture}
+ <div id="help">
+ {ts}You can configure one or more SMS Providers for your CiviCRM installation. To learn more about the procedure to install SMS extension and Provider, refer{/ts} {$wikiLink}
+ </div>
{if $rows}
- {if $action ne 1 and $action ne 2}
- <div class="action-link">
- <a href="{crmURL q="action=add&reset=1"}" id="newProvider" class="button"><span><div class="icon add-icon"></div>{ts}Add New Provider{/ts}</span></a>
- </div>
- {/if}
-
-<div id="ltype">
+ <div id="ltype">
{strip}
{* handle enable/disable actions*}
{include file="CRM/common/enableDisableApi.tpl"}
{/foreach}
</table>
{/strip}
-</div>
-{elseif $action ne 1}
+ </div>
+ {else}
<div class="messages status no-popup">
<div class="icon inform-icon"></div>
- {ts}There are no providers configured.{/ts}
- </div>
- <div class="action-link">
- <a href="{crmURL p='civicrm/admin/sms/provider' q="action=add&reset=1"}" class="button"><span><div class="icon add-icon"></div>{ts}Add SMS Provider{/ts}</span></a>
+ {ts}None found.{/ts}
</div>
-{/if}
+ {/if}
+ <div class="action-link">
+ <a href="{crmURL p='civicrm/admin/sms/provider' q="action=add&reset=1"}" class="button"><span><div class="icon add-icon"></div>{ts}Add SMS Provider{/ts}</span></a>
+ </div>
{/if}
function enableDisable() {
$row = $(this).closest('.crm-entity');
info = $(this).crmEditableEntity();
- fieldLabel = info.label || info.title || info.name || {/literal}'{ts escape="js"}Record{/ts}'{literal};
+ fieldLabel = info.label || info.title || info.display_name || info.name || {/literal}'{ts escape="js"}Record{/ts}'{literal};
enabled = !$row.hasClass('disabled');
if (enabled) {
CRM.confirm({{/literal}