Skip to content
Snippets Groups Projects
Unverified Commit 13a9acf4 authored by Alexis BENOIT's avatar Alexis BENOIT Committed by GitHub
Browse files

Correction du hero des formations (#696)

parent 5aabf398
No related branches found
No related tags found
No related merge requests found
<div class="essential-container" id="#{{ urlize (i18n "programs.toc.essential") }}"> <div class="essential-container" id="#{{ urlize (i18n "programs.toc.essential") }}">
<div class="container"> <div class="container">
{{ $parent := .Params.parent }} {{ $duration := .Params.duration }}
{{ $locations := .Params.locations}} {{ $diploma := site.GetPage (printf "/diplomas/%s" .Params.diplomas) }}
{{- with .Params.diplomas -}} {{- if or $diploma $duration .Params.parent .Params.locations -}}
{{- $diploma := site.GetPage (printf "/diplomas/%s" .) -}} {{ if $diploma }}
{{- with $diploma -}} {{ $duration = $duration | default $diploma.Params.duration }}
<dl class="essential"> {{ end }}
<dl class="essential">
{{ with $diploma }}
<dt>{{ i18n "programs.diploma" }}</dt> <dt>{{ i18n "programs.diploma" }}</dt>
<dd><a href="{{ .Permalink }}">{{ partial "PrepareHTML" .Title }}</a></dd> <dd><a href="{{ .Permalink }}">{{ partial "PrepareHTML" .Title }}</a></dd>
{{- if .Params.level -}} {{- if .Params.level -}}
<dt>{{ i18n "programs.level" }}</dt> <dt>{{ i18n "programs.level" }}</dt>
<dd>{{ partial "PrepareHTML" .Params.level }}</dd> <dd>{{ partial "PrepareHTML" .Params.level }}</dd>
{{- end -}} {{- end -}}
{{- with $parent -}} {{- end -}}
<dt>{{ i18n "programs.mention" }}</dt> {{- with .Params.parent -}}
<dd><a href="{{ .url }}">{{ partial "PrepareHTML" .title }}</a></dd> <dt>{{ i18n "programs.mention" }}</dt>
{{- end -}} <dd><a href="{{ .url }}">{{ partial "PrepareHTML" .title }}</a></dd>
{{- if .Params.duration -}} {{- end -}}
<dt>{{ i18n "programs.duration" }}</dt> {{- with $duration -}}
<dd>{{ partial "PrepareHTML" .Params.duration }}</dd> <dt>{{ i18n "programs.duration" }}</dt>
{{- end -}} <dd>{{ partial "PrepareHTML" . }}</dd>
{{- with $locations -}} {{- end -}}
<dt>{{ i18n "programs.location" ( len . ) }}</dt> {{- with .Params.locations -}}
<dd> <dt>{{ i18n "programs.location" ( len . ) }}</dt>
{{- range . -}} <dd>
{{- $locationpage := site.GetPage ( printf "/locations/%s" .slug ) -}} {{- range . -}}
<a href="{{ .path }}">{{ $locationpage.Params.title }}</a> {{- $locationpage := site.GetPage ( printf "/locations/%s" .slug ) -}}
{{- end -}} <a href="{{ .path }}">{{ $locationpage.Params.title }}</a>
</dd> {{- end -}}
{{- end -}} </dd>
</dl> {{- end -}}
{{- end -}} </dl>
{{- end -}} {{- end -}}
<div class="buttons"> <div class="buttons">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment