From 1aeb14ddc603a44704ad20f5835aa73826ff3998 Mon Sep 17 00:00:00 2001 From: Antoine Vintache Date: Fri, 21 Sep 2018 00:01:04 +0200 Subject: [PATCH] Code intelligent pour print la version du switch --- templates/hp.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/hp.tpl b/templates/hp.tpl index cff6914..9a3e30b 100644 --- a/templates/hp.tpl +++ b/templates/hp.tpl @@ -1,4 +1,4 @@ -; {{ switch.model.reference }}A Configuration Editor; Created on release #{{ switch.model.firmware }} +; {%- if switch.model.reference[-1]=='A' %} {{ switch.model.reference }}{%- else %} {{ switch.model.reference }}A{%- endif %} Configuration Editor; Created on release {%- if switch.model.firmware[0]=='#' %} {{ switch.model.firmware }}{%- else %} #{{ switch.model.firmware }}{%- endif %} hostname "{{ switch.short_name }}" ; Generated on {{ date_gen }} by re2o