report staff fee
parent
93fbd6c64b
commit
54738bce05
|
@ -73,10 +73,10 @@ class ReportStaffFeeDetail(Model):
|
|||
if staff_type:
|
||||
dom.append(['staff_id.type','=',staff_type])
|
||||
staff_name=''
|
||||
show_qty=False
|
||||
if staff_id:
|
||||
staff=get_model("clinic.staff").browse(staff_id)
|
||||
staff_name=staff.name
|
||||
dom.append(['staff_id','=',staff.id])
|
||||
dom.append(['staff_id','=',staff_id])
|
||||
show_qty=True
|
||||
dlines=get_model('clinic.labor.cost.line').search_browse(dom)
|
||||
# group by date
|
||||
all_vals={}
|
||||
|
@ -123,6 +123,11 @@ class ReportStaffFeeDetail(Model):
|
|||
start=int(time_start[8:10])
|
||||
stop=int(time_stop[8:10])
|
||||
diff=stop-start
|
||||
branch_name=''
|
||||
if branch:
|
||||
branch_name='(%s)'%branch.name or ''
|
||||
if department:
|
||||
branch_name='(%s)'%department.name or ''
|
||||
data={
|
||||
'company_name': company.name or "",
|
||||
'parent_company_name': company.parent_id.name or "",
|
||||
|
@ -135,6 +140,8 @@ class ReportStaffFeeDetail(Model):
|
|||
'to': time_stop,
|
||||
'is_duration': diff+1 < total_day,
|
||||
'year': year,
|
||||
'branch_name': branch_name,
|
||||
'show_qty': show_qty,
|
||||
}
|
||||
return data
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<center>
|
||||
<h2>ผลตอบแทนดูแลผู้ป่วย</h2>
|
||||
<h3>
|
||||
{{parent_company_name}} {{company_name}}<br/>
|
||||
{{parent_company_name}} {{company_name}}{{branch_name}}<br/>
|
||||
</h3>
|
||||
<h4>
|
||||
{{staff_name}}
|
||||
|
@ -51,9 +51,15 @@
|
|||
{{/unless}}
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th style="text-align:right">รวม</th>
|
||||
<th style="text-align:right">{{currency total_amount}}</th>
|
||||
{{#if show_qty}}
|
||||
<th style="text-align:right">รวม</th>
|
||||
<th style="text-align:right">{{total_qty}}</th>
|
||||
<th style="text-align:right">{{currency total_amount}}</th>
|
||||
{{else}}
|
||||
<th></th>
|
||||
<th style="text-align:right">รวม</th>
|
||||
<th style="text-align:right">{{currency total_amount}}</th>
|
||||
{{/if}}
|
||||
</tfoot>
|
||||
</table>
|
||||
{{else}}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<center>
|
||||
<h2>ผลตอบแทนดูแลผู้ป่วย</h2>
|
||||
<h2>รายละเอียดผลตอบแทนดูแลผู้ป่วย</h2>
|
||||
<h3>
|
||||
{{parent_company_name}} {{company_name}}<br/>
|
||||
</h3>
|
||||
|
|
Loading…
Reference in New Issue