summaryrefslogtreecommitdiff
path: root/UI/rc-display-form.html
blob: b29a80e080454f7bd7be994d620df687647cc0e5 (plain)
  1. <?lsmb INCLUDE 'ui-header.html' ?>
  2. <?lsmb PROCESS elements.html ?>
  3. <body>
  4. <form method="post" action="<?lsmb form.script ?>">
  5. <table width="100%">
  6. <tr>
  7. <th class="listtop" colspan="<?lsmb columns.size ?>"><?lsmb form.title ?></th>
  8. </tr>
  9. <tr>
  10. <?lsmb IF options.defined ?>
  11. <td><?lsmb FOREACH option IN options; option ?><br /><?lsmb END ?></td>
  12. <?lsmb ELSE ?>
  13. <td colspan="<?lsmb columns.size ?>"></td>
  14. <?lsmb END ?>
  15. </tr>
  16. <tr>
  17. <td>
  18. <table width="100%">
  19. <tr class="listheading">
  20. <?lsmb FOREACH column IN columns ?>
  21. <th class="listtop">
  22. <?lsmb IF heading.$column.href ?><a class="listtop" href="<?lsmb heading.$column.href ?>"><?lsmb heading.$column.text ?></a>
  23. <?lsmb ELSE; heading.$column; END ?>
  24. </th>
  25. <?lsmb END ?>
  26. </tr>
  27. <?lsmb FOREACH row IN rows ?>
  28. <?lsmb IF row.class == 'heading'; s = 'th'; c = 'listheading';
  29. ELSIF row.class == 'subtotal'; s = 'th'; c = 'listsubtotal';
  30. ELSE; s = 'td'; c = "listrow${row.i}"; END ?>
  31. <tr class="<?lsmb c ?>">
  32. <?lsmb FOREACH column IN columns ?>
  33. <<?lsmb s ?> class="<?lsmb c ?>" <?lsmb IF (!row.class.defined || row.class != 'heading') && row_alignment.$column ?>align="<?lsmb row_alignment.$column ?>"<?lsmb END ?>>
  34. <?lsmb IF row.$column.href.defined ?>
  35. <a href="<?lsmb row.$column.href?>"><?lsmb row.$column.text ?></a>
  36. <?lsmb ELSIF row.$column.delimiter;
  37. FOREACH l IN row.$column.text.split(row.$column.delimiter); l ?><br /><?lsmb END ?>
  38. <?lsmb ELSIF row.$column.input.defined;
  39. PROCESS input element_data=row.$column.input ?>
  40. <?lsmb ELSE; row.$column; END ?>
  41. </<?lsmb s ?>>
  42. <?lsmb END ?>
  43. </tr>
  44. <?lsmb END ?>
  45. <?lsmb IF totals ?>
  46. <tr class="listtotal">
  47. <?lsmb FOREACH column IN columns ?>
  48. <th class="listtotal" align="right"><?lsmb totals.$column ?></th>
  49. <?lsmb END ?>
  50. </tr>
  51. <?lsmb END ?>
  52. </table>
  53. </td>
  54. </tr>
  55. <?lsmb IF form.report ?>
  56. </table>
  57. <?lsmb ELSE ?>
  58. <tr>
  59. <td>
  60. <table width="100%">
  61. <tr>
  62. <td align="right">
  63. <table>
  64. <tr>
  65. <th align="right"><?lsmb text('Statement Balance') ?></th>
  66. <td width="10%" />
  67. <td><?lsmb PROCESS input element_data={
  68. name => 'statementbalance',
  69. size => '11',
  70. value => form.statementbalance,
  71. } -?>
  72. </td>
  73. </tr>
  74. <?lsmb IF form.pos ?>
  75. <tr>
  76. <th align="right"><?lsmb options =
  77. [{text => text('Under'), value => 'under'},
  78. {text => text('Over'), value => 'over'}];
  79. IF form.over_under == 'under';
  80. options.0.selected = 'selected';
  81. ELSIF form.over_under == 'over';
  82. options.1.selected = 'selected';
  83. END;
  84. PROCESS select element_data={
  85. name => 'over_under',
  86. options => options,
  87. } ?></th>
  88. <td width="10%" />
  89. <td align="right"><?lsmb PROCESS input element_data={
  90. name => 'null',
  91. size => '11',
  92. value => form.null2,
  93. } ?></td>
  94. </tr>
  95. <?lsmb ELSE ?>
  96. <tr>
  97. <th align="right"><?lsmb text('Difference') ?></th>
  98. <td width="10%" />
  99. <td align="right"><?lsmb PROCESS input element_data={
  100. name => 'null',
  101. size => '11',
  102. value => hiddens.difference,
  103. } ?></td>
  104. </tr>
  105. <?lsmb END ?>
  106. </table>
  107. </td>
  108. </tr>
  109. </table>
  110. </td>
  111. </tr>
  112. <tr><td colspan="<?lsmb columns.size ?>"><hr size="3" /></td></tr>
  113. </table>
  114. <br />
  115. <?lsmb FOREACH hidden IN hiddens.keys;
  116. PROCESS input element_data={
  117. type => 'hidden',
  118. name => hidden,
  119. value => hiddens.item(hidden)
  120. }; END ?>
  121. <?lsmb FOREACH button IN buttons; PROCESS button element_data=button; END ?>
  122. <?lsmb END ?>
  123. </form>
  124. </body>
  125. </html>