index : flyspray | |
Archlinux32 customized Flyspray installation | gitolite user |
summaryrefslogtreecommitdiff |
-rw-r--r-- | js/callbacks/checkrelated.php | 20 |
diff --git a/js/callbacks/checkrelated.php b/js/callbacks/checkrelated.php new file mode 100644 index 0000000..3ce3ee8 --- /dev/null +++ b/js/callbacks/checkrelated.php @@ -0,0 +1,20 @@ +<?php +/* + Checks if a related tasks belongs to a different project. +*/ + +define('IN_FS', true); + +require_once('../../header.php'); + +$sql = $db->query('SELECT project_id + FROM {tasks} + WHERE task_id = ?', + array(Get::val('related_task'))); + +$relatedproject = $db->fetchOne($sql); + +if (Get::val('project') == $relatedproject || !$relatedproject) { + echo 'ok'; +} +?> |