forked from open-webui/open-webui
		
	feat: wip chat route
This commit is contained in:
		
							parent
							
								
									9174331025
								
							
						
					
					
						commit
						540b50e176
					
				
					 2 changed files with 13 additions and 3 deletions
				
			
		| 
						 | 
				
			
			@ -88,7 +88,10 @@ class ChatTable:
 | 
			
		|||
    ) -> List[ChatModel]:
 | 
			
		||||
        return [
 | 
			
		||||
            ChatModel(**model_to_dict(chat))
 | 
			
		||||
            for chat in Chat.select(Chat.user_id == user_id).limit(limit).offset(skip)
 | 
			
		||||
            for chat in Chat.select(Chat.id, Chat.title)
 | 
			
		||||
            .where(Chat.user_id == user_id)
 | 
			
		||||
            .limit(limit)
 | 
			
		||||
            .offset(skip)
 | 
			
		||||
        ]
 | 
			
		||||
 | 
			
		||||
    def get_chat_by_id_and_user_id(self, id: str, user_id: str) -> Optional[ChatModel]:
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue