You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					
					
						
							14 lines
						
					
					
						
							528 B
						
					
					
				
			
		
		
		
			
			
			
		
		
	
	
							14 lines
						
					
					
						
							528 B
						
					
					
				
								from odoo import http
							 | 
						|
								from odoo.http import request
							 | 
						|
								
							 | 
						|
								
							 | 
						|
								class TicketSearch(http.Controller):
							 | 
						|
								    @http.route(['/ticketsearch'], type='json', auth="public", website=True)
							 | 
						|
								    def ticket_search(self,**kwargs):
							 | 
						|
								        search_value = kwargs.get("search_value")
							 | 
						|
								        tickets = request.env["help.ticket"].search([('name', '=', search_value)])
							 | 
						|
								        values = {
							 | 
						|
								            'tickets': tickets,
							 | 
						|
								        }
							 | 
						|
								        response = http.Response(template='odoo_website_helpdesk.ticket_table',qcontext=values)
							 | 
						|
								        return response.render()
							 |