tcms.testplans.views module

class tcms.testplans.views.Clone(**kwargs)[source]

Bases: FormView

dispatch(request, *args, **kwargs)
form_class

alias of ClonePlanForm

form_valid(form)[source]

If the form is valid, redirect to the supplied URL.

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

Handle GET requests: instantiate a blank version of the form.

get_context_data(**kwargs)[source]

Insert the form into the context dict.

get_form(form_class=None)[source]

Return an instance of the form to be used in this view.

get_form_kwargs()[source]

Return the keyword arguments for instantiating the form.

object = None
post(request, *args, **kwargs)[source]

Handle POST requests: instantiate a form instance with the passed POST variables and then check if it’s valid.

template_name = 'testplans/clone.html'
class tcms.testplans.views.Edit(**kwargs)[source]

Bases: UpdateView

dispatch(request, *args, **kwargs)
form_class

alias of NewPlanForm

form_invalid(form)[source]

If the form is invalid, render the invalid form.

form_valid(form)[source]

If the form is valid, save the associated model.

get_context_data(**kwargs)[source]

Insert the form into the context dict.

get_form(form_class=None)[source]

Return an instance of the form to be used in this view.

model

alias of TestPlan

template_name = 'testplans/mutable.html'
class tcms.testplans.views.GetTestPlanRedirectView(**kwargs)[source]

Bases: DetailView

dispatch(request, *args, **kwargs)
get(request, *args, **kwargs)[source]
http_method_names = ['get']
model

alias of TestPlan

class tcms.testplans.views.NewTestPlanView(**kwargs)[source]

Bases: CreateView

dispatch(request, *args, **kwargs)
form_class

alias of NewPlanForm

form_valid(form)[source]

If the form is valid, save the associated model.

get_context_data(**kwargs)[source]

Insert the form into the context dict.

get_form(form_class=None)[source]

Return an instance of the form to be used in this view.

get_form_kwargs()[source]

Return the keyword arguments for instantiating the form.

model

alias of TestPlan

template_name = 'testplans/mutable.html'
class tcms.testplans.views.SearchTestPlanView(**kwargs)[source]

Bases: TemplateView

dispatch(request, *args, **kwargs)
get_context_data(**kwargs)[source]
template_name = 'testplans/search.html'
class tcms.testplans.views.TestPlanGetView(**kwargs)[source]

Bases: DetailView

dispatch(request, *args, **kwargs)
get_context_data(**kwargs)[source]

Insert the single object into the context dict.

http_method_names = ['get']
model

alias of TestPlan

template_name = 'testplans/get.html'