Ver código fonte

Adding routines to print the form layout

Andrej Studen 2 anos atrás
pai
commit
51073114d2
3 arquivos alterados com 71 adições e 0 exclusões
  1. 57 0
      views/crfManager.html
  2. 10 0
      views/crfManager.view.xml
  3. 4 0
      views/crfManager.webpart.xml

+ 57 - 0
views/crfManager.html

@@ -0,0 +1,57 @@
+<style>
+.box{
+width:120px;
+height:120px;
+}
+
+.gold{ background-color: gold; }
+.red{ background-color: red; }
+
+.large{
+	font-size: 30px;
+}
+
+.center{
+	text-align: center;
+}
+
+.stretch{
+	padding: 50px;
+}
+</style>
+
+<table cellspacing="2" cellpadding="5" border="0">
+<tr><td>Version: </td><td><strong id="version">0.0</strong></td></tr>
+</table>
+
+<div id="formDiv">
+</div>
+
+<div id="debugDiv" style="display:block">
+	<h3>Debug notes</h3>
+	<textarea cols="95" rows="5" id="debugArea">
+	</textarea>
+</div>
+
+
+<script type "text/javascript">
+window.onload=init;
+function init(){
+	config.document=document;
+	config.window=window;
+	config.div="formDiv";
+	config.debugArea="debugArea";
+	config.role="crfSponsor";
+	clear();
+	print("StartingX");
+	//add a button with callback
+	config.button = config.document.createElement("button");
+        config.button.innerHTML = "Generate description";
+	let el=config.document.getElementById(config.div);
+	//print(el);
+	el.appendChild(config.button);
+	config.button.onclick=generateDescription;
+
+
+}
+</script>

+ 10 - 0
views/crfManager.view.xml

@@ -0,0 +1,10 @@
+<view xmlns="http://labkey.org/data/xml/view" title="CRF Management" frame="portal">
+	<dependencies>
+		<dependency path="crf/crfManager.js"/>
+		<dependency path="crf/pdfkit.standalone.js" />
+		<dependency path="crf/blob-stream.js"/>
+	</dependencies>
+	<permissions>
+		<permission name="login"/>
+	</permissions>
+</view>

+ 4 - 0
views/crfManager.webpart.xml

@@ -0,0 +1,4 @@
+<webpart xlmns="http://labkey.org/data/xml/webpart"
+	title="CRF Manager">
+	<view name="crfManager"/>
+</webpart>