Skip to content
Snippets Groups Projects
Commit a199ba73 authored by Axel Hahn's avatar Axel Hahn
Browse files

- fix for overview (non existing localstorage returns null)

parent 0bd322d9
No related branches found
No related tags found
No related merge requests found
...@@ -212,33 +212,30 @@ class projectlist extends base{ ...@@ -212,33 +212,30 @@ class projectlist extends base{
*/ */
function setDefaultView(){ function setDefaultView(){
var sPrj=false;
var sPhase=false;
if(localStorage.getItem("selectedPrj")!=\'null\'){ if(localStorage.getItem("selectedPrj")!=\'null\'){
$("#prjfilter").val(localStorage.getItem("selectedPrj")); $("#prjfilter").val(localStorage.getItem("selectedPrj"));
} else {
$("#prjfilter").val($("#prjfilter option:first").val());
} }
if (localStorage.getItem("selectedPhase")!=\'null\'){ if (localStorage.getItem("selectedPhase")!=\'null\'){
$("#phasefilter").val(localStorage.getItem("selectedPhase")); $("#phasefilter").val(localStorage.getItem("selectedPhase"));
} else {
$("#phasefilter").val($("#phasefilter option:first").val());
} }
sPrj=$("#prjfilter").val();
sPhase=$("#phasefilter").val();
if (sPrj + sPhase) {
window.setTimeout("filterOverviewTable();", 10); window.setTimeout("filterOverviewTable();", 10);
}
if (localStorage.getItem("efilter")) { if (localStorage.getItem("efilter")!=\'null\') {
$("#efilter").val(localStorage.getItem("efilter")); $("#efilter").val(localStorage.getItem("efilter"));
window.setTimeout("filterTable();", 10); window.setTimeout("filterTable();", 10);
} }
if (localStorage.getItem("role")) { if (localStorage.getItem("role")!=\'null\') {
$("#rolefilter").val(localStorage.getItem("role")); $("#rolefilter").val(localStorage.getItem("role"));
window.setTimeout("setrole();", 20); window.setTimeout("setrole();", 20);
} }
var sMode=localStorage.getItem("mode"); var sMode=localStorage.getItem("mode");
if (sMode)setview(sMode); if (sMode)setview(sMode);
} }
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment