diff --git a/app/static/app/js/UpdateInfoControl.js b/app/static/app/js/UpdateInfoControl.js new file mode 100644 index 0000000..30d3f9e --- /dev/null +++ b/app/static/app/js/UpdateInfoControl.js @@ -0,0 +1,16 @@ +/* ALLES RUND UM DIE UPDATE INFO MELDUNG */ + +function setUpdateOk() { + document.getElementById('update_content').style.display = 'none'; + document.getElementById('dashboard').classList.remove('d-none'); + document.getElementById('refresh_icon').classList.remove('d-none') + document.getElementById('settings_icon').classList.remove('d-none') +} + +document.getElementById("allUpdateOk").addEventListener('click', function(){ + localStorage.setItem('UpdateInfoRead', "true"); + setUpdateOk(); +}) + +const UpdateInfoReadingState = localStorage.getItem('UpdateInfoRead'); +if (UpdateInfoReadingState === "true") {setUpdateOk();} \ No newline at end of file diff --git a/app/static/app/js/home.js b/app/static/app/js/home.js index e6f88ba..03977a4 100644 --- a/app/static/app/js/home.js +++ b/app/static/app/js/home.js @@ -168,7 +168,7 @@ async function getActualDataAndFillView() { // DATEN VON SETTINGS ABFRAGEN getAllEntries('settings') .then(function(result) { - document.getElementById('studysinput').value = parseInt(result.find(element => element.SettingsID === 1).SettingsValue) + document.getElementById('studysinput').value = (result.find(element => element.SettingsID === 1) == undefined) ? 0 : parseInt(result.find(element => element.SettingsID === 1).SettingsValue) document.getElementById('MonthGoalInput').value = (result.find(element => element.SettingsID === 2) == undefined) ? 50 : parseInt(result.find(element => element.SettingsID === 2).SettingsValue) MonthGoal = (result.find(element => element.SettingsID === 2) == undefined) ? 50 : parseInt(result.find(element => element.SettingsID === 2).SettingsValue) }); diff --git a/app/static/app/js/welcomeControl.js b/app/static/app/js/welcomeControl.js index 42963c8..afbbe9b 100644 --- a/app/static/app/js/welcomeControl.js +++ b/app/static/app/js/welcomeControl.js @@ -2,9 +2,11 @@ function setAllOk() { document.getElementById('welcome_content').style.display = 'none'; - document.getElementById('dashboard').classList.remove('d-none'); - document.getElementById('refresh_icon').classList.remove('d-none') - document.getElementById('settings_icon').classList.remove('d-none') + if (localStorage.getItem('UpdateInfoRead')) { + document.getElementById('dashboard').classList.remove('d-none'); + document.getElementById('refresh_icon').classList.remove('d-none') + document.getElementById('settings_icon').classList.remove('d-none') + } } document.getElementById("allOk").addEventListener('click', function(){ diff --git a/app/templates/app/home.html b/app/templates/app/home.html index 10cee05..a85ea93 100644 --- a/app/templates/app/home.html +++ b/app/templates/app/home.html @@ -34,6 +34,13 @@ +
+ Wie versproche geht es weiter!
+
Ja kleine Schritte, aber ich hoffe hilfreich 😀
+
+
Was ist neu?
+
1. Die Einstellungen oben Rechts
+
2. Einstellugnen: Bibelstudien pflegen
+
3. Einstellungen: Eigenes Monatsziel
+
+
Fehlerbehebung:
+
1. Einträge nach Datum sortieren nicht nach Hinzufügen
+
+
Viel Freude beim Testen und Gruß,
+
Samuel
+
+