rtml 1.2.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (397) hide show
  1. data/History.txt +4 -0
  2. data/Manifest.txt +396 -0
  3. data/PostInstall.txt +2 -0
  4. data/README.rdoc +42 -0
  5. data/Rakefile +33 -0
  6. data/app_generators/rtml/USAGE +5 -0
  7. data/app_generators/rtml/rtml_generator.rb +78 -0
  8. data/app_generators/rtml/templates/rails_template.rb +36 -0
  9. data/app_generators/rtml/templates/rtml/MIT-LICENSE +20 -0
  10. data/app_generators/rtml/templates/rtml/README +109 -0
  11. data/app_generators/rtml/templates/rtml/Rakefile +38 -0
  12. data/app_generators/rtml/templates/rtml/app/controllers/beryl_controller.rb +70 -0
  13. data/app_generators/rtml/templates/rtml/app/controllers/rtml/magcard_demo_controller.rb +9 -0
  14. data/app_generators/rtml/templates/rtml/app/controllers/rtml/oe/btmlpa_controller.rb +158 -0
  15. data/app_generators/rtml/templates/rtml/app/controllers/rtml/rtml_app_controller.rb +252 -0
  16. data/app_generators/rtml/templates/rtml/app/controllers/rtml/tml_app_controller.rb +418 -0
  17. data/app_generators/rtml/templates/rtml/app/helpers/beryl_helper.rb +72 -0
  18. data/app_generators/rtml/templates/rtml/app/helpers/beryl_tml_helpers/auth_result.rb +56 -0
  19. data/app_generators/rtml/templates/rtml/app/helpers/beryl_tml_helpers/common.rb +19 -0
  20. data/app_generators/rtml/templates/rtml/app/helpers/beryl_tml_helpers/index.rb +82 -0
  21. data/app_generators/rtml/templates/rtml/app/helpers/rtml/magcard_demo_helper.rb +2 -0
  22. data/app_generators/rtml/templates/rtml/app/helpers/rtml/magcard_demo_tml_helpers/authorized.rb +10 -0
  23. data/app_generators/rtml/templates/rtml/app/helpers/rtml/magcard_demo_tml_helpers/common.rb +20 -0
  24. data/app_generators/rtml/templates/rtml/app/helpers/rtml/magcard_demo_tml_helpers/index.rb +33 -0
  25. data/app_generators/rtml/templates/rtml/app/helpers/rtml/oe/btmlpa_helper.rb +2 -0
  26. data/app_generators/rtml/templates/rtml/app/helpers/rtml/oe/btmlpa_tml_helpers/auth_result.rb +23 -0
  27. data/app_generators/rtml/templates/rtml/app/helpers/rtml/oe/btmlpa_tml_helpers/common.rb +23 -0
  28. data/app_generators/rtml/templates/rtml/app/helpers/rtml/oe/btmlpa_tml_helpers/dynamic.rb +11 -0
  29. data/app_generators/rtml/templates/rtml/app/helpers/rtml/oe/btmlpa_tml_helpers/icc.rb +384 -0
  30. data/app_generators/rtml/templates/rtml/app/helpers/rtml/oe/btmlpa_tml_helpers/index.rb +191 -0
  31. data/app_generators/rtml/templates/rtml/app/helpers/rtml/oe/btmlpa_tml_helpers/receipt.rb +152 -0
  32. data/app_generators/rtml/templates/rtml/app/helpers/rtml/rtml_app_helper.rb +74 -0
  33. data/app_generators/rtml/templates/rtml/app/helpers/rtml/rtml_app_tml_helpers/common.rb +9 -0
  34. data/app_generators/rtml/templates/rtml/app/helpers/rtml/tml_app_helper.rb +43 -0
  35. data/app_generators/rtml/templates/rtml/app/models/rtml/card.rb +83 -0
  36. data/app_generators/rtml/templates/rtml/app/models/rtml/card_avs.rb +14 -0
  37. data/app_generators/rtml/templates/rtml/app/models/rtml/card_cvv.rb +14 -0
  38. data/app_generators/rtml/templates/rtml/app/models/rtml/card_parser.rb +21 -0
  39. data/app_generators/rtml/templates/rtml/app/models/rtml/card_pin.rb +18 -0
  40. data/app_generators/rtml/templates/rtml/app/models/rtml/emv_card_data.rb +25 -0
  41. data/app_generators/rtml/templates/rtml/app/models/rtml/mag_card_data.rb +21 -0
  42. data/app_generators/rtml/templates/rtml/app/models/rtml/reference_code.rb +26 -0
  43. data/app_generators/rtml/templates/rtml/app/models/rtml/state.rb +12 -0
  44. data/app_generators/rtml/templates/rtml/app/models/rtml/terminal.rb +8 -0
  45. data/app_generators/rtml/templates/rtml/app/models/rtml/transaction.rb +68 -0
  46. data/app_generators/rtml/templates/rtml/app/views/beryl/auth_result/another_rcpt.rtml.erb +15 -0
  47. data/app_generators/rtml/templates/rtml/app/views/beryl/auth_result/receipt.rtml.erb +108 -0
  48. data/app_generators/rtml/templates/rtml/app/views/beryl/auth_result/receipt_single_column.rtml.erb +106 -0
  49. data/app_generators/rtml/templates/rtml/app/views/beryl/index/about.rtml.erb +8 -0
  50. data/app_generators/rtml/templates/rtml/app/views/beryl/index/admin.rtml.erb +4 -0
  51. data/app_generators/rtml/templates/rtml/app/views/beryl/index/construction.rtml.erb +10 -0
  52. data/app_generators/rtml/templates/rtml/app/views/beryl/index/idle.rtml.erb +13 -0
  53. data/app_generators/rtml/templates/rtml/app/views/beryl/index/main_menu.rtml.erb +12 -0
  54. data/app_generators/rtml/templates/rtml/app/views/beryl/index/menu_credit.rtml.erb +8 -0
  55. data/app_generators/rtml/templates/rtml/app/views/beryl/index/menu_debit.rtml.erb +3 -0
  56. data/app_generators/rtml/templates/rtml/app/views/layouts/rtml/beryl_color.rtml.erb +24 -0
  57. data/app_generators/rtml/templates/rtml/app/views/layouts/rtml/beryl_mono.rtml.erb +8 -0
  58. data/app_generators/rtml/templates/rtml/app/views/layouts/rtml/magcard_demo_color.rtml.erb +24 -0
  59. data/app_generators/rtml/templates/rtml/app/views/layouts/rtml/magcard_demo_mono.rtml.erb +3 -0
  60. data/app_generators/rtml/templates/rtml/app/views/layouts/rtml/oe/btmlpa_i5100.rtml.erb +3 -0
  61. data/app_generators/rtml/templates/rtml/app/views/layouts/rtml/oe/btmlpa_i8550.rtml.erb +17 -0
  62. data/app_generators/rtml/templates/rtml/app/views/layouts/rtml/uml.html.erb +11 -0
  63. data/app_generators/rtml/templates/rtml/app/views/rtml/magcard_demo/authorized.html.erb +15 -0
  64. data/app_generators/rtml/templates/rtml/app/views/rtml/magcard_demo/authorized/main.rtml.erb +5 -0
  65. data/app_generators/rtml/templates/rtml/app/views/rtml/magcard_demo/index.html.erb +15 -0
  66. data/app_generators/rtml/templates/rtml/app/views/rtml/magcard_demo/index/_error.rtml.erb +2 -0
  67. data/app_generators/rtml/templates/rtml/app/views/rtml/magcard_demo/index/enter_amount.rtml.erb +5 -0
  68. data/app_generators/rtml/templates/rtml/app/views/rtml/magcard_demo/index/main.rtml.erb +4 -0
  69. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/dynamic/response.rtml.erb +2 -0
  70. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/icc.rtml.erb +760 -0
  71. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_enter_amount.rtml.erb +4 -0
  72. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_about.rtml.erb +8 -0
  73. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_duplicate.rtml.erb +9 -0
  74. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_examples.rtml.erb +9 -0
  75. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_logo.rtml.erb +11 -0
  76. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_other.rtml.erb +20 -0
  77. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_refund.rtml.erb +8 -0
  78. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_reversal.rtml.erb +9 -0
  79. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_sale.rtml.erb +8 -0
  80. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/_menu_sale_cashback.rtml.erb +8 -0
  81. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/about.rtml.erb +1 -0
  82. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/assert.rtml.erb +2 -0
  83. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/card_nmb.rtml.erb +19 -0
  84. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/compl_txn.rtml.erb +1 -0
  85. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/confirm_rev.rtml.erb +3 -0
  86. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/duplicate_na.rtml.erb +1 -0
  87. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/error_scr.rtml.erb +4 -0
  88. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/main_menu.rtml.bak +31 -0
  89. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/main_menu.rtml.erb +40 -0
  90. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/print_pf.rtml.erb +1 -0
  91. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/rd_sale_disp.rtml.erb +1 -0
  92. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/read_refund.rtml.erb +1 -0
  93. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/read_scb.rtml.erb +10 -0
  94. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/reject_trans.rtml.erb +1 -0
  95. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/remove_card.rtml.erb +1 -0
  96. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/rev_bad.rtml.erb +1 -0
  97. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/scb_check_f.rtml.erb +2 -0
  98. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/sign_check.rtml.erb +3 -0
  99. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/subm_err.rtml.erb +2 -0
  100. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/to_man_entry.rtml.erb +2 -0
  101. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/trans_abrt.rtml.erb +1 -0
  102. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/index/void_trans.rtml.erb +1 -0
  103. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/receipt/_receipt.rtml.erb +29 -0
  104. data/app_generators/rtml/templates/rtml/app/views/rtml/oe/btmlpa/receipt/error_paper.rtml.erb +3 -0
  105. data/app_generators/rtml/templates/rtml/app/views/rtml/rtml_app/_default_development.html.erb +167 -0
  106. data/app_generators/rtml/templates/rtml/app/views/rtml/rtml_app/_default_header.html.erb +12 -0
  107. data/app_generators/rtml/templates/rtml/app/views/rtml/rtml_app/_default_production.html.erb +8 -0
  108. data/app_generators/rtml/templates/rtml/app/views/rtml/rtml_app/charts.html.erb +14 -0
  109. data/app_generators/rtml/templates/rtml/app/views/rtml/tml_app/do_tml_redirect.rtml.erb +7 -0
  110. data/app_generators/rtml/templates/rtml/app/views/rtml/tml_app/get_terminal_info.rtml.erb +26 -0
  111. data/app_generators/rtml/templates/rtml/app/views/rtml/tml_app/rescue_action_in_public.rtml.erb +9 -0
  112. data/app_generators/rtml/templates/rtml/app/views/rtml/tml_app/rescue_action_locally.rtml.erb +42 -0
  113. data/app_generators/rtml/templates/rtml/components/rtml/features/common.rb +303 -0
  114. data/app_generators/rtml/templates/rtml/components/rtml/features/force.rb +46 -0
  115. data/app_generators/rtml/templates/rtml/components/rtml/features/return.rb +22 -0
  116. data/app_generators/rtml/templates/rtml/components/rtml/features/sale.rb +49 -0
  117. data/app_generators/rtml/templates/rtml/components/rtml/features/views/_confirmation.rtml.erb +10 -0
  118. data/app_generators/rtml/templates/rtml/components/rtml/features/views/_receipt_agreement.rtml.erb +3 -0
  119. data/app_generators/rtml/templates/rtml/components/rtml/features/views/_receipt_footer.rtml.erb +2 -0
  120. data/app_generators/rtml/templates/rtml/components/rtml/features/views/_receipt_header.rtml.erb +4 -0
  121. data/app_generators/rtml/templates/rtml/components/rtml/features/views/ask_cashback.rtml.erb +11 -0
  122. data/app_generators/rtml/templates/rtml/components/rtml/features/views/card_imprint.rtml.erb +7 -0
  123. data/app_generators/rtml/templates/rtml/components/rtml/features/views/check_cb.rtml.erb +11 -0
  124. data/app_generators/rtml/templates/rtml/components/rtml/features/views/conf_debit.rtml.erb +5 -0
  125. data/app_generators/rtml/templates/rtml/components/rtml/features/views/confirm_sale.rtml.erb +4 -0
  126. data/app_generators/rtml/templates/rtml/components/rtml/features/views/confrm_force.rtml.erb +4 -0
  127. data/app_generators/rtml/templates/rtml/components/rtml/features/views/cvv_skipped.rtml.erb +10 -0
  128. data/app_generators/rtml/templates/rtml/components/rtml/features/views/disp_avs.rtml.erb +8 -0
  129. data/app_generators/rtml/templates/rtml/components/rtml/features/views/do_avs_zip.rtml.erb +8 -0
  130. data/app_generators/rtml/templates/rtml/components/rtml/features/views/enter_amount.rtml.erb +12 -0
  131. data/app_generators/rtml/templates/rtml/components/rtml/features/views/enter_card.rtml.erb +8 -0
  132. data/app_generators/rtml/templates/rtml/components/rtml/features/views/enter_cashbk.rtml.erb +10 -0
  133. data/app_generators/rtml/templates/rtml/components/rtml/features/views/enter_cvv2.rtml.erb +8 -0
  134. data/app_generators/rtml/templates/rtml/components/rtml/features/views/enter_expiry.rtml.erb +9 -0
  135. data/app_generators/rtml/templates/rtml/components/rtml/features/views/fraud_check1.rtml.erb +6 -0
  136. data/app_generators/rtml/templates/rtml/components/rtml/features/views/fraud_check2.rtml.erb +8 -0
  137. data/app_generators/rtml/templates/rtml/components/rtml/features/views/frc_aprvl.rtml.erb +8 -0
  138. data/app_generators/rtml/templates/rtml/components/rtml/features/views/frc_avs_zip.rtml.erb +8 -0
  139. data/app_generators/rtml/templates/rtml/components/rtml/features/views/frc_bad_aprv.rtml.erb +5 -0
  140. data/app_generators/rtml/templates/rtml/components/rtml/features/views/frd_chk_fail.rtml.erb +5 -0
  141. data/app_generators/rtml/templates/rtml/components/rtml/features/views/invalid_exp.rtml.erb +1 -0
  142. data/app_generators/rtml/templates/rtml/components/rtml/features/views/no_entr_crd.rtml.erb +1 -0
  143. data/app_generators/rtml/templates/rtml/components/rtml/features/views/remove_card.rtml.erb +1 -0
  144. data/app_generators/rtml/templates/rtml/components/rtml/features/views/swipe_card.rtml.erb +7 -0
  145. data/app_generators/rtml/templates/rtml/components/rtml/features/views/trans_abort.rtml.erb +1 -0
  146. data/app_generators/rtml/templates/rtml/components/rtml/features/views/trans_reject.rtml.erb +1 -0
  147. data/app_generators/rtml/templates/rtml/components/rtml/features/views/void_ref.rtml.erb +10 -0
  148. data/app_generators/rtml/templates/rtml/components/rtml/features/void.rb +30 -0
  149. data/app_generators/rtml/templates/rtml/components/rtml/widgets/card_parser_widget.rb +90 -0
  150. data/app_generators/rtml/templates/rtml/components/rtml/widgets/display_widget.rb +66 -0
  151. data/app_generators/rtml/templates/rtml/components/rtml/widgets/element_builder_widget.rb +123 -0
  152. data/app_generators/rtml/templates/rtml/components/rtml/widgets/emv_support_widget.rb +365 -0
  153. data/app_generators/rtml/templates/rtml/components/rtml/widgets/form_submit_widget.rb +65 -0
  154. data/app_generators/rtml/templates/rtml/components/rtml/widgets/get_transaction_variables_widget.rb +33 -0
  155. data/app_generators/rtml/templates/rtml/components/rtml/widgets/get_variable_widget.rb +39 -0
  156. data/app_generators/rtml/templates/rtml/components/rtml/widgets/receipt_widget.rb +66 -0
  157. data/app_generators/rtml/templates/rtml/components/rtml/widgets/screen_builder_widget.rb +49 -0
  158. data/app_generators/rtml/templates/rtml/db/migrate/20090825132217_create_rtml_states.rb +15 -0
  159. data/app_generators/rtml/templates/rtml/db/migrate/20090825132401_create_rtml_terminals.rb +16 -0
  160. data/app_generators/rtml/templates/rtml/db/migrate/20090825132530_create_rtml_transactions.rb +24 -0
  161. data/app_generators/rtml/templates/rtml/db/migrate/20090825134118_create_rtml_cards.rb +23 -0
  162. data/app_generators/rtml/templates/rtml/db/migrate/20090825134622_create_rtml_emv_card_data.rb +20 -0
  163. data/app_generators/rtml/templates/rtml/db/migrate/20090825134629_create_rtml_mag_card_data.rb +17 -0
  164. data/app_generators/rtml/templates/rtml/db/migrate/20090825135838_create_rtml_card_parsers.rb +19 -0
  165. data/app_generators/rtml/templates/rtml/db/migrate/20090826103509_create_reference_codes.rb +14 -0
  166. data/app_generators/rtml/templates/rtml/db/migrate/20090915030044_add_batch_to_rtml_transactions.rb +10 -0
  167. data/app_generators/rtml/templates/rtml/db/migrate/20090915031155_add_additional_data_to_rtml_transactions.rb +10 -0
  168. data/app_generators/rtml/templates/rtml/db/migrate/20090915031156_add_hidden_data_to_rtml_transactions.rb +10 -0
  169. data/app_generators/rtml/templates/rtml/db/migrate/20091016133313_create_rtml_card_avs.rb +16 -0
  170. data/app_generators/rtml/templates/rtml/db/migrate/20091016135800_create_rtml_card_cvvs.rb +16 -0
  171. data/app_generators/rtml/templates/rtml/db/migrate/20091016135810_create_rtml_card_pins.rb +16 -0
  172. data/app_generators/rtml/templates/rtml/db/migrate/20091016135820_reverse_card_transaction_relationship.rb +11 -0
  173. data/app_generators/rtml/templates/rtml/db/migrate/20100127115105_convert_rtml_migrations_to_rails_migrations.rb +31 -0
  174. data/app_generators/rtml/templates/rtml/generators/rtml_controller/USAGE +25 -0
  175. data/app_generators/rtml/templates/rtml/generators/rtml_controller/rtml_controller_generator.rb +49 -0
  176. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/common_tml_helper.rb +20 -0
  177. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/controller.rb +3 -0
  178. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/css_color.css +37 -0
  179. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/css_mono.css +12 -0
  180. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/functional_test.rb +11 -0
  181. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/helper.rb +2 -0
  182. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/layout_color.rtml.erb +24 -0
  183. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/layout_mono.rtml.erb +3 -0
  184. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/tml_helper.rb +16 -0
  185. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/view.html.erb +15 -0
  186. data/app_generators/rtml/templates/rtml/generators/rtml_controller/templates/view.rtml.erb +2 -0
  187. data/app_generators/rtml/templates/rtml/generators/rtml_document/USAGE +8 -0
  188. data/app_generators/rtml/templates/rtml/generators/rtml_document/rtml_document_generator.rb +45 -0
  189. data/app_generators/rtml/templates/rtml/generators/rtml_document/templates/controller.rb +7 -0
  190. data/app_generators/rtml/templates/rtml/generators/rtml_document/templates/functional_test.rb +10 -0
  191. data/app_generators/rtml/templates/rtml/generators/rtml_document/templates/helper.rb +2 -0
  192. data/app_generators/rtml/templates/rtml/generators/rtml_document/templates/view.rtml.erb +11 -0
  193. data/app_generators/rtml/templates/rtml/generators/rtml_widget/USAGE +8 -0
  194. data/app_generators/rtml/templates/rtml/generators/rtml_widget/rtml_widget_generator.rb +66 -0
  195. data/app_generators/rtml/templates/rtml/generators/rtml_widget/templates/basic_widget.rb +57 -0
  196. data/app_generators/rtml/templates/rtml/generators/rtml_widget/templates/basic_widget_no_help.rb +27 -0
  197. data/app_generators/rtml/templates/rtml/init.rb +40 -0
  198. data/app_generators/rtml/templates/rtml/install.rb +18 -0
  199. data/app_generators/rtml/templates/rtml/lib/environment.rb +61 -0
  200. data/app_generators/rtml/templates/rtml/lib/extensions/action_controller/request.rb +9 -0
  201. data/app_generators/rtml/templates/rtml/lib/extensions/action_controller/routing/route_set.rb +34 -0
  202. data/app_generators/rtml/templates/rtml/lib/extensions/action_view/base.rb +74 -0
  203. data/app_generators/rtml/templates/rtml/lib/extensions/action_view/partial_template.rb +24 -0
  204. data/app_generators/rtml/templates/rtml/lib/extensions/active_record.rb +13 -0
  205. data/app_generators/rtml/templates/rtml/lib/extensions/active_support/dependencies.rb +25 -0
  206. data/app_generators/rtml/templates/rtml/lib/extensions/array.rb +15 -0
  207. data/app_generators/rtml/templates/rtml/lib/extensions/attr_boolean.rb +10 -0
  208. data/app_generators/rtml/templates/rtml/lib/extensions/hash.rb +28 -0
  209. data/app_generators/rtml/templates/rtml/lib/extensions/nil_class.rb +20 -0
  210. data/app_generators/rtml/templates/rtml/lib/extensions/rake.rb +19 -0
  211. data/app_generators/rtml/templates/rtml/lib/extensions/regexp.rb +16 -0
  212. data/app_generators/rtml/templates/rtml/lib/extensions/string.rb +37 -0
  213. data/app_generators/rtml/templates/rtml/lib/other_plugins.rb +23 -0
  214. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/MIT-LICENSE +20 -0
  215. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/README +36 -0
  216. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/Rakefile +44 -0
  217. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/init.rb +25 -0
  218. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/lib/action_controller/filters/before_render_filter.rb +30 -0
  219. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/lib/before_render.rb +43 -0
  220. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/lib/before_render_instance.rb +45 -0
  221. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/lib/filter_chain_has_many_types_of_filters.rb +87 -0
  222. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/lib/filter_has_before_render.rb +26 -0
  223. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/tasks/before_render_tasks.rake +25 -0
  224. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/test/before_render_test.rb +29 -0
  225. data/app_generators/rtml/templates/rtml/lib/other_plugins/before_render/test/test_helper.rb +24 -0
  226. data/app_generators/rtml/templates/rtml/lib/rtml.rb +77 -0
  227. data/app_generators/rtml/templates/rtml/lib/rtml/beryl/constants.rb +12 -0
  228. data/app_generators/rtml/templates/rtml/lib/rtml/beryl/version.rb +11 -0
  229. data/app_generators/rtml/templates/rtml/lib/rtml/common/renderable.rb +13 -0
  230. data/app_generators/rtml/templates/rtml/lib/rtml/core/include.rb +30 -0
  231. data/app_generators/rtml/templates/rtml/lib/rtml/core/layout.rb +59 -0
  232. data/app_generators/rtml/templates/rtml/lib/rtml/core/next.rb +188 -0
  233. data/app_generators/rtml/templates/rtml/lib/rtml/core/screen.rb +91 -0
  234. data/app_generators/rtml/templates/rtml/lib/rtml/core/screen/iterators.rb +63 -0
  235. data/app_generators/rtml/templates/rtml/lib/rtml/core/screen/next_screen_methods.rb +70 -0
  236. data/app_generators/rtml/templates/rtml/lib/rtml/core/screen/variable_methods.rb +73 -0
  237. data/app_generators/rtml/templates/rtml/lib/rtml/core/support/importer.rb +55 -0
  238. data/app_generators/rtml/templates/rtml/lib/rtml/core/tml_document.rb +318 -0
  239. data/app_generators/rtml/templates/rtml/lib/rtml/core/tml_document/screen_methods.rb +79 -0
  240. data/app_generators/rtml/templates/rtml/lib/rtml/core/tml_document/variable_methods.rb +83 -0
  241. data/app_generators/rtml/templates/rtml/lib/rtml/core/variable.rb +123 -0
  242. data/app_generators/rtml/templates/rtml/lib/rtml/debug/browser_emulator.rb +59 -0
  243. data/app_generators/rtml/templates/rtml/lib/rtml/debug/rtml_controller_test_case.rb +7 -0
  244. data/app_generators/rtml/templates/rtml/lib/rtml/debug/rtml_core_unit_test.rb +11 -0
  245. data/app_generators/rtml/templates/rtml/lib/rtml/debug/unit_test.rb +3 -0
  246. data/app_generators/rtml/templates/rtml/lib/rtml/delegation.rb +8 -0
  247. data/app_generators/rtml/templates/rtml/lib/rtml/doc.rb +12 -0
  248. data/app_generators/rtml/templates/rtml/lib/rtml/element.rb +75 -0
  249. data/app_generators/rtml/templates/rtml/lib/rtml/errors/widget_accessor_failure.rb +9 -0
  250. data/app_generators/rtml/templates/rtml/lib/rtml/events/event_handler.rb +79 -0
  251. data/app_generators/rtml/templates/rtml/lib/rtml/events/event_processor.rb +106 -0
  252. data/app_generators/rtml/templates/rtml/lib/rtml/events/processors.rb +10 -0
  253. data/app_generators/rtml/templates/rtml/lib/rtml/events/processors/defaults_processor.rb +18 -0
  254. data/app_generators/rtml/templates/rtml/lib/rtml/events/processors/key_processor.rb +21 -0
  255. data/app_generators/rtml/templates/rtml/lib/rtml/feature.rb +32 -0
  256. data/app_generators/rtml/templates/rtml/lib/rtml/feature_config.rb +195 -0
  257. data/app_generators/rtml/templates/rtml/lib/rtml/features.rb +18 -0
  258. data/app_generators/rtml/templates/rtml/lib/rtml/features/array_of_feature_instances.rb +17 -0
  259. data/app_generators/rtml/templates/rtml/lib/rtml/features/controller_class_methods.rb +30 -0
  260. data/app_generators/rtml/templates/rtml/lib/rtml/features/controller_instance_methods.rb +35 -0
  261. data/app_generators/rtml/templates/rtml/lib/rtml/helpers.rb +21 -0
  262. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/controller_helpers.rb +59 -0
  263. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/controller_helpers/menu_helpers.rb +193 -0
  264. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/core_helpers/action_view_wrapper.rb +23 -0
  265. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/core_helpers/event_helpers.rb +28 -0
  266. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/core_helpers/layout_helpers.rb +47 -0
  267. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/core_helpers/widget_support.rb +181 -0
  268. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/core_helpers/widget_support/class_methods.rb +28 -0
  269. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/core_helpers/yield_helpers.rb +33 -0
  270. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/proxy_helpers/feature_helpers.rb +17 -0
  271. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/render_helper.rb +71 -0
  272. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/terminal_helpers.rb +21 -0
  273. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/test_helpers.rb +6 -0
  274. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/test_helpers/tml_validation_assertions.rb +10 -0
  275. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/test_helpers/variable_assertions.rb +27 -0
  276. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/view_helpers/form_helpers.rb +70 -0
  277. data/app_generators/rtml/templates/rtml/lib/rtml/helpers/view_helpers/rtml_form_builder.rb +174 -0
  278. data/app_generators/rtml/templates/rtml/lib/rtml/oe/btmlpa_constants.rb +48 -0
  279. data/app_generators/rtml/templates/rtml/lib/rtml/proxying/method_missing_methods.rb +14 -0
  280. data/app_generators/rtml/templates/rtml/lib/rtml/proxying/rtml_interface.rb +33 -0
  281. data/app_generators/rtml/templates/rtml/lib/rtml/proxying/sandbox.rb +18 -0
  282. data/app_generators/rtml/templates/rtml/lib/rtml/text_utils.rb +51 -0
  283. data/app_generators/rtml/templates/rtml/lib/rtml/tml_param_parser.rb +95 -0
  284. data/app_generators/rtml/templates/rtml/lib/rtml/validation/dom_rule_parser.rb +61 -0
  285. data/app_generators/rtml/templates/rtml/lib/rtml/validation/dom_tag.rb +52 -0
  286. data/app_generators/rtml/templates/rtml/lib/rtml/validation/predefined_variable_rule_parser.rb +97 -0
  287. data/app_generators/rtml/templates/rtml/lib/rtml/validation/tml_validator.rb +16 -0
  288. data/app_generators/rtml/templates/rtml/lib/rtml/version.rb +11 -0
  289. data/app_generators/rtml/templates/rtml/lib/rtml/widgets/property.rb +11 -0
  290. data/app_generators/rtml/templates/rtml/lib/rtml/widgets/property_accessors.rb +59 -0
  291. data/app_generators/rtml/templates/rtml/lib/rtml/widgets/widget.rb +251 -0
  292. data/app_generators/rtml/templates/rtml/lib/rtml/widgets/widget_class_methods.rb +213 -0
  293. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/dot.gif +0 -0
  294. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_can.gif +0 -0
  295. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_cand.gif +0 -0
  296. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_en.gif +0 -0
  297. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_end.gif +0 -0
  298. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_i.gif +0 -0
  299. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_icd.gif +0 -0
  300. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_icl.gif +0 -0
  301. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_icr.gif +0 -0
  302. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_ics.gif +0 -0
  303. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_icsw.gif +0 -0
  304. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_icv.gif +0 -0
  305. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_int.gif +0 -0
  306. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_int2.gif +0 -0
  307. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_men.gif +0 -0
  308. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_mend.gif +0 -0
  309. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_next.gif +0 -0
  310. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_no.gif +0 -0
  311. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_nod.gif +0 -0
  312. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_ok.gif +0 -0
  313. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_okd.gif +0 -0
  314. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_pic1.gif +0 -0
  315. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_pic2.gif +0 -0
  316. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_pic3.gif +0 -0
  317. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_pic4.gif +0 -0
  318. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_top.gif +0 -0
  319. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_txn.gif +0 -0
  320. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_yes.gif +0 -0
  321. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/btmlpa/nbg_yesd.gif +0 -0
  322. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/btmlpa.gif +0 -0
  323. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/can_dn.gif +0 -0
  324. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/can_up.gif +0 -0
  325. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/conf.gif +0 -0
  326. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/iccemv.gif +0 -0
  327. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/images.lib +0 -0
  328. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/magcard.gif +0 -0
  329. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/no_dn.gif +0 -0
  330. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/no_up.gif +0 -0
  331. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/ok_dn.gif +0 -0
  332. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/ok_up.gif +0 -0
  333. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/top.gif +0 -0
  334. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/yes_dn.gif +0 -0
  335. data/app_generators/rtml/templates/rtml/public/images/rtml/oe/examples/yes_up.gif +0 -0
  336. data/app_generators/rtml/templates/rtml/public/stylesheets/rtml/beryl_color.css +37 -0
  337. data/app_generators/rtml/templates/rtml/public/stylesheets/rtml/beryl_mono.css +17 -0
  338. data/app_generators/rtml/templates/rtml/public/stylesheets/rtml/charts.css +0 -0
  339. data/app_generators/rtml/templates/rtml/public/stylesheets/rtml/oe/btmlpa/i5100.css +12 -0
  340. data/app_generators/rtml/templates/rtml/public/stylesheets/rtml/oe/btmlpa/i8550.css +37 -0
  341. data/app_generators/rtml/templates/rtml/public/stylesheets/rtml/oe/btmlpa/receipt.css +4 -0
  342. data/app_generators/rtml/templates/rtml/public/stylesheets/rtml/oe/examples/i5100.css +12 -0
  343. data/app_generators/rtml/templates/rtml/public/stylesheets/rtml/oe/examples/i8550.css +37 -0
  344. data/app_generators/rtml/templates/rtml/reporting/110409 +227 -0
  345. data/app_generators/rtml/templates/rtml/reporting/linecount.rb +42 -0
  346. data/app_generators/rtml/templates/rtml/rules/predefined_tml_variables.rb +63 -0
  347. data/app_generators/rtml/templates/rtml/rules/tml_document_structure.rb +84 -0
  348. data/app_generators/rtml/templates/rtml/rules/varns/audio.rb +30 -0
  349. data/app_generators/rtml/templates/rtml/rules/varns/card.rb +17 -0
  350. data/app_generators/rtml/templates/rtml/rules/varns/card/emv.rb +31 -0
  351. data/app_generators/rtml/templates/rtml/rules/varns/card/mag.rb +8 -0
  352. data/app_generators/rtml/templates/rtml/rules/varns/card/parser.rb +7 -0
  353. data/app_generators/rtml/templates/rtml/rules/varns/card/pin.rb +6 -0
  354. data/app_generators/rtml/templates/rtml/rules/varns/cfgm.rb +15 -0
  355. data/app_generators/rtml/templates/rtml/rules/varns/com.rb +9 -0
  356. data/app_generators/rtml/templates/rtml/rules/varns/err.rb +14 -0
  357. data/app_generators/rtml/templates/rtml/rules/varns/gma/event.rb +13 -0
  358. data/app_generators/rtml/templates/rtml/rules/varns/gprs.rb +8 -0
  359. data/app_generators/rtml/templates/rtml/rules/varns/imager.rb +8 -0
  360. data/app_generators/rtml/templates/rtml/rules/varns/ip.rb +15 -0
  361. data/app_generators/rtml/templates/rtml/rules/varns/oebr.rb +42 -0
  362. data/app_generators/rtml/templates/rtml/rules/varns/oebr/3rdparty.rb +7 -0
  363. data/app_generators/rtml/templates/rtml/rules/varns/oebr/backlight.rb +4 -0
  364. data/app_generators/rtml/templates/rtml/rules/varns/oebr/cache.rb +1 -0
  365. data/app_generators/rtml/templates/rtml/rules/varns/oebr/connect.rb +5 -0
  366. data/app_generators/rtml/templates/rtml/rules/varns/oebr/connection.rb +5 -0
  367. data/app_generators/rtml/templates/rtml/rules/varns/oebr/offline.rb +5 -0
  368. data/app_generators/rtml/templates/rtml/rules/varns/oegw.rb +12 -0
  369. data/app_generators/rtml/templates/rtml/rules/varns/payment.rb +21 -0
  370. data/app_generators/rtml/templates/rtml/rules/varns/ppp.rb +11 -0
  371. data/app_generators/rtml/templates/rtml/rules/varns/terminal.rb +29 -0
  372. data/app_generators/rtml/templates/rtml/tasks/rtml_tasks.rake +78 -0
  373. data/app_generators/rtml/templates/rtml/template.rb +64 -0
  374. data/app_generators/rtml/templates/rtml/test/core/element_test.rb +17 -0
  375. data/app_generators/rtml/templates/rtml/test/core/screen_test.rb +91 -0
  376. data/app_generators/rtml/templates/rtml/test/core/tml_document_test.rb +53 -0
  377. data/app_generators/rtml/templates/rtml/test/functional/beryl_controller_test.rb +13 -0
  378. data/app_generators/rtml/templates/rtml/test/functional/btmlpa_controller_test.rb +13 -0
  379. data/app_generators/rtml/templates/rtml/test/functional/magcard_demo_controller_test.rb +20 -0
  380. data/app_generators/rtml/templates/rtml/test/functional/rtml_app_controller_test.rb +9 -0
  381. data/app_generators/rtml/templates/rtml/test/functional/rtml_routing_test.rb +19 -0
  382. data/app_generators/rtml/templates/rtml/test/functional/tml_controller_params_test.rb +20 -0
  383. data/app_generators/rtml/templates/rtml/test/rtml_test_helper.rb +44 -0
  384. data/app_generators/rtml/templates/rtml/test/validation/predefined_variable_rule_parser_test.rb +11 -0
  385. data/app_generators/rtml/templates/rtml/uninstall.rb +1 -0
  386. data/app_generators/rtml/templates/rtml/update.rb +57 -0
  387. data/bin/rtml +36 -0
  388. data/lib/rtml.rb +4 -0
  389. data/script/console +10 -0
  390. data/script/destroy +14 -0
  391. data/script/generate +14 -0
  392. data/tasks/reglob.rake +28 -0
  393. data/test/test_generator_helper.rb +29 -0
  394. data/test/test_helper.rb +3 -0
  395. data/test/test_rtml.rb +11 -0
  396. data/test/test_rtml_generator.rb +43 -0
  397. metadata +516 -0
