207 lines
7.5 KiB
Plaintext
207 lines
7.5 KiB
Plaintext
extends layout_side
|
|
|
|
block content
|
|
style.
|
|
.slidingDiv {
|
|
height:180px;
|
|
|
|
}
|
|
.show_hide {
|
|
display:none;
|
|
}
|
|
script.
|
|
|
|
|
|
link(rel='stylesheet', href='https://use.fontawesome.com/releases/v5.6.1/css/all.css', integrity='sha384-gfdkjb5BdAXd+lj+gudLWI+BXq4IuLW5IT+brZEZsLFm++aCMlF1V92rMkPaX4PP', crossorigin='anonymous')
|
|
h2.contHeader #{title}
|
|
h4#userName(style='display:none') #{user.name}
|
|
h4#invoicemode(style='display:none') #{mode}
|
|
#darktable.container.bottompad
|
|
form.form-inline(style='margin-bottom:10px;padding-left:100px;')
|
|
i.fas.fa-search(aria-hidden='true', style='color:#ffffff;')
|
|
input#searchInvoices.form-control.form-control-sm.ml-3.w-75(type='text', placeholder='Keresés', aria-label='Keresés',style='margin-left:10px;width:400px;color: white;background-color:#2C3446;')
|
|
table#invoicesTable.container(style='width:90%;')
|
|
col(width='5%')
|
|
col(width='auto')
|
|
col(width='auto')
|
|
col(width='10%')
|
|
col(width='10%')
|
|
col(width='8%')
|
|
col(width='8%')
|
|
col(width='15%')
|
|
thead
|
|
tr
|
|
th
|
|
h1(style='text-align:center') #no
|
|
th
|
|
h1 Kibocsátó
|
|
th
|
|
h1(style='text-align:center') Számlaszám
|
|
th
|
|
h1(style='text-align:center') Kelt
|
|
th
|
|
h1(style='text-align:center') Esedékes
|
|
th
|
|
h1(style='text-align:center') Határidő
|
|
th
|
|
h1(style='text-align:center') Státusz
|
|
th
|
|
h1(style='text-align:center') Érték
|
|
tbody
|
|
each invoice, i in invoices
|
|
tr.clickable-row(id=invoice._id data-href="/invoices/details/"+invoice._id)
|
|
//-(data-href="/invoices/invoiceDetails/"+invoice._id, onclick='rowClick(data-href)')
|
|
td #{i+1}
|
|
td #{invoice.owner}
|
|
td(style='text-align:right') #{invoice.invoiceNumber}
|
|
td #{invoice.dateEmission}
|
|
// Fizetetlen
|
|
if (invoice.state===3)
|
|
if (invoice.delayed>0)
|
|
td(style='text-align:center') #{invoice.expiryDate} #{moment(invoice.expiryDate, "YYYY.MM.DD").add(invoice.delayed, 'days').format("YYYY.MM.DD")}
|
|
td(style='text-align:center')
|
|
span.badge #{invoice.daysLeft} + #{invoice.delayed}
|
|
td(style='text-align:center') Halasztva
|
|
else
|
|
td(style='text-align:center') #{invoice.expiryDate}
|
|
td(style='text-align:center')
|
|
span.badge #{invoice.daysLeft}
|
|
td(style='text-align:center') Fizetetlen
|
|
// Fizetett
|
|
if (invoice.state===0)
|
|
if (invoice.delayed>0)
|
|
td(style='text-align:center') #{invoice.expiryDate} #{moment(invoice.expiryDate, "YYYY.MM.DD").add(invoice.delayed, 'days').format("YYYY.MM.DD")}
|
|
td(style='text-align:center')
|
|
span.badge 0
|
|
else
|
|
td(style='text-align:center') #{invoice.expiryDate}
|
|
td(style='text-align:center')
|
|
span.badge 0
|
|
td(style='text-align:center') Fizetve
|
|
// Érték sor
|
|
if (invoice.currency==='HUF')
|
|
td(style='text-align:right') #{tsep(invoice.nPrice)+' HUF'}
|
|
if (invoice.currency==='EUR')
|
|
td(style='text-align:right') #{tsep(invoice.nPrice)+' EUR'}
|
|
if (invoice.currency==='USD')
|
|
td(style='text-align:right') #{tsep(invoice.nPrice)+' USD'}
|
|
.infoPanel.slidingDiv
|
|
.brand
|
|
|
|
i.fas.fa-chart-line(style='margin-left: 10px;font-size: 2em; color: #e1ffff;')
|
|
| Info board
|
|
.row
|
|
.col-md-3
|
|
.labelinfoHeader Kintlevőség
|
|
.labelinfoContent
|
|
section.productList
|
|
.product
|
|
//span.name Kintlevőség:
|
|
span.price#kl_huf
|
|
br
|
|
span.price#kl_eur
|
|
br
|
|
span.name
|
|
span.price#kl_usd
|
|
.col-md-3
|
|
.labelinfoHeader Tartozás
|
|
.labelinfoContent
|
|
section.productList
|
|
.product
|
|
//span.name Kintlevőség:
|
|
span.price#tart_huf
|
|
br
|
|
span.price#tart_eur
|
|
br
|
|
span.name
|
|
span.price#tart_usd
|
|
.col-md-3
|
|
.labelinfoHeader Havi Bevétel
|
|
.labelinfoContent
|
|
section.productList
|
|
.product
|
|
//span.name Kintlevőség:
|
|
span.price#bev_huf
|
|
br
|
|
span.price#bev_eur
|
|
br
|
|
span.name
|
|
span.price#bev_usd
|
|
script(src='/js/invoice.js')
|
|
script(src='/build/pdfmake.js')
|
|
script(src='/build/vfs_fonts.js')
|
|
script.
|
|
$(document).ready(function () {
|
|
$(".slidingDiv").slideDown();
|
|
$(".show_hide").show();
|
|
setTimeout(function() {
|
|
$(".slidingDiv").slideUp();
|
|
}, 5000); // <-- time in milliseconds
|
|
|
|
$('.show_hide').click(function(){
|
|
$(".slidingDiv").slideToggle();
|
|
});
|
|
|
|
$('#printBtn').removeClass("hide")
|
|
var local_data = "#{mode}"
|
|
|
|
//console.log('Local_data:'+local_data);
|
|
/*$('tr[data-href]').on("click", function() {
|
|
document.location = $(this).data('href');
|
|
});*/
|
|
|
|
if (local_data==='all')
|
|
$("#invoiceall").addClass("active");
|
|
// Bejövő számlák manü kibontása
|
|
if (local_data==='in')
|
|
{
|
|
$("#invoices_inh").click();
|
|
$("#invoiceslin").addClass("active");
|
|
}
|
|
if (local_data==='in-unpaid')
|
|
{
|
|
$("#invoices_inh").click();
|
|
$("#invoiceslinunpaid").addClass("active");
|
|
}
|
|
if (local_data==='in-month-pay')
|
|
{
|
|
$("#invoices_inh").click();
|
|
$("#invoiceslinmontpay").addClass("active");
|
|
}
|
|
if (local_data==='in-nextmonth-pay')
|
|
{
|
|
$("#invoices_inh").click();
|
|
$("#invoiceslinnextmontpay").addClass("active");
|
|
}
|
|
if (local_data==='in-paid')
|
|
{
|
|
$("#invoices_inh").click();
|
|
$("#invoiceslinpaid").addClass("active");
|
|
}
|
|
// Kimenő számlák manü kibontása
|
|
if (local_data==='out')
|
|
{
|
|
$("#invoices_outh").click();
|
|
$("#invoiceslOut").addClass("active");
|
|
}
|
|
if (local_data==='out-unpaid')
|
|
{
|
|
$("#invoices_outh").click();
|
|
$("#invoiceslOutunpaid").addClass("active");
|
|
}
|
|
if (local_data==='out-month-pay')
|
|
{
|
|
$("#invoices_outh").click();
|
|
$("#invoiceslOutmontpay").addClass("active");
|
|
}
|
|
if (local_data==='out-nextmonth-pay')
|
|
{
|
|
$("#invoices_outh").click();
|
|
$("#invoiceslOutnextmontpay").addClass("active");
|
|
}
|
|
if (local_data==='out-paid')
|
|
{
|
|
$("#invoices_outh").click();
|
|
$("#invoiceslOutpaid").addClass("active");
|
|
}
|
|
}) |