def message(self):
     return str(
         self.shpe
     ) + ' de ' + prettyPrice(self.old_price, '') + ' a ' + prettyPrice(
         self.new_price, ''
     ) + ' (<a href="' + self.shpe.url + '">Link</a> / <a href="/admin/cotizador/storehasproductentity/' + str(
         self.shpe.id) + '/">Editar</a>)'
Beispiel #2
0
    def pretty_min_price(self):
        if self.shp:
            if hasattr(self, 'is_sponsored'):
                price = prettyPrice(self.sponsored_shp.shpe.latest_price)
            else:
                if hasattr(self, 'tier'):
                    tier = self.tier
                else:
                    tier = self.pricing.best_tier
                    if not tier:
                        return '0'

                cellphone_price = tier.cellphone_price
                plan_price = tier.monthly_quota
                if plan_price:
                    price = prettyPrice(
                        cellphone_price
                    ) + '<br /><span class="cell_pricing_span"> con plan de ' + prettyPrice(
                        plan_price) + '</span>'
                else:
                    price = prettyPrice(
                        cellphone_price
                    ) + '<br /><span class="cell_pricing_span"> con plan prepago</span>'
            return price
        else:
            return 'No disponible'
Beispiel #3
0
 def message(self):
     return str(
         self.product
     ) + ' de ' + prettyPrice(self.old_price, '') + ' a ' + prettyPrice(
         self.new_price, ''
     ) + ' (<a href="/' + self.product.ptype.urlname + '/' + str(
         self.product.id
     ) + '/">Link</a> / <a href="/admin/cotizador/' + self.product.ptype.adminurlname + '/' + str(
         self.product.id) + '/">Editar</a>)'
 def message(self):
     return (
         str(self.shpe)
         + " de "
         + prettyPrice(self.old_price, "")
         + " a "
         + prettyPrice(self.new_price, "")
         + ' (<a href="'
         + self.shpe.url
         + '">Link</a> / <a href="/admin/cotizador/storehasproductentity/'
         + str(self.shpe.id)
         + '/">Editar</a>)'
     )
 def prettyRepr(self):
     months = [
         'Enero', 'Febrero', 'Marzo', 'Abril', 'Mayo', 'Junio', 'Julio',
         'Agosto', 'Septiembre', 'Octubre', 'Noviembre', 'Diciembre'
     ]
     return unicode(self.date.day) + ' de ' + months[
         self.date.month - 1] + ' de ' + unicode(
             self.date.year) + ': ' + prettyPrice(self.price)
Beispiel #6
0
 def pretty_min_price(self):
     if self.shp:
         if hasattr(self, 'is_sponsored'):
             price = prettyPrice(self.sponsored_shp.shpe.latest_price)
         else:
             if hasattr(self, 'tier'):
                 tier = self.tier
             else:
                 tier = self.pricing.best_tier
                 if not tier:
                     return '0'
                 
             cellphone_price = tier.cellphone_price
             plan_price = tier.monthly_quota
             if plan_price:
                 price = prettyPrice(cellphone_price) + '<br /><span class="cell_pricing_span"> con plan de ' + prettyPrice(plan_price) + '</span>'
             else:
                 price = prettyPrice(cellphone_price) + '<br /><span class="cell_pricing_span"> con plan prepago</span>'
         return price
     else:
         return 'No disponible'
 def pretty_price(self):
     return prettyPrice(self.latest_price)
Beispiel #8
0
 def pretty_price(self):
     return prettyPrice(self.latest_price)
 def message(self):
     return str(self.product) + ' de ' + prettyPrice(self.old_price, '') + ' a ' + prettyPrice(self.new_price, '') + ' (<a href="/' + self.product.ptype.urlname + '/' + str(self.product.id) + '/">Link</a> / <a href="/admin/cotizador/' + self.product.ptype.adminurlname + '/' + str(self.product.id) + '/">Editar</a>)'
 def prettyPrice(self):
     utils.prettyPrice(self.price)
Beispiel #11
0
 def pretty_min_price(self):
     if self.shp:
         return prettyPrice(self.latest_price())
     else:
         return 'No disp.'
 def prettyRepr(self):
     months = ['Enero', 'Febrero', 'Marzo', 'Abril', 'Mayo', 'Junio', 'Julio',
               'Agosto', 'Septiembre', 'Octubre', 'Noviembre', 'Diciembre']
     return unicode(self.date.day) + ' de ' + months[self.date.month - 1] + ' de ' + unicode(self.date.year) + ': ' + prettyPrice(self.price)