mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Ability to download the statement
This commit is contained in:
parent
289c4952a0
commit
42daa83a9c
9
resources/js/clients/statements/view.js
vendored
9
resources/js/clients/statements/view.js
vendored
@ -80,6 +80,15 @@ class Statement {
|
||||
|
||||
handle() {
|
||||
this.bindEventListeners();
|
||||
|
||||
document
|
||||
.querySelector('#pdf-download')
|
||||
.addEventListener('click', () => {
|
||||
let url = new URL(this.composedUrl);
|
||||
url.searchParams.append('download', 1);
|
||||
|
||||
window.location.href = url.href;
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -31,7 +31,7 @@
|
||||
<span class="ml-2">{{ ctrans('texts.show_aging') }}</span>
|
||||
</label> <!-- End show aging checkbox -->
|
||||
</div>
|
||||
<button class="button button-primary bg-primary mt-4 md:mt-0">{{ ctrans('texts.download') }}</button>
|
||||
<button id="pdf-download" class="button button-primary bg-primary mt-4 md:mt-0">{{ ctrans('texts.download') }}</button>
|
||||
</div>
|
||||
|
||||
@include('portal.ninja2020.components.pdf-viewer', ['url' => route('client.statement.raw')])
|
||||
|
Loading…
x
Reference in New Issue
Block a user