Example #1
0
 function project($id = "-1")
 {
     global $loginInst;
     if ($id != "-1") {
         $this->activate($id);
     }
     $this->logger = new logger();
     $this->logger->setUser($loginInst);
     $this->logger->setToken("PROJECT");
     // call super constructor
     parent::priority();
 }
Example #2
0
		$file = $common->direct_replace($db_object,$file,$val);
		echo $file;
	}//end view
	function delete($db_object,$common,$default,$user_id,$pid,$min,$err)
	{
		$priority_table = $common->prefix_table("priority");
		$qry1 = "select count(p_id) from $priority_table ";
		$res = $db_object->get_single_column($qry1);
		$chk = $res[0];
		if($chk > $min)
		{
			$qry = "delete from $priority_table where p_id='$pid'";
			$db_object->insert($qry);
		}
		else
		{
			echo $err['cSorryminpriority']." ".$min;
		}
		
	}//end delete
}//end class
	$ob = new priority;
	if($pid!="")
	{
		$ob->delete($db_object,$common,$default,$user_id,$pid,$gbl_min_priority,$error_msg);
	}
	$ob->view_form($db_object,$common,$default,$user_id);
	
include_once("footer.php");
?>
Example #3
0
 function request($id = "-1")
 {
     global $loginInst;
     if ($id != "-1") {
         $this->activate($id);
     }
     $this->logger = new logger();
     $this->logger->setUser($loginInst);
     $this->logger->setToken("REQUEST");
     $this->loadTypes();
     // call super constructor
     parent::priority();
 }
    echo " <option ";
    if ($doer->id == $current->doer_userID) {
        echo " selected ";
    }
    echo ' value="' . $doer->id . '" ';
    echo " > ";
    echo $doer->username;
    echo " </option> ";
}
?>
	</select>
	
	Приоритет: <select name="priorityID">
		<option disabled selected>Выберите приоритет</option>
		<?php 
$priorities = priority::GETALL();
foreach ($priorities as $priority) {
    echo " <option ";
    if ($priority->id == $current->priorityID) {
        echo " selected ";
    }
    echo ' value="' . $priority->id . '"';
    echo " > ";
    echo $priority->name;
    echo " </option> ";
}
?>
	</select>	
	
	Статус: <select name="statusID">
		<option disabled selected>Выберите статус</option>
Example #5
0
function getpriorities($obj)
{
    $priority = new priority();
    return $priority->getall();
}
Example #6
0
 public function printOne($task)
 {
     echo "<table>";
     echo "<tr><td><b>\tid\t\t\t</b></td><td>\t\t\t\t {$task->id}\t\t\t\t\t\t  </a></td></tr>";
     echo "<tr><td><b>\tЗадание\t\t</b></td><td>\t\t\t\t {$task->name}\t\t\t\t\t  </a></td></tr>";
     echo "<tr><td><b>\tОписание\t</b></td><td>\t\t\t\t {$task->description}\t\t\t\t  </a></td></tr>";
     echo "<tr><td><b>\tПоручено\t</b></td><td>";
     if (!is_null($task->insert_datetime)) {
         echo DateTime::createFromFormat("M d Y h:i:s:uA", $task->insert_datetime)->format("Y-m-d H:i");
     }
     echo "</a></td></tr>";
     echo "<tr><td><b>\tСрок\t\t</b></td><td>";
     if (!is_null($task->deadlineDate)) {
         echo DateTime::createFromFormat("M d Y h:i:s:uA", $task->deadlineDate)->format("Y-m-d H:i");
     }
     echo "</a></td></tr>";
     echo "<tr><td><b>\tОкончено\t</b></td><td>";
     if (!is_null($task->finishedDate)) {
         echo DateTime::createFromFormat("M d Y h:i:s:uA", $task->finishedDate)->format("Y-m-d H:i");
     }
     echo "</a></td></tr>";
     echo "<tr><td><b>\tКто поручил\t</b></td><td>" . user::GET($task->giver_userID)->username . "</a></td></tr>";
     echo "<tr><td><b>\tКому поручено</b></td><td>" . user::GET($task->doer_userID)->username . "</a></td></tr>";
     echo "<tr><td><b>\tПриоритет\t</b></td><td>" . priority::GET($task->priorityID)->name . "</a></td></tr>";
     echo "<tr><td><b>\tСтатус\t\t</b></td><td>" . status::GET($task->statusID)->name . "</a></td></tr>";
     echo "<tr><td><b>\tСайт\t\t</b></td><td><a href=\"/site/view/{$task->siteID}\">" . site::GET($task->siteID)->name . "</a>\t\t\t\t\t  </a></td></tr>";
     echo "</table>";
 }