mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Closes #13102: Establish initial translation support in templates
--------- Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
This commit is contained in:
@@ -1,22 +1,23 @@
|
||||
{% extends 'generic/object.html' %}
|
||||
{% load helpers %}
|
||||
{% load plugins %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block content %}
|
||||
<div class="row mb-3">
|
||||
<div class="col col-md-6">
|
||||
<div class="card">
|
||||
<h5 class="card-header">
|
||||
Webhook
|
||||
{% trans "Webhook" %}
|
||||
</h5>
|
||||
<div class="card-body">
|
||||
<table class="table table-hover attr-table">
|
||||
<tr>
|
||||
<th scope="row">Name</th>
|
||||
<th scope="row">{% trans "Name" %}</th>
|
||||
<td>{{ object.name }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Enabled</th>
|
||||
<th scope="row">{% trans "Enabled" %}</th>
|
||||
<td>{% checkmark object.enabled %}</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -24,28 +25,28 @@
|
||||
</div>
|
||||
<div class="card">
|
||||
<h5 class="card-header">
|
||||
Events
|
||||
{% trans "Events" %}
|
||||
</h5>
|
||||
<div class="card-body">
|
||||
<table class="table table-hover attr-table">
|
||||
<tr>
|
||||
<th scope="row">Create</th>
|
||||
<th scope="row">{% trans "Create" %}</th>
|
||||
<td>{% checkmark object.type_create %}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Update</th>
|
||||
<th scope="row">{% trans "Update" %}</th>
|
||||
<td>{% checkmark object.type_update %}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Delete</th>
|
||||
<th scope="row">{% trans "Delete" %}</th>
|
||||
<td>{% checkmark object.type_delete %}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Job start</th>
|
||||
<th scope="row">{% trans "Job start" %}</th>
|
||||
<td>{% checkmark object.type_job_start %}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Job end</th>
|
||||
<th scope="row">{% trans "Job end" %}</th>
|
||||
<td>{% checkmark object.type_job_end %}</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -53,24 +54,24 @@
|
||||
</div>
|
||||
<div class="card">
|
||||
<h5 class="card-header">
|
||||
HTTP Request
|
||||
{% trans "HTTP Request" %}
|
||||
</h5>
|
||||
<div class="card-body">
|
||||
<table class="table table-hover attr-table">
|
||||
<tr>
|
||||
<th scope="row">HTTP Method</th>
|
||||
<th scope="row">{% trans "HTTP Method" %}</th>
|
||||
<td>{{ object.get_http_method_display }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Payload URL</th>
|
||||
<th scope="row">{% trans "Payload URL" %}</th>
|
||||
<td class="font-monospace">{{ object.payload_url }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">HTTP Content Type</th>
|
||||
<th scope="row">{% trans "HTTP Content Type" %}</th>
|
||||
<td>{{ object.http_content_type }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Secret</th>
|
||||
<th scope="row">{% trans "Secret" %}</th>
|
||||
<td>{{ object.secret|placeholder }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -78,16 +79,16 @@
|
||||
</div>
|
||||
<div class="card">
|
||||
<h5 class="card-header">
|
||||
SSL
|
||||
{% trans "SSL" %}
|
||||
</h5>
|
||||
<div class="card-body">
|
||||
<table class="table table-hover attr-table">
|
||||
<tr>
|
||||
<th scope="row">SSL Verification</th>
|
||||
<th scope="row">{% trans "SSL Verification" %}</th>
|
||||
<td>{% checkmark object.ssl_verification %}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">CA File Path</th>
|
||||
<th scope="row">{% trans "CA File Path" %}</th>
|
||||
<td>{{ object.ca_file_path|placeholder }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -98,7 +99,7 @@
|
||||
<div class="col col-md-6">
|
||||
<div class="card">
|
||||
<h5 class="card-header">
|
||||
Assigned Models
|
||||
{% trans "Assigned Models" %}
|
||||
</h5>
|
||||
<div class="card-body">
|
||||
<table class="table table-hover attr-table">
|
||||
@@ -112,37 +113,37 @@
|
||||
</div>
|
||||
<div class="card">
|
||||
<h5 class="card-header">
|
||||
Conditions
|
||||
{% trans "Conditions" %}
|
||||
</h5>
|
||||
<div class="card-body">
|
||||
{% if object.conditions %}
|
||||
<pre>{{ object.conditions|json }}</pre>
|
||||
{% else %}
|
||||
<p class="text-muted">None</p>
|
||||
<p class="text-muted">{% trans "None" %}</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card">
|
||||
<h5 class="card-header">
|
||||
Additional Headers
|
||||
{% trans "Additional Headers" %}
|
||||
</h5>
|
||||
<div class="card-body">
|
||||
{% if object.additional_headers %}
|
||||
<pre>{{ object.additional_headers }}</pre>
|
||||
{% else %}
|
||||
<span class="text-muted">None</span>
|
||||
<span class="text-muted">{% trans "None" %}</span>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card">
|
||||
<h5 class="card-header">
|
||||
Body Template
|
||||
{% trans "Body Template" %}
|
||||
</h5>
|
||||
<div class="card-body">
|
||||
{% if object.body_template %}
|
||||
<pre>{{ object.body_template }}</pre>
|
||||
{% else %}
|
||||
<span class="text-muted">None</span>
|
||||
<span class="text-muted">{% trans "None" %}</span>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
Reference in New Issue
Block a user