Holger Knublauch

Download page new design

......@@ -7,50 +7,79 @@
<script type="text/javascript" src="lib/rh/jquery/jquery.js"></script>
<script type="text/javascript" src="lib/rh/jquery/jquery-ui.js"></script>
</head>
<body>
<rhswp:Header />
<h3>Download a Daily Drilling Report</h3>
<form action="ddrFileDownload">
Well Bore:<br />
<select size="15">
<ui:forEach ui:resultSet="{#
SELECT ?well ?wellName
WHERE {
GRAPH &lt;https://www.reportinghub.no/data/npd&gt; {
?well a npd:Well .
?well npd:name ?wellName .
}
} ORDER BY ?wellName
}">
<optgroup label="{= ?wellName }">
<ui:forEach ui:resultSet="{#
SELECT ?wellBore ?wellBoreName
WHERE {
GRAPH &lt;https://www.reportinghub.no/data/npd&gt; {
?wellBore npd:partOfWell ?well .
?wellBore npd:name ?wellBoreName .
}
} ORDER By ?wellBoreName
}">
<option value="{= xsd:string(?wellBore) }">{= ?wellBoreName }</option>
</ui:forEach>
</optgroup>
</ui:forEach>
</select>
<br /><br />
<script>
Date: <input type="text" id="datepicker" />
<script>
$(function() {
$("#datepicker").datepicker();
function updateWellBores() {
$("#wellSelect option:selected").each(function() {
$.getJSON("getWellBores.json.swp",{ well: $(this).val(), ajax: 'true'}, function(j) {
var options = '';
for (var i = 0; i &lt; j.length; i++) {
options += '<option value="' + j[i].value + '">' + j[i].label + '</option>';
}
$("#wellBoreSelect").html(options);
});
});
</script>
&nbsp;
<input type="submit" value="Download" />
</form>
}
</script>
</head>
<body>
<div id="wrapper">
<rhswp:Header />
<div id="content">
<h3>Download a Daily Drilling Report</h3>
<form action="ddrFileDownload">
<table>
<tr>
<td style="vertical-align: top">
<div class="formHeader">1. Select Well:</div>
<select size="10" id="wellSelect" style="width: 200px">
<ui:forEach ui:resultSet="{#
SELECT ?well ?wellName
WHERE {
GRAPH &lt;https://www.reportinghub.no/data/npd&gt; {
?well a npd:Well .
?well npd:name ?wellName .
}
} ORDER BY ?wellName
}">
<option value="{= ?well }">{= ?wellName }</option>
</ui:forEach>
</select>
<script>
$('#wellSelect').change(function() {
updateWellBores();
});
</script>
</td>
<td></td>
<td style="padding-left:20px; vertical-align: top">
<div>
<div class="formHeader">2. Select Well Bore:</div>
<select size="5" id="wellBoreSelect" style="width:200px">
</select>
</div><br />
<div>
<div class="formHeader">3. Select Date:</div><input type="text" id="datepicker" />
<script>
$(function() {
$("#datepicker").datepicker();
});
</script>
&nbsp;
<input type="submit" value="Download" />
</div>
</td>
</tr>
</table>
</form>
</div>
</div>
</body>
</html>
\ No newline at end of file
......
<ui:setContext
xmlns:npd="http://www.reportinghub.no/schema/npd#"
ui:queryGraph="&lt;https://www.reportinghub.no/data/npd&gt;"
let:well="{= ui:param('well', rdfs:Resource) }">
[
<ui:forEach ui:resultSet="{#
SELECT ?wellBore ?wellBoreName
WHERE {
?wellBore npd:partOfWell ?well .
?wellBore npd:name ?wellBoreName .
} ORDER By ?wellBoreName
}" ui:indexVar="i"><ui:if ui:condition="{= ?i &gt; 0 }">,</ui:if>
{
"value" : "{= ui:json(?wellBore) }",
"label" : "{= ?wellBoreName }"
}</ui:forEach>
]
</ui:setContext>
\ No newline at end of file
<div>
<img src="lib/rh/images/EPIMLogoLong.jpg" />
<h1>ReportingHub</h1>
<div>You are logged in as: <b>{= rhspin:userName() }</b></div>
</div>
\ No newline at end of file
<ui:group>
<div>&nbsp;</div>
<div class="logoContainer"><a href="http://www.epim.no" target="_new"><img src="lib/rh/images/logoEpim.gif" width="201" height="106" align="right" title="EPIM" /></a>
<div style="padding: 10px">
<h1>ReportingHub</h1>
<div>You are logged in as: <b>{= rhspin:userName() }</b></div>
</div>
</div>
</ui:group>
\ No newline at end of file
......
......@@ -2,4 +2,42 @@
body {
font-family: sans-serif;
margin:0 0px 0 0;
font-family:Tahoma,arial,Helvetica;
font-size:12px;
background-color:#FEFEFC;
background-image:url(images/bg.png);
background-position:top center;
background-repeat:repeat-x;
color:#333;
}
#content {
position:relative;
margin-top:0px;
display:block;
padding:15px 30px 30px 30px;
background-color:#fefefc;
}
#wrapper{
position:relative;
width:950px;
margin:0 auto;
display:block;
background-repeat:no-repeat;
}
a,a:link,a:visited {
color:#375f82;
}
.logoContainer {
background: url(images/headerBg.png);
width: 950px;
height: 106px;
}
.formHeader {
font-weight: bold;
}
\ No newline at end of file
......