本文整理汇总了PHP中RequestUtil::getLandingPageUrl方法的典型用法代码示例。如果您正苦于以下问题:PHP RequestUtil::getLandingPageUrl方法的具体用法?PHP RequestUtil::getLandingPageUrl怎么用?PHP RequestUtil::getLandingPageUrl使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类RequestUtil
的用法示例。
在下文中一共展示了RequestUtil::getLandingPageUrl方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getTotalMWBELink
static function getTotalMWBELink()
{
if (preg_match('/contract/', $_GET['q'])) {
$domain = "contracts";
} else {
$domain = "spending";
}
switch ($domain) {
case "spending":
$table = "aggregateon_mwbe_spending_coa_entities";
$table_subven = "aggregateon_subven_spending_coa_entities";
$urlParamMap = array("year" => "year_id", "yeartype" => "type_of_year", "agency" => "agency_id", "vendor" => "vendor_id");
$urlParamMapSubven = array("year" => "year_id", "yeartype" => "type_of_year", "agency" => "agency_id", "vendor" => "prime_vendor_id");
$default_params = array("minority_type_id" => "2~3~4~5~9");
break;
case "contracts":
$table = "aggregateon_mwbe_contracts_cumulative_spending";
$table_subven = "aggregateon_subven_contracts_cumulative_spending";
$urlParamMap = array("year" => "fiscal_year_id", "agency" => "agency_id", "yeartype" => "type_of_year", "vendor" => "vendor_id");
$urlParamMapSubven = array("year" => "fiscal_year_id", "agency" => "agency_id", "yeartype" => "type_of_year", "vendor" => "prime_vendor_id");
$default_params = array("status_flag" => "A", "minority_type_id" => "2~3~4~5~9");
break;
}
if (self::get_top_nav_records_count($urlParamMap, $default_params, $table) > 0) {
$dashboard = "mp";
} elseif (self::get_top_nav_records_count($urlParamMapSubven, $default_params, $table_subven) > 0) {
// tm_wbe is an exception case for total MWBE link. When prime data is not present but sub data is present for the agency vendor combination.
$dashboard = "ms/tm_wbe/Y";
} else {
return "";
}
return '/' . RequestUtil::getLandingPageUrl($domain, _getRequestParamValue("year"), _getRequestParamValue("yeartype")) . "/mwbe/" . MappingUtil::$total_mwbe_cats . "/dashboard/" . $dashboard . _checkbook_project_get_url_param_string("agency") . _checkbook_project_get_url_param_string("vendor");
}
示例2: getCurrentSubVendorsTopNavFilters
/**
* Function to populate the Sub Vendors dashboard drop down filters
*
* @param $active_domain_link
* @param $domain
* @return string
*/
static function getCurrentSubVendorsTopNavFilters($active_domain_link, $domain)
{
$mwbe_filters_html = "";
$tm_wbe = _getRequestParamValue('tm_wbe');
//M/WBE filters should be included in mp and sp dashboards
if (RequestUtil::isDashboardFlowPrimevendor() || $tm_wbe == "Y") {
$applicable_minority_types = self::getCurrentSubMWBEApplicableFilters($domain);
$active_domain_link = preg_replace('/\\/mwbe\\/[^\\/]*/', '', $active_domain_link);
if (array_intersect($applicable_minority_types, array(4, 5))) {
$mwbe_filters_html .= "<li class='no-click'><a href='/" . $active_domain_link . "/mwbe/4~5'>Asian American</a></li>";
}
if (array_intersect($applicable_minority_types, array(2))) {
$mwbe_filters_html .= "<li class='no-click'><a href='/" . $active_domain_link . "/mwbe/2'>Black American</a></li>";
}
if (array_intersect($applicable_minority_types, array(9))) {
$mwbe_filters_html .= "<li class='no-click'><a href='/" . $active_domain_link . "/mwbe/9'>Women</a></li>";
}
if (array_intersect($applicable_minority_types, array(3))) {
$mwbe_filters_html .= "<li class='no-click'><a href='/" . $active_domain_link . "/mwbe/3'>Hispanic American</a></li>";
}
if ($mwbe_filters_html != "") {
$mwbe_filters_html = "<li class='no-click title'>M/WBE Category</li>" . $mwbe_filters_html;
}
}
//Sub vendors home link
$year = _getRequestParamValue('year');
$yearType = _getRequestParamValue('yeartype');
$sub_vendors_home_link = RequestUtil::getLandingPageUrl($domain, $year, $yearType);
$home_link_html = "<li class='no-click'><a href='/" . $sub_vendors_home_link . "/dashboard/ss'>Sub Vendors Home</a></li>";
//Sub vendors total link
$total_subven_link = RequestUtil::getTotalSubvendorsLink();
$total_link_html = $total_subven_link != null && $total_subven_link != "" ? "<li class='no-click'><a href='" . $total_subven_link . "'>Total Sub Vendors</a></li>" : "";
//Append all links
$filters_html = "<div class='main-nav-drop-down' style='display:none'>";
$filters_html .= "<ul>";
$filters_html .= $mwbe_filters_html . $total_link_html . $home_link_html;
$filters_html .= "</ul>";
$filters_html .= "</div>";
return $filters_html;
}