add print format and id to monthly salary register
This commit is contained in:
parent
d5ebd79ad7
commit
32c366508a
@ -0,0 +1,39 @@
|
||||
<div style="margin-bottom: 7px;" class="text-center">
|
||||
{%= frappe.boot.letter_heads[filters.letter_head || frappe.defaults.get_default("letter_head")] %}
|
||||
</div>
|
||||
<h2 class="text-center">{%= __(report.report_name) %}</h2>
|
||||
<h5 class="text-center">Fiscal Year: {%= filters.fiscal_year %}</h5>
|
||||
<h5 class="text-center">Month: {%= filters.month %}</h5>
|
||||
<hr>
|
||||
<table class="table table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
{% for(var i=1, l=report.columns.length; i<l; i++) { %}
|
||||
<th class="text-right">{%= report.columns[i].label %}</th>
|
||||
{% } %}
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for(var j=0, k=data.length; j<k; j++) { %}
|
||||
{%
|
||||
var row = data[j];
|
||||
%}
|
||||
<tr>
|
||||
{% for(var i=1, l=report.columns.length; i<l; i++) { %}
|
||||
<td class="text-right">
|
||||
{% var fieldname = report.columns[i].field; %}
|
||||
{% if (i > 10) { %}
|
||||
{%= format_currency(row[fieldname]) %}
|
||||
{% } else { %}
|
||||
{% if (!is_null(row[fieldname])) { %}
|
||||
{%= row[fieldname] %}
|
||||
{% } %}
|
||||
{% } %}
|
||||
</td>
|
||||
{% } %}
|
||||
</tr>
|
||||
{% } %}
|
||||
</tbody>
|
||||
</table>
|
||||
<p class="text-right text-muted">Printed On {%= dateutil.str_to_user(dateutil.get_datetime_as_string()) %}</p>
|
||||
|
@ -17,7 +17,7 @@ def execute(filters=None):
|
||||
|
||||
data = []
|
||||
for ss in salary_slips:
|
||||
row = [ss.employee, ss.employee_name, ss.branch, ss.department, ss.designation,
|
||||
row = [ss.name, ss.employee, ss.employee_name, ss.branch, ss.department, ss.designation,
|
||||
ss.company, ss.month, ss.leave_withut_pay, ss.payment_days]
|
||||
|
||||
for e in earning_types:
|
||||
@ -36,7 +36,7 @@ def execute(filters=None):
|
||||
|
||||
def get_columns(salary_slips):
|
||||
columns = [
|
||||
_("Employee") + ":Link/Employee:120", _("Employee Name") + "::140", _("Branch") + ":Link/Branch:120",
|
||||
_("Salary Slip ID") + ":Link/Salary Slip:150",_("Employee") + ":Link/Employee:120", _("Employee Name") + "::140", _("Branch") + ":Link/Branch:120",
|
||||
_("Department") + ":Link/Department:120", _("Designation") + ":Link/Designation:120",
|
||||
_("Company") + ":Link/Company:120", _("Month") + "::80", _("Leave Without Pay") + ":Float:130",
|
||||
_("Payment Days") + ":Float:120"
|
||||
|
Loading…
x
Reference in New Issue
Block a user