本文整理汇总了PHP中manager::GET方法的典型用法代码示例。如果您正苦于以下问题:PHP manager::GET方法的具体用法?PHP manager::GET怎么用?PHP manager::GET使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类manager
的用法示例。
在下文中一共展示了manager::GET方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: printArray
public function printArray($all)
{
if (is_array($all)) {
// Kint::dump($all);
echo "<table border=1px>";
echo "\r\n\t\t\t\t<thead>\r\n\t\t\t\t\t<th></th>\r\n \t\t\t\t<th>id</th>\r\n \t\t\t\t\t<th>Задание</th>\r\n \t\t\t\t\t<th>Описание</th>\r\n \t\t\t\t\t<th>Поручено</th>\r\n \t\t\t\t\t<th>Срок</th>\r\n \t\t\t\t\t<th>Окончено</th>\r\n \t\t\t\t\t<th>Кто поручил</th>\r\n \t\t\t\t\t<th>Кому поручено</th>\r\n \t\t\t\t\t<th>Приоритет</th>\r\n \t\t\t\t\t<th>Статус</th>\r\n \t\t\t\t\t<th>Сайт</th>\r\n\t\t\t\t</thead>";
foreach ($all as $x) {
$id = $x->id;
$hostingName = hosting::GET($x->hostingID)->name;
$managerName = manager::GET($x->managerID)->name;
$registratorName = registrator::GET($x->registratorID)->name;
$from = $_SERVER['REQUEST_URI'];
echo "\r\n\t\t\t\t\t<tr>\r\n\t\t\t\t\t\t<td>\r\n\t\t\t\t\t\t\t<a href=\"/task/edit/{$id}?return-url={$from}\">\r\n\t\t\t\t\t\t\t\tE\r\n\t\t\t\t\t\t\t</a>\r\n\t\t\t\t\t\t</td>\r\n\t\t\t\t\t\t<td>\r\n\t\t\t\t\t\t\t<a href=\"/task/view/{$id}\">\r\n\t\t\t\t\t\t\t\t{$id}\r\n\t\t\t\t\t\t\t</a>\r\n\t\t\t\t\t\t</td>\r\n\t\t\t\t\t\t<td><a href=\"/task/view/{$id}\">\r\n\t\t\t\t\t\t\t{$x->name}\r\n\t\t\t\t\t\t</td></a>\r\n\t\t\t\t\t\t<td>{$x->description}</td>\r\n\t\t\t\t\t\t<td>";
if (!is_null($x->insert_datetime)) {
echo DateTime::createFromFormat("M d Y h:i:s:uA", $x->insert_datetime)->format("Y-m-d H:i");
}
echo "</td>\r\n\t\t\t\t\t\t<td>";
if (!is_null($x->deadlineDate)) {
echo DateTime::createFromFormat("M d Y h:i:s:uA", $x->deadlineDate)->format("Y-m-d H:i");
}
echo "</td>\r\n\t\t\t\t\t\t<td>";
if (!is_null($x->finishedDate)) {
echo DateTime::createFromFormat("M d Y h:i:s:uA", $x->finishedDate)->format("Y-m-d H:i");
}
echo "</td>\r\n\t\t\t\t\t\t<td><a href=\"/user/view/{$x->giver_userID}\">\r\n\t\t\t\t\t\t\t" . user::GET($x->giver_userID)->username . "\r\n\t\t\t\t\t\t</a></td>\r\n\t\t\t\t\t\t<td><a href=\"/user/view/{$x->doer_userID}\">\r\n\t\t\t\t\t\t\t" . user::GET($x->doer_userID)->username . "\r\n\t\t\t\t\t\t</a></td>\r\n\t\t\t\t\t\t<td>" . priority::GET($x->priorityID)->name . "</td>\r\n\t\t\t\t\t\t<td>" . status::GET($x->statusID)->name . "</td>\r\n\t\t\t\t\t\t<td><a href=\"/site/view/{$x->siteID}\">" . site::GET($x->siteID)->name . "</a></td>\r\n\t\t\t\t\t</tr>\r\n\t\t\t\t";
}
echo "</table>";
}
}
示例2: confirm
<a href="/manager">INDEX</a><br><br>
<?php
global $menuHover;
$menuHover->Add("Все", "/manager");
$menuHover->Add("Новый", "/manager/new");
$menuHover->Add("Изменить", "/manager/edit/" . $args['id']);
$menuHover->Add("Удалить", "/manager/delete/" . $args['id'], "return confirm('Are you sure?');");
?>
<?php
$current = manager::GET($args['id']);
echo 'id: ' . $current->id . '<br>name: ' . $current->name;
?>
<br><br>
<!-- <a href="/manager/edit/<?php
echo $args['id'];
?>
">EDIT</a><br>-->
<!-- <a href="/manager/delete/<?php
echo $args['id'];
?>
" onclick="return confirm('Are you sure?');">DELETE</a><br>-->
<br><br><h3>sites of manager</h3>
<?php
site::printArray(site::GETSQL("SELECT * FROM site WHERE deleted = 0 AND managerID=" . $current->id));
示例3: printOne
public function printOne($site)
{
$id = $site->id;
$hostingName = hosting::GET($site->hostingID)->name;
$managerName = manager::GET($site->managerID)->name;
$registratorName = registrator::GET($site->registratorID)->name;
echo "<table>";
echo "<tr><td><b>\tid\t\t\t</b></td><td>\t\t\t\t\t\t\t\t\t\t\t\t\t\t{$site->id}\t\t\t</a></td></tr>";
echo "<tr><td><b>\tИмя\t\t\t</b></td><td>\t\t\t\t\t\t\t\t\t\t\t\t\t\t{$site->name}\t\t\t</a></td></tr>";
echo "<tr><td><b>\tХостинг\t\t</b></td><td><a \thref=\"/hosting/view/{$site->hostingID}\">\t\t{$hostingName}\t\t</a></td></tr>";
echo "<tr><td><b>\tМенеджер\t</b></td><td><a \thref=\"/manager/view/{$site->managerID}\">\t\t{$managerName}\t\t</a></td></tr>";
echo "<tr><td><b>\tРегистратор\t</b></td><td><a href=\"/registrator/view/{$site->registratorID}\">\t{$registratorName}\t</a></td></tr>";
echo "</table>";
}
示例4: confirm
<!-- <a href="/manager">INDEX</a><br><br>-->
<?php
global $menuHover;
$menuHover->Add("Все", "/manager");
$menuHover->Add("Новый", "/manager/new");
$menuHover->Add("Просмотр", "/manager/view/" . $args['id']);
$menuHover->Add("Удалить", "/manager/delete/" . $args['id'], "return confirm('Are you sure?');");
?>
<form method="post">
name:<input name="name" type="text" value="<?php
echo manager::GET($args['id'])->name;
?>
">
<input type="submit">
</form>
<!-- <a href="/manager/view/<?php
echo $args['id'];
?>
">VIEW</a><br> -->