X
O uso deste material é autorizado apenas para fins editoriais.
Editory
Inovação
Petrobras substitui mergulho por robôs em profundidades maiores que 50 metrosPublished in 2024.04.12
Inovação
Petrobras inicia implantação de tecnologia inédita de separação de gás rico em CO2 no leito marinhoPublished in 2024.02.20
Inovação
Petrobras tops patent application record in 2023Petrobras bate recorde de depósito de patentes em 2023Published in 2024.01.08
— 8 éléments par page
Une erreur s'est produite lors du traitement du modèle.
The following has evaluated to null or missing: ==> default [in template "20099#20135#20663294" at line 58, column 55] ---- Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: #return {"message": message, "title":... [in template "20099#20135#20663294" in function "extractInfo" at line 55, column 9] ----
1<#--
2Widget templates can be used to modify the look of a
3specific application.
4
5Please use the right panel to quickly add commonly used variables.
6Autocomplete is also available and can be invoked by typing "${".
7-->
8
9<#include "${templatesPath}/1975398" />
10
11<#assign journalArticleService = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService") />
12
13<#function extractInfo entry journalArticleService>
14 <#if !entry?? >
15 <#return {} />
16 </#if>
17
18 <#assign article = journalArticleService.getLatestArticle(entry.getClassPK()) />
19 <#if !article??>
20 <#return {} />
21 </#if>
22
23 <#assign ddmStructure = article.getDDMStructure() />
24 <#if !ddmStructure??>
25 <#return {} />
26 </#if>
27
28 <#assign fieldList = getFieldListByStructure(ddmStructure) />
29 <#assign xmlArticle = article.getDocument().getRootElement() />
30
31 <#assign message = getFieldValue(fieldList, xmlArticle, "Mensagem") />
32 <#assign title = getFieldValue(fieldList, xmlArticle, "Título") />
33 <#assign titleSizeOption = getFieldValue(fieldList, xmlArticle, "Tamanho do título") />
34 <#assign barColorOption = getFieldValue(fieldList, xmlArticle, "Travessão") />
35
36 <#assign barColor = "" />
37 <#if barColorOption == "Opção28990651" >
38 <#assign barColor = "color-neutral-700" />
39 <#elseif barColorOption == "Opção22989740" />
40 <#assign barColor = "color-secondary-medium" />
41 </#if>
42
43 <#assign sizeMap = {
44 "Opção28990651": "display-lg" ,
45 "Opção00087472": "display-ms",
46 "Opção81960825": "display-sm",
47 "Opção80389944": "h1",
48 "Opção72919892": "h2",
49 "Opção71416405": "h3",
50 "Opção47671926": "h4",
51 "Opção78536628": "h5",
52 "Opção26419901": "h6"
53 } />
54
55 <#return {
56 "message": message,
57 "title": title,
58 "titleSize": sizeMap[titleSizeOption]!default("display-lg"),
59 "barColor": barColor,
60 "barColorOption": barColorOption
61 }/>
62</#function>
63
64<#if entry?has_content>
65 <#assign info = extractInfo(entry, journalArticleService) />
66 <#if info.message?? && (info.message?trim)?has_content>
67 <hr class="message-above-footer-hr"/>
68 <div class="breakpoint">
69 <#if info.title?? && (info.title?trim)?has_content>
70 <div class="footer-message-title col-1-12 md-col-1-8 sm-col-1-4" >
71 <p class="${info.titleSize}">
72 ${info.title}
73 </p>
74 <#if info.barColor?? & (info.barColor)?has_content>
75 <div class="yellow-bar yellow-bar-${info.titleSize} col-1-12 md-col-1-8 sm-col-1-4" style="background-color: var(--${info.barColor})"></div>
76 </#if>
77 </div>
78 </#if>
79 <div class="message-above-footer col-1-12 md-col-1-8 sm-col-1-4 .paragraph-micro-regular">
80 ${info.message}
81 </div>
82 </div>
83 </#if>
84</#if>
85
86<style>
87 .footer-message-title p {
88 font-family: var(--font-family-base);
89 font-style: normal;
90 font-weight: 700;
91 color: #373737;
92 }
93
94 .footer-message-title .yellow-bar {
95 margin-bottom: 8px;
96 }
97
98 .footer-message-title .yellow-bar-h6 {
99 width: 18px;
100 height: 1.9px;
101 margin-top: 13px;
102 }
103
104 .footer-message-title .yellow-bar-h5 {
105 width: 20px;
106 height: 2.1px;
107 margin-top: 14px;
108 }
109
110 .footer-message-title .yellow-bar-h4 {
111 width: 22px;
112 height: 2.5px;
113 margin-top: 16px;
114 }
115
116 .footer-message-title .yellow-bar-h3 {
117 width: 24px;
118 height: 3px;
119 margin-top: 17.5px;
120 }
121
122 .footer-message-title .yellow-bar-h2 {
123 width: 32px;
124 height: 3.5px;
125 margin-top: 21px;
126 }
127
128 .footer-message-title .yellow-bar-h1 {
129 width: 40px;
130 height: 4.1px;
131 margin-top: 26px;
132 }
133
134 .footer-message-title .yellow-bar-display-sm {
135 width: 40px;
136 height: 4.1px;
137 margin-top: 26px;
138 }
139
140 .footer-message-title .yellow-bar-display-md {
141 width: 52px;
142 height: 5.4px;
143 margin-top: 38px;
144 }
145
146 .footer-message-title .yellow-bar-display-lg {
147 width: 64px;
148 height: 3.2px;
149 margin-top: 46px;
150 }
151
152 @media (max-width: 480px) {
153 .footer-message-title .yellow-bar-h6 {
154 width: 16px;
155 height: 1.6px;
156 }
157
158 .footer-message-title .yellow-bar-h5 {
159 width: 18px;
160 height: 1.9px;
161 }
162
163 .footer-message-title .yellow-bar-h4 {
164 width: 20px;
165 height: 2.1px;
166 }
167
168 .footer-message-title .yellow-bar-h3 {
169 width: 22px;
170 height: 2.5px;
171 }
172
173 .footer-message-title .yellow-bar-h2 {
174 width: 28px;
175 height: 3px;
176 }
177
178 .footer-message-title .yellow-bar-h1 {
179 width: 32px;
180 height: 3.5px;
181 }
182
183 .footer-message-title .yellow-bar-display-sm {
184 width: 32px;
185 height: 3.5px;
186 }
187
188 .footer-message-title .yellow-bar-display-md {
189 width: 40px;
190 height: 4.1px;
191 }
192
193 .footer-message-title .yellow-bar-display-lg {
194 width: 40px;
195 height: 2px;
196 }
197 }
198
199 .message-above-footer-hr {
200 height: 1px;
201 width: 100%;
202 background: var(--border-color-light);
203 margin: 0;
204 margin-bottom: var(--space-lg)
205 }
206
207 div.message-above-footer {
208 padding: 0;
209 margin-bottom: -10px; /* compensa uma margem de 10px de uma tag 'section' do liferay */
210 }
211
212 div.message-above-footer p {
213 padding: 0;
214 margin: 0;
215 }
216
217 div.message-above-footer a {
218 text-decoration-line: var(--text-decoration-underline, underline);
219 color: #008542;
220 }
221</style>
Navegue nas Seções:
Escolha um Canal:
Acessibilidade
Idioma:
Selecione um idioma: