#12200 Added setup flag for easter egg
This commit is contained in:
parent
4ba13ad0e7
commit
9f72dd7d6e
|
@ -1328,7 +1328,7 @@ if (is_ajax()) {
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<th style="width: 40%; border: 0px;">
|
<th style="width: 40%; border: 0px;">
|
||||||
<a href="javascript:christmas_click()">
|
<a href="javascript:christmas_click('.$config['eastern_eggs_disabled'].')">
|
||||||
<img src="'.$image_about.'" alt="logo" width="70%">
|
<img src="'.$image_about.'" alt="logo" width="70%">
|
||||||
<input id="count_click" type="hidden" value="0" />
|
<input id="count_click" type="hidden" value="0" />
|
||||||
</a>
|
</a>
|
||||||
|
|
|
@ -2558,11 +2558,11 @@ function WarningPeriodicityModal(title, message) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function christmas_click() {
|
function christmas_click(flagEasternEgg) {
|
||||||
let counter = $("#count_click").val();
|
let counter = $("#count_click").val();
|
||||||
counter++;
|
counter++;
|
||||||
$("#count_click").val(counter);
|
$("#count_click").val(counter);
|
||||||
if (counter == 25) {
|
if (counter == 25 && flagEasternEgg == true) {
|
||||||
$("#container-snow").removeClass("invisible");
|
$("#container-snow").removeClass("invisible");
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
$("#container-snow").addClass("invisible");
|
$("#container-snow").addClass("invisible");
|
||||||
|
|
|
@ -1682,8 +1682,10 @@ require 'include/php_to_js_values.php';
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
const date = new Date();
|
const date = new Date();
|
||||||
const today = date.toLocaleDateString();
|
const today = date.toLocaleDateString();
|
||||||
const christmasDay = "25-12-2023";
|
const year = date.getFullYear();
|
||||||
if (today == christmasDay) {
|
const christmasDay = "25/12/"+year;
|
||||||
|
let flagEasternEgg = $("#flagEasternEgg").val();
|
||||||
|
if (today === christmasDay && flagEasternEgg == true) {
|
||||||
$("#container-snow").removeClass('invisible');
|
$("#container-snow").removeClass('invisible');
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
$("#container-snow").addClass('invisible');
|
$("#container-snow").addClass('invisible');
|
||||||
|
|
Loading…
Reference in New Issue