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.

877 lines
47 KiB

  1. <?xml version="1.0" encoding="utf-8" ?>
  2. <odoo>
  3. <template id="trial_balance">
  4. <t t-call="web.html_container">
  5. <t t-foreach="docs" t-as="o">
  6. <t t-call="account_financial_report.internal_layout">
  7. <t t-call="account_financial_report.report_trial_balance_base" />
  8. </t>
  9. </t>
  10. </t>
  11. </template>
  12. <template id="report_trial_balance_base">
  13. <!-- Saved flag fields into variables, used to define columns display -->
  14. <t t-set="show_partner_details" t-value="show_partner_details" />
  15. <t t-set="foreign_currency" t-value="foreign_currency" />
  16. <t t-set="show_hierarchy_level" t-value="show_hierarchy_level" />
  17. <t t-set="limit_hierarchy_level" t-value="limit_hierarchy_level" />
  18. <!-- Defines global variables used by internal layout -->
  19. <t t-set="title">Trial Balance - <t t-raw="company_name" /> - <t
  20. t-raw="currency_name"
  21. /></t>
  22. <t t-set="company_name" t-value="Company_Name" />
  23. <!-- <t t-set="res_company" t-value="company_id"/>-->
  24. <t class="page">
  25. <div class="row">
  26. <h4
  27. class="mt0"
  28. t-esc="title or 'Odoo Report'"
  29. style="text-align: center;"
  30. />
  31. </div>
  32. <!-- Display filters -->
  33. <t t-call="account_financial_report.report_trial_balance_filters" />
  34. <div class="act_as_table list_table" style="margin-top: 10px;" />
  35. <!-- Display account lines -->
  36. <t t-if="not show_partner_details">
  37. <div class="act_as_table data_table" style="width: 100%;">
  38. <!-- Display account header -->
  39. <t
  40. t-call="account_financial_report.report_trial_balance_lines_header"
  41. />
  42. <!-- Display each lines -->
  43. <t t-foreach="trial_balance" t-as="balance">
  44. <!-- Adapt -->
  45. <t t-set="style" t-value="'font-size:12px;'" />
  46. <t t-if="hierarchy_on == 'none'">
  47. <t
  48. t-call="account_financial_report.report_trial_balance_line"
  49. />
  50. </t>
  51. <t t-if="hierarchy_on == 'computed'">
  52. <t t-if="balance['type'] == 'group_type'">
  53. <t
  54. t-set="style"
  55. t-value="style + 'font-weight: bold; color: blue;'"
  56. />
  57. <t
  58. t-call="account_financial_report.report_trial_balance_line"
  59. />
  60. </t>
  61. <t t-if="balance['type'] == 'account_type'">
  62. <t
  63. t-call="account_financial_report.report_trial_balance_line"
  64. />
  65. </t>
  66. </t>
  67. <!-- <t t-set="padding" t-value="line.level * 4"/>-->
  68. <!-- <t t-if="hierarchy_on != 'none'">-->
  69. <!-- <t t-set="style" t-value="'font-size: ' + str(14 - line.level) + 'px; margin-left: ' + str(line.level * 4) + 'px;'"/>-->
  70. <!-- </t>-->
  71. <t t-if="hierarchy_on == 'relation'">
  72. <t t-if="balance['type'] == 'group_type'">
  73. <t
  74. t-set="style"
  75. t-value="style + 'font-weight: bold; color: blue;'"
  76. />
  77. <t
  78. t-call="account_financial_report.report_trial_balance_line"
  79. />
  80. </t>
  81. <t t-if="balance['type'] == 'account_type'">
  82. <t t-if="limit_hierarchy_level">
  83. <t t-if="show_hierarchy_level > balance['level']">
  84. <t
  85. t-call="account_financial_report.report_trial_balance_line"
  86. />
  87. </t>
  88. </t>
  89. <t t-if="not limit_hierarchy_level">
  90. <t
  91. t-call="account_financial_report.report_trial_balance_line"
  92. />
  93. </t>
  94. </t>
  95. </t>
  96. </t>
  97. </div>
  98. </t>
  99. <!-- Display partner lines -->
  100. <t t-if="show_partner_details">
  101. <t t-set="padding" t-value="0" />
  102. <t t-foreach="total_amount.keys()" t-as="account_id">
  103. <div class="page_break">
  104. <t t-set="style" t-value="'font-size:12px;'" />
  105. <!-- Display account header -->
  106. <div
  107. class="act_as_table list_table"
  108. style="margin-top: 10px;"
  109. />
  110. <div class="act_as_caption account_title" style="width: 100%;">
  111. <span
  112. t-att-res-id="account_id"
  113. res-model="account.account"
  114. view-type="form"
  115. >
  116. <t
  117. t-raw="accounts_data[account_id]['code']"
  118. /> - <t t-raw="accounts_data[account_id]['name']" />
  119. </span>
  120. </div>
  121. <div class="act_as_table data_table" style="width: 100%;">
  122. <!-- Display account/partner header -->
  123. <t
  124. t-call="account_financial_report.report_trial_balance_lines_header"
  125. />
  126. <!-- Adapt style -->
  127. <t t-set="padding" t-value="padding+4" />
  128. <!-- Display each partners -->
  129. <t
  130. t-foreach="total_amount[account_id].keys()"
  131. t-as="partner_id"
  132. >
  133. <t t-if="isinstance(partner_id, int)">
  134. <t t-set="type" t-value='"partner_type"' />
  135. <!-- Display partner line -->
  136. <t
  137. t-call="account_financial_report.report_trial_balance_line"
  138. />
  139. </t>
  140. </t>
  141. <t t-set="padding" t-value="padding-4" />
  142. </div>
  143. <!-- Display account footer -->
  144. <t t-set="type" t-value='"account_type"' />
  145. <t
  146. t-call="account_financial_report.report_trial_balance_account_footer"
  147. />
  148. </div>
  149. </t>
  150. </t>
  151. </t>
  152. </template>
  153. <template id="account_financial_report.report_trial_balance_filters">
  154. <div class="act_as_table data_table" style="width: 100%;">
  155. <div class="act_as_row labels">
  156. <div class="act_as_cell">Date range filter</div>
  157. <div class="act_as_cell">Target moves filter</div>
  158. <div class="act_as_cell">Account at 0 filter</div>
  159. <div class="act_as_cell">Limit hierarchy levels</div>
  160. </div>
  161. <div class="act_as_row">
  162. <div class="act_as_cell">
  163. From: <span
  164. t-esc="date_from"
  165. t-options="{'widget': 'date'}"
  166. /> To <span t-esc="date_to" t-options="{'widget': 'date'}" />
  167. </div>
  168. <div class="act_as_cell">
  169. <t t-if="only_posted_moves">All posted entries</t>
  170. <t t-if="not only_posted_moves">All entries</t>
  171. </div>
  172. <div class="act_as_cell">
  173. <t t-if="hide_account_at_0">Hide</t>
  174. <t t-if="not hide_account_at_0">Show</t>
  175. </div>
  176. <div class="act_as_cell">
  177. <t t-if="limit_hierarchy_level">
  178. Level <span t-esc="show_hierarchy_level" />
  179. </t>
  180. <t t-if="not limit_hierarchy_level">
  181. No limit
  182. </t>
  183. </div>
  184. </div>
  185. </div>
  186. </template>
  187. <template id="account_financial_report.report_trial_balance_lines_header">
  188. <!-- Display table headers for lines -->
  189. <div class="act_as_thead">
  190. <div class="act_as_row labels">
  191. <t t-if="not show_partner_details">
  192. <!--## Code-->
  193. <div class="act_as_cell" style="width: 8%;">Code</div>
  194. <!--## Account-->
  195. <div class="act_as_cell" style="width: 25%;">Account
  196. </div>
  197. </t>
  198. <t t-if="show_partner_details">
  199. <!--## Partner-->
  200. <div class="act_as_cell" style="width: 33%;">Partner
  201. </div>
  202. </t>
  203. <!--## Initial balance-->
  204. <div class="act_as_cell" style="width: 9%;">Initial
  205. balance</div>
  206. <!--## Debit-->
  207. <div class="act_as_cell" style="width: 9%;">Debit</div>
  208. <!--## Credit-->
  209. <div class="act_as_cell" style="width: 9%;">Credit</div>
  210. <!--## Period balance-->
  211. <div class="act_as_cell" style="width: 9%;">Period balance</div>
  212. <!--## Ending balance-->
  213. <div class="act_as_cell" style="width: 9%;">Ending balance</div>
  214. <t t-if="foreign_currency">
  215. <!--## currency_name-->
  216. <div class="act_as_cell" style="width: 4%;">Cur.</div>
  217. <!--## amount_currency-->
  218. <div class="act_as_cell" style="width: 9%;">Initial
  219. balance cur.</div>
  220. <div class="act_as_cell" style="width: 9%;">Ending balance
  221. cur.</div>
  222. </t>
  223. </div>
  224. </div>
  225. </template>
  226. <template id="account_financial_report.report_trial_balance_line">
  227. <!-- # line -->
  228. <div class="act_as_row lines">
  229. <t t-if="not show_partner_details">
  230. <!--## Code-->
  231. <t t-if="balance['type'] == 'account_type'">
  232. <div class="act_as_cell left">
  233. <span
  234. t-att-res-id="balance['id']"
  235. res-model="account.account"
  236. view-type="form"
  237. >
  238. <t t-att-style="style" t-esc="balance['code']" />
  239. </span>
  240. </div>
  241. <!-- ## Account/Partner-->
  242. <div class="act_as_cell left">
  243. <span
  244. t-att-res-id="balance['id']"
  245. res-model="account.account"
  246. view-type="form"
  247. >
  248. <t t-att-style="style" t-esc="balance['name']" />
  249. </span>
  250. </div>
  251. </t>
  252. <t t-if="balance['type'] == 'group_type'">
  253. <div class="act_as_cell left">
  254. <t t-set="res_model" t-value="'account.group'" />
  255. <span
  256. t-att-res-id="balance['id']"
  257. res-model="account.group"
  258. view-type="form"
  259. >
  260. <t t-att-style="style" t-raw="balance['code']" />
  261. </span>
  262. </div>
  263. <div class="act_as_cell left">
  264. <t t-set="res_model" t-value="'account.group'" />
  265. <span
  266. t-att-res-id="balance['id']"
  267. res-model="account.group"
  268. view-type="form"
  269. >
  270. <t t-att-style="style" t-esc="balance['name']" />
  271. </span>
  272. </div>
  273. </t>
  274. </t>
  275. <t t-if="show_partner_details">
  276. <div class="act_as_cell left">
  277. <t t-set="res_model" t-value="'res.partner'" />
  278. <span
  279. t-att-res-id="partner_id"
  280. res-model="res.partner"
  281. view-type="form"
  282. >
  283. <t
  284. t-att-style="style"
  285. t-esc="partners_data[partner_id]['name']"
  286. />
  287. </span>
  288. </div>
  289. </t>
  290. <!--## Initial balance-->
  291. <div class="act_as_cell amount">
  292. <t t-if="not show_partner_details">
  293. <t t-if="balance['type'] == 'account_type'">
  294. <t
  295. t-set="domain"
  296. t-value="[('account_id', '=', balance['id']),
  297. ('date', '&lt;', date_from)]"
  298. />
  299. <span t-att-domain="domain" res-model="account.move.line">
  300. <t
  301. t-att-style="style"
  302. t-esc="balance['initial_balance']"
  303. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  304. />
  305. </span>
  306. </t>
  307. <t t-if="balance['type'] == 'group_type'">
  308. <t
  309. t-set="domain"
  310. t-value="[('account_id', 'in', balance['account_ids']),
  311. ('date', '&lt;', date_from)]"
  312. />
  313. <span t-att-domain="domain" res-model="account.move.line">
  314. <t
  315. t-att-style="style"
  316. t-raw="balance['initial_balance']"
  317. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  318. />
  319. </span>
  320. </t>
  321. </t>
  322. <t t-if="type == 'partner_type'">
  323. <t
  324. t-set="domain"
  325. t-value="[('account_id', '=', int(account_id)),
  326. ('partner_id', '=', int(partner_id)),
  327. ('date', '&lt;', date_from)]"
  328. />
  329. <span t-att-domain="domain" res-model="account.move.line">
  330. <t
  331. t-att-style="style"
  332. t-raw="total_amount[account_id][partner_id]['initial_balance']"
  333. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  334. />
  335. </span>
  336. </t>
  337. </div>
  338. <!--## Debit-->
  339. <div class="act_as_cell amount">
  340. <t t-if="not show_partner_details">
  341. <t t-if="balance['type'] == 'account_type'">
  342. <t
  343. t-set="domain"
  344. t-value="[('account_id', '=', balance['id']),
  345. ('date', '&gt;=', date_from),
  346. ('date', '&lt;=', date_to),
  347. ('debit', '&lt;&gt;', 0)]"
  348. />
  349. <span t-att-domain="domain" res-model="account.move.line">
  350. <t
  351. t-att-style="style"
  352. t-esc="balance['debit']"
  353. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  354. />
  355. </span>
  356. </t>
  357. <t t-if="balance['type'] == 'group_type'">
  358. <t
  359. t-set="domain"
  360. t-value="[('account_id', 'in', balance['account_ids']),
  361. ('date', '&gt;=', date_from),
  362. ('date', '&lt;=', date_to),
  363. ('debit', '&lt;&gt;', 0)]"
  364. />
  365. <span t-att-domain="domain" res-model="account.move.line">
  366. <t
  367. t-att-style="style"
  368. t-raw="balance['debit']"
  369. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  370. />
  371. </span>
  372. </t>
  373. </t>
  374. <t t-if="type == 'partner_type'">
  375. <t
  376. t-set="domain"
  377. t-value="[('account_id', '=', int(account_id)),
  378. ('partner_id', '=', int(partner_id)),
  379. ('date', '&gt;=', date_from),
  380. ('date', '&lt;=', date_to),
  381. ('debit', '&lt;&gt;', 0)]"
  382. />
  383. <span t-att-domain="domain" res-model="account.move.line">
  384. <t
  385. t-att-style="style"
  386. t-raw="total_amount[account_id][partner_id]['debit']"
  387. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  388. />
  389. </span>
  390. </t>
  391. </div>
  392. <!-- &lt;!&ndash;## Credit&ndash;&gt;-->
  393. <div class="act_as_cell amount">
  394. <t t-if="not show_partner_details">
  395. <t t-if="balance['type'] == 'account_type'">
  396. <t
  397. t-set="domain"
  398. t-value="[('account_id', '=', balance['id']),
  399. ('date', '&gt;=', date_from),
  400. ('date', '&lt;=', date_to),
  401. ('credit', '&lt;&gt;', 0)]"
  402. />
  403. <span t-att-domain="domain" res-model="account.move.line">
  404. <t
  405. t-att-style="style"
  406. t-esc="balance['credit']"
  407. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  408. />
  409. </span>
  410. </t>
  411. <t t-if="balance['type'] == 'group_type'">
  412. <t
  413. t-set="domain"
  414. t-value="[('account_id', 'in', balance['account_ids']),
  415. ('date', '&gt;=', date_from),
  416. ('date', '&lt;=', date_to),
  417. ('credit', '&lt;&gt;', 0)]"
  418. />
  419. <span t-att-domain="domain" res-model="account.move.line">
  420. <t
  421. t-att-style="style"
  422. t-raw="balance['credit']"
  423. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  424. />
  425. </span>
  426. </t>
  427. </t>
  428. <t t-if="type == 'partner_type'">
  429. <t
  430. t-set="domain"
  431. t-value="[('account_id', '=', int(account_id)),
  432. ('partner_id', '=', int(partner_id)),
  433. ('date', '&gt;=', date_from),
  434. ('date', '&lt;=', date_to),
  435. ('credit', '&lt;&gt;', 0)]"
  436. />
  437. <span t-att-domain="domain" res-model="account.move.line">
  438. <t
  439. t-att-style="style"
  440. t-raw="total_amount[account_id][partner_id]['credit']"
  441. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  442. />
  443. </span>
  444. </t>
  445. </div>
  446. <!-- &lt;!&ndash;## Period balance&ndash;&gt;-->
  447. <div class="act_as_cell amount">
  448. <t t-if="not show_partner_details">
  449. <t t-if="balance['type'] == 'account_type'">
  450. <t
  451. t-set="domain"
  452. t-value="[('account_id', '=', balance['id']),
  453. ('date', '&gt;=', date_from),
  454. ('date', '&lt;=', date_to),
  455. ('balance', '&lt;&gt;', 0)]"
  456. />
  457. <span t-att-domain="domain" res-model="account.move.line">
  458. <t
  459. t-att-style="style"
  460. t-esc="balance['balance']"
  461. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  462. />
  463. </span>
  464. </t>
  465. <t t-if="balance['type'] == 'group_type'">
  466. <t
  467. t-set="domain"
  468. t-value="[('account_id', 'in', balance['account_ids']),
  469. ('date', '&gt;=', date_from),
  470. ('date', '&lt;=', date_to)]"
  471. />
  472. <span t-att-domain="domain" res-model="account.move.line">
  473. <t
  474. t-att-style="style"
  475. t-raw="balance['balance']"
  476. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  477. />
  478. </span>
  479. </t>
  480. </t>
  481. <t t-if="type == 'partner_type'">
  482. <t
  483. t-set="domain"
  484. t-value="[('account_id', '=', int(account_id)),
  485. ('partner_id', '=', int(partner_id)),
  486. ('date', '&gt;=', date_from),
  487. ('date', '&lt;=', date_to),
  488. ('balance', '&lt;&gt;', 0)]"
  489. />
  490. <span t-att-domain="domain" res-model="account.move.line">
  491. <t
  492. t-att-style="style"
  493. t-raw="total_amount[account_id][partner_id]['balance']"
  494. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  495. />
  496. </span>
  497. </t>
  498. </div>
  499. <!-- &lt;!&ndash;## Ending balance&ndash;&gt;-->
  500. <div class="act_as_cell amount">
  501. <t t-if="not show_partner_details">
  502. <t t-if="balance['type'] == 'account_type'">
  503. <t
  504. t-set="domain"
  505. t-value="[('account_id', '=', balance['id']),
  506. ('date', '&lt;=', date_to)]"
  507. />
  508. <span t-att-domain="domain" res-model="account.move.line">
  509. <t
  510. t-att-style="style"
  511. t-esc="balance['ending_balance']"
  512. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  513. />
  514. </span>
  515. </t>
  516. <t t-if="balance['type'] == 'group_type'">
  517. <t
  518. t-set="domain"
  519. t-value="[('account_id', 'in', balance['account_ids'])]"
  520. />
  521. <span t-att-domain="domain" res-model="account.move.line">
  522. <t
  523. t-att-style="style"
  524. t-raw="balance['ending_balance']"
  525. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  526. />
  527. </span>
  528. </t>
  529. </t>
  530. <t t-if="type == 'partner_type'">
  531. <t
  532. t-set="domain"
  533. t-value="[('account_id', '=', int(account_id)),
  534. ('partner_id', '=', int(partner_id)),
  535. ('date', '&lt;=', date_to)]"
  536. />
  537. <span t-att-domain="domain" res-model="account.move.line">
  538. <t
  539. t-att-style="style"
  540. t-esc="total_amount[account_id][partner_id]['ending_balance']"
  541. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  542. />
  543. </span>
  544. </t>
  545. </div>
  546. <t t-if="foreign_currency">
  547. <t t-if="not show_partner_details">
  548. <t t-if="balance['type'] == 'account_type'">
  549. <t t-if="balance['currency_id']">
  550. <!--## currency_name-->
  551. <div class="act_as_cell" style="width: 4.43%;">
  552. <span t-esc="balance['currency_name']" />
  553. </div>
  554. <!--## Initial balance cur.-->
  555. <div class="act_as_cell amount">
  556. <t
  557. t-set="domain"
  558. t-value="[('account_id', '=', balance['id'])]"
  559. />
  560. <span
  561. t-att-domain="domain"
  562. res-model="account.move.line"
  563. >
  564. <t
  565. t-att-style="style"
  566. t-esc="balance['initial_currency_balance']"
  567. />
  568. </span>
  569. <!-- <t t-if="line.account_group_id">-->
  570. <!-- <t t-set="domain"-->
  571. <!-- t-value="[('account_id', 'in', line.compute_account_ids.ids)]"/>-->
  572. <!-- <span>-->
  573. <!-- <a t-att-data-t-att-domain="domain"-->
  574. <!-- t-att-data-res-model="'account.move.line'"-->
  575. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  576. <!-- t-att-style="style">-->
  577. <!-- <t t-att-style="style" t-raw="line.initial_balance_foreign_currency" t-options="{'widget': 'monetary', 'display_currency': line.currency_id}"/></a>-->
  578. <!-- </span>-->
  579. <!-- </t>-->
  580. </div>
  581. </t>
  582. </t>
  583. </t>
  584. <t t-if="show_partner_details">
  585. <t t-if="total_amount[account_id]['currency_id']">
  586. <t t-if="type == 'partner_type'">
  587. <!--## currency_name-->
  588. <div class="act_as_cell" style="width: 4.43%;">
  589. <span
  590. t-esc="total_amount[account_id]['currency_name']"
  591. />
  592. </div>
  593. <div class="act_as_cell amount">
  594. <t
  595. t-set="domain"
  596. t-value="[('account_id', '=', account_id),
  597. ('partner_id', '=', partner_id)]"
  598. />
  599. <span
  600. t-att-domain="domain"
  601. res-model="account.move.line"
  602. >
  603. <t
  604. t-att-style="style"
  605. t-raw="total_amount[account_id][partner_id]['initial_currency_balance']"
  606. />
  607. </span>
  608. </div>
  609. </t>
  610. </t>
  611. </t>
  612. <!--## Ending balance cur.-->
  613. <t t-if="not show_partner_details">
  614. <t t-if="balance['type'] == 'account_type'">
  615. <t t-if="balance['currency_id']">
  616. <div class="act_as_cell amount">
  617. <t
  618. t-set="domain"
  619. t-value="[('account_id', '=', balance['id'])]"
  620. />
  621. <span
  622. t-att-domain="domain"
  623. res-model="account.move.line"
  624. >
  625. <t
  626. t-att-style="style"
  627. t-raw="balance['ending_currency_balance']"
  628. />
  629. </span>
  630. <!-- <t t-if="line.account_group_id">-->
  631. <!-- <t t-set="domain"-->
  632. <!-- t-value="[('account_id', 'in', line.compute_account_ids.ids)]"/>-->
  633. <!-- <span>-->
  634. <!-- <a t-att-data-t-att-domain="domain"-->
  635. <!-- t-att-data-res-model="'account.move.line'"-->
  636. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  637. <!-- t-att-style="style">-->
  638. <!-- <t t-att-style="style" t-raw="line.final_balance_foreign_currency" t-options="{'widget': 'monetary', 'display_currency': line.currency_id}"/></a>-->
  639. <!-- </span>-->
  640. <!-- </t>-->
  641. </div>
  642. </t>
  643. </t>
  644. </t>
  645. <t t-if="show_partner_details">
  646. <t t-if="total_amount[account_id]['currency_id']">
  647. <div class="act_as_cell amount">
  648. <t t-if="type == 'partner_type'">
  649. <t
  650. t-set="domain"
  651. t-value="[('account_id', '=', account_id),
  652. ('partner_id', '=', partner_id)]"
  653. />
  654. <span
  655. t-att-domain="domain"
  656. res-model="account.move.line"
  657. >
  658. <t
  659. t-att-style="style"
  660. t-raw="total_amount[account_id][partner_id]['ending_currency_balance']"
  661. />
  662. </span>
  663. </t>
  664. </div>
  665. </t>
  666. </t>
  667. <t t-if="show_partner_details">
  668. <t t-if="not total_amount[account_id]['currency_id']">
  669. <!--## balance_currency-->
  670. <div class="act_as_cell" />
  671. <div class="act_as_cell" />
  672. <div class="act_as_cell" />
  673. </t>
  674. </t>
  675. <t t-if="not show_partner_details">
  676. <t t-if="balance['type'] == 'account_type'">
  677. <t t-if="not balance['currency_id']">
  678. <!--## balance_currency-->
  679. <div class="act_as_cell" />
  680. <div class="act_as_cell" />
  681. <div class="act_as_cell" />
  682. </t>
  683. </t>
  684. <t t-if="balance['type'] == 'group_type'">
  685. <!--## balance_currency-->
  686. <div class="act_as_cell" />
  687. <div class="act_as_cell" />
  688. <div class="act_as_cell" />
  689. </t>
  690. </t>
  691. </t>
  692. </div>
  693. </template>
  694. <!-- <template id="account_financial_report.report_trial_balance_account_footer">-->
  695. <!-- &lt;!&ndash; Display account footer &ndash;&gt;-->
  696. <!-- <div class="act_as_table list_table" style="width: 100%;">-->
  697. <!-- <div class="act_as_row labels" style="font-weight: bold;">-->
  698. <!-- &lt;!&ndash;## Account&ndash;&gt;-->
  699. <!-- <div class="act_as_cell left" style="width: 61.44%;">-->
  700. <!-- <t t-set="res_model" t-value="'account.account'"/>-->
  701. <!-- <span>-->
  702. <!-- <a t-att-data-active-id="account.account_id.id"-->
  703. <!-- t-att-data-res-model="res_model"-->
  704. <!-- class="o_account_financial_reports_web_action"-->
  705. <!-- t-att-style="style">-->
  706. <!-- <t t-att-style="style" t-raw="account.code"/> - <t t-att-style="style" t-raw="account.name"/></a>-->
  707. <!-- </span>-->
  708. <!-- </div>-->
  709. <!-- &lt;!&ndash;## Initial balance&ndash;&gt;-->
  710. <!-- <div class="act_as_cell amount" style="width: 9.64%;">-->
  711. <!-- <t t-set="domain"-->
  712. <!-- t-value="[('account_id', '=', account.account_id.id),-->
  713. <!-- ('date', '&lt;', o.date_from.strftime('%Y-%m-%d'))]"/>-->
  714. <!-- <span>-->
  715. <!-- <a t-att-data-t-att-domain="domain"-->
  716. <!-- t-att-data-res-model="'account.move.line'"-->
  717. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  718. <!-- t-att-style="style">-->
  719. <!-- <t t-att-style="style" t-raw="account.initial_balance" t-options="{'widget': 'monetary', 'display_currency': company_currency}"/></a>-->
  720. <!-- </span>-->
  721. <!-- </div>-->
  722. <!-- &lt;!&ndash;## Debit&ndash;&gt;-->
  723. <!-- <div class="act_as_cell amount" style="width: 9.64%;">-->
  724. <!-- <t t-set="domain"-->
  725. <!-- t-value="[('account_id', '=', account.account_id.id),-->
  726. <!-- ('date', '&gt;=', account.report_id.date_from.strftime('%Y-%m-%d')),-->
  727. <!-- ('date', '&lt;=', account.report_id.date_to.strftime('%Y-%m-%d')),-->
  728. <!-- ('debit', '&lt;&gt;', 0)]"/>-->
  729. <!-- <span>-->
  730. <!-- <a t-att-data-t-att-domain="domain"-->
  731. <!-- t-att-data-res-model="'account.move.line'"-->
  732. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  733. <!-- t-att-style="style">-->
  734. <!-- <t t-att-style="style" t-raw="account.debit" t-options="{'widget': 'monetary', 'display_currency': company_currency}"/></a>-->
  735. <!-- </span>-->
  736. <!-- </div>-->
  737. <!-- &lt;!&ndash;## Credit&ndash;&gt;-->
  738. <!-- <div class="act_as_cell amount" style="width: 9.64%;">-->
  739. <!-- <t t-set="domain"-->
  740. <!-- t-value="[('account_id', '=', account.account_id.id),-->
  741. <!-- ('date', '&gt;=', account.report_id.date_from.strftime('%Y-%m-%d')),-->
  742. <!-- ('date', '&lt;=', account.report_id.date_to.strftime('%Y-%m-%d')),-->
  743. <!-- ('credit', '&lt;&gt;', 0)]"/>-->
  744. <!-- <span>-->
  745. <!-- <a t-att-data-t-att-domain="domain"-->
  746. <!-- t-att-data-res-model="'account.move.line'"-->
  747. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  748. <!-- t-att-style="style">-->
  749. <!-- <t t-att-style="style" t-raw="account.credit" t-options="{'widget': 'monetary', 'display_currency': company_currency}"/></a>-->
  750. <!-- </span>-->
  751. <!-- </div>-->
  752. <!-- &lt;!&ndash;## Period Balance &ndash;&gt;-->
  753. <!-- <div class="act_as_cell amount" style="width: 9.64%;">-->
  754. <!-- <t t-set="domain"-->
  755. <!-- t-value="[('account_id', '=', account.account_id.id),-->
  756. <!-- ('date', '&gt;=', account.report_id.date_from.strftime('%Y-%m-%d')),-->
  757. <!-- ('date', '&lt;=', account.report_id.date_to.strftime('%Y-%m-%d')),-->
  758. <!-- ('period_balance', '&lt;&gt;', 0)]"/>-->
  759. <!-- <span>-->
  760. <!-- <a t-att-data-t-att-domain="domain"-->
  761. <!-- t-att-data-res-model="'account.move.line'"-->
  762. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  763. <!-- t-att-style="style">-->
  764. <!-- <t t-att-style="style" t-raw="account.period_balance" t-options="{'widget': 'monetary', 'display_currency': company_currency}"/></a>-->
  765. <!-- </span>-->
  766. <!-- </div>-->
  767. <!-- &lt;!&ndash;## Ending balance&ndash;&gt;-->
  768. <!-- <div class="act_as_cell amount" style="width: 9.64%;">-->
  769. <!-- <t t-set="domain"-->
  770. <!-- t-value="[('account_id', '=', account.account_id.id)]"/>-->
  771. <!-- <span>-->
  772. <!-- <a t-att-data-t-att-domain="domain"-->
  773. <!-- t-att-data-res-model="'account.move.line'"-->
  774. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  775. <!-- t-att-style="style" >-->
  776. <!-- <t t-att-style="style" t-raw="account.final_balance" t-options="{'widget': 'monetary', 'display_currency': company_currency}"/></a>-->
  777. <!-- </span>-->
  778. <!-- </div>-->
  779. <!-- <t t-if="foreign_currency">-->
  780. <!-- <t t-if="account.currency_id.id">-->
  781. <!-- &lt;!&ndash;## currency_name&ndash;&gt;-->
  782. <!-- <div class="act_as_cell" style="width: 4.43%;">-->
  783. <!-- <t t-set="domain"-->
  784. <!-- t-value="[('account_id', '=', account.account_id.id)]"/>-->
  785. <!-- <span t-field="account.currency_id.display_name"/>-->
  786. <!-- </div>-->
  787. <!-- &lt;!&ndash;## balance_currency&ndash;&gt;-->
  788. <!-- <div class="act_as_cell amount" style="width: 8.86%;">-->
  789. <!-- <t t-set="domain"-->
  790. <!-- t-value="[('account_id', '=', account.account_id.id),-->
  791. <!-- ('date', '&lt;', date_from.strftime('%Y-%m-%d'))]"/>-->
  792. <!-- <span>-->
  793. <!-- <a t-att-data-t-att-domain="domain"-->
  794. <!-- t-att-data-res-model="'account.move.line'"-->
  795. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  796. <!-- t-att-style="style">-->
  797. <!-- <t t-att-style="style" t-raw="account.initial_balance_foreign_currency" t-options="{'widget': 'monetary', 'display_currency': account.account_id.currency_id}"/></a>-->
  798. <!-- </span>-->
  799. <!-- </div>-->
  800. <!-- <div class="act_as_cell amount" style="width: 8.86%;">-->
  801. <!-- <t t-set="domain"-->
  802. <!-- t-value="[('account_id', '=', account.account_id.id)]"/>-->
  803. <!-- <span>-->
  804. <!-- <a t-att-data-t-att-domain="domain"-->
  805. <!-- t-att-data-res-model="'account.move.line'"-->
  806. <!-- class="o_account_financial_reports_web_action_monetary_multi"-->
  807. <!-- t-att-style="style" >-->
  808. <!-- <t t-att-style="style" t-raw="account.final_balance_foreign_currency" t-options="{'widget': 'monetary', 'display_currency': account.account_id.currency_id}"/></a>-->
  809. <!-- </span>-->
  810. <!-- </div>-->
  811. <!-- </t>-->
  812. <!-- <t t-if="not account.currency_id.id">-->
  813. <!-- <div class="act_as_cell" style="width: 4.43%;"/>-->
  814. <!-- <div class="act_as_cell" style="width: 8.86%;"/>-->
  815. <!-- <div class="act_as_cell" style="width: 8.86%;"/>-->
  816. <!-- </t>-->
  817. <!-- </t>-->
  818. <!-- </div>-->
  819. <!-- </div>-->
  820. <!-- </template>-->
  821. <template id="account_financial_report.report_trial_balance_account_footer">
  822. <!-- Display ending balance line for account or partner -->
  823. <div class="act_as_table list_table" style="width: 100%;">
  824. <div class="act_as_row labels" style="font-weight: bold;">
  825. <!--## date-->
  826. <div class="act_as_cell first_column" style="width: 33%;">
  827. <span t-esc="accounts_data[account_id]['code']" />
  828. -
  829. <span t-esc="accounts_data[account_id]['name']" />
  830. </div>
  831. <!--## Initial Balance-->
  832. <div class="act_as_cell amount" style="width: 9%;">
  833. <span
  834. t-esc="total_amount[account_id]['initial_balance']"
  835. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  836. />
  837. </div>
  838. <!--## Debit-->
  839. <div class="act_as_cell amount" style="width: 9%;">
  840. <span
  841. t-esc="total_amount[account_id]['debit']"
  842. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  843. />
  844. </div>
  845. <!--## Credit-->
  846. <div class="act_as_cell amount" style="width: 9%;">
  847. <span
  848. t-esc="total_amount[account_id]['credit']"
  849. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  850. />
  851. </div>
  852. <!--## Period balance-->
  853. <div class="act_as_cell amount" style="width: 9%;">
  854. <span
  855. t-esc="total_amount[account_id]['balance']"
  856. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  857. />
  858. </div>
  859. <!--## Ending balance-->
  860. <div class="act_as_cell amount" style="width: 9%;">
  861. <span
  862. t-esc="total_amount[account_id]['ending_balance']"
  863. t-options="{'widget': 'monetary', 'display_currency': company_currency}"
  864. />
  865. </div>
  866. <t t-if="foreign_currency">
  867. <!--## currency_name-->
  868. <div class="act_as_cell" style="width: 4%;" />
  869. <!--## amount_total_due_currency-->
  870. <div class="act_as_cell" style="width: 9%;" />
  871. <!--## amount_residual_currency-->
  872. <div class="act_as_cell" style="width: 9%;" />
  873. </t>
  874. </div>
  875. </div>
  876. </template>
  877. </odoo>