73
| <![CDATA[<a href="https://educacao.barretos.sp.gov.br/noticias" class="btn gray" style="margin-top: 16px">+ NotÃcias</a>]]>
|
77
| <![CDATA[<script>
fetchData('/educacao/news/?page=1&perpage=11&highlight=1').then(response => {
const sliderList = document.querySelector('#slider .splide__list');
const boxNewsFirst = document.querySelector('.news-bottom.first');
const boxNewsSecond = document.querySelector('.news-bottom.second');
let slide = '';
let newsFirst = '';
let newsSecond = '';
let x = 0;
response.data.forEach(obj => {
let {idNoticia, nomeCategoria, tituloNoticia, fotoPrincipal} = obj;
if(x < 7)
slide += `<li class="splide__slide">
<a href="${ '/noticia/' + idNoticia + '/' + slugify(tituloNoticia)}">
<span class="title">${tituloNoticia}</span>
<img data-splide-lazy="${env.URL_TMP}arquivosNoticiasInterna/${fotoPrincipal}" alt="${tituloNoticia}">
</a>
</li>`;
else if(x < 9)
newsFirst += `<article class="second">
<a href="${ '/noticia/' + idNoticia + '/' + slugify(tituloNoticia)}">
<img src="${env.URL_TMP}arquivosNoticiasInterna/${fotoPrincipal}" alt="${tituloNoticia}">
<span class="title">${tituloNoticia}</span>
</a>
</article>`;
else
newsSecond += `<article class="second">
<a href="${ '/noticia/' + idNoticia + '/' + slugify(tituloNoticia)}">
<img src="${env.URL_TMP}arquivosNoticiasInterna/${fotoPrincipal}" alt="${tituloNoticia}">
<span class="title">${tituloNoticia}</span>
</a>
</article>`;
x ++;
});
sliderList.innerHTML = slide;
boxNewsFirst.innerHTML = newsFirst;
boxNewsSecond.innerHTML = newsSecond;
new Splide('#slider', {
autoplay: true,
interval: 3000,
rewind: true,
type: 'slide',
/* arrows: false, */
lazyLoad: 'nearby'
}).mount();
});
</script>]]>
|
132
| <![CDATA[<script>
let url = '/educacao/services';
let link = '';
const boxLinks = document.getElementById('links');
const getLinks = (url) => {
fetchData(url).then(response => {
response.data.forEach(obj => {
let {name, slug, external, file} = obj;
if(slug){
link += `<a href="${slug}">${name}</a>`;
}else{
if(file){
link += `<a href="https://files.barretos.sp.gov.br/pdf/educacao/${file}" target="_blank">${name}</a>`;
}else{
let pos = external.search('educacao.barretos.sp.gov.br')
if(pos > 0){
link += `<a href="${external}">${name}</a>`;
}else{
link += `<a href="${external}" target="_blank">${name}</a>`;
}
}
}
});
boxLinks.innerHTML = link;
});
}
getLinks(url);
</script>]]>
|
209
| <![CDATA[<script>
new window.VLibras.Widget('https://vlibras.gov.br/app');
</script>]]>
|