fix: add link to CORE for profile employee tab
This commit is contained in:
		
							parent
							
								
									af7deee26b
								
							
						
					
					
						commit
						4a3f4cf829
					
				
					 1 changed files with 12 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -80,6 +80,18 @@ class PersonViewSupplement(ViewSupplement):
 | 
			
		|||
 | 
			
		||||
        return context
 | 
			
		||||
 | 
			
		||||
    def get_context_for_employee(self, employee, context):
 | 
			
		||||
 | 
			
		||||
        if employee.corepos_number:
 | 
			
		||||
            app = self.get_rattail_app()
 | 
			
		||||
            corepos = app.get_corepos_handler()
 | 
			
		||||
            url = corepos.get_office_employee_url(employee.corepos_number)
 | 
			
		||||
            if url:
 | 
			
		||||
                context['external_links'].append({'label': "View in CORE Office",
 | 
			
		||||
                                                  'url': url})
 | 
			
		||||
 | 
			
		||||
        return context
 | 
			
		||||
 | 
			
		||||
    def get_member_xref_buttons(self, person):
 | 
			
		||||
        buttons = OrderedDict()
 | 
			
		||||
        app = self.get_rattail_app()
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue