Beispiel #1
0
def unique_slug(name):
    return '%s-%s' % (slugify(name), get_random_hash())
Beispiel #2
0
 def save(self, *args, **kwargs):
     if not self.hash:
         self.hash = get_random_hash()
     super(LocalOffer, self).save(*args, **kwargs)