Add unit_of_measure to product detail view.
				
					
				
			This commit is contained in:
		
							parent
							
								
									d50aef4e49
								
							
						
					
					
						commit
						6ea032c591
					
				
					 1 changed files with 5 additions and 1 deletions
				
			
		|  | @ -37,9 +37,11 @@ from webhelpers.html.tags import link_to | |||
| from pyramid.httpexceptions import HTTPFound | ||||
| from pyramid.renderers import render_to_response | ||||
| 
 | ||||
| from . import SearchableAlchemyGridView | ||||
| from tailbone.views import SearchableAlchemyGridView | ||||
| from tailbone.forms import EnumFieldRenderer | ||||
| 
 | ||||
| import rattail.labels | ||||
| from rattail import enum | ||||
| from rattail import sil | ||||
| from rattail import batches | ||||
| from rattail.threads import Thread | ||||
|  | @ -269,6 +271,7 @@ class ProductCrud(CrudView): | |||
|         fs = self.make_fieldset(model) | ||||
|         fs.upc.set(renderer=GPCFieldRenderer) | ||||
|         fs.brand.set(options=[]) | ||||
|         fs.unit_of_measure.set(renderer=EnumFieldRenderer(enum.UNIT_OF_MEASURE)) | ||||
|         fs.regular_price.set(renderer=PriceFieldRenderer) | ||||
|         fs.current_price.set(renderer=PriceFieldRenderer) | ||||
|         fs.configure( | ||||
|  | @ -277,6 +280,7 @@ class ProductCrud(CrudView): | |||
|                 fs.brand.with_renderer(BrandFieldRenderer), | ||||
|                 fs.description, | ||||
|                 fs.size, | ||||
|                 fs.unit_of_measure.label("Unit of Measure"), | ||||
|                 fs.case_pack, | ||||
|                 fs.department, | ||||
|                 fs.subdepartment, | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Lance Edgar
						Lance Edgar