def save(self, *args, **kwargs): self.abstract_markup = mark_safe( formatter(self.abstract, filter_name=self.markup)) self.body_markup = mark_safe( formatter(self.body, filter_name=self.markup)) if self.markup == "restructuredtext": self.abstract_markup = unescape_inline(self.abstract_markup) self.body_markup = unescape_inline(self.body_markup) super(Story, self).save(*args, **kwargs)
def save(self, *args, **kwargs): self.abstract_markup = mark_safe( formatter(self.abstract, filter_name=self.markup)) self.body_markup = mark_safe( formatter(self.body, filter_name=self.markup)) if self.markup == "restructuredtext": self.abstract_markup = unescape_inline(self.abstract_markup) self.body_markup = unescape_inline(self.body_markup) super(Story, self).save(*args, **kwargs)
def save(self, *args, **kwargs): self.abstract_markup = mark_safe( formatter(self.abstract, filter_name=self.markup)) self.body_markup = mark_safe( formatter(self.body, filter_name=self.markup)) if self.markup == "restructuredtext": self.abstract_markup = unescape_inline(self.abstract_markup) self.body_markup = unescape_inline(self.body_markup) super(Story, self).save(*args, **kwargs) if self.status == PUBLIC: try: ping_google() except: pass
def save(self, *args, **kwargs): self.abstract_markup = mark_safe( formatter(self.abstract, filter_name=self.markup)) self.body_markup = mark_safe( formatter(self.body, filter_name=self.markup)) if self.markup == "restructuredtext": self.abstract_markup = unescape_inline(self.abstract_markup) self.body_markup = unescape_inline(self.body_markup) super(Story, self).save(*args, **kwargs) if self.status == PUBLIC: try: ping_google() except: pass
def save(self, *args, **kwargs): self.site_id = settings.SITE_ID self.abstract_markup = mark_safe( formatter(self.abstract, filter_name=self.markup)) self.body_markup = mark_safe( formatter(self.body, filter_name=self.markup)) if self.markup == "restructuredtext": self.abstract_markup = unescape_inline(self.abstract_markup) self.body_markup = unescape_inline(self.body_markup) super(Story, self).save(*args, **kwargs) if self.status == 3: # public blog_config = Config.get_current() ping_google = getattr(blog_config, "ping_google", False) if ping_google: try: ping_google() except: pass