Commit 0a63216c authored by Dominik Hebeler's avatar Dominik Hebeler

Merge branch...

Merge branch '477-nach-dem-loschen-eines-eigenen-fokus-ist-kein-fokus-mehr-eingestellt' into 'development'

Fokus wird jetzt nach dem löschen eines ausgewählten Fokus auf Web gestellt

Closes #477

See merge request !828
parents 84d82c63 16f1538f
This diff is collapsed.
......@@ -258,6 +258,9 @@ function saveFocus() {
*/
function deleteFocus() {
var oldId = document.getElementById("original-id").value;
if ($('#' + oldId).prop('checked')) {
setFocusToDefault()
}
localStorage.removeItem(oldId);
removeFocusById(oldId);
$("#create-focus-modal").modal("hide");
......@@ -405,4 +408,12 @@ function resetOptions() {
localStorage.removeItem(key);
}
}
}
function setFocusToDefault() {
setFocus('web')
}
function setFocus(focusID) {
$('#' + focusID).prop('checked', true)
}
\ No newline at end of file
......@@ -2,7 +2,7 @@
"js/editLanguage.js": "js/editLanguage-7a1cbfb2ba.js",
"js/kontakt.js": "js/kontakt-de49d68db3.js",
"js/scriptResultPage.js": "js/scriptResultPage-357d27fe23.js",
"js/scriptStartPage.js": "js/scriptStartPage-8f01e5974d.js",
"js/scriptStartPage.js": "js/scriptStartPage-a59b8ddf71.js",
"js/settings.js": "js/settings-6ff0eab621.js",
"js/widgets.js": "js/widgets-866379dd63.js"
}
\ No newline at end of file
......@@ -258,6 +258,9 @@ function saveFocus() {
*/
function deleteFocus() {
var oldId = document.getElementById("original-id").value;
if ($('#' + oldId).prop('checked')) {
setFocusToDefault()
}
localStorage.removeItem(oldId);
removeFocusById(oldId);
$("#create-focus-modal").modal("hide");
......@@ -405,4 +408,12 @@ function resetOptions() {
localStorage.removeItem(key);
}
}
}
function setFocusToDefault() {
setFocus('web')
}
function setFocus(focusID) {
$('#' + focusID).prop('checked', true)
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment