mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-02 11:52:28 +01:00
Service Offering page - implement new advanced search.
This commit is contained in:
parent
65f9f02e0a
commit
c47ba59939
@ -268,10 +268,7 @@
|
||||
<div class="adv_searchpopup_bg" id="advanced_search_popup" style="display: none;">
|
||||
<div class="adv_searchformbox">
|
||||
<form action="#" method="post">
|
||||
<ol>
|
||||
<li>
|
||||
<input class="text textwatermark" type="text" id="adv_search_name" value="by name" />
|
||||
</li>
|
||||
<ol>
|
||||
<li id="adv_search_domain_li" style="display: none;">
|
||||
<select class="select" id="adv_search_domain">
|
||||
</select>
|
||||
|
||||
@ -19,25 +19,20 @@
|
||||
function serviceOfferingGetSearchParams() {
|
||||
var moreCriteria = [];
|
||||
|
||||
var $advancedSearchPopup = $("#advanced_search_popup");
|
||||
if (lastSearchType == "advanced_search" && $advancedSearchPopup.length > 0) {
|
||||
var name = $advancedSearchPopup.find("#adv_search_name").val();
|
||||
if (name!=null && trim(name).length > 0)
|
||||
moreCriteria.push("&name="+todb(name));
|
||||
|
||||
var searchInput = $("#basic_search").find("#search_input").val();
|
||||
if (searchInput != null && searchInput.length > 0) {
|
||||
moreCriteria.push("&keyword="+todb(searchInput));
|
||||
}
|
||||
|
||||
var $advancedSearchPopup = getAdvancedSearchPopupInSearchContainer();
|
||||
if ($advancedSearchPopup.length > 0 && $advancedSearchPopup.css("display") != "none" ) {
|
||||
if ($advancedSearchPopup.find("#adv_search_domain_li").css("display") != "none") {
|
||||
var domainId = $advancedSearchPopup.find("#adv_search_domain").val();
|
||||
if (domainId!=null && domainId.length > 0)
|
||||
moreCriteria.push("&domainid="+domainId);
|
||||
}
|
||||
}
|
||||
else {
|
||||
var searchInput = $("#basic_search").find("#search_input").val();
|
||||
if (lastSearchType == "basic_search" && searchInput != null && searchInput.length > 0) {
|
||||
moreCriteria.push("&keyword="+todb(searchInput));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return moreCriteria.join("");
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user