diff options
Diffstat (limited to 'install/static/hostgroup.js')
-rw-r--r-- | install/static/hostgroup.js | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/install/static/hostgroup.js b/install/static/hostgroup.js new file mode 100644 index 000000000..64eeb3afc --- /dev/null +++ b/install/static/hostgroup.js @@ -0,0 +1,35 @@ +function setupHostgroup(facet){ + if (facet == "details"){ + setupHostgroupDetails(); + }else{ + setupHostgroupSearch(); + } +} + +function setupHostgroupDetails(){ + var detailsForm = new DetailsForm(); +} + + +function setupHostgroupSearch(){ + + var columns = [ + {title:"Hostgroup",column:"cn",render: function(current,cell){ + renderDetailColumn(current,cell,current[this.column],"hostgroup"); + }}, + {title:"Description", column:"description",render: renderSimpleColumn}]; + + var hostgroupSearchForm = new SearchForm("hostgroup", "find", columns); + + $("#query").unbind(); + + $("#query").click(function(){ + sampleData = "sampledata/hostgrouplist.json"; + executeSearch(hostgroupSearchForm); + }); + $("#new").unbind(); + $("#new").click( function() { + alert("New Hostgroup..."); + }); + +} |