Example #1
0
 def _inject_ursh_link(self,
                       target=None,
                       event=None,
                       dropdown=False,
                       element_class='',
                       text='',
                       **kwargs):
     if is_configured() and (target or event):
         return render_plugin_template('ursh_link.html',
                                       target=target,
                                       event=event,
                                       dropdown=dropdown,
                                       element_class=element_class,
                                       text=text,
                                       **kwargs)
 def _process(self):
     if not is_configured():
         raise NotFound('Plugin is not configured')
     return WPShortenURLPage.render_template('ursh_shortener_page.html')
Example #3
0
 def _inject_ursh_footer(self, **kwargs):
     if is_configured():
         return render_plugin_template('ursh_footer.html')