formPortal.html 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. <style>
  2. .box{
  3. width:120px;
  4. height:120px;
  5. }
  6. .gold{ background-color: gold; }
  7. .red{ background-color: red; }
  8. .green { background-color: #ecffdc;}
  9. .blue { background-color: #b6d0e2; }
  10. .brown { background-color: #eaddca; }
  11. .orange { background-color: #ffe5b4; }
  12. .large{
  13. font-size: 30px;
  14. }
  15. .center{
  16. text-align: center;
  17. }
  18. .stretch{
  19. padding: 50px;
  20. }
  21. </style>
  22. <table cellspacing="2" cellpadding="5" border="0">
  23. <tr><td>Version: </td><td><strong id="version">0.0</strong></td></tr>
  24. </table>
  25. <div id="formDiv">
  26. </div>
  27. <div id="debugDiv" style="display:none">
  28. <h3>Debug notes</h3>
  29. <textarea cols="95" rows="5" id="formStatus">
  30. </textarea>
  31. </div>
  32. <script type "text/javascript">
  33. window.onload=loadScripts;
  34. function loadScripts(){
  35. LABKEY.requiresScript(["crfTecant/formPortal.js","crfTecant/debug.js"],init);
  36. }
  37. function init(){
  38. console.log('Here');
  39. let config=formPortal.config;
  40. config.document=document;
  41. config.div="formDiv";
  42. debug.document=document;
  43. debug.debugArea="formStatus";
  44. //set this to true to enable on-page debug display (otherwise, error messages appear in consloe)
  45. if (false){
  46. formPortal.setDebug(debug);
  47. document.getElementById("debugDiv").style.display="block";
  48. }
  49. config.role="crfEditor";
  50. formPortal.clear();
  51. formPortal.print("XStarting");
  52. config.participantField="PatientId";
  53. formPortal.generateFormArray();
  54. //formPortal.scriptsLoaded();
  55. }
  56. </script>