Merge pull request #437 from eReuse/bugfix/4283-replace-erasure-sanitization
Bugfix/4283 replace erasure sanitization
This commit is contained in:
commit
91d13808a7
|
@ -1149,7 +1149,7 @@ class ExportsView(View):
|
||||||
n_computers = len({x.parent for x in erasures} - erasures_host)
|
n_computers = len({x.parent for x in erasures} - erasures_host)
|
||||||
|
|
||||||
params = {
|
params = {
|
||||||
'title': 'Erasure Certificate',
|
'title': 'Device Sanitization',
|
||||||
'erasures': tuple(erasures),
|
'erasures': tuple(erasures),
|
||||||
'url_pdf': '',
|
'url_pdf': '',
|
||||||
'date_report': '{:%c}'.format(datetime.datetime.now()),
|
'date_report': '{:%c}'.format(datetime.datetime.now()),
|
||||||
|
|
|
@ -138,7 +138,7 @@ class DocumentView(DeviceView):
|
||||||
url_pdf = boltons.urlutils.URL(flask.request.url)
|
url_pdf = boltons.urlutils.URL(flask.request.url)
|
||||||
url_pdf.query_params['format'] = 'PDF'
|
url_pdf.query_params['format'] = 'PDF'
|
||||||
params = {
|
params = {
|
||||||
'title': 'Erasure Certificate',
|
'title': 'Device Sanitization',
|
||||||
'erasures': tuple(erasures()),
|
'erasures': tuple(erasures()),
|
||||||
'url_pdf': url_pdf.to_text(),
|
'url_pdf': url_pdf.to_text(),
|
||||||
}
|
}
|
||||||
|
@ -280,7 +280,7 @@ class LotRow(OrderedDict):
|
||||||
self['Registered in'] = format(lot.created, '%c')
|
self['Registered in'] = format(lot.created, '%c')
|
||||||
try:
|
try:
|
||||||
self['Description'] = lot.description
|
self['Description'] = lot.description
|
||||||
except:
|
except Exception:
|
||||||
self['Description'] = ''
|
self['Description'] = ''
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -73,7 +73,7 @@
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a class="dropdown-item d-flex align-items-center" href="{{ url_for('inventory.device_erasure_list') }}">
|
<a class="dropdown-item d-flex align-items-center" href="{{ url_for('inventory.device_erasure_list') }}">
|
||||||
<i class="bi bi-tag"></i><span>Data Storage Erasures</span>
|
<i class="bi bi-eraser-fill"></i><span>Drives Sanitization</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -37,7 +37,7 @@
|
||||||
<button class="nav-link active" data-bs-toggle="tab" data-bs-target="#profile-change-password">Change Password</button>
|
<button class="nav-link active" data-bs-toggle="tab" data-bs-target="#profile-change-password">Change Password</button>
|
||||||
</li>
|
</li>
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<button class="nav-link" data-bs-toggle="tab" data-bs-target="#profile-sanitization-entity">Sanitization Entity</button>
|
<button class="nav-link" data-bs-toggle="tab" data-bs-target="#profile-sanitization-entity">Sanitization Certificate</button>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="tab-content pt-2">
|
<div class="tab-content pt-2">
|
||||||
|
@ -71,7 +71,7 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="tab-pane fade pt-3" id="profile-sanitization-entity">
|
<div class="tab-pane fade pt-3" id="profile-sanitization-entity">
|
||||||
<!-- Sanitization Entity datas Form -->
|
<!-- Sanitization Certificate datas Form -->
|
||||||
<form action="{{ url_for('core.set-sanitization') }}" method="post">
|
<form action="{{ url_for('core.set-sanitization') }}" method="post">
|
||||||
{% for f in sanitization_form %}
|
{% for f in sanitization_form %}
|
||||||
{% if f == sanitization_form.csrf_token %}
|
{% if f == sanitization_form.csrf_token %}
|
||||||
|
@ -95,7 +95,7 @@
|
||||||
<div class="text-center">
|
<div class="text-center">
|
||||||
<button type="submit" class="btn btn-primary">Change sanitization data</button>
|
<button type="submit" class="btn btn-primary">Change sanitization data</button>
|
||||||
</div>
|
</div>
|
||||||
</form><!-- End Sanitization Entity datas Form -->
|
</form><!-- End Sanitization Certificate datas Form -->
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div><!-- End Bordered Tabs -->
|
</div><!-- End Bordered Tabs -->
|
||||||
|
|
|
@ -256,7 +256,7 @@
|
||||||
<li>
|
<li>
|
||||||
<a href="javascript:export_file('certificates')" class="dropdown-item">
|
<a href="javascript:export_file('certificates')" class="dropdown-item">
|
||||||
<i class="bi bi-eraser-fill"></i>
|
<i class="bi bi-eraser-fill"></i>
|
||||||
Erasure Certificate
|
Device Sanitization
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
<nav>
|
<nav>
|
||||||
<ol class="breadcrumb">
|
<ol class="breadcrumb">
|
||||||
<li class="breadcrumb-item"><a href="{{ url_for('inventory.devicelist')}}">Inventory</a></li>
|
<li class="breadcrumb-item"><a href="{{ url_for('inventory.devicelist')}}">Inventory</a></li>
|
||||||
<li class="breadcrumb-item active">Erasures disks</li>
|
<li class="breadcrumb-item active">Drive Sanitization</li>
|
||||||
</ol>
|
</ol>
|
||||||
</nav>
|
</nav>
|
||||||
</div><!-- End Page Title -->
|
</div><!-- End Page Title -->
|
||||||
|
@ -82,7 +82,7 @@
|
||||||
<li>
|
<li>
|
||||||
<a href="javascript:export_file('certificates')" class="dropdown-item">
|
<a href="javascript:export_file('certificates')" class="dropdown-item">
|
||||||
<i class="bi bi-eraser-fill"></i>
|
<i class="bi bi-eraser-fill"></i>
|
||||||
Erasure Certificate
|
Device Sanitization
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -172,7 +172,7 @@
|
||||||
<li>
|
<li>
|
||||||
<a href="javascript:export_file('certificates')" class="dropdown-item">
|
<a href="javascript:export_file('certificates')" class="dropdown-item">
|
||||||
<i class="bi bi-eraser-fill"></i>
|
<i class="bi bi-eraser-fill"></i>
|
||||||
Erasure Certificate
|
Device Sanitization
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -20,12 +20,13 @@
|
||||||
<div class="pt-6 pb-2">
|
<div class="pt-6 pb-2">
|
||||||
<div class="row pt-3">
|
<div class="row pt-3">
|
||||||
<div class="col">
|
<div class="col">
|
||||||
|
<h5 class="card-title">Sanitization servers</h5>
|
||||||
<form method="post">
|
<form method="post">
|
||||||
<table class="table table-hover">
|
<table class="table table-hover">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th scope="col">PHID</th>
|
<th scope="col">PHID</th>
|
||||||
<th scope="col" class="text-center">Erasure Host</th>
|
<th scope="col" class="text-center">Sanitization Host</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
|
|
@ -23,7 +23,7 @@ class SettingsView(GenericMixin):
|
||||||
decorators = [login_required]
|
decorators = [login_required]
|
||||||
methods = ['GET', 'POST']
|
methods = ['GET', 'POST']
|
||||||
template_name = 'workbench/settings.html'
|
template_name = 'workbench/settings.html'
|
||||||
page_title = "Snapshots"
|
page_title = "Setup"
|
||||||
|
|
||||||
def dispatch_request(self):
|
def dispatch_request(self):
|
||||||
self.get_context()
|
self.get_context()
|
||||||
|
|
Reference in New Issue