X-Git-Url: http://git.harvie.cz/?a=blobdiff_plain;ds=inline;f=inc%2Feventz%2Fdelete.inc;fp=inc%2Feventz%2Fdelete.inc;h=bc4ec0e427a6658098ebc4637b3c397245bdad72;hb=e586807dafc64c3fe152ab518599e6cf3f0f84e1;hp=0000000000000000000000000000000000000000;hpb=bc13d5d6e1834068f8b690c32bba114e352dacdd;p=mirrors%2FKyberia-bloodline.git diff --git a/inc/eventz/delete.inc b/inc/eventz/delete.inc new file mode 100644 index 0000000..bc4ec0e --- /dev/null +++ b/inc/eventz/delete.inc @@ -0,0 +1,78 @@ +query($q); + echo $q; + if (!empty($vector)) { + $q="select node_id from nodes where node_vector like '$vector%'"; + echo $q; + $cset=$db->query($q); + while ($cset->next()) { + $chosen_child=$cset->getString('node_id'); + $q="insert into tiamat (node_id,node_name,node_parent,node_vector, +node_external_access,node_system_access,node_children_count,node_creator,node_created,lastchild_created,k, +node_views,node_destructor,node_content,node_descendant_count,lastdescendant_created,template_id,external_link) +select nodes.node_id,node_name,node_parent,node_vector,node_external_access,node_system_access, +node_children_count,node_creator,node_created,lastchild_created,k,node_views,'$user_id',node_content, +node_descendant_count,lastdescendant_created,template_id,external_link from nodes left join node_content on nodes.node_id=node_content.node_id where nodes.node_id='$chosen_child'"; + echo $q; + $db->query($q); + + } + } + log::log('delete',$chosen,'ok',$_SESSION['user_id']); + } + else { + global $error_messages; + $error=$error_messages['EVENT_PERMISSION_ERROR']; + log::log('delete',$chosen,'EVENT_PERMISSION_ERROR',$_SESSION['user_id']); + return false; + } + + + + } + +} +?> \ No newline at end of file