improve report
							parent
							
								
									fe20240d78
								
							
						
					
					
						commit
						a6a48ebf3f
					
				| 
						 | 
				
			
			@ -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'
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -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"> {{number}}</span>
 | 
			
		||||
                                {{else}}
 | 
			
		||||
                                    {{number}}
 | 
			
		||||
                                    {{#ifeq number "Cancelled"}}
 | 
			
		||||
                                        <span class="glyphicon glyphicon-thumbs-down"> {{number}}</span>
 | 
			
		||||
                                    {{else}}
 | 
			
		||||
                                        <span class="glyphicon glyphicon-thumbs-up"> {{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}}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue