improve report

conv_bal
watcha.h@almacom.co.th 2015-04-30 22:47:56 +07:00
parent fe20240d78
commit a6a48ebf3f
2 changed files with 11 additions and 6 deletions

View File

@ -75,8 +75,6 @@ class VisitBoard(Model):
department_id=defaults.get("department_id",None)
branch_id=defaults.get("branch_id",None)
print('defaults ', defaults)
#user_id=get_active_user()
#set_active_user(1) #FIXME to allow user to see doctor different department
if ids:
obj=self.browse(ids)[0]
date_from=obj.date_from
@ -106,6 +104,7 @@ class VisitBoard(Model):
'no': '',
'number': '',
'visit_id': None,
'visit_state': '',
'cycle_name': '',
'cycle_color': '',
'department_id': None,
@ -171,7 +170,9 @@ class VisitBoard(Model):
elif hd_case_state=='in_progress':
#visit_color='#f9e37d'
visit_color=''
pass
elif hd_case_state=='cancelled':
visit_color='#dbdbdb',
hd_case_number="Cancelled"
number=visit.number
if number=='/':
number='Waiting'

View File

@ -31,12 +31,16 @@
{{else}}
<td style="background-color:{{cycle_color}};color:white;width:6%"><center>{{cycle_name}}</center></td>
<td style="background-color:{{visit_color}}">{{no}}</td>
<td style="background-color:{{visit_color}};width:8%">
<td style="background-color:{{visit_color}};width:12%">
<a href="/ui#name=clinic_visit&active_id={{visit_id}}&mode=form">
{{#ifeq number "Waiting"}}
<span class="glyphicon glyphicon-arrow-right">&nbsp;{{number}}</span>
{{else}}
{{number}}
{{#ifeq number "Cancelled"}}
<span class="glyphicon glyphicon-thumbs-down">&nbsp;{{number}}</span>
{{else}}
<span class="glyphicon glyphicon-thumbs-up">&nbsp;{{number}}</span>
{{/ifeq}}
{{/ifeq}}
</a>
</td>
@ -67,7 +71,7 @@
<span class="glyphicon glyphicon-refresh">
{{else}}
{{#ifeq hd_case_state "cancelled"}}
<span class="glyphicon glyphicon-ban-cycle">
<span class="glyphicon glyphicon-remove">
{{else}}
<span class="glyphicon glyphicon-ok">
{{/ifeq}}