What I want to achieve is to make the parent accounts subtotals appear below their children accounts. I tried switching their order in <tr> tag but still it won't reflect to the report.
Example in account/views/report_trialbalance.xml
<xpath expr="//table[@class='table table-condensed']/tbody" position="replace"><tbody><t t-foreach="lines(data['form'])" t-as="childrenaccount">
<tr t-if="childrenaccount['type'] == 'view'"> <t t-set="style" t-value="'font-weight:bold;'"/> <td> <span t-att-style="style" t-esc="childrenaccount['code']"/> </td> <td> <span style="color: white;" t-esc="'.' * (childrenaccount['level'] - 1)"/> <span t-att-style="style" t-esc="childrenaccount['name']"/> </td> <td class="text-right"> <span t-att-style="style" t-esc="childrenaccount['debit']"/> </td> <td class="text-right"> <span t-att-style="style" t-esc="childrenaccount['credit']"/> </td> <td class="text-right"> <span t-att-style="style" t-esc="formatLang(childrenaccount['balance'], currency_obj=res_company.currency_id)"/> </td> </tr> <tr t-if="childrenaccount['type'] != 'view'"> <t t-set="style" t-value="'font-weight:normal;'"/>
<td> <span t-att-style="style" t-esc="childrenaccount['code']"/> </td> <td> <span style="color: white;" t-esc="'.' * (childrenaccount['level'] - 1)"/> <span t-att-style="style" t-esc="childrenaccount['name']"/> </td> <td class="text-right"> <span t-att-style="style" t-esc="childrenaccount['debit']"/> </td> <td class="text-right"> <span t-att-style="style" t-esc="childrenaccount['credit']"/> </td> <td class="text-right"> <span t-att-style="style" t-esc="formatLang(childrenaccount['balance'], currency_obj=res_company.currency_id)"/> </td> </tr> <tr t-if="childrenaccount['type'] == 'view'"> <t t-set="style" t-value="'font-weight:bold;color:blue;'"/>
<td colspan="2"> <span style="color:white;">...</span> </td> <td class="text-right"> <span t-att-style="style" t-esc="childrenaccount['debit']"/> </td> <td class="text-right"> <span t-att-style="style" t-esc="childrenaccount['credit']"/> </td> <td class="text-right"> <span t-att-style="style" t-esc="formatLang(childrenaccount['balance'], currency_obj=res_company.currency_id)"/> </td> </tr></t></tbody></xpath>