Skip to content

Commit

Permalink
Merge branch 'i180' into development
Browse files Browse the repository at this point in the history
  • Loading branch information
gschueler committed Feb 18, 2011
2 parents b859989 + 52baf14 commit 9f0a782
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 15 deletions.
11 changes: 3 additions & 8 deletions rundeckapp/grails-app/views/framework/nodes.gsp
Expand Up @@ -441,19 +441,14 @@
/**
* filter toggle
*/
<g:set var="isCompact" value="${params.compact?true:false}"/>
function filterToggle(evt) {
['${rkey}filter','${rkey}filterdispbtn'].each(Element.toggle);
if (${isCompact}) {
$('${rkey}nodescontent').toggle();
}
['outsidefiltersave'].each($('${rkey}filter').visible()?Element.hide:Element.show);
}
function filterToggleSave(evt) {
['${rkey}filter','${rkey}fsave'].each(Element.show);
['${rkey}filterdispbtn','${rkey}fsavebtn'].each(Element.hide);
if (${isCompact}) {
$('${rkey}nodescontent').hide();
}
['outsidefiltersave'].each($('${rkey}filter').visible()?Element.hide:Element.show);
}
/** START history
Expand Down Expand Up @@ -710,7 +705,7 @@


<g:if test="${!filterName}">
<span class="prompt action obs_filtersave" title="Click to save this filter with a name">
<span class="prompt action obs_filtersave" title="Click to save this filter with a name" id="outsidefiltersave">
save this filter&hellip;
</span>
</g:if>
Expand Down
11 changes: 5 additions & 6 deletions rundeckapp/grails-app/views/menu/_workflowsFull.gsp
Expand Up @@ -25,9 +25,8 @@
<g:timerStart key="_workflowsFull.gsp"/>
<g:timerStart key="head"/>
<%-- define form display conditions --%>
<g:set var="isCompact" value="${params.compact?true:false}"/>

<g:set var="rkey" value="${g.rkey()}"/>
<g:set var="rkey" value="${rkey?:g.rkey()}"/>

<g:if test="${session.user && User.findByLogin(session.user)?.jobfilters}">
<g:set var="filterset" value="${User.findByLogin(session.user)?.jobfilters}"/>
Expand Down Expand Up @@ -55,7 +54,7 @@
<g:if test="${params.compact}">
<g:hiddenField name="compact" value="${params.compact}"/>
</g:if>
<span class="prompt action" onclick="['${rkey}filter','${rkey}filter-toggle'].each(Element.toggle);if(${isCompact}){$('${rkey}wfcontent').toggle();}">
<span class="prompt action obs_filtertoggle">
Filter
<img src="${resource(dir:'images',file:'icon-tiny-disclosure-open.png')}" width="12px" height="12px"/>
</span>
Expand Down Expand Up @@ -119,12 +118,12 @@
<!--<span class="info note">Filter:</span>-->
</g:if>
<g:if test="${!filterName}">
<span class="prompt action " onclick="['${rkey}filter','${rkey}filter-toggle','${rkey}fsave','${rkey}fsavebtn'].each(Element.toggle);if(${isCompact}){$('${rkey}wfcontent').toggle();}" id="${rkey}fsavebtn" title="Click to save this filter with a name">
<span class="prompt action obs_filtersave" id="outsidefiltersave" title="Click to save this filter with a name">
save this filter&hellip;
</span>
</g:if>
<div style="padding:5px 0;margin:5px 0;" id='${rkey}filter-toggle'>
<span title="Click to modify filter" class="info textbtn query action" onclick="['${rkey}filter','${rkey}filter-toggle'].each(Element.toggle);if(${isCompact}){$('${rkey}wfcontent').toggle();}" >
<span title="Click to modify filter" class="info textbtn query action obs_filtertoggle" >
<g:each in="${wasfiltered.sort()}" var="qparam">
<span class="querykey"><g:message code="jobquery.title.${qparam}"/></span>:

Expand All @@ -149,7 +148,7 @@
<span class="prompt"><g:message code="domain.ScheduledExecution.title"/>s (${total})</span>
</g:if>

<span class="prompt action" onclick="['${rkey}filter','${rkey}filter-toggle'].each(Element.toggle);if(${isCompact}){$('${rkey}wfcontent').toggle();}" id="${rkey}filter-toggle">
<span class="prompt action obs_filtertoggle" id="${rkey}filter-toggle">
Filter
<img src="${resource(dir:'images',file:'icon-tiny-disclosure'+(wasfiltered?'-open':'')+'.png')}" width="12px" height="12px"/></span>
<g:if test="${filterset}">
Expand Down
19 changes: 18 additions & 1 deletion rundeckapp/grails-app/views/menu/jobs.gsp
@@ -1,5 +1,6 @@
<html>
<head>
<g:set var="rkey" value="${g.rkey()}" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<meta name="layout" content="base"/>
<meta name="tabpage" content="jobs"/>
Expand Down Expand Up @@ -274,6 +275,15 @@
Event.observe(e,'mouseover',jobLinkMouseover.curry(e));
Event.observe(e,'mouseout',jobLinkMouseout.curry(e));
});
}
function filterToggle(evt) {
['${rkey}filter','${rkey}filter-toggle'].each(Element.toggle);
['outsidefiltersave'].each($('${rkey}filter').visible()?Element.hide:Element.show);
}
function filterToggleSave(evt) {
['${rkey}filter','${rkey}fsave'].each(Element.show);
['${rkey}filter-toggle','${rkey}fsavebtn'].each(Element.hide);
['outsidefiltersave'].each($('${rkey}filter').visible()?Element.hide:Element.show);
}
function init(){
loadNowRunning();
Expand All @@ -289,6 +299,13 @@
}
return true;
},false);
$$('.obs_filtertoggle').each(function(e) {
Event.observe(e, 'click', filterToggle);
});
$$('.obs_filtersave').each(function(e) {
Event.observe(e, 'click', filterToggleSave);
});
}
Event.observe(window,'load',init);
</script>
Expand Down Expand Up @@ -341,7 +358,7 @@
<div id="error" class="error" style="display:none;"></div>
</div>
<div class="runbox jobs" id="indexMain">
<g:render template="workflowsFull" model="${[jobgroups:jobgroups,wasfiltered:wasfiltered?true:false,nowrunning:nowrunning,nextExecutions:nextExecutions,jobauthorizations:jobauthorizations,authMap:authMap,nowrunningtotal:nowrunningtotal,max:max,offset:offset,paginateParams:paginateParams,sortEnabled:true]}"/>
<g:render template="workflowsFull" model="${[jobgroups:jobgroups,wasfiltered:wasfiltered?true:false,nowrunning:nowrunning,nextExecutions:nextExecutions,jobauthorizations:jobauthorizations,authMap:authMap,nowrunningtotal:nowrunningtotal,max:max,offset:offset,paginateParams:paginateParams,sortEnabled:true,rkey:rkey]}"/>
</div>
<div id="execDiv" style="display:none">

Expand Down

0 comments on commit 9f0a782

Please sign in to comment.