2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-04-14 09:35:29 +00:00

98_weekprofile: fix handle csrfToken

git-svn-id: https://svn.fhem.de/fhem/trunk@13977 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
Risiko 2017-04-12 20:14:24 +00:00
parent 18445e421a
commit 205335236a
2 changed files with 6 additions and 1 deletions

View File

@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it.
- bugfix: 98_weekprofile: handle csrfToken
- bugfix: 02_HTTPSRV: strip parameters from filename
- bugfix: 88_HMCCURPC: fixed binary RPC init procedure
- feature: 93_DBLog: new version 2.16.3, new command addlog,

View File

@ -137,7 +137,11 @@ function weekprofile_DoEditWeek(devName,newPage)
var widget = $('div[informid="'+devName+'"]').get(0);
if (newPage == 1) {
window.location.assign(FW_root+'?cmd={weekprofile_editOnNewpage("'+widget.DEVICE+'","'+widget.CURTOPIC+':'+widget.CURPRF+'");;}');
var csrfToken = $("body").attr('fwcsrf');
var url = FW_root+'?cmd={weekprofile_editOnNewpage("'+widget.DEVICE+'","'+widget.CURTOPIC+':'+widget.CURPRF+'");;}';
if (csrfToken)
url = url + '&fwcsrf='+ csrfToken;
window.location.assign(url);
} else {
widget.MODE = 'EDIT';
$(widget.MENU.BASE).hide();