@@ -0,0 +1,106 @@
1
+ <table width='100%'>
2
+ <%spacer = "<tr><td class='small'><br/></td></tr>"%>
3
+ <%=spacer%>
4
+ <tr>
5
+ <td align='center' class='large bold'>
6
+ <%=receipt_text(controller.feature_config.common.receipt_header)%>
7
+ </td>
8
+ </tr>
9
+ <%=spacer%>
10
+ <tr>
11
+ <td align='left'>
12
+ <%=@transaction.created_at.strftime("%m/%d/%y %H:%M:%S")%>
13
+ </td>
14
+ </tr>
15
+ <tr><td align='left'>TID: <%=tid_for_transaction(@transaction)%></td></tr>
16
+ <%if @transaction.card%>
17
+ <tr><td align='left'>Entry Method: <%=@transaction.card.input_type.to_s.titleize%></td></tr>
18
+ <%end%>
19
+ <%unless @transaction.batch.blank?%>
20
+ <tr><td align='left'>Batch #: <%=@transaction.batch%></td></tr>
21
+ <%end%>
22
+ <%unless @transaction.additional_data.empty?
23
+ @transaction.additional_data.each do |label, value|%>
24
+ <tr><td align='left'><%=label.to_s.titleize%>:<%=value%></td></tr>
25
+ <%end
26
+ end%>
27
+ <tr><td align='left'>REF #:<%=@transaction.reference_code.to_s%></td></tr>
28
+ <%=spacer%>
29
+ <tr><td class='bold'>Auth Code: <%=@transaction.auth_code%></td></tr>
30
+ <tr><td class='bold'><getvar name='card.pan' format='n#*n4' /></td></tr>
31
+ <%((@transaction.payment_order.empty?) ? @transaction.payment_data.keys : @transaction.payment_order).each do |key|%>
32
+ <%value = (@transaction.payment_data.key? key) ? @transaction.payment_data[key] : nil%>
33
+ <%unless [:cashback, :total].include? key%>
34
+ <%if key.nil? or key.blank? or key == :blank or value == :blank%>
35
+ <%=spacer%>
36
+ <%elsif @transaction.payment_data.key? key%>
37
+ <%if value.kind_of? String%>
38
+ <tr>
39
+ <td align='left' class='bold'><%=key.to_s.titleize%>: <%=value%></td>
40
+ </tr>
41
+ <%elsif value.nil?%>
42
+ <tr>
43
+ <td align='left' class='bold'><%=key.to_s.titleize%></td>
44
+ </tr>
45
+ <%else%>
46
+ <tr>
47
+ <td align='left' class='bold'><%=key.to_s.titleize%>: <%=integer_as_currency value%></td>
48
+ </tr>
49
+ <%end%>
50
+ <%end%>
51
+ <%end%>
52
+ <%end%>
53
+ <%if @transaction.amount_other and @transaction.amount_other > 0%>
54
+ <%if @transaction.payment_data.key? :cashback and @transaction.payment_order.include? :cashback%>
55
+ <tr>
56
+ <td align='left' class='bold'>
57
+ Cashback: <%=integer_as_currency(@transaction.payment_data[:cashback] || @transaction.amount_other)%>
58
+ </td>
59
+ </tr>
60
+ <%end%>
61
+ <%if @transaction.payment_data.key? :total and @transaction.payment_order.include? :total%>
62
+ <tr>
63
+ <td align='left' class='bold'>
64
+ Total: <%=integer_as_currency(@transaction.payment_data[:total]||(@transaction.payment_data[:amount]||@transaction.amount)+@transaction.amount_other)%>
65
+ </td>
66
+ </tr>
67
+ <%end%>
68
+ <%end%>
69
+ <%=spacer%>
70
+ <tr>
71
+ <td align='center' class='small'>
72
+ <%=@transaction.message%>
73
+ </td>
74
+ </tr>
75
+ <%=spacer%>
76
+ <tr>
77
+ <td align='left'>
78
+ <%if @duplicate || @transaction.hidden_data[:duplicate]%>
79
+ (DUPLICATE TRANSACTION)
80
+ <%else%>
81
+ <getvar name='signature_line' />
82
+ <%end%>
83
+ </td>
84
+ </tr>
85
+ <%=spacer%>
86
+ <tr>
87
+ <td align='center'>
88
+ <%=receipt_text(controller.feature_config.common.receipt_agreement)%>
89
+ </td>
90
+ </tr>
91
+ <%=spacer%>
92
+ <tr>
93
+ <td align='center'>
94
+ <%=receipt_text(controller.feature_config.common.receipt_footer)%>
95
+ </td>
96
+ </tr>
97
+ <%=spacer%>
98
+ <tr>
99
+ <td align='center'>
100
+ <getvar name='owner' /> COPY
101
+ </td>
102
+ </tr>
103
+ </table>
104
+ <br/><br/><br/>
105
+ <br/><br/><br/>
106
+ <br/><br/><br/>
@@ -0,0 +1,8 @@
1
+ <table width='100%' height='100%'>
2
+ <tr><td align='center'><h1><%=controller.controller_name.titleize%></h1></td></tr>
3
+ <tr><td align='center'>
4
+ Beryl v<%=Rtml::Beryl::VERSION::STRING%><br/>
5
+ RubyTML v<%=Rtml::VERSION::STRING%><br/>
6
+ Ruby v<%=VERSION%> / Rails v<%=Rails::VERSION::STRING%>
7
+ </td></tr>
8
+ </table>
@@ -0,0 +1,4 @@
1
+ <table width='100%'>
2
+ <tr><td align='left'>1. </td><td align='left'><%=link_to 'About', :anchor => :about%></td></tr>
3
+ <tr><td align='left'>2. </td><td align='left'><%=link_to 'Configuration', embedded_app%></td></tr>
4
+ </table>
@@ -0,0 +1,10 @@
1
+ <table width='100%' height='100%'>
2
+ <tr>
3
+ <td valign='middle' align='center'>
4
+ <img src='/images/1bpp/constr.bmp' alt='' />
5
+ </td>
6
+ </tr>
7
+ <tr>
8
+ <td align='center'>Under Construction</td>
9
+ </tr>
10
+ </table>
@@ -0,0 +1,13 @@
1
+ <table width='100%' height='100%'>
2
+ <tr>
3
+ <td valign='middle' align='center'>
4
+ <h1><%=controller.controller_name.titleize%></h1>
5
+ </td>
6
+ </tr>
7
+ <tr>
8
+ <td align='center'><br/></td>
9
+ </tr>
10
+ <tr>
11
+ <td align='center'>Please Swipe Card<br/>or Press MENU</td>
12
+ </tr>
13
+ </table>
@@ -0,0 +1,12 @@
1
+ <%content_for :title do%>Main Menu<%end%>
2
+
3
+ <table width='100%'>
4
+ <tr><td align='left'>1. </td><td align='left'><%=link_to 'Credit Card', :anchor => :menu_credit%></td></tr>
5
+ <tr><td align='left'>2. </td><td align='left'><%=link_to 'Debit Card', :anchor => :menu_debit%></td></tr>
6
+ <!--
7
+ <tr><td><%=link_to '3. EBT', :anchor => :construction%></td></tr>
8
+ <tr><td><%=link_to '4. Reprint', :anchor => :construction%></td></tr>
9
+ <tr><td><%=link_to '5. Reports', :anchor => :construction%></td></tr>
10
+ <tr><td><%=link_to '6. Settle', :anchor => :construction%></td></tr>
11
+ -->
12
+ </table>
@@ -0,0 +1,8 @@
1
+ <%content_for :title do%>CREDIT MENU<%end%>
2
+
3
+ <%=controller.rtml_interface.feature_menu%>
4
+ <!--
5
+ <%["Auth Only", "Void", "Trans Adj", "Tip Adj"].each do |x|%>
6
+ <%=link_to x, :anchor => :construction%><br/>
7
+ <%end%>
8
+ -->
@@ -0,0 +1,3 @@
1
+ <%content_for :title do%>DEBIT MENU<%end%>
2
+
3
+ <%=controller.rtml_interface.feature_menu(:only => [ :sale, :return ])%>
@@ -0,0 +1,24 @@
1
+ <table height="240" width="240" class="menu">
2
+ <tr><td align="center" valign="middle">
3
+ <table height="240" width="240">
4
+ <tr><td align="center" valign="middle">
5
+ <table width="100%" height="240">
6
+ <tr><td align="center" valign="middle">
7
+ <table class="c_small" height="77">
8
+ <tr><td align="left" valign="middle">
9
+ RTML Application (layout_graphic.rtml.erb)
10
+ </td></tr>
11
+ </table>
12
+ </td></tr>
13
+ <tr><td align="center">
14
+ <table width="240" border="0" height="163">
15
+ <tr><td align='center' valign='middle' class='c_bold_large'>
16
+ <%=yield%>
17
+ </td></tr>
18
+ </table>
19
+ </td></tr>
20
+ </table>
21
+ </td></tr>
22
+ </table>
23
+ </td></tr>
24
+ </table>
@@ -0,0 +1,8 @@
1
+ <table height='100%' width='100%'>
2
+ <tr><td align='center'>
3
+ <h1><%=(yield :title) || (title rescue nil) || "<getvar name='transaction_type' />"%></h1>
4
+ </td></tr>
5
+ <tr><td align='center' valign='middle'>
6
+ <%=yield%>
7
+ </td></tr>
8
+ </table>
@@ -0,0 +1,24 @@
1
+ <table height="240" width="240" class="menu">
2
+ <tr><td align="center" valign="middle">
3
+ <table height="240" width="240">
4
+ <tr><td align="center" valign="middle">
5
+ <table width="100%" height="240">
6
+ <tr><td align="center" valign="middle">
7
+ <table class="c_small" height="77">
8
+ <tr><td align="left" valign="middle">
9
+ RTML Application (layout_graphic.rtml.erb)
10
+ </td></tr>
11
+ </table>
12
+ </td></tr>
13
+ <tr><td align="center">
14
+ <table width="240" border="0" height="163">
15
+ <tr><td align='center' valign='middle' class='c_bold_large'>
16
+ <%=yield%>
17
+ </td></tr>
18
+ </table>
19
+ </td></tr>
20
+ </table>
21
+ </td></tr>
22
+ </table>
23
+ </td></tr>
24
+ </table>
@@ -0,0 +1,3 @@
1
+ <table height='100%' width='100%'><tr><td align='center' valign='middle'>
2
+ <%=yield%>
3
+ </td></tr></table>
@@ -0,0 +1,3 @@
1
+ <table height='100%' width='100%'><tr><td align='center' valign='middle'>
2
+ <%=yield%>
3
+ </td></tr></table>
@@ -0,0 +1,17 @@
1
+ <table height="240" width="240" class="menu">
2
+ <tr><td align="center" valign="middle">
3
+ <table height="240" width="240">
4
+ <tr><td align="center" valign="middle">
5
+ <table width="100%" height="240">
6
+ <tr><td align="center">
7
+ <table width="240" border="0" height="163">
8
+ <tr><td align='center' valign='middle' class='c_bold_large'>
9
+ <%=yield%>
10
+ </td></tr>
11
+ </table>
12
+ </td></tr>
13
+ </table>
14
+ </td></tr>
15
+ </table>
16
+ </td></tr>
17
+ </table>
@@ -0,0 +1,11 @@
1
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
+ <html>
3
+ <head>
4
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
5
+ <title>RTML Charts for <%=params[:controller].titleize%>#<%=params[:for].titleize%></title>
6
+ <%=stylesheet_link_tag 'rtml/charts'%>
7
+ </head>
8
+ <body>
9
+ <%=yield%>
10
+ </body>
11
+ </html>
@@ -0,0 +1,15 @@
1
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
+ <html>
3
+ <head>
4
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
5
+ <title><%=params[:controller]%> - <%=params[:action]%></title>
6
+ <%=render :partial => 'rtml/rtml_app/default_header'%>
7
+ </head>
8
+ <body>
9
+ <%if ENV['RAILS_ENV'] == 'production'%>
10
+ <%=render :partial => "rtml/rtml_app/default_production"%>
11
+ <%else # this could include test %>
12
+ <%=render :partial => "rtml/rtml_app/default_development"%>
13
+ <%end%>
14
+ </body>
15
+ </html>
@@ -0,0 +1,5 @@
1
+ Thank you, <%=params[:card][:cardholder_name]%>.
2
+ Your authorization code is <%=@auth_code%>.
3
+ <br/><br/>
4
+ This concludes the RubyTML Magnetic Card demo.<br/>
5
+ Press ENTER to start over.
@@ -0,0 +1,15 @@
1
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
+ <html>
3
+ <head>
4
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
5
+ <title><%=params[:controller]%> - <%=params[:action]%></title>
6
+ <%=render :partial => 'rtml/rtml_app/default_header'%>
7
+ </head>
8
+ <body>
9
+ <%if ENV['RAILS_ENV'] == 'production'%>
10
+ <%=render :partial => "rtml/rtml_app/default_production"%>
11
+ <%else # this could include test %>
12
+ <%=render :partial => "rtml/rtml_app/default_development"%>
13
+ <%end%>
14
+ </body>
15
+ </html>
@@ -0,0 +1,2 @@
1
+ <h1><%=error%></h1>
2
+ <p><getvar name="err.baddata_reason" /></p>
@@ -0,0 +1,5 @@
1
+ <%form_for :payment do |f|%>
2
+ Enter Amount: <%=f.number_field :amount, :format => '^$*0.00'%>
3
+ <br/><br/>
4
+ Press ENTER to continue.
5
+ <%end%>
@@ -0,0 +1,4 @@
1
+ <p>
2
+ This is an example of a simple magnetic card application written in RubyTML.<br/><br/>
3
+ Please swipe card to begin.
4
+ </p>
@@ -0,0 +1,2 @@
1
+ <%=h @message%><br/><br/>
2
+ <%=link_to 'OK', :action => 'index', :anchor => @destination%>
@@ -0,0 +1,760 @@
1
+ <?xml version="1.0" encoding="ISO-8859-1"?>
2
+
3
+ <tml xmlns="http://www.ingenico.co.uk/tml">
4
+
5
+ <head>
6
+ <defaults cancel="<%=@index%>"/>
7
+ <error uri="#error_scr"/>
8
+ </head>
9
+
10
+ <!-- use the same stylesheet as tmlapp.tml -->
11
+
12
+ <!-- String containing PIN verification method -->
13
+ <vardcl name="txt_cvm" perms="rw---"/>
14
+
15
+ <!-- list of EMV applications that will be displayed for manual selection -->
16
+ <vardcl name="btmlpa.emv.selection_list" perms="rw---"/>
17
+
18
+ <!-- used to select a particular item from the list -->
19
+ <vardcl name="btmlpa.emv.selected_item" perms="rw---"/>
20
+
21
+ <vardcl name="app_item"/>
22
+ <vardcl name="app_sel_mode"/>
23
+ <vardcl name="app_list"/>
24
+ <vardcl name="aid_list"/>
25
+ <vardcl name="index" type="integer"/>
26
+ <vardcl name="count" type="integer"/>
27
+ <vardcl name="app"/>
28
+ <vardcl name="aid"/>
29
+ <vardcl name="app_status"/>
30
+ <vardcl name="sep"/>
31
+
32
+
33
+ <!--===========================================================================
34
+ If card requires cardholder confirmation, display the list
35
+ else, check if there are several applications or only a single one
36
+ ============================================================================-->
37
+ <screen id="check_apps">
38
+ <setvar name="count" lo="tmlvar:card.emv.app_status_list" op="number"/>
39
+ <next uri="<%=@assert%>">
40
+ <variant uri="#man_app_sel" lo="tmlvar:card.emv.selected_app" op="equal" ro="manual"/>
41
+ <variant uri="#chk_multi" lo="tmlvar:card.emv.selected_app" op="equal" ro=""/>
42
+ </next>
43
+ </screen>
44
+
45
+ <!--===========================================================================
46
+ Check if there are several applications or only a single one.
47
+ If there are several applications, display the list fo manual selection , even if not required (best practice)
48
+ If there is only a single one, try to select it automatically
49
+ ============================================================================-->
50
+ <screen id="chk_multi">
51
+ <next uri="#man_app_sel">
52
+ <variant uri="#auto_app_sel" lo="tmlvar:count" op="equal" ro="1"/>
53
+ </next>
54
+ </screen>
55
+
56
+ <!--===========================================================================
57
+ Enable automatic application selection
58
+ ============================================================================-->
59
+ <screen id="auto_app_sel" next="#final_select" timeout="1">
60
+ <!-- save the label of the application that will be used for the transaction -->
61
+ <setvar name="btmlpa.emv.txn_app" lo="tmlvar:card.emv.app_list"/>
62
+
63
+ <setvar name="app_sel_mode" lo="auto"/>
64
+ <setvar name="card.emv.selected_app" lo=""/>
65
+
66
+ <display>
67
+ <table class="message"><tr><td>
68
+ <span>
69
+
70
+ Auto selection
71
+
72
+ </span>
73
+ </td></tr></table>
74
+ </display>
75
+ </screen>
76
+
77
+ <!--===========================================================================
78
+ Enable cardholder manual application selection
79
+ ============================================================================-->
80
+ <screen id="man_app_sel" timeout="1">
81
+ <setvar name="app_sel_mode" lo="manual"/>
82
+ <next uri="<%=@assert%>">
83
+ <variant uri="#prepare_list" lo="card.emv.app_list" op="not_equal" ro=""/>
84
+ </next>
85
+ <display>
86
+ <table class="message"><tr><td>
87
+ <span>
88
+
89
+ Manual selection
90
+
91
+ </span>
92
+ </td></tr></table>
93
+ </display>
94
+ </screen>
95
+
96
+ <!--=========================================================
97
+ Building an application list for user selection
98
+ ===========================================================-->
99
+
100
+ <!-- Enable cardholder manual application selection -->
101
+ <screen id="prepare_list">
102
+ <setvar name="sep" lo=""/>
103
+ <setvar name="app_list" lo=""/>
104
+ <setvar name="aid_list" lo=""/>
105
+ <setvar name="btmlpa.emv.selection_list" lo=""/>
106
+ <setvar name="index" lo="0"/>
107
+ <setvar name="count" lo="tmlvar:card.emv.app_status_list" op="number"/>
108
+ <next uri="<%=@assert%>">
109
+ <variant uri="#check_status" lo="0" op="less" ro="tmlvar:count"/>
110
+ </next>
111
+ </screen>
112
+
113
+ <!--
114
+ Copy the active applications into the list to be displayed. Inactive applications
115
+ are just skipped.
116
+ -->
117
+ <screen id="check_status" next="#copy_app1">
118
+ <setvar name="app_status" lo="tmlvar:card.emv.app_status_list" op="item" ro="tmlvar:index"/>
119
+ <next uri="<%=@assert%>">
120
+ <variant uri="#copy_app1" lo="tmlvar:app_status" op="equal" ro="active"/>
121
+ <variant uri="#loop_app" lo="tmlvar:app_status" op="equal" ro="inactive"/>
122
+ </next>
123
+ </screen>
124
+
125
+ <!--
126
+ Copy an application into the list of application to be displayed
127
+ -->
128
+ <screen id="copy_app1" next="#copy_app2">
129
+ <setvar name="app" lo="tmlvar:card.emv.app_list" op="item" ro="tmlvar:index"/>
130
+ <strtemplate name="app_item" format="%1%2: %3">
131
+ <getvar name="sep" />
132
+ <getvar name="index" format="^00"/>
133
+ <getvar name="app" />
134
+ </strtemplate>
135
+ </screen>
136
+
137
+ <screen id="copy_app2" next="#loop_app">
138
+ <setvar name="btmlpa.emv.selection_list" lo="tmlvar:btmlpa.emv.selection_list" op="plus" ro="tmlvar:app_item" />
139
+ <setvar name="app" lo="tmlvar:sep" op="plus" ro="tmlvar:app" />
140
+ <setvar name="app_list" lo="tmlvar:app_list" op="plus" ro="tmlvar:app" />
141
+ <setvar name="aid" lo="tmlvar:card.emv.aid_list" op="item" ro="tmlvar:index"/>
142
+ <setvar name="aid" lo="tmlvar:sep" op="plus" ro="tmlvar:aid"/>
143
+ <setvar name="aid_list" lo="tmlvar:aid_list" op="plus" ro="tmlvar:aid"/>
144
+ <setvar name="sep" lo=";"/>
145
+ </screen>
146
+
147
+ <!--
148
+ Move forward the index for application status check process
149
+ -->
150
+ <screen id="loop_app">
151
+ <setvar name="index" lo="tmlvar:index" op="plus" ro="1"/>
152
+ <next uri="#check_status">
153
+ <variant uri="#select_first" lo="tmlvar:index" op="equal" ro="tmlvar:count"/>
154
+ </next>
155
+ </screen>
156
+
157
+ <!--
158
+ Check whether the list of available applications is empty or not
159
+ -->
160
+ <screen id="select_first">
161
+ <setvar name="count" lo="tmlvar:app_list" op="number"/>
162
+ <next uri="#rej_no_app">
163
+ <variant uri="#show_app_lst" lo="0" op="less" ro="tmlvar:count"/>
164
+ </next>
165
+ </screen>
166
+
167
+ <!--
168
+ If none of the application sare active, abort the transaction
169
+ -->
170
+ <screen id="rej_no_app" next="<%=@abort%>">
171
+ <display>
172
+ <table border="2" class="warning"><tr><td>
173
+ <span>
174
+
175
+ All applications are inactive.<br/>
176
+ Transaction will be rejected.
177
+
178
+ </span>
179
+ </td></tr></table>
180
+ </display>
181
+ </screen>
182
+
183
+ <!--===========================================================================
184
+ Show the list of available applications for cardholder selection
185
+ ============================================================================-->
186
+ <!-- input a value from the list -->
187
+ <screen id="show_app_lst" cancel="<%=@abort%>">
188
+ <setvar name="btmlpa.emv.selected_item" lo="tmlvar:btmlpa.emv.selection_list" op="item" ro="0"/>
189
+ <next uri="<%=@assert%>">
190
+ <variant uri="#select_aid1" lo="tmlvar:btmlpa.emv.selected_item" op="not_equal" ro=""/>
191
+ </next>
192
+ <display>
193
+ <form>
194
+ <div class="title">
195
+ <span class="title">
196
+ Select ICC Application:
197
+ </span>
198
+ </div>
199
+ <div class="menu">
200
+ <input type="list" name="btmlpa.emv.selected_item" value="tmlvar:btmlpa.emv.selection_list" rows="4" width="100%" multiple="no" />
201
+ </div>
202
+ </form>
203
+ </display>
204
+ </screen>
205
+
206
+ <!--===========================================================================
207
+ Based on cardholder selection, fill the card.emv.selected_aid
208
+ ============================================================================-->
209
+
210
+ <!-- get the aid value from the list value -->
211
+ <screen id="select_aid1" cancel="<%=@index%>" timeout="1">
212
+
213
+ <!-- formatting 'btmlpa.emv.selected_item' to contain only the first two digits, but not the rest of the list item.
214
+ for instance, if you have selected "00: VISA CREDIT" from the list on the
215
+ 'show_app_lst' screen, after format operation,
216
+ 'btmlpa.emv.selected_item' will contain only "00" -->
217
+ <setvar name="btmlpa.emv.selected_item" lo="tmlvar:btmlpa.emv.selected_item" op="format" format="nn"/>
218
+ <!-- 'btmlpa.emv.selected_item' contains only digits, so it can be cast into integer -->
219
+ <setvar name="index" lo="tmlvar:btmlpa.emv.selected_item"/>
220
+
221
+ <!-- set up variables for the card parser -->
222
+ <setvar name="card.emv.selected_app" lo=""/>
223
+ <setvar name="card.emv.selected_aid" lo="tmlvar:aid_list" op="item" ro="tmlvar:index"/>
224
+
225
+ <!-- set variables that will be used in other modules of the BTMLPA
226
+ such as receipt printing -->
227
+ <setvar name="btmlpa.emv.txn_aid" lo="tmlvar:card.emv.selected_aid" />
228
+ <setvar name="btmlpa.emv.txn_app" lo="tmlvar:app_list" op="item" ro="tmlvar:index" />
229
+
230
+ <next uri="<%=@assert%>">
231
+ <variant uri="#final_select" lo="tmlvar:card.emv.selected_aid" op="not_equal" ro=""/>
232
+ </next>
233
+ <display>
234
+ <table class="message"><tr><td>
235
+ <span>
236
+
237
+ <getvar name="btmlpa.emv.txn_app"/><br/>
238
+ <getvar name="btmlpa.emv.txn_aid"/><br/>
239
+
240
+ </span>
241
+ </td></tr></table>
242
+ </display>
243
+ </screen>
244
+
245
+
246
+ <!--===========================================================================
247
+ Final application selection and initialization after application
248
+ auto/manual choice
249
+ ============================================================================-->
250
+
251
+ <screen id="final_select" next="#chk_resel">
252
+ <tform>
253
+ <baddata max="1" next="<%=@abort%>">
254
+ <table border="2" class="warning"><tr><td>
255
+ <span>
256
+
257
+ <getvar name="err.baddata_reason"/> <br/>
258
+ err.high = <getvar name="err.code.high"/> <br/>
259
+ err.low = <getvar name="err.code.low"/><br/>
260
+ card.emv.apdu_list: <getvar name="card.emv.apdu_list"/>
261
+
262
+ </span>
263
+ </td></tr></table>
264
+ </baddata>
265
+ <card parser="icc_emv" parser_params="final_select"/>
266
+ </tform>
267
+ </screen>
268
+
269
+ <!--===========================================================================
270
+ Ensure the final selection was ok. If not, application list shall be
271
+ re-displayed
272
+ If application selection was OK, go to PIN check
273
+ If application selection failed, try to select another one
274
+ ============================================================================-->
275
+ <screen id="chk_resel">
276
+ <next uri="#icc_get_cvm">
277
+ <!-- application selection failed -->
278
+ <variant uri="#dsp_selfld" lo="tmlvar:err.code.low" op="equal" ro="-32817"/>
279
+ <variant uri="#dsp_selfld" lo="tmlvar:err.code.low" op="equal" ro="-4380"/>
280
+ </next>
281
+ </screen>
282
+
283
+ <!--####################################################################-->
284
+ <!-- these screens are not used by the BTMLPA. They can be used to safely cancel an initiated transaction.
285
+ This can be used, for example, to read the customer name from an EMV card after the application selection, but to correctly
286
+ stop the transaction from going further
287
+ this cancellation should not be required for normal EMV transaction-->
288
+
289
+ <screen id="cncltran" next="#dspcncl">
290
+ <tform>
291
+ <baddata max="1" next="<%=@abort%>">
292
+ <table border="2" class="warning"><tr><td>
293
+ <span>
294
+
295
+ <getvar name="err.baddata_reason"/>
296
+
297
+ </span>
298
+ </td></tr></table>
299
+ </baddata>
300
+ <card parser="icc_emv" parser_params="cancel"/>
301
+ </tform>
302
+ </screen>
303
+
304
+ <screen id="dspcncl" next="<%=@abort%>">
305
+ <display>
306
+ The transaction has been canceled <br/>
307
+ Cardholder name = <getvar name="card.cardholder_name"/><br/>
308
+ AAC = <getvar name="card.emv.aac"/>
309
+ </display>
310
+ </screen>
311
+ <!--####################################################################-->
312
+
313
+ <!--===========================================================================
314
+ If final application selection failed, prompt the cardholder for another
315
+ application selection if a list was previously displayed
316
+ ============================================================================-->
317
+ <screen id="dsp_selfld">
318
+ <next uri="#auto_app_sel">
319
+ <variant uri="#man_app_sel" lo="tmlvar:app_sel_mode" op="equal" ro="manual"/>
320
+ </next>
321
+ <display>
322
+ <table border="2" class="warning"><tr><td>
323
+ <span>
324
+
325
+ <getvar name="err.baddata_reason"/> <br/>
326
+ err.high = <getvar name="err.code.high"/> <br/>
327
+ err.low = <getvar name="err.code.low"/><br/>
328
+ card.emv.apdu_list: <getvar name="card.emv.apdu_list"/><br/>
329
+ app: <getvar name="card.emv.app_list"/><br/>
330
+ status: <getvar name="card.emv.app_status_list"/>
331
+
332
+ </span>
333
+ </td></tr></table>
334
+ </display>
335
+ </screen>
336
+
337
+
338
+
339
+
340
+ <!-- icc screen analyses card verification method -->
341
+ <screen id="icc_get_cvm" next="#chksign">
342
+
343
+ <tform>
344
+ <baddata max="1" next="<%=@abort%>">
345
+ <table border="2" class="warning"><tr><td>
346
+ <span>
347
+
348
+ <getvar name="err.baddata_reason"/>
349
+ err.high = <getvar name="err.code.high"/> <br/>
350
+ err.low = <getvar name="err.code.low"/><br/>
351
+ card.emv.apdu_list: <getvar name="card.emv.apdu_list"/>
352
+
353
+ </span>
354
+ </td></tr></table>
355
+ </baddata>
356
+ <card parser="icc_emv" parser_params="get_cvm"/>
357
+ </tform>
358
+ </screen>
359
+
360
+ <screen id="chksign">
361
+ <setvar name="txt_cvm" lo=""/>
362
+ <next uri="#chkcvm">
363
+ <variant lo="tmlvar:card.emv.signature" op="equal" ro="1" uri="#set_sign"/>
364
+ </next>
365
+ </screen>
366
+
367
+ <screen id="set_sign" next="#chkcvm">
368
+ <setvar name="txt_cvm" lo=" + SIGNATURE"/>
369
+ </screen>
370
+
371
+ <screen id="chkcvm">
372
+ <next uri="<%=@assert%>">
373
+ <variant lo="tmlvar:card.parser.verdict" op="equal" ro="reject" uri="<%=@reject%>"/>
374
+ <variant lo="tmlvar:card.parser.cvm" op="equal" ro="pin" uri="#enter_pin"/>
375
+ <variant lo="tmlvar:card.parser.cvm" op="equal" ro="pin_online" uri="#online_cvm"/>
376
+ <variant lo="tmlvar:card.parser.cvm" op="equal" ro="no_cv" uri="#cv_no_cv"/>
377
+ <variant lo="tmlvar:card.parser.cvm" op="equal" ro="" uri="#icc_rsk_mgmt"/>
378
+ </next>
379
+ </screen>
380
+
381
+ <!-- Empty form, just to set the cvr -->
382
+ <screen id="online_cvm" next="#bypass_cvm" timeout="1">
383
+ <display>
384
+ <table class="message"><tr><td>
385
+ <span>
386
+
387
+ ONLINE PIN <getvar name="txt_cvm"/>
388
+
389
+ </span>
390
+ </td></tr></table>
391
+ </display>
392
+ </screen>
393
+
394
+ <screen id="bypass_cvm" next="#icc_get_cvm">
395
+ <setvar name="card.parser.cvr" lo="bypassed"/>
396
+ </screen>
397
+
398
+ <!-- Empty form, just to set the cvr -->
399
+ <screen id="cv_no_cv" next="#icc_get_cvm" timeout="1">
400
+ <setvar name="card.parser.cvr" lo="ok"/>
401
+ <display>
402
+ <table class="message"><tr><td>
403
+ <span>
404
+
405
+ NO CVM <getvar name="txt_cvm"/>
406
+
407
+ </span>
408
+ </td></tr></table>
409
+ </display>
410
+ </screen>
411
+
412
+ <!--
413
+ Check if it is last attempt
414
+ in case user presses cancel we should set present him next type of
415
+ card verification method
416
+ -->
417
+ <screen id="enter_pin" cancel="#cvr_no_pin" timeout="1">
418
+ <next uri="<%=@assert%>">
419
+ <variant lo="tmlvar:card.emv.last_attempt" op="equal" ro="0" uri="#enterpin"/>
420
+ <variant lo="tmlvar:card.emv.last_attempt" op="equal" ro="1" uri="#enterpinlast"/>
421
+ </next>
422
+ <display>
423
+ <table class="message"><tr><td>
424
+ <span>
425
+
426
+ Offline PIN <getvar name="txt_cvm"/>
427
+
428
+ </span>
429
+ </td></tr></table>
430
+ </display>
431
+ </screen>
432
+
433
+ <!--
434
+ in case user presses cancel we should present him next type of
435
+ card verification method
436
+ -->
437
+ <screen id="enterpin" cancel="#cvr_no_pin" next="#verify_pin">
438
+ <tform>
439
+
440
+ <baddata max="1" next="<%=@abort%>">
441
+ <table border="2" class="warning"><tr><td>
442
+ <span>
443
+
444
+ <getvar name="err.baddata_reason"/><br/>
445
+ err.high = <getvar name="err.code.high"/> <br/>
446
+ err.low = <getvar name="err.code.low"/><br/>
447
+
448
+ </span>
449
+ </td></tr></table>
450
+ </baddata>
451
+ <!-- calls SSA for secure PIN entry -->
452
+ <pinentry type="icc" prompt="Enter PIN" />
453
+
454
+ </tform>
455
+ </screen>
456
+
457
+ <!--
458
+ Sets cvr to "failed" as the customer refused to enter pin (instead of
459
+ "failed" "bypassed" value may be used to bypass "pin" method)
460
+ -->
461
+ <screen id="cvr_no_pin" next="#icc_get_cvm">
462
+ <setvar name="card.parser.cvr" lo="failed"/>
463
+ </screen>
464
+
465
+ <!--
466
+ in case user presses cancel we should present him next type of
467
+ card verification method
468
+ -->
469
+ <screen id="enterpinlast" timeout="3" cancel="#cvr_no_pin" next="#pinlast">
470
+ <display>
471
+ <table class="message"><tr><td>
472
+ <span>
473
+
474
+ Last Try.
475
+
476
+ </span>
477
+ </td></tr></table>
478
+ </display>
479
+ </screen>
480
+
481
+ <!--
482
+ in case user preses cancel we should present him next type of
483
+ card verification method
484
+ -->
485
+ <screen id="pinlast" cancel="#cvr_no_pin" next="#verify_pin">
486
+ <tform>
487
+ <baddata next="<%=@abort%>">
488
+ <table border="2" class="warning"><tr><td>
489
+ <span>
490
+
491
+ <getvar name="err.baddata_reason"/>
492
+
493
+ </span>
494
+ </td></tr></table>
495
+ </baddata>
496
+
497
+ <pinentry type="icc" prompt="Enter PIN"/>
498
+
499
+ </tform>
500
+ </screen>
501
+
502
+ <!-- Verifies pin -->
503
+ <screen id="verify_pin">
504
+ <next uri="<%=@assert%>">
505
+ <variant lo="tmlvar:card.parser.verdict" op="equal" ro="reject" uri="<%=@reject%>"/>
506
+
507
+ <variant lo="tmlvar:card.parser.cvr" op="equal" ro="ok" uri="#icc_get_cvm"/>
508
+ <variant lo="tmlvar:card.parser.cvr" op="equal" ro="ok_msg" uri="#pin_ok_msg"/>
509
+ <variant lo="tmlvar:card.parser.cvr" op="equal" ro="failed" uri="#wrong_pin"/>
510
+ <variant lo="tmlvar:card.parser.cvr" op="equal" ro="pin_tries" uri="#wrong_pin"/>
511
+ </next>
512
+ <tform>
513
+ <baddata max="1" next="<%=@abort%>">
514
+ <table border="2" class="warning"><tr><td>
515
+ <span>
516
+
517
+ <getvar name="err.baddata_reason"/><br/>
518
+ err.high = <getvar name="err.code.high"/> <br/>
519
+ err.low = <getvar name="err.code.low"/>
520
+
521
+ </span>
522
+ </td></tr></table>
523
+ </baddata>
524
+ <card parser="icc_emv" parser_params="verify"/>
525
+ </tform>
526
+ </screen>
527
+
528
+ <!-- Notifies that user entered correct pin -->
529
+ <screen id="pin_ok_msg" timeout="1" cancel="#icc_get_cvm" next="#icc_get_cvm">
530
+ <display>
531
+ <table class="message"><tr><td>
532
+ <span>
533
+
534
+ PIN OK
535
+
536
+ </span>
537
+ </td></tr></table>
538
+ </display>
539
+ </screen>
540
+
541
+ <!-- Notifies that user entered incorrect pin -->
542
+ <screen id="wrong_pin" timeout="1" cancel="#icc_get_cvm">
543
+ <next uri="<%=@assert%>">
544
+ <variant lo="tmlvar:card.parser.cvr" op="equal" ro="failed" uri="#enter_pin"/>
545
+ <variant lo="tmlvar:card.parser.cvr" op="equal" ro="pin_tries" uri="#icc_get_cvm"/>
546
+ </next>
547
+ <display>
548
+ <table class="message"><tr><td>
549
+ <span>
550
+
551
+ Incorrect PIN
552
+
553
+ </span>
554
+ </td></tr></table>
555
+ </display>
556
+ </screen>
557
+
558
+ <!-- Perform the risk management.
559
+ The "icc_emv" parser will:
560
+ analyse amount and transaction type;
561
+ analyse previous submission attempt ("oebr.econn" TML value);
562
+ update "card.parser.verdict" variable;
563
+ fill "card.parser.reject_reason" variable, if necessary.
564
+ -->
565
+
566
+ <screen id="icc_rsk_mgmt" next="#chk_verdict">
567
+ <setvar name="btmlpa.emv.txn_aid" lo="tmlvar:card.emv.aid"/>
568
+ <setvar name="payment.txn_date" lo="tmlvar:terminal.datetime"/>
569
+ <setvar name="payment.auth_code" lo=""/>
570
+ <setvar name="payment.auth_resp_code" lo=""/>
571
+ <tform>
572
+ <baddata max="1" next="<%=@abort%>">
573
+ <table border="2" class="warning"><tr><td>
574
+ <span>
575
+
576
+ <getvar name="err.baddata_reason"/><br/>
577
+ err.high=<getvar name="err.code.high"/><br/>
578
+ err.low=<getvar name="err.code.low"/>
579
+ card.emv.apdu_list: <getvar name="card.emv.apdu_list"/>
580
+
581
+ </span>
582
+ </td></tr></table>
583
+ </baddata>
584
+ <card parser="icc_emv" parser_params="risk_mgmt"/>
585
+ </tform>
586
+ </screen>
587
+
588
+ <screen id="chk_verdict">
589
+ <setvar name="oebr.submit_mode" lo="tmlvar:card.parser.verdict"/>
590
+ <next uri="<%=@assert%>">
591
+ <variant lo="tmlvar:card.parser.verdict" op="equal" ro="reject" uri="#off_rej"/>
592
+ <variant lo="tmlvar:card.parser.verdict" op="equal" ro="offline" uri="#off_comp"/>
593
+ <variant lo="tmlvar:card.parser.verdict" op="equal" ro="online" uri="#icc_submit"/>
594
+ </next>
595
+
596
+ </screen>
597
+
598
+
599
+
600
+ <screen id="off_rej" next="<%=@abort%>" timeout="1">
601
+ <display>
602
+ <table border="2" class="warning"><tr><td>
603
+ <span>
604
+
605
+ REJECTED
606
+
607
+ </span>
608
+ </td></tr></table>
609
+ </display>
610
+ </screen>
611
+
612
+ <screen id="off_comp" next="#icc_submit" timeout="1">
613
+ <display>
614
+ <table border="0" class="message"><tr><td>
615
+ <span>
616
+
617
+ TRANSACTION PROCESSED OFFLINE
618
+
619
+ </span>
620
+ </td></tr></table>
621
+ </display>
622
+ </screen>
623
+
624
+ <!--==========================================
625
+ Submits transaction data to host
626
+ ============================================ -->
627
+
628
+ <!-- In case of the successful online submit (oebr.submit_mode ="online") the next screen that will be executed will be
629
+ the dynamic TML page generated by the host.
630
+ In case of the successful offline submit the next screen is determined by the "next" attribute.
631
+ In case of a submission error, no values are submitted and the next screen is determined by the "econn" attribute -->
632
+ <screen id="icc_submit" next="<%=@receipt%>">
633
+ <!-- to process the test cards that are expired. Remove for normal operations -->
634
+ <setvar name="card.expiry_date" lo="2010/12/31"/>
635
+ <!-- set the submit mode to either online or offline -->
636
+ <setvar name="oebr.submit_mode" lo="tmlvar:card.parser.verdict"/>
637
+ <submit tgt="/btmlpa/auth" econn="#icc_conn_fld">
638
+ <getvar name="oebr.submit_mode"/>
639
+ <getvar name="payment.trans_type"/>
640
+ <getvar name="card.pan"/>
641
+ <getvar name="card.issue_number"/>
642
+ <getvar name="card.expiry_date"/>
643
+ <getvar name="card.cardholder_name"/>
644
+ <getvar name="card.effective_date"/>
645
+ <getvar name="transid"/>
646
+ <getvar name="payment.amount"/>
647
+ <getvar name="payment.amount_other"/>
648
+ <getvar name="currency_code"/>
649
+ <getvar name="card.input_type"/>
650
+ <getvar name="card.mag.iso2_track"/>
651
+ <!-- ICC data -->
652
+ <getvar name="card.emv.aid"/>
653
+ <getvar name="card.emv.aip"/>
654
+ <getvar name="card.emv.auc"/>
655
+ <getvar name="card.emv.atc"/>
656
+ <getvar name="card.emv.aac"/>
657
+ <getvar name="card.emv.tc"/>
658
+ <getvar name="card.emv.arqc"/>
659
+ <getvar name="card.emv.iad"/>
660
+ <getvar name="card.emv.tvr"/>
661
+ <getvar name="card.emv.unumber"/>
662
+ <getvar name="payment.txn_date"/>
663
+ <getvar name="oebr.time_zone"/>
664
+ </submit>
665
+ </screen>
666
+
667
+ <!--===========================================================================
668
+ This screen is used when the host is unreachable
669
+ ============================================================================-->
670
+ <!-- this screen is reached in case there was an error with either online or offline submit
671
+ first check which one of then caused the error-->
672
+
673
+ <screen id="icc_conn_fld">
674
+ <next uri="<%=@assert%>">
675
+ <variant lo="tmlvar:oebr.submit_mode" op="equal" ro="online" uri="#con_fld_onln"/>
676
+ <variant lo="tmlvar:oebr.submit_mode" op="equal" ro="offline" uri="#con_fld_ofln"/>
677
+ </next>
678
+ </screen>
679
+
680
+ <!-- submission error during online submission. The card should perform its risk management to see if it is ok to do an
681
+ offline transaction or the transaction should be rejected -->
682
+ <screen id="con_fld_onln" next="#icc_rsk_mgmt" timeout="2">
683
+ <display>
684
+ <table border="2" class="warning"><tr><td>
685
+ <span>
686
+
687
+ HOST IS UNREACHABLE
688
+
689
+ </span>
690
+ </td></tr></table>
691
+ </display>
692
+ </screen>
693
+
694
+ <!-- this screen is reached if an offline submission failed. This occurs
695
+ if the Offline Transaction Pull is full and OEGW can not be reached to clear the pull.
696
+ The transaction should be rejected -->
697
+ <screen id="con_fld_ofln" next="#off_rej" timeout="2">
698
+ <display>
699
+ <table border="2" class="warning"><tr><td>
700
+ <span>
701
+
702
+ OFFLINE TRANSACTION PULL IS FULL
703
+
704
+ </span>
705
+ </td></tr></table>
706
+ </display>
707
+ </screen>
708
+
709
+
710
+ <!-- Screen which dynamic TML may refer to -->
711
+ <screen id="icc_tc_aac" cancel="<%=@abort%>">
712
+ <setvar name="oebr.submit_mode" lo="offline"/>
713
+ <next uri="<%=@void%>">
714
+ <variant lo="tmlvar:card.emv.tc" op="not_equal" ro="" uri="<%=@receipt%>"/>
715
+ </next>
716
+ <submit tgt="<%=url_for :only_path => true, :action => 'auth'%>" econn="<%=@compl_txn%>">
717
+ <getvar name="card.emv.aac"/>
718
+ <getvar name="card.emv.tc"/>
719
+ <getvar name="transid"/>
720
+ </submit>
721
+ </screen>
722
+
723
+
724
+ <screen id="error_scr">
725
+ <display>
726
+ <table border="2" class="warning"><tr><td>
727
+ <span>
728
+
729
+ code-low: <getvar name="err.code.low"/> <br/>
730
+ code-high: <getvar name="err.code.high"/> <br/>
731
+ baddata_reason: <getvar name="err.baddata_reason"/> <br/>
732
+ descr: <getvar name="err.description"/> <br/>
733
+
734
+ </span>
735
+ </td></tr></table>
736
+ </display>
737
+ </screen>
738
+
739
+
740
+
741
+
742
+ </tml>
743
+
744
+ <!--========================================================================
745
+
746
+ COPYRIGHT (C) 2008 Ingenico
747
+ ALL RIGHTS RESERVED
748
+
749
+ Copyright in the whole and every part of this software program belongs to
750
+ Ingenico. It may not be used, sold, licensed, transferred, copied
751
+ or reproduced in whole or in part in any manner or form other than in
752
+ accordance with and subject to the terms of a licence from Ingenico
753
+ or with the prior written consent of Ingenico or as permitted by
754
+ applicable law.
755
+ This software program contains confidential and proprietary information and
756
+ must not be disclosed, in whole or in part, to any person or organisation
757
+ without the prior written consent of Ingenico.
758
+ Any copies or reproductions of this software program (in whole or in part)
759
+ made by any method must also include a copy of this legend.
760
+ ========================================================================-->