diff --git a/cms/models.py b/cms/models.py index 734c2e1..2f37f3e 100644 --- a/cms/models.py +++ b/cms/models.py @@ -176,12 +176,12 @@ class PDFResponse(HttpResponse): self['Content-Disposition'] = 'attachment; filename={0}'.format(filename) self['Content-Type'] = 'charset=utf-8' self.story = [] - image = Image(settings.MEDIA_ROOT + '/media/header.png', width=499, height=99) + image = Image(settings.MEDIA_ROOT + '/media/header.png', width=480, height=80) image.hAlign = 0 self.story.append(image) - self.story.append(Spacer(0,1*cm)) + #self.story.append(Spacer(0,1*cm)) data = [['Filières EDS', title]] if portrait: diff --git a/cms/views.py b/cms/views.py index 9ac0cb0..cc41137 100644 --- a/cms/views.py +++ b/cms/views.py @@ -70,7 +70,7 @@ class HomwPDFView(TemplateView): [Preformatted(d[7].__str__(), style_normal, maxLineLength=40), Preformatted(p[10].__str__(), style_normal, maxLineLength=60) , 'Macc' , '' ,'' , '' , '' , '' ], ] - t = Table(data, colWidths=[5.5*cm, 8*cm, 1.5*cm, 1.5*cm,1.5*cm, 1.5*cm,1.5*cm,1.5*cm], spaceBefore=1*cm, spaceAfter=1*cm) + t = Table(data, colWidths=[5.5*cm, 8*cm, 1.5*cm, 1.5*cm,1.5*cm, 1.5*cm,1.5*cm,1.5*cm], spaceBefore=0.5*cm, spaceAfter=1*cm) t.setStyle(TableStyle([ ('SIZE', (0,0), (-1,-1), 8), ('FONT', (0,0), (-1,0), 'Helvetica-Bold'), @@ -323,7 +323,7 @@ class PeriodePDFView(TemplateView): t.hAlign = 0 response.story.append(t) - response.story.append(Paragraph('Total des heures de cours: {0} h.'.format(context['tot']), style_normal)) + response.story.append(Paragraph('Total des heures de cours: {0} heures'.format(context['tot']), style_normal)) doc = MyDocTemplate(response) doc.build(response.story) diff --git a/templates/cms/index.html b/templates/cms/index.html index 3612673..a3a5932 100644 --- a/templates/cms/index.html +++ b/templates/cms/index.html @@ -80,8 +80,8 @@ {{D6.url|safe}} {{P09.url|safe}} {{M16_1.url_code|safe}} - {{M16_2a.url_code|safe}} / {{M16_2b.url_code|safe}} / {{M16_2c.url_code|safe}} - {{M16_3a.url_code|safe}} / {{M16_3b.url_code|safe}} / {{M16_3c.url_code|safe}} + {{M16_2.url_code|safe}} + {{M16_3.url_code|safe}} diff --git a/templates/cms/periodes.html b/templates/cms/periodes.html index 3368646..862683f 100644 --- a/templates/cms/periodes.html +++ b/templates/cms/periodes.html @@ -9,39 +9,42 @@

Périodes de formation

- -
Semestre 1{{tot1.sem1__sum}}h.Semestre 2{{tot2.sem2__sum}}h.
+ + + - -
Semestre 1{{tot1.sem1__sum}}h.Semestre 2{{tot2.sem2__sum}}h.
{% for s in sem1 %} {% endfor %}
{{s}}{{s.sem1}} h.
- +
{% for s in sem2 %} {% endfor %}
{{s}}{{s.sem2}} h.
Semestre 3{{tot3.sem3__sum}}h.Semestre 4{{tot4.sem4__sum}}h.
+ + -
Semestre 3{{tot3.sem3__sum}}h.Semestre 4{{tot4.sem4__sum}}h.
{% for s in sem3 %} {% endfor %}
{{s}}{{s.sem3}} h.
+ + - -
{% for s in sem4 %} {% endfor %}
{{s}}{{s.sem4}} h.
Semestre 5{{tot5.sem5__sum}}h.Semestre 6{{tot6.sem6__sum}}h.
+ + +
Semestre 5{{tot5.sem5__sum}}h.Semestre 6{{tot6.sem6__sum}}h.
{% for s in sem5 %} {% endfor %}
{{s}}{{s.sem5}} h.
- +
{% for s in sem6 %} {% endfor %} @@ -50,7 +53,7 @@
{{s}}{{s.sem6}} h.

-Total des périodes de cours: {{tot}} heures +Total des heures de cours: {{tot}} heures

Imprimer en PDF