diff options
author | Adam Young <ayoung@redhat.com> | 2010-08-06 10:01:44 -0400 |
---|---|---|
committer | Adam Young <ayoung@redhat.com> | 2010-08-06 11:55:38 -0400 |
commit | 125bd09faf21411fafda01e76989b4856bbd267c (patch) | |
tree | b9e2ad70165154f95463f6a69dc5d62de5821f87 /install/static/hostgroup.js | |
parent | a63fd83e890ed4f2ec3f0cd0f96f0a329698796a (diff) | |
download | freeipa.git-125bd09faf21411fafda01e76989b4856bbd267c.tar.gz freeipa.git-125bd09faf21411fafda01e76989b4856bbd267c.tar.xz freeipa.git-125bd09faf21411fafda01e76989b4856bbd267c.zip |
The Javascript code for the new web UI
Now with whitespace cleanup.
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 00000000..64eeb3af --- /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..."); + }); + +} |