salix/modules/invoiceOut/front/index/index.html

86 lines
3.3 KiB
HTML

<vn-crud-model
vn-id="model"
url="/api/InvoiceOuts/filter"
limit="20"
data="invoiceOuts"
order="issued DESC">
</vn-crud-model>
<div class="content-block">
<vn-card class="vn-pa-md vn-w-sm">
<vn-searchbar
panel="vn-invoice-search-panel"
on-search="$ctrl.onSearch($params)"
info="Search invoices by reference"
vn-focus>
</vn-searchbar>
</vn-card>
<vn-data-viewer
model="model"
class="vn-w-md vn-my-md">
<vn-card>
<vn-table model="model">
<vn-thead>
<vn-tr>
<vn-th field="ref">Reference</vn-th>
<vn-th field="issued">Issued</vn-th>
<vn-th field="amount" number>Amount</vn-th>
<vn-th field="clientFk">Client</vn-th>
<vn-th field="created">Created</vn-th>
<vn-th field="companyFk">Company</vn-th>
<vn-th field="dued">Due date</vn-th>
<vn-th></vn-th>
<vn-th></vn-th>
</vn-tr>
</vn-thead>
<vn-tbody>
<a ng-repeat="invoiceOut in invoiceOuts"
class="clickable vn-tr searchResult"
ui-sref="invoiceOut.card.summary({id: {{::invoiceOut.id}}})">
<vn-td>{{::invoiceOut.ref | dashIfEmpty}}</vn-td>
<vn-td>{{::invoiceOut.issued | date:'dd/MM/yyyy' | dashIfEmpty}}</vn-td>
<vn-td number>{{::invoiceOut.amount | currency: 'EUR': 2 | dashIfEmpty}}</vn-td>
<vn-td>
<span
class="link"
ng-click="$ctrl.showClientDescriptor($event, invoiceOut.clientFk)">
{{::invoiceOut.clientSocialName | dashIfEmpty}}
</span>
</vn-td>
<vn-td>{{::invoiceOut.created | date:'dd/MM/yyyy' | dashIfEmpty}}</vn-td>
<vn-td>{{::invoiceOut.companyCode | dashIfEmpty}}</vn-td>
<vn-td>{{::invoiceOut.dued | date:'dd/MM/yyyy' | dashIfEmpty}}</vn-td>
<vn-td>
<vn-icon-button
ng-show="invoiceOut.hasPdf"
ng-click="$ctrl.openPdf(invoiceOut.id, $event)"
icon="cloud_download"
title="Download PDF"
vn-tooltip="Download PDF">
</vn-icon-button>
</vn-td>
<vn-td>
<vn-icon-button
ng-click="$ctrl.preview($event, invoiceOut)"
vn-tooltip="Preview"
icon="desktop_windows">
</vn-icon-button>
</vn-td>
</a>
</vn-tbody>
</vn-table>
</vn-card>
</vn-data-viewer>
</div>
<vn-dialog
vn-id="summary"
class="dialog-summary">
<tpl-body>
<vn-invoice-out-summary
invoice-out="$ctrl.selectedInvoiceOut">
</vn-invoice-out-summary>
</tpl-body>
</vn-dialog>
<vn-client-descriptor-popover
vn-id="clientDescriptor">
</vn-client-descriptor-popover>
<vn-scroll-up></vn-scroll-up>