| 1 | <?xml version="1.0" encoding="UTF-8" ?> |
| 2 | <templates> |
| 3 | <t t-name="stock_account.StockValuationReport.InventoryValuationLine"> |
| 4 | <tr t-att-class="cssClass"> |
| 5 | <td class="line_name w-50" t-on-click="onClick"> |
| 6 | <div class="wrapper"> |
| 7 | <t t-if="label"> |
| 8 | <a t-if="props.onClickMethod" href="#" t-out="label"/> |
| 9 | <span t-else="" t-out="label"/> |
| 10 | </t> |
| 11 | </div> |
| 12 | </td> |
| 13 | <td class="w-25"> |
| 14 | <div t-if="formattedValue" t-out="formattedValue"/> |
| 15 | <div t-elif="debit" t-out="debit"/> |
| 16 | </td> |
| 17 | <td t-if="credit" class="w-25"> |
| 18 | <div t-out="credit"/> |
| 19 | </td> |
| 20 | <td t-else="" t-on-click="onClickToggle" class="w-25"> |
| 21 | <button t-attf-class="btn btn_foldable#{props.sublines ? '' : '_empty'}" |
| 22 | t-att-tabindex="props.lines ? 0 : -1"> |
| 23 | <i t-if="hasSublines" |
| 24 | t-attf-class="fa fa-folder#{state.displaySublines ? '-open' : ''}-o"/> |
| 25 | </button> |
| 26 | </td> |
| 27 | </tr> |
| 28 | <t t-if="state.displaySublines && hasSublines"> |
| 29 | <t t-if="props.displayDebitCredit"> |
| 30 | <tr> |
| 31 | <td/> |
| 32 | <td>Debit</td> |
| 33 | <td>Credit</td> |
| 34 | </tr> |
| 35 | </t> |
| 36 | <t t-foreach="props.sublines" t-as="line" t-key="line.account_id"> |
| 37 | <StockValuationReportLine |
| 38 | label="line.display_name || line.label" |
| 39 | line="line" |
| 40 | sublines="line.lines" |
| 41 | level="props.level + 2" |
| 42 | onClickMethod="line.method" |
| 43 | value="line.value"/> |
| 44 | </t> |
| 45 | </t> |
| 46 | </t> |
| 47 | </templates> |