pki.views.cert_profilesΒΆ

Views for Certificate Profile management.

ClassesΒΆ

CertProfileContextMixin

Mixin which adds context_data for the PKI -> Cert Profiles pages.

CertProfileTableView

Certificate Profile Table View.

CertProfileConfigView

View to display the details of and edit a Certificate Profile.

CertProfileBulkDeleteConfirmView

View to confirm the deletion of multiple certificate profiles.

Module ContentsΒΆ

class pki.views.cert_profiles.CertProfileContextMixin[source]ΒΆ

Bases: trustpoint.views.base.ContextDataMixin

Mixin which adds context_data for the PKI -> Cert Profiles pages.

context_page_category = 'pki'[source]ΒΆ
context_page_name = 'cert_profiles'[source]ΒΆ
class pki.views.cert_profiles.CertProfileTableView[source]ΒΆ

Bases: CertProfileContextMixin, trustpoint.views.base.SortableTableMixin[pki.models.CertificateProfileModel], django.views.generic.list.ListView[pki.models.CertificateProfileModel]

Certificate Profile Table View.

model[source]ΒΆ
template_name = 'pki/cert_profiles/cert_profiles.html'[source]ΒΆ
context_object_name = 'cert_profiles'[source]ΒΆ
paginate_by = 50[source]ΒΆ
default_sort_param = 'unique_name'[source]ΒΆ
class pki.views.cert_profiles.CertProfileConfigView[source]ΒΆ

Bases: trustpoint.logger.LoggerMixin, CertProfileContextMixin, django.views.generic.edit.UpdateView[pki.models.CertificateProfileModel, pki.forms.CertProfileConfigForm]

View to display the details of and edit a Certificate Profile.

http_method_names = ('get', 'post')[source]ΒΆ
model[source]ΒΆ
success_url[source]ΒΆ
template_name = 'pki/cert_profiles/config.html'[source]ΒΆ
context_object_name = 'profile'[source]ΒΆ
form_class[source]ΒΆ
get_object(_queryset=None)[source]ΒΆ

Retrieve the CertificateProfileModel object based on the primary key in the URL.

Parameters:

_queryset (django.db.models.QuerySet[Any, Any] | None)

Return type:

pki.models.CertificateProfileModel | None

get_context_data(**kwargs)[source]ΒΆ

Add additional context data.

Parameters:

kwargs (Any)

Return type:

dict[str, Any]

get_initial()[source]ΒΆ

Initialize the form with default values.

Return type:

dict[str, Any]

form_valid(form)[source]ΒΆ

Handle the case where the form is valid.

Parameters:

form (pki.forms.CertProfileConfigForm)

Return type:

django.http.HttpResponse

class pki.views.cert_profiles.CertProfileBulkDeleteConfirmView[source]ΒΆ

Bases: CertProfileContextMixin, trustpoint.views.base.BulkDeleteView

View to confirm the deletion of multiple certificate profiles.

model[source]ΒΆ
success_url[source]ΒΆ
ignore_url[source]ΒΆ
template_name = 'pki/cert_profiles/confirm_delete.html'[source]ΒΆ
context_object_name = 'cert_profiles'[source]ΒΆ
queryset: django.db.models.QuerySet[pki.models.CertificateProfileModel][source]ΒΆ
get(request, *args, **kwargs)[source]ΒΆ

Handle GET requests.

Parameters:
  • request (django.http.HttpRequest)

  • args (Any)

  • kwargs (Any)

Return type:

django.http.HttpResponse

form_valid(form)[source]ΒΆ

Delete the selected credentials on valid form.

Parameters:

form (django.forms.Form)

Return type:

django.http.HttpResponse