本文整理汇总了PHP中CRM_Core_Page_Basic::browse方法的典型用法代码示例。如果您正苦于以下问题:PHP CRM_Core_Page_Basic::browse方法的具体用法?PHP CRM_Core_Page_Basic::browse怎么用?PHP CRM_Core_Page_Basic::browse使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CRM_Core_Page_Basic
的用法示例。
在下文中一共展示了CRM_Core_Page_Basic::browse方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: browse
/**
* Browse all options
*
*
* @return void
* @access public
* @static
*/
function browse()
{
if (!self::$_gName) {
return parent::browse();
}
CRM_Core_Resources::singleton()->addScriptFile('civicrm', 'js/crm.livePage.js');
$groupParams = array('name' => self::$_gName);
$optionValue = CRM_Core_OptionValue::getRows($groupParams, $this->links(), 'component_id,weight');
$gName = self::$_gName;
$returnURL = CRM_Utils_System::url("civicrm/admin/options/{$gName}", "reset=1&group={$gName}");
$filter = "option_group_id = " . self::$_gId;
CRM_Utils_Weight::addOrder($optionValue, 'CRM_Core_DAO_OptionValue', 'id', $returnURL, $filter);
// retrieve financial account name for the payment instrument page
if ($gName = "payment_instrument") {
foreach ($optionValue as $key => $option) {
$optionValue[$key]['financial_account'] = CRM_Financial_BAO_FinancialTypeAccount::getFinancialAccount($key, 'civicrm_option_value');
}
}
$this->assign('includeWysiwygEditor', TRUE);
$this->assign('rows', $optionValue);
}
示例2: browse
/**
* Browse all options.
*
*
* @return void
*/
public function browse()
{
if (!self::$_gName) {
return parent::browse();
}
$groupParams = array('name' => self::$_gName);
$optionValue = CRM_Core_OptionValue::getRows($groupParams, $this->links(), 'component_id,weight');
$gName = self::$_gName;
$returnURL = CRM_Utils_System::url("civicrm/admin/options/{$gName}", "reset=1&group={$gName}");
$filter = "option_group_id = " . self::$_gId;
CRM_Utils_Weight::addOrder($optionValue, 'CRM_Core_DAO_OptionValue', 'id', $returnURL, $filter);
// retrieve financial account name for the payment method page
if ($gName = "payment_instrument") {
foreach ($optionValue as $key => $option) {
$optionValue[$key]['financial_account'] = CRM_Financial_BAO_FinancialTypeAccount::getFinancialAccount($key, 'civicrm_option_value');
}
}
$this->assign('rows', $optionValue);
}