Subversion Repositories SmartDukaan

Rev

Rev 17771 | Rev 17936 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 17771 Rev 17788
Line 817... Line 817...
817
            try:
817
            try:
818
                if item[0]['showVideo']==0:
818
                if item[0]['showVideo']==0:
819
                    item[0]['videoLink'] =""
819
                    item[0]['videoLink'] =""
820
            except:
820
            except:
821
                item[0]['videoLink'] =""
821
                item[0]['videoLink'] =""
822
            try:
822
#             try:
823
                if item[0]['quantity'] >1:
823
#                 if item[0]['quantity'] >1:
824
                    ppq = float(item[0]['available_price'])/item[0]['quantity']
824
#                     ppq = float(item[0]['available_price'])/item[0]['quantity']
825
                    
825
#                     
826
                    if ppq == round(ppq):
826
#                     if ppq == round(ppq):
827
                        item[0]['ppq'] = int(ppq)
827
#                         item[0]['ppq'] = int(ppq)
828
                    else:
828
#                     else:
829
                        item[0]['ppq'] = round(ppq,2)
829
#                         item[0]['ppq'] = round(ppq,2)
830
                    item[0]['tagline'] = ""
830
#                     item[0]['tagline'] = ""
831
                else:
831
#                 else:
832
                    item[0]['ppq'] = 0
832
#                     item[0]['ppq'] = 0
833
            except:
833
#             except:
834
                item[0]['ppq'] = 0
834
#                 item[0]['ppq'] = 0
835
            if filterData is None:
835
            if filterData is None:
836
                if item[0]['category_id']!=6:
836
                if item[0]['category_id']!=6:
837
                    try:
837
                    try:
838
                        item[0]['filterLink'] = '/category/'+str(int(item[0]['category_id']))+'?filter=brand&brands='+str(int(item[0]['brand_id']))
838
                        item[0]['filterLink'] = '/category/'+str(int(item[0]['category_id']))+'?filter=brand&brands='+str(int(item[0]['brand_id']))
839
                        item[0]['filterText'] = 'More %s items'%(item[0]['brand'])
839
                        item[0]['filterText'] = 'More %s items'%(item[0]['brand'])