dash.contrib.plugins.url package

Submodules

dash.contrib.plugins.url.admin module

dash.contrib.plugins.url.apps module

class dash.contrib.plugins.url.apps.Config(app_name, app_module)[source]

Bases: django.apps.config.AppConfig

label = 'dash.contrib.plugins.url'
name = 'dash.contrib.plugins.url'

dash.contrib.plugins.url.conf module

dash.contrib.plugins.url.conf.get_setting(setting, override=None)[source]

Get a setting from dash.contrib.plugins.url conf module, falling back to the default.

If override is not None, it will be used instead of the setting.

Parameters:
  • setting – String with setting name
  • override – Value to use when no setting is available. Defaults to None.
Returns:

Setting value.

dash.contrib.plugins.url.dash_plugins module

class dash.contrib.plugins.url.dash_plugins.BaseURLPlugin(layout_uid, placeholder_uid, workspace=None, user=None, position=None)[source]

Bases: dash.base.BaseDashboardPlugin

Base URL plugin.

form

alias of URLForm

group = <django.utils.functional.__proxy__ object at 0x7f10ff43a890>
html_class[source]

If plugin has an image, we add a class iconic to it.

name = <django.utils.functional.__proxy__ object at 0x7f10ff43a7d0>

dash.contrib.plugins.url.dash_widgets module

class dash.contrib.plugins.url.dash_widgets.BaseURLWidget(plugin)[source]

Bases: dash.base.BaseDashboardPluginWidget

URL plugin widget.

render(request=None)[source]
class dash.contrib.plugins.url.dash_widgets.BaseBookmarkWidget(plugin)[source]

Bases: dash.base.BaseDashboardPluginWidget

Bookmark plugin widget.

render(request=None)[source]
class dash.contrib.plugins.url.dash_widgets.URL1x1Widget(plugin)[source]

Bases: dash.contrib.plugins.url.dash_widgets.BaseURLWidget

URL plugin 1x1 widget.

plugin_uid = 'url_1x1'
class dash.contrib.plugins.url.dash_widgets.URL2x2Widget(plugin)[source]

Bases: dash.contrib.plugins.url.dash_widgets.BaseURLWidget

URL plugin 2x2 widget.

cols = 2
plugin_uid = 'url_2x2'
rows = 2

dash.contrib.plugins.url.defaults module

dash.contrib.plugins.url.forms module

class dash.contrib.plugins.url.forms.URLForm(*args, **kwargs)[source]

Bases: django.forms.forms.Form, dash.base.DashboardPluginFormBase

URL form for BaseURLPlugin plugin.

class Media[source]
css = {'all': ('css/dash_plugin_url_form.css',)}
js = ('js/dash_plugin_url_form.js',)
URLForm.base_fields = OrderedDict([('title', <django.forms.fields.CharField object at 0x7f10ff44ed90>), ('url', <django.forms.fields.URLField object at 0x7f10ff44ee50>), ('external', <django.forms.fields.BooleanField object at 0x7f10ff44ef10>), ('image', <django.forms.fields.ChoiceField object at 0x7f10ff44efd0>)])
URLForm.declared_fields = OrderedDict([('title', <django.forms.fields.CharField object at 0x7f10ff44ed90>), ('url', <django.forms.fields.URLField object at 0x7f10ff44ee50>), ('external', <django.forms.fields.BooleanField object at 0x7f10ff44ef10>), ('image', <django.forms.fields.ChoiceField object at 0x7f10ff44efd0>)])
URLForm.media
URLForm.plugin_data_fields = [('title', ''), ('url', ''), ('external', False), ('image', '')]
class dash.contrib.plugins.url.forms.BookmarkForm(data=None, files=None, auto_id=u'id_%s', prefix=None, initial=None, error_class=<class 'django.forms.utils.ErrorList'>, label_suffix=None, empty_permitted=False)[source]

Bases: django.forms.forms.Form, dash.base.DashboardPluginFormBase

Bookmark form for BaseBookmarkPlugin plugin.

class Media[source]
css = {'all': ('css/dash_plugin_url_form.css',)}
js = ('js/dash_plugin_url_form.js',)
BookmarkForm.base_fields = OrderedDict([('bookmark', <django.forms.models.ModelChoiceField object at 0x7f10ff450210>)])
BookmarkForm.declared_fields = OrderedDict([('bookmark', <django.forms.models.ModelChoiceField object at 0x7f10ff450210>)])
BookmarkForm.media
BookmarkForm.plugin_data_fields = [('bookmark', ''), ('title', ''), ('url', ''), ('external', False), ('image', '')]
BookmarkForm.save_plugin_data(request=None)[source]

Saving the plugin data and moving the file.

dash.contrib.plugins.url.models module

class dash.contrib.plugins.url.models.Bookmark(*args, **kwargs)[source]

Bases: django.db.models.base.Model

Bookmark.

  • title (string): Bookmark title.
  • url (string): Bookmark URL.
  • external (bool): External/internal link.
  • image (string): Bookmark image icon.
exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception Bookmark.MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

Bookmark.get_image_display(*moreargs, **morekwargs)
Bookmark.objects = <django.db.models.manager.Manager object at 0x7f10ff44ed10>

dash.contrib.plugins.url.settings module

Module contents