Refactor Query.get() => Session.get() per SQLAlchemy 1.4
				
					
				
			This commit is contained in:
		
							parent
							
								
									20ab228032
								
							
						
					
					
						commit
						46f5db7460
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -2,7 +2,7 @@
 | 
			
		|||
################################################################################
 | 
			
		||||
#
 | 
			
		||||
#  Rattail -- Retail Software Framework
 | 
			
		||||
#  Copyright © 2010-2022 Lance Edgar
 | 
			
		||||
#  Copyright © 2010-2023 Lance Edgar
 | 
			
		||||
#
 | 
			
		||||
#  This file is part of Rattail.
 | 
			
		||||
#
 | 
			
		||||
| 
						 | 
				
			
			@ -65,7 +65,7 @@ class VendorCatalogView(base.VendorCatalogView):
 | 
			
		|||
        kwargs = super(VendorCatalogView, self).get_batch_kwargs(batch)
 | 
			
		||||
 | 
			
		||||
        if 'vendor_name' not in kwargs and batch.vendor_id:
 | 
			
		||||
            vendor = CoreOfficeSession.query(corepos.Vendor).get(batch.vendor_id)
 | 
			
		||||
            vendor = CoreOfficeSession.get(corepos.Vendor, batch.vendor_id)
 | 
			
		||||
            if vendor:
 | 
			
		||||
                kwargs['vendor_name'] = vendor.name
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue