Nikola auto commit.

Source commit: 506c7ab5fa
Nikola version: 8.3.3
master
Patricio García 2025-08-24 23:43:46 +01:00
parent 276580989d
commit 29cff39d63
3 changed files with 24 additions and 5 deletions

View File

@ -30,8 +30,16 @@ function ActivePastEvents(tab_next, tab_past) {
} }
} }
function ActivePastEventsIfNotNexts(ge_id, tab_next, tab_past) { function ShowElement(id) {
const element = document.getElementById(id);
if (element) {
element.style.display = "block";
}
}
function ActivePastEventsIfNotNexts(ge_id, tab_next, tab_past, msg_id) {
if (GetNextEventsCount(ge_id) == 0) { if (GetNextEventsCount(ge_id) == 0) {
ActivePastEvents(tab_next, tab_past); ActivePastEvents(tab_next, tab_past);
} }
ShowElement(msg_id);
} }

View File

@ -109,17 +109,22 @@ bg-dark
</ul> </ul>
<!-- Tab panes --><div class="tab-content"> <!-- Tab panes --><div class="tab-content">
<div id="tab-pane-0" class="container-xl tab-pane active"> <div id="tab-pane-0" class="container-xl tab-pane active">
<br><gancio-events baseurl="https://eventos.txs.es" title="Próximos eventos" theme="light" sidebar="false" id="nextevents"></gancio-events><p>No existen mas próximos eventos programados actualmente.</p> <br><gancio-events baseurl="https://eventos.txs.es" title="Próximos eventos" theme="light" sidebar="false" id="nextevents"></gancio-events><div id="msg_non_nexts" style="display:none">
<p>No existen próximos eventos programados actualmente.</p>
</div>
</div> </div>
<div id="tab-pane-1" class="container-xl tab-pane fade"> <div id="tab-pane-1" class="container-xl tab-pane fade">
<br><gancio-events baseurl="https://eventos.txs.es" title="Eventos pasados" theme="light" sidebar="false" past="true"></gancio-events> <br><gancio-events baseurl="https://eventos.txs.es" title="Eventos pasados" theme="light" sidebar="false" past="true"></gancio-events>
</div> </div>
</div> </div>
<p>Si quieres organizar un evento con nosotros <a href="../contact/">contáctanos</a>.</p>
<script src="../assets/js/gancio-events.es.js"></script><p> <script src="../assets/js/gancio-events.es.js"></script><p>
@ -227,6 +232,6 @@ bg-dark
for (let i = 0; i < document.forms.length; i++) for (let i = 0; i < document.forms.length; i++)
document.forms[i].onsubmit = submit; document.forms[i].onsubmit = submit;
})(); })();
</script><script src="../assets/js/gancio-events-detect.js"></script><script> $(document).ready(function(){ ActivePastEventsIfNotNexts("nextevents", "0", "1"); });</script> </script><script src="../assets/js/gancio-events-detect.js"></script><script> $(document).ready(function(){ ActivePastEventsIfNotNexts("nextevents", "0", "1", "msg_non_nexts"); });</script>
</body> </body>
</html> </html>

View File

@ -12,14 +12,20 @@
{{% tabpannel active='1' %}} {{% tabpannel active='1' %}}
Próximos Próximos
<gancio-events baseurl='https://eventos.txs.es' title='Próximos eventos' theme='light' sidebar='false' id='nextevents'></gancio-events><p>No existen mas próximos eventos programados actualmente.</p> <gancio-events baseurl='https://eventos.txs.es' title='Próximos eventos' theme='light' sidebar='false' id='nextevents'></gancio-events>
<div id="msg_non_nexts" style="display:none">
<p>No existen próximos eventos programados actualmente.</p>
</div>
Pasados Pasados
<gancio-events baseurl='https://eventos.txs.es' title='Eventos pasados' theme='light' sidebar='false' past='true'></gancio-events> <gancio-events baseurl='https://eventos.txs.es' title='Eventos pasados' theme='light' sidebar='false' past='true'></gancio-events>
{{% /tabpannel %}} {{% /tabpannel %}}
Si quieres organizar un evento con nosotros {{% doc %}}contáctanos <contact>{{% /doc %}}.
<script src='/assets/js/gancio-events.es.js'></script> <script src='/assets/js/gancio-events.es.js'></script>
{{% gancio-events-detect ge_id='nextevents' tab_next='0' tab_past='1' %}} {{% gancio-events-detect ge_id='nextevents' tab_next='0' tab_past='1' msg_id='msg_non_nexts' %}}