django model returning multiple values -
i have convert of code django php
here sample code:
def loadproduct(id=0) if id==0: product=baseproduct.products.all()[0]; else: product = baseproduct.objects.get(id=id); color = product.color images = color.images.all(); return {'product':product, 'color':{'color':color, 'images':images}}
now have basic knowledge of django..
not able understand return type in this...
can 1 me on this...
the method returning dictionary, equivalent associative array in php.
Comments
Post a Comment