Subversion Repositories SmartDukaan

Rev

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

Rev 16738 Rev 16742
Line 112... Line 112...
112
                    existingAppOffer.show = True
112
                    existingAppOffer.show = True
113
                    existingAppOffer.offer_active = True
113
                    existingAppOffer.offer_active = True
114
                    app_offer.show = False
114
                    app_offer.show = False
115
    else:
115
    else:
116
        try:
116
        try:
-
 
117
            offerPrice = float(offer['offerPrice'])
-
 
118
            if app_offer.override_payout:
-
 
119
                ratio = float(app_offer.overriden_payout)/float(app_offer.offer_price)
-
 
120
                app_offer.overriden_payout = math.floor(ratio*float(offer['offerPrice']))
-
 
121
            
117
            app_offer.offer_price = float(offer['offerPrice'])
122
            app_offer.offer_price = float(offer['offerPrice'])
118
        except:
123
        except:
119
            app_offer.offer_price = 0.0
124
            app_offer.offer_price = 0.0
120
        app_offer.user_payout = math.floor(.64 * app_offer.offer_price)
125
        app_offer.user_payout = math.floor(.64 * float(offer['offerPrice']))
121
        app_offer.description = input_json.get('description')
126
        app_offer.description = input_json.get('description')
122
        app_offer.shortDescription = offer.get('shortDesc')
127
        app_offer.shortDescription = offer.get('shortDesc')
123
        app_offer.longDescription = offer.get('longDesc')
128
        app_offer.longDescription = offer.get('longDesc')
124
        app_offer.link = offer.get('url')
129
        app_offer.link = offer.get('url')
125
        app_offer.offerCategory = offer.get('offerCategory')
130
        app_offer.offerCategory = offer.get('offerCategory')