summaryrefslogtreecommitdiffstats
path: root/idrop-web/grails-app/views/browse/index.gsp
blob: 428079560eac3023f5b961ce551145815ceba626 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<head>
	<meta name="layout" content="mainNoSidebar" />
	<g:javascript library="mydrop/home" />
	<g:javascript library="mydrop/metadata" />
</head>
<div class="wrapper clearfix"
	style="height: 820px; overflow:hidden;">
	<g:hiddenField name="mode" id="mode" value="${mode}"/>
	<g:hiddenField name="viewStateBrowseOptionVal" id="viewStateBrowseOptionVal" value="${viewState.browseView}"/>
	<g:hiddenField name="presetPath" id="presetPath" value="${viewState.rootPath}"/>
	<g:hiddenField id="viewStateSelectedPath" name="viewStateSelectedPath" value="${viewState.selectedPath}"/>
	<g:render template="/browse/browseTabContent" />
	
</div> 
<script type="text/javascript">
	var dataLayout;
	var tabs;
	$(document).ready(function() {

		$("#topbarBrowser").addClass("active");

		$.ajaxSetup({
			cache : false
		});

		$("#infoDiv").resize();

		dataLayout = $("#dataTreeView").layout({
			applyDefaultStyles : false,
			size : "auto",
			west__minSize : 150,
			west__resizable : true
		});

		var mode = $("#mode").val();
		browseOptionVal = $("#viewStateBrowseOptionVal").val();
		dataTreePath = $("#presetPath").val();
		var thisSelectedPath = $("#viewStateSelectedPath").val();

		
		if (mode == null || mode=="") {
			retrieveBrowserFirstView("detect","", thisSelectedPath);
		} else {
			retrieveBrowserFirstView(mode, dataTreePath, thisSelectedPath);
		}

		 $(window).bind( 'hashchange', function(e) {
			  
             processStateChange( $.bbq.getState());

		});

	});
</script>