Differential D8395 Diff 21520 plugins/messageviewer/bodypartformatter/pkpass/templates/boardingpass.html
Changeset View
Changeset View
Standalone View
Standalone View
plugins/messageviewer/bodypartformatter/pkpass/templates/boardingpass.html
- This file was added.
1 | <a name="att{{block.attachmentIndex}}"></a> | ||||
---|---|---|---|---|---|
2 | <div id="attachmentDiv{{block.attachmentIndex}}"> | ||||
3 | | ||||
4 | <div style=" | ||||
5 | background-color: {{ pass.backgroundColor }}; | ||||
6 | color: {{ pass.foregroundColor }}; | ||||
7 | padding:12px; | ||||
8 | border-radius:10px; | ||||
9 | margin-left: auto; | ||||
10 | margin-right: auto; | ||||
11 | margin-top: 10px; | ||||
12 | margin-bottom: 10px; | ||||
13 | width: 332px; | ||||
14 | "> | ||||
15 | <!-- header --> | ||||
16 | <div> | ||||
17 | <table style="border-collapse: collapse;"> | ||||
18 | <tr> | ||||
19 | <td rowspan="2" style="vertical-align:center;"> | ||||
20 | {% if pass.logoUrl %} | ||||
21 | <img src="{{ pass.logoUrl }}"/> | ||||
22 | {% endif %} | ||||
23 | </td> | ||||
24 | <td rowspan="2" style="vertical-align:center; font-size:150%; font-weight:bold; width:100%;">{{ pass.logoText }}</td> | ||||
25 | {% for field in pass.headerFields %} | ||||
26 | <td style="white-space: nowrap; color: {{ pass.labelColor }}; padding-bottom:0px;">{{ field.label }}</td> | ||||
27 | {% endfor %} | ||||
28 | </tr><tr> | ||||
29 | {% for field in pass.headerFields %} | ||||
30 | <td style="font-size: 150%; padding-top:0px;">{{ field.value }}</td> | ||||
31 | {% endfor %} | ||||
32 | </tr> | ||||
33 | </table> | ||||
34 | </div> | ||||
35 | <!-- primary fields --> | ||||
36 | <hr/> | ||||
37 | <div> | ||||
38 | <table style="width:100%; border-collapse: collapse;"> | ||||
39 | <tr> | ||||
40 | <td style="width:50%; white-space: nowrap; color: {{ pass.labelColor }}; padding-bottom:0px;">{{ pass.primaryFields.0.label }}</td> | ||||
41 | <td></td> | ||||
42 | <td style="width:50%; white-space: nowrap; text-align:right; color: {{ pass.labelColor }}; padding-bottom:0px;">{{ pass.primaryFields.1.label }}</td> | ||||
43 | </tr><tr style="font-size: 200%;"> | ||||
44 | <td style="vertical-align:top; padding-top:0px;">{{ pass.primaryFields.0.value }}</td> | ||||
45 | <td style="color: {{ pass.labelColor }}; padding-top:0px;"> | ||||
46 | {% if pass.transitType == pass.Air %} | ||||
47 | ✈ | ||||
48 | {% elif pass.transitType == pass.Bus %} <!-- the Unicode characters for the other transport type are not widely available --> | ||||
49 | → | ||||
50 | {% elif pass.transitType == pass.Boat %} | ||||
51 | → | ||||
52 | {% elif pass.transitType == pass.Train %} | ||||
53 | → | ||||
54 | {% else %} | ||||
55 | → | ||||
56 | {% endif %} | ||||
57 | </td> | ||||
58 | <td style="text-align:right; vertical-align:top; padding-top:0px;">{{ pass.primaryFields.1.value }}</td> | ||||
59 | </tr> | ||||
60 | </table> | ||||
61 | </div> | ||||
62 | <!-- auxiliaryFields fields --> | ||||
63 | <div style="padding-top:4px;"> | ||||
64 | <table style="width:100%; border-collapse: collapse;"> | ||||
65 | <tr> | ||||
66 | {% for field in pass.auxiliaryFields %} | ||||
67 | <td style="white-space: nowrap; color: {{ pass.labelColor }}; padding-bottom:0px;">{{ field.label }}</td> | ||||
68 | {% endfor %} | ||||
69 | </tr><tr style="font-size: 150%;"> | ||||
70 | {% for field in pass.auxiliaryFields %} | ||||
71 | <td style="vertical-align:top; padding-top:0px;">{{ field.value }}</td> | ||||
72 | {% endfor %} | ||||
73 | </tr> | ||||
74 | </table> | ||||
75 | </div> | ||||
76 | <!-- secondary fields --> | ||||
77 | <div style="padding-top:4px;"> | ||||
78 | <table style="width:100%; border-collapse: collapse;"> | ||||
79 | <tr> | ||||
80 | {% for field in pass.secondaryFields %} | ||||
81 | <td style="white-space: nowrap; color: {{ pass.labelColor }}; padding-bottom:0px;">{{ field.label }}</td> | ||||
82 | {% endfor %} | ||||
83 | </tr><tr style="font-size: 150%;"> | ||||
84 | {% for field in pass.secondaryFields %} | ||||
85 | <td style="vertical-align:top; padding-top:0px;">{{ field.value }}</td> | ||||
86 | {% endfor %} | ||||
87 | </tr> | ||||
88 | </table> | ||||
89 | </div> | ||||
90 | <!-- footer (not included in boarding passes apparently) --> | ||||
91 | <!-- barcode --> | ||||
92 | <div style="background-color: #ffffff; color: #000000; margin-top:8px;"> | ||||
93 | <div style="text-align:center;"> | ||||
94 | {% if pass.barcodeUrl %} | ||||
95 | <img src="{{ pass.barcodeUrl }}"/> | ||||
96 | {% else %} | ||||
97 | Unsupported barcode format. | ||||
98 | {% endif %} | ||||
99 | </div> | ||||
100 | <div style="text-align:center; color: #606060;">{{ pass.barcodeAltText }}</div> | ||||
101 | </div> | ||||
102 | <!-- back fields --> | ||||
103 | <hr/> | ||||
104 | {% for field in pass.backFields %} | ||||
105 | <div style="color: {{ pass.labelColor }};">{{ field.label }}</div> | ||||
106 | <div>{{ field.value|safe }}</div> | ||||
107 | {% endfor %} | ||||
108 | </div> <!-- boarding pass --> | ||||
109 | | ||||
110 | </div> <!-- attachment container --> |