pos.xml 2.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <templates>
  3. <t t-extend="PaymentScreenWidget">
  4. <t t-jquery=".payment-due-total" t-operation="after">
  5. <t t-if="widget.pos.config.multi_currency_enable">
  6. <div>
  7. <div class="onoffswitch" style="float:left">
  8. <input type="checkbox" name="toggle_multi_currency" class="onoffswitch-checkbox" id="toggle_multi_currency" />
  9. <label class="onoffswitch-label" for="toggle_multi_currency">
  10. <span class="onoffswitch-inner"></span>
  11. <span class="onoffswitch-switch"></span>
  12. </label>
  13. </div>
  14. <div style="padding:5px;text-align:right !important;float:left">
  15. <span> Moneda Extranjera</span>
  16. </div>
  17. </div>
  18. <br/><br/>
  19. <div id="multi_currency" style="display:none;border:1px solid lightgrey;">
  20. <div class="foreign_infoline">
  21. <label class="left-block" id="currency_selection_label"
  22. for="currency_selection">Moneda: </label>
  23. <t t-set="selected_curr" t-value="widget.get_currency_selection()" />
  24. <select style="height:30px;width:50%;"
  25. class="right-block" id="currency_selection">
  26. <t t-foreach="widget.pos.currency_list" t-as="currencylist">
  27. <t t-if="selected_curr==currencylist.id">
  28. <option selected="selected" t-att-value="currencylist.id">
  29. <b><t t-esc="currencylist.name"/></b>
  30. </option>
  31. </t>
  32. <t t-if="selected_curr!=currencylist.id">
  33. <option t-att-value="currencylist.id">
  34. <b><t t-esc="currencylist.name"/></b>
  35. </option>
  36. </t>
  37. </t>
  38. </select>
  39. </div>
  40. <t t-if="widget.pos.config.display_conversion">
  41. <div class="foreign_infoline" style="text-align:center;font-weight:bold"
  42. id="conversion_rate">
  43. </div>
  44. </t>
  45. <div class="foreign_infoline">
  46. <span class="left-block" id="currency_value_label"></span>
  47. <span id="currency_value" class="right-block"></span>
  48. </div>
  49. <div class="foreign_infoline">
  50. <span id="foreign_input_label" class="left-block"></span>
  51. <input placeholder="Ingresar Valor"
  52. class="paymentline-input-foreign right-block"
  53. id="curr_input" type="number" step="0.01" pattern="!/^([0-9])*$/" min="0.0"></input>
  54. <!-- Expresion regular orginal -->
  55. <!-- [0-9]+([\.][0-9]+)? -->
  56. <!-- Nueva expresion regular -->
  57. <!-- !/^([0-9])*$/ -->
  58. </div>
  59. </div>
  60. <br/>
  61. </t>
  62. </t>
  63. <t t-jquery=".infoline.bigger" t-operation="after">
  64. <t t-if="widget.pos.config.multi_currency_enable">
  65. <div class="infoline bigger" id="foreign_change_div" style="display:none">
  66. <span class='left-block' id="foreign_change_label">
  67. </span>
  68. <span class="right-block" id="foreign_change_value"></span>
  69. </div>
  70. </t>
  71. </t>
  72. </t>
  73. </templates>