mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 06:39:11 +00:00
98_todoist: bugfix - better move to other project in widget
git-svn-id: https://svn.fhem.de/fhem/trunk@20971 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
8ff0b19927
commit
6f4de21ea6
@ -787,10 +787,10 @@ sub todoist_HandleTaskCallback($$$){
|
||||
# remove line in possible webling widget
|
||||
map {FW_directNotify("#FHEMWEB:$_", "if (typeof todoist_removeLine === \"function\") todoist_removeLine('$name','$taskId')", "")} devspec2array("TYPE=FHEMWEB");
|
||||
}
|
||||
if ($param->{wType} eq "create") {
|
||||
if ($param->{wType} eq "create" || $param->{wType} eq "move") {
|
||||
if ($param->{parentId}) {
|
||||
# set parent id with additional updateTask command / API cannot add it in create
|
||||
CommandSet(undef, "$name updateTask ID:$taskId parent_id=".$param->{parentId});
|
||||
CommandSet(undef, "$name moveTask ID:$taskId parent_id=".$param->{parentId});
|
||||
Log3 $name, 3, "todoist ($name): startet set parent_id over update after create: Task-ID: ".$taskId." - parent_id: ".$param->{parentId};
|
||||
}
|
||||
# add a line in possible weblink widget
|
||||
|
@ -322,6 +322,7 @@ if (typeof todoist_checkVar === 'undefined') {
|
||||
var nameHT = tid.split("_");
|
||||
var lastVal = nameHT.pop(); // Get last element
|
||||
var nameH = nameHT.join("_");
|
||||
todoist_refreshTable(nameH);
|
||||
//todoist_sendCommand('set ' + nameH + ' deleteTask ID:'+ id);
|
||||
},
|
||||
over: function (event,ui) {
|
||||
@ -349,6 +350,7 @@ if (typeof todoist_checkVar === 'undefined') {
|
||||
var pid = parent.data('project-id');
|
||||
var value = ui.item.find('span').html();
|
||||
todoist_sendCommand('set '+ nameF +' moveTask ID:' + id + ' projectID=' + pid);
|
||||
todoist_refreshTable(nameR,1);
|
||||
ui.item.attr('data-remove','1');
|
||||
}
|
||||
}).disableSelection();
|
||||
|
Loading…
Reference in New Issue
Block a user