diff --git a/topologie/acl.py b/topologie/acl.py
index c0a37084..d1aa6a0d 100644
--- a/topologie/acl.py
+++ b/topologie/acl.py
@@ -41,6 +41,6 @@ def can_view(user):
can = user.has_module_perms("topologie")
return (
can,
- None if can else _("You don't have the right to view this" " application."),
+ None if can else _("You don't have the right to view this application."),
("topologie",),
)
diff --git a/topologie/models.py b/topologie/models.py
index 93e7968c..ab6a22dd 100644
--- a/topologie/models.py
+++ b/topologie/models.py
@@ -84,7 +84,7 @@ class Stack(AclMixin, RevMixin, models.Model):
""" Verification que l'id_max < id_min"""
if self.member_id_max < self.member_id_min:
raise ValidationError(
- {"member_id_max": _("The maximum ID is less than the" " minimum ID.")}
+ {"member_id_max": _("The maximum ID is less than the minimum ID.")}
)
@@ -96,7 +96,7 @@ class AccessPoint(AclMixin, Machine):
location = models.CharField(
max_length=255,
- help_text=_("Details about the AP's location"),
+ help_text=_("Details about the AP's location."),
blank=True,
null=True,
)
@@ -187,7 +187,7 @@ class Switch(AclMixin, Machine):
Validation au save que l'id du stack est bien dans le range id_min
id_max de la stack parente"""
- number = models.PositiveIntegerField(help_text=_("Number of ports"))
+ number = models.PositiveIntegerField(help_text=_("Number of ports."))
stack = models.ForeignKey(
"topologie.Stack", blank=True, null=True, on_delete=models.SET_NULL
)
@@ -197,7 +197,7 @@ class Switch(AclMixin, Machine):
blank=True,
null=True,
on_delete=models.SET_NULL,
- help_text=_("Switch model"),
+ help_text=_("Switch model."),
)
switchbay = models.ForeignKey(
"topologie.SwitchBay", blank=True, null=True, on_delete=models.SET_NULL
@@ -207,17 +207,17 @@ class Switch(AclMixin, Machine):
blank=True,
null=True,
on_delete=models.PROTECT,
- help_text=_("RADIUS key of the switch"),
+ help_text=_("RADIUS key of the switch."),
)
management_creds = models.ForeignKey(
"preferences.SwitchManagementCred",
blank=True,
null=True,
on_delete=models.PROTECT,
- help_text=_("Management credentials for the switch"),
+ help_text=_("Management credentials for the switch."),
)
automatic_provision = models.BooleanField(
- default=False, help_text=_("Automatic provision for the switch")
+ default=False, help_text=_("Automatic provision for the switch.")
)
class Meta:
@@ -245,14 +245,14 @@ class Switch(AclMixin, Machine):
)
else:
raise ValidationError(
- {"stack_member_id": _("The stack member ID can't be" " void.")}
+ {"stack_member_id": _("The stack member ID can't be void.")}
)
def create_ports(self, begin, end):
""" Crée les ports de begin à end si les valeurs données
sont cohérentes. """
if end < begin:
- raise ValidationError(_("The end port is less than the start" " port."))
+ raise ValidationError(_("The end port is less than the start port."))
ports_to_create = range(begin, end + 1)
existing_ports = Port.objects.filter(switch=self.switch).values_list(
"port", flat=True
@@ -262,7 +262,7 @@ class Switch(AclMixin, Machine):
if len(non_existing_ports) + existing_ports.count() > self.number:
raise ValidationError(_("This switch can't have that many ports."))
with transaction.atomic(), reversion.create_revision():
- reversion.set_comment(_("Creation"))
+ reversion.set_comment("Creation")
Port.objects.bulk_create(
[
Port(switch=self.switch, port=port_id)
@@ -491,15 +491,15 @@ class ModuleSwitch(AclMixin, RevMixin, models.Model):
reference = models.CharField(
max_length=255,
- help_text=_("Reference of a module"),
- verbose_name=_("Module reference"),
+ help_text=_("Reference of a module."),
+ verbose_name=_("module reference"),
)
comment = models.CharField(
max_length=255,
null=True,
blank=True,
- help_text=_("Comment"),
- verbose_name=_("Comment"),
+ help_text=_("Comment."),
+ verbose_name=_("comment"),
)
class Meta:
@@ -517,14 +517,14 @@ class ModuleOnSwitch(AclMixin, RevMixin, models.Model):
module = models.ForeignKey("ModuleSwitch", on_delete=models.CASCADE)
switch = models.ForeignKey("Switch", on_delete=models.CASCADE)
slot = models.CharField(
- max_length=15, help_text=_("Slot on switch"), verbose_name=_("Slot")
+ max_length=15, help_text=_("Slot on switch."), verbose_name=_("slot")
)
class Meta:
permissions = (
(
"view_moduleonswitch",
- _("Can view a link between switch and" " module object"),
+ _("Can view a link between switch and module object"),
),
)
verbose_name = _("link between switch and module")
@@ -532,7 +532,7 @@ class ModuleOnSwitch(AclMixin, RevMixin, models.Model):
unique_together = ["slot", "switch"]
def __str__(self):
- return _("On slot ") + str(self.slot) + _(" of ") + str(self.switch)
+ return _("On slot %(slot)s of %(switch)s").format(slot=str(self.slot), switch=str(self.switch))
class ConstructorSwitch(AclMixin, RevMixin, models.Model):
@@ -542,10 +542,10 @@ class ConstructorSwitch(AclMixin, RevMixin, models.Model):
class Meta:
permissions = (
- ("view_constructorswitch", _("Can view a switch constructor" " object")),
+ ("view_constructorswitch", _("Can view a switch constructor object")),
)
verbose_name = _("switch constructor")
- verbose_name_plural = "switch constructors"
+ verbose_name_plural = _("switch constructors")
def __str__(self):
return self.name
@@ -655,8 +655,8 @@ class Port(AclMixin, RevMixin, models.Model):
)
state = models.BooleanField(
default=True,
- help_text=_("Port state Active"),
- verbose_name=_("Port state Active"),
+ help_text=_("Port state Active."),
+ verbose_name=_("port state Active"),
)
details = models.CharField(max_length=255, blank=True)
@@ -809,13 +809,13 @@ class PortProfile(AclMixin, RevMixin, models.Model):
("asso_machine", _("Organisation machine")),
("nothing", _("Nothing")),
)
- name = models.CharField(max_length=255, verbose_name=_("Name"))
+ name = models.CharField(max_length=255, verbose_name=_("name"))
profil_default = models.CharField(
max_length=32,
choices=PROFIL_DEFAULT,
blank=True,
null=True,
- verbose_name=_("Default profile"),
+ verbose_name=_("default profile"),
)
on_dormitory = models.ForeignKey(
"topologie.Dormitory",
@@ -823,7 +823,7 @@ class PortProfile(AclMixin, RevMixin, models.Model):
on_delete=models.SET_NULL,
blank=True,
null=True,
- verbose_name=_("Profil on dormitory"),
+ verbose_name=_("profile on dormitory"),
)
vlan_untagged = models.ForeignKey(
"machines.Vlan",
@@ -843,7 +843,7 @@ class PortProfile(AclMixin, RevMixin, models.Model):
max_length=32,
choices=TYPES,
help_text=_(
- "Type of RADIUS authentication : inactive, MAC-address or" " 802.1X"
+ "Type of RADIUS authentication: inactive, MAC-address or 802.1X."
),
verbose_name=_("RADIUS type"),
)
@@ -852,44 +852,44 @@ class PortProfile(AclMixin, RevMixin, models.Model):
choices=MODES,
default="COMMON",
help_text=_(
- "In case of MAC-authentication : mode COMMON or STRICT on" " this port"
+ "In case of MAC-authentication: mode COMMON or STRICT on this port."
),
verbose_name=_("RADIUS mode"),
)
speed = models.CharField(
- max_length=32, choices=SPEED, default="auto", help_text=_("Port speed limit")
+ max_length=32, choices=SPEED, default="auto", help_text=_("Port speed limit.")
)
mac_limit = models.IntegerField(
null=True,
blank=True,
- help_text=_("Limit of MAC-address on this port"),
+ help_text=_("Limit of MAC-address on this port."),
verbose_name=_("MAC limit"),
)
- flow_control = models.BooleanField(default=False, help_text=_("Flow control"))
+ flow_control = models.BooleanField(default=False, help_text=_("Flow control."))
dhcp_snooping = models.BooleanField(
default=False,
- help_text=_("Protect against rogue DHCP"),
+ help_text=_("Protect against rogue DHCP."),
verbose_name=_("DHCP snooping"),
)
dhcpv6_snooping = models.BooleanField(
default=False,
- help_text=_("Protect against rogue DHCPv6"),
+ help_text=_("Protect against rogue DHCPv6."),
verbose_name=_("DHCPv6 snooping"),
)
arp_protect = models.BooleanField(
default=False,
- help_text=_("Check if IP adress is DHCP assigned"),
+ help_text=_("Check if IP address is DHCP assigned."),
verbose_name=_("ARP protection"),
)
ra_guard = models.BooleanField(
default=False,
- help_text=_("Protect against rogue RA"),
+ help_text=_("Protect against rogue RA."),
verbose_name=_("RA guard"),
)
loop_protect = models.BooleanField(
default=False,
- help_text=_("Protect against loop"),
- verbose_name=_("Loop protection"),
+ help_text=_("Protect against loop."),
+ verbose_name=_("loop protection"),
)
class Meta:
@@ -933,7 +933,7 @@ class PortProfile(AclMixin, RevMixin, models.Model):
raise ValidationError(
{
"profil_default": _(
- "A default profile for all dormitory of that type already exists."
+ "A default profile for all dormitories of that type already exists."
)
}
)
diff --git a/topologie/templates/topologie/aff_dormitory.html b/topologie/templates/topologie/aff_dormitory.html
index cd5a0fbb..b4311b8a 100644
--- a/topologie/templates/topologie/aff_dormitory.html
+++ b/topologie/templates/topologie/aff_dormitory.html
@@ -35,7 +35,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Dormitory" as tr_dormitory %}
{% include 'buttons/sort.html' with prefix='dormitory' col='name' text=tr_dormitory %} |
- {% trans "Building" %} |
+ {% trans "Buildings" %} |
|
diff --git a/topologie/templates/topologie/aff_model_switch.html b/topologie/templates/topologie/aff_model_switch.html
index 24a759e1..51f98617 100644
--- a/topologie/templates/topologie/aff_model_switch.html
+++ b/topologie/templates/topologie/aff_model_switch.html
@@ -36,7 +36,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Reference" as tr_ref %}
{% include 'buttons/sort.html' with prefix='model-switch' col='reference' text=tr_ref %} |
{% trans "Commercial name" %} |
- Firmware |
+ {% trans "Firmware" %} |
{% trans "Switch constructor" as tr_constructor %}
{% include 'buttons/sort.html' with prefix='model-switch' col='constructor' text=tr_constructor %} |
{% trans "Switches" %}
diff --git a/topologie/templates/topologie/aff_port_profile.html b/topologie/templates/topologie/aff_port_profile.html
index 4ed8a7b4..009c0b0f 100644
--- a/topologie/templates/topologie/aff_port_profile.html
+++ b/topologie/templates/topologie/aff_port_profile.html
@@ -35,7 +35,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Name" %} |
- {% trans "Default for and place" %} |
+ {% trans "Default for" %} |
{% trans "VLANs" %} |
{% trans "RADIUS settings" %} |
{% trans "Speed limit" %} |
@@ -47,7 +47,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% for port_profile in port_profile_list %}
{{ port_profile.name }} |
- {{ port_profile.profil_default }} {% if port_profile.profil_default%} - {% if port_profile.on_dormitory %} on {{ port_profile.on_dormitory }} {% else %} Everywhere {% endif %}{% endif %} |
+ {{ port_profile.profil_default }} {% if port_profile.profil_default%} - {% if port_profile.on_dormitory %}{% blocktrans with dorm=port_profile.on_dormitory %} on {{ dorm }}{% endblocktrans %}{% else %}{% trans "Everywhere" %}{% endif %}{% endif %} |
{% if port_profile.vlan_untagged %}
{% trans "Untagged: " %}{{ port_profile.vlan_untagged }}
diff --git a/topologie/templates/topologie/aff_switch.html b/topologie/templates/topologie/aff_switch.html
index 58871d19..e2866aba 100644
--- a/topologie/templates/topologie/aff_switch.html
+++ b/topologie/templates/topologie/aff_switch.html
@@ -44,7 +44,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
| {% include 'buttons/sort.html' with prefix='switch' col='ports' text=tr_ports %} |
{% trans "Stack" as tr_stack %}
{% include 'buttons/sort.html' with prefix='switch' col='stack' text=tr_stack %} |
- {% trans "Stack ID" %} |
+ {% trans "Stack member ID" %} |
{% trans "Switch model" %} |
{% trans "Details" %} |
|
diff --git a/topologie/templates/topologie/index.html b/topologie/templates/topologie/index.html
index 1d0c8722..4d021779 100644
--- a/topologie/templates/topologie/index.html
+++ b/topologie/templates/topologie/index.html
@@ -65,7 +65,7 @@ function toggle_graph() {
{% trans "Switches" %}
{% can_create Switch %}
-{% trans " Add a switch" %}
+ {% trans "Add a switch" %}
{% acl_end %}
{% include 'topologie/aff_switch.html' with switch_list=switch_list %}
diff --git a/topologie/templates/topologie/index_ap.html b/topologie/templates/topologie/index_ap.html
index 570d22ab..b1521937 100644
--- a/topologie/templates/topologie/index_ap.html
+++ b/topologie/templates/topologie/index_ap.html
@@ -32,7 +32,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% block content %}
{% trans "Access points" %}
{% can_create AccessPoint %}
-{% trans " Add an access point" %}
+ {% trans "Add an access point" %}
{% acl_end %}
{% include 'topologie/aff_ap.html' with ap_list=ap_list %}
diff --git a/topologie/templates/topologie/index_model_switch.html b/topologie/templates/topologie/index_model_switch.html
index 2612c29c..da82adb7 100644
--- a/topologie/templates/topologie/index_model_switch.html
+++ b/topologie/templates/topologie/index_model_switch.html
@@ -33,7 +33,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Switch models" %}
{% can_create ModelSwitch %}
- {% trans " Add a switch model" %}
+ {% trans "Add a switch model" %}
{% acl_end %}
@@ -42,7 +42,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Switch constructors" %}
{% can_create ConstructorSwitch %}
- {% trans " Add a switch constructor" %}
+ {% trans "Add a switch constructor" %}
{% acl_end %}
diff --git a/topologie/templates/topologie/index_module.html b/topologie/templates/topologie/index_module.html
index f7432bf1..fae9b282 100644
--- a/topologie/templates/topologie/index_module.html
+++ b/topologie/templates/topologie/index_module.html
@@ -32,7 +32,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% block content %}
{% trans "Switch modules" %}
{% can_create ModuleSwitch %}
-{% trans " Add a module" %}
+ {% trans "Add a module" %}
{% acl_end %}
{% include 'topologie/aff_modules.html' with module_list=module_list modular_switchs=modular_switchs %}
diff --git a/topologie/templates/topologie/index_p.html b/topologie/templates/topologie/index_p.html
index 8d215ebd..462bd146 100644
--- a/topologie/templates/topologie/index_p.html
+++ b/topologie/templates/topologie/index_p.html
@@ -48,8 +48,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% include 'buttons/edit.html' with href='topologie:edit-switch' id=id_switch %}
{% can_create Port %}
-{% include 'buttons/add.html' with href='topologie:new-port' id=id_switch %}
-{% include 'buttons/add.html' with href='topologie:create-ports' id=id_switch %}
+ {% trans "Add a port" %}
+ {% trans "Add ports to the port list" %}
{% acl_end %}
{% include 'topologie/aff_repr_switch.html' with port_list=port_list %}
diff --git a/topologie/templates/topologie/index_physical_grouping.html b/topologie/templates/topologie/index_physical_grouping.html
index 9e4c32a8..cea4fb75 100644
--- a/topologie/templates/topologie/index_physical_grouping.html
+++ b/topologie/templates/topologie/index_physical_grouping.html
@@ -33,7 +33,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Stacks" %}
{% can_create Stack %}
- {% trans " Add a stack" %}
+ {% trans "Add a stack" %}
{% acl_end %}
{% include 'topologie/aff_stacks.html' with stack_list=stack_list %}
@@ -41,7 +41,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Switch bays" %}
{% can_create SwitchBay %}
- {% trans " Add a switch bay" %}
+ {% trans "Add a switch bay" %}
{% acl_end %}
@@ -50,7 +50,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Buildings" %}
{% can_create Building %}
- {% trans " Add a building" %}
+ {% trans "Add a building" %}
{% acl_end %}
@@ -60,7 +60,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Dormitories" %}
{% can_create Dormitory %}
- {% trans " Add a dormitory" %}
+ {% trans "Add a dormitory" %}
{% acl_end %}
diff --git a/topologie/templates/topologie/index_portprofile.html b/topologie/templates/topologie/index_portprofile.html
index a528b992..dd04687d 100644
--- a/topologie/templates/topologie/index_portprofile.html
+++ b/topologie/templates/topologie/index_portprofile.html
@@ -33,7 +33,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% trans "Port profiles" %}
{% can_create PortProfile %}
-{% trans " Add a port profile" %}
+ {% trans "Add a port profile" %}
{% acl_end %}
{% include 'topologie/aff_port_profile.html' with port_profile_list=port_profile_list %}
diff --git a/topologie/templates/topologie/index_room.html b/topologie/templates/topologie/index_room.html
index c383a226..17658e0c 100644
--- a/topologie/templates/topologie/index_room.html
+++ b/topologie/templates/topologie/index_room.html
@@ -32,7 +32,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% block content %}
{% trans "Rooms" %}
{% can_create Room %}
-{% trans " Add a room" %}
+ {% trans "Add a room" %}
{% acl_end %}
{% include 'topologie/aff_chambres.html' with room_list=room_list %}
diff --git a/topologie/templates/topologie/switch.html b/topologie/templates/topologie/switch.html
index 5c39e322..bdc0dae0 100644
--- a/topologie/templates/topologie/switch.html
+++ b/topologie/templates/topologie/switch.html
@@ -36,15 +36,15 @@ with this program; if not, write to the Free Software Foundation, Inc.,
-{% bootstrap_icon "list" %}{% trans " Go to the ports list" %}
+{% bootstrap_icon "list" %} {% trans "Go to the ports list" %}
diff --git a/topologie/templates/topologie/topo.html b/topologie/templates/topologie/topo.html
index 7dad1138..409b65ec 100644
--- a/topologie/templates/topologie/topo.html
+++ b/topologie/templates/topologie/topo.html
@@ -33,7 +33,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% bootstrap_form_errors topoform %}
{% if id_switch %}
-{% bootstrap_icon "list" %}{% trans " Go to the ports list" %}
+{% bootstrap_icon "list" %} {% trans "Go to the ports list" %}
{% endif %}
diff --git a/topologie/views.py b/topologie/views.py
index 84b0345a..3d3f742a 100644
--- a/topologie/views.py
+++ b/topologie/views.py
@@ -442,7 +442,7 @@ def new_stack(request):
messages.success(request, _("The stack was created."))
return redirect(reverse("topologie:index-physical-grouping"))
return form(
- {"topoform": stack, "action_name": _("Create")}, "topologie/topo.html", request
+ {"topoform": stack, "action_name": _("Add")}, "topologie/topo.html", request
)
@@ -454,6 +454,7 @@ def edit_stack(request, stack, **_kwargs):
if stack.is_valid():
if stack.changed_data:
stack.save()
+ messages.success(request, _("The stack was edited."))
return redirect(reverse("topologie:index-physical-grouping"))
return form(
{"topoform": stack, "action_name": _("Edit")}, "topologie/topo.html", request
@@ -538,7 +539,7 @@ def new_switch(request):
"machineform": switch,
"domainform": domain,
"i_mbf_param": i_mbf_param,
- "device": "switch",
+ "device": _("switch"),
},
"topologie/topo_more.html",
request,
@@ -611,7 +612,7 @@ def edit_switch(request, switch, switchid):
"machineform": switch_form,
"domainform": domain_form,
"i_mbf_param": i_mbf_param,
- "device": "switch",
+ "device": _("switch"),
},
"topologie/topo_more.html",
request,
@@ -660,7 +661,7 @@ def new_ap(request):
"machineform": ap,
"domainform": domain,
"i_mbf_param": i_mbf_param,
- "device": "wifi ap",
+ "device": _("access point"),
},
"topologie/topo_more.html",
request,
@@ -712,7 +713,7 @@ def edit_ap(request, ap, **_kwargs):
"machineform": ap_form,
"domainform": domain_form,
"i_mbf_param": i_mbf_param,
- "device": "wifi ap",
+ "device": _("access point"),
},
"topologie/topo_more.html",
request,
@@ -729,7 +730,7 @@ def new_room(request):
messages.success(request, _("The room was created."))
return redirect(reverse("topologie:index-room"))
return form(
- {"topoform": room, "action_name": _("Create")}, "topologie/topo.html", request
+ {"topoform": room, "action_name": _("Add")}, "topologie/topo.html", request
)
@@ -769,7 +770,7 @@ def del_room(request, room, **_kwargs):
)
return redirect(reverse("topologie:index-room"))
return form(
- {"objet": room, "objet_name": _("Room")}, "topologie/delete.html", request
+ {"objet": room, "objet_name": _("room")}, "topologie/delete.html", request
)
@@ -783,7 +784,7 @@ def new_model_switch(request):
messages.success(request, _("The switch model was created."))
return redirect(reverse("topologie:index-model-switch"))
return form(
- {"topoform": model_switch, "action_name": _("Create")},
+ {"topoform": model_switch, "action_name": _("Add")},
"topologie/topo.html",
request,
)
@@ -828,7 +829,7 @@ def del_model_switch(request, model_switch, **_kwargs):
)
return redirect(reverse("topologie:index-model-switch"))
return form(
- {"objet": model_switch, "objet_name": _("Switch model")},
+ {"objet": model_switch, "objet_name": _("switch model")},
"topologie/delete.html",
request,
)
@@ -844,7 +845,7 @@ def new_switch_bay(request):
messages.success(request, _("The switch bay was created."))
return redirect(reverse("topologie:index-physical-grouping"))
return form(
- {"topoform": switch_bay, "action_name": _("Create")},
+ {"topoform": switch_bay, "action_name": _("Add")},
"topologie/topo.html",
request,
)
@@ -888,7 +889,7 @@ def del_switch_bay(request, switch_bay, **_kwargs):
)
return redirect(reverse("topologie:index-physical-grouping"))
return form(
- {"objet": switch_bay, "objet_name": _("Switch bay")},
+ {"objet": switch_bay, "objet_name": _("switch bay")},
"topologie/delete.html",
request,
)
@@ -905,7 +906,7 @@ def new_building(request):
messages.success(request, _("The building was created."))
return redirect(reverse("topologie:index-physical-grouping"))
return form(
- {"topoform": building, "action_name": _("Create")},
+ {"topoform": building, "action_name": _("Add")},
"topologie/topo.html",
request,
)
@@ -949,7 +950,7 @@ def del_building(request, building, **_kwargs):
)
return redirect(reverse("topologie:index-physical-grouping"))
return form(
- {"objet": building, "objet_name": _("Building")},
+ {"objet": building, "objet_name": _("building")},
"topologie/delete.html",
request,
)
@@ -966,7 +967,7 @@ def new_dormitory(request):
messages.success(request, _("The dormitory was created."))
return redirect(reverse("topologie:index-physical-grouping"))
return form(
- {"topoform": dormitory, "action_name": _("Create")},
+ {"topoform": dormitory, "action_name": _("Add")},
"topologie/topo.html",
request,
)
@@ -1012,7 +1013,7 @@ def del_dormitory(request, dormitory, **_kwargs):
)
return redirect(reverse("topologie:index-physical-grouping"))
return form(
- {"objet": dormitory, "objet_name": _("Dormitory")},
+ {"objet": dormitory, "objet_name": _("dormitory")},
"topologie/delete.html",
request,
)
@@ -1028,7 +1029,7 @@ def new_constructor_switch(request):
messages.success(request, _("The switch constructor was created."))
return redirect(reverse("topologie:index-model-switch"))
return form(
- {"topoform": constructor_switch, "action_name": _("Create")},
+ {"topoform": constructor_switch, "action_name": _("Add")},
"topologie/topo.html",
request,
)
@@ -1075,7 +1076,7 @@ def del_constructor_switch(request, constructor_switch, **_kwargs):
)
return redirect(reverse("topologie:index-model-switch"))
return form(
- {"objet": constructor_switch, "objet_name": _("Switch constructor")},
+ {"objet": constructor_switch, "objet_name": _("switch constructor")},
"topologie/delete.html",
request,
)
@@ -1091,7 +1092,7 @@ def new_port_profile(request):
messages.success(request, _("The port profile was created."))
return redirect(reverse("topologie:index-port-profile"))
return form(
- {"topoform": port_profile, "action_name": _("Create")},
+ {"topoform": port_profile, "action_name": _("Add")},
"topologie/topo.html",
request,
)
@@ -1126,7 +1127,7 @@ def del_port_profile(request, port_profile, **_kwargs):
messages.success(request, _("Impossible to delete the port profile."))
return redirect(reverse("topologie:index-port-profile"))
return form(
- {"objet": port_profile, "objet_name": _("Port profile")},
+ {"objet": port_profile, "objet_name": _("port profile")},
"topologie/delete.html",
request,
)
@@ -1142,7 +1143,7 @@ def add_module(request):
messages.success(request, _("The module was created."))
return redirect(reverse("topologie:index-module"))
return form(
- {"topoform": module, "action_name": _("Create")}, "topologie/topo.html", request
+ {"topoform": module, "action_name": _("Add")}, "topologie/topo.html", request
)
@@ -1182,7 +1183,7 @@ def del_module(request, module, **_kwargs):
)
return redirect(reverse("topologie:index-module"))
return form(
- {"objet": module, "objet_name": _("Module")}, "topologie/delete.html", request
+ {"objet": module, "objet_name": _("module")}, "topologie/delete.html", request
)
@@ -1238,7 +1239,7 @@ def del_module_on(request, module, **_kwargs):
)
return redirect(reverse("topologie:index-module"))
return form(
- {"objet": module, "objet_name": _("Module")}, "topologie/delete.html", request
+ {"objet": module, "objet_name": _("module")}, "topologie/delete.html", request
)
|