shuup.front.apps.saved_carts package

Submodules

shuup.front.apps.saved_carts.dashboard_items module

class shuup.front.apps.saved_carts.dashboard_items.SavedCartsItem(request)[source]

Bases: DashboardItem

template_name = 'shuup/saved_carts/dashboard_item.jinja'

Title shown in dashboard menu and in dashboard

title = 'Saved Carts'

Sequence number of dashboard item

icon = 'fa fa-shopping-cart'

Text for dashboard

If your dashboard item shows single object, Edit is just fine but if you are listing objects, Show All might be better.

get_context()[source]

Get context for template

This is usually overridden in subclasses.

Returns:

Dict of context items

Return type:

dict

shuup.front.apps.saved_carts.urls module

shuup.front.apps.saved_carts.views module

class shuup.front.apps.saved_carts.views.CartViewMixin[source]

Bases: object

model

alias of StoredBasket

get_queryset()[source]
class shuup.front.apps.saved_carts.views.CartListView(**kwargs)[source]

Bases: DashboardViewMixin, CartViewMixin, ListView

Constructor. Called in the URLconf; can contain helpful extra keyword arguments, and other things.

template_name = 'shuup/saved_carts/cart_list.jinja'
context_object_name = 'carts'
class shuup.front.apps.saved_carts.views.CartDetailView(**kwargs)[source]

Bases: DashboardViewMixin, CartViewMixin, DetailView

Constructor. Called in the URLconf; can contain helpful extra keyword arguments, and other things.

template_name = 'shuup/saved_carts/cart_detail.jinja'
context_object_name = 'cart'
get_queryset()[source]

Return the QuerySet that will be used to look up the object.

This method is called by the default implementation of get_object() and may not be called if get_object() is overridden.

get_context_data(**kwargs)[source]

Insert the single object into the context dict.

class shuup.front.apps.saved_carts.views.CartSaveView(**kwargs)[source]

Bases: View

Constructor. Called in the URLconf; can contain helpful extra keyword arguments, and other things.

post(request, *args, **kwargs)[source]
class shuup.front.apps.saved_carts.views.CartAddAllProductsView(**kwargs)[source]

Bases: CartViewMixin, SingleObjectMixin, View

Constructor. Called in the URLconf; can contain helpful extra keyword arguments, and other things.

get_object()[source]

Return the object the view is displaying.

Require self.queryset and a pk or slug argument in the URLconf. Subclasses can override this to return any object.

post(request, *args, **kwargs)[source]
class shuup.front.apps.saved_carts.views.CartDeleteView(**kwargs)[source]

Bases: CartViewMixin, SingleObjectMixin, View

Constructor. Called in the URLconf; can contain helpful extra keyword arguments, and other things.

post(request, *args, **kwargs)[source]

Module contents

class shuup.front.apps.saved_carts.AppConfig(*args, **kwargs)[source]

Bases: AppConfig

name = 'shuup.front.apps.saved_carts'
verbose_name = 'Shuup Frontend - Saved Baskets'
label = 'shuup_front_saved_baskets'
provides = {'customer_dashboard_items': ['shuup.front.apps.saved_carts.dashboard_items:SavedCartsItem'], 'front_urls': ['shuup.front.apps.saved_carts.urls:urlpatterns']}

See /provides for details about the provides variable.