You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

115 lines
5.3 KiB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <odoo>
  3. <template id="cooperator_certificat_G001_document">
  4. <t t-call="web.external_layout">
  5. <t t-set="address">
  6. <address t-field="o.commercial_partner_id" t-options='{"widget": "contact", "fields": ["address", "name"], "no_marker": True}' />
  7. </t>
  8. <div class="page mt32">
  9. <h2>
  10. <span>Cooperator Certificate</span>
  11. </h2>
  12. <p name="certificate_generation_date" class="mt16">
  13. <span> Certificate generated on </span>
  14. <span t-esc="context_timestamp(datetime.datetime.now()).strftime('%d/%m/%Y')"/>
  15. </p>
  16. <p name="label_coop_number" class="mt16">
  17. <span t-field="o.name"/>
  18. is recorded in the register of cooperators under number
  19. <span t-field="o.cooperator_register_number"/>.
  20. </p>
  21. <table class="table table-sm o_main_table mt16" name="invoice_line_table">
  22. <thead>
  23. <tr>
  24. <t t-set="colspan" t-value="5"/>
  25. <th class="text-left">Effective date</th>
  26. <th class="text-right">Share type</th>
  27. <th class="text-right">Quantity</th>
  28. <th class="text-right">Unit Price</th>
  29. <th class="text-right">Total</th>
  30. </tr>
  31. </thead>
  32. <tbody class="invoice_tbody">
  33. <t t-set="nb_ligne" t-value="0"/>
  34. <t t-foreach="o.share_ids" t-as="line">
  35. <tr>
  36. <td class="text-left" name="effective_date">
  37. <span t-field="line.effective_date"/>
  38. </td>
  39. <td class="text-right" name="share_short_name">
  40. <span t-field="line.share_short_name"/>
  41. </td>
  42. <td class="text-right" name="share_number">
  43. <span t-field="line.share_number"/>
  44. </td>
  45. <td t-attf-class="text-right {{ 'd-none d-md-table-cell' if report_type == 'html' else '' }}"
  46. name="share_unit_price">
  47. <span t-field="line.share_unit_price"
  48. t-options='{"widget": "monetary", "display_currency": o.currency_id}'/>
  49. </td>
  50. <td class="text-right" name="total_amount_line">
  51. <span t-field="line.total_amount_line"
  52. t-options='{"widget": "monetary", "display_currency": o.currency_id}'/>
  53. </td>
  54. </tr>
  55. </t>
  56. </tbody>
  57. </table>
  58. <div class="clearfix">
  59. <div name="total_table" id="total" class="row">
  60. <div t-attf-class="#{'col-4' if report_type != 'html' else 'col-sm-7 col-md-5'} ml-auto">
  61. <table class="table table-sm">
  62. <tr class="border-black o_total">
  63. <td><strong>Total</strong></td>
  64. <td class="text-right">
  65. <span t-field="o.number_of_share"/>
  66. <span> share(s) </span>
  67. </td>
  68. <td class="text-right">
  69. <span t-field="o.total_value"
  70. t-options='{"widget": "monetary", "display_currency": o.currency_id}'/>
  71. </td>
  72. </tr>
  73. </table>
  74. </div>
  75. </div>
  76. </div>
  77. <div class="row mt32">
  78. <div name="board_commitee" class="col-sm-6">
  79. <p>
  80. For the board of <span t-field="o.company_id.name"/>.
  81. </p>
  82. <p>
  83. <strong>
  84. <span t-field="o.company_id.board_representative"/>
  85. </strong>
  86. </p>
  87. <img t-if="o.company_id.signature_scan"
  88. t-attf-class="mt16 w-50"
  89. t-attf-style="{{ 'min-width: 100px; max-width: 250px' if report_type == 'pdf' else '' }}"
  90. t-att-src="'data:image/png;base64,%s' % o.company_id.signature_scan.decode()"/>
  91. </div>
  92. </div>
  93. </div>
  94. </t>
  95. </template>
  96. <template id="cooperator_certificat_G001">
  97. <t t-call="web.html_container">
  98. <t t-foreach="docs" t-as="o">
  99. <t t-call="easy_my_coop.cooperator_certificat_G001_document" t-lang="o.lang"/>
  100. </t>
  101. </t>
  102. </template>
  103. </odoo>