Новый способ отображать предметы
This commit is contained in:
parent
65a6d133cc
commit
9fcbfb7ba4
17
repair.php
17
repair.php
@ -48,6 +48,11 @@ if ($_GET['sid'] && $_GET['rep']) {
|
||||
}
|
||||
}
|
||||
|
||||
if (input::post('goto') == 'remont') {
|
||||
$data = db::c()->query('SELECT * FROM `inventory` WHERE `type` < 12 AND `dressed` = 0 AND `isrep` = 1 AND `setsale` = 0 AND `owner` = ?i ORDER BY `update` DESC', $_SESSION['uid']);
|
||||
$onecost = 0.1;
|
||||
}
|
||||
|
||||
?>
|
||||
<HTML>
|
||||
<HEAD>
|
||||
@ -113,6 +118,16 @@ if ($_GET['sid'] && $_GET['rep']) {
|
||||
<span class="wrap"><?= $status ?></span>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php if (input::post('goto') == 'remont'):
|
||||
while ($row = $data->fetch_assoc()): ?>
|
||||
<div class="appblock">
|
||||
<span class="legend"><?= $row['name'] ?></span>
|
||||
<div style="text-align: center">
|
||||
<img src="i/sh/<?= $row['img'] ?>">
|
||||
<a href="?rep=<?= $row['id'] ?>&sid=full">Ремонт за <?= round(($row['duration'] * $onecost), 2) ?> кр.</a>
|
||||
</div>
|
||||
</div>
|
||||
<?php endwhile; endif; ?>
|
||||
<TABLE width=100%>
|
||||
<TR>
|
||||
<FORM METHOD=POST ACTION="repair.php">
|
||||
@ -123,9 +138,7 @@ if ($_GET['sid'] && $_GET['rep']) {
|
||||
<TABLE WIDTH=100% BGCOLOR="#A5A5A5">
|
||||
<?php
|
||||
if (input::post('goto') == 'remont') {
|
||||
$data = db::c()->query('SELECT * FROM `inventory` WHERE `type` < 12 AND `dressed` = 0 AND `isrep` = 1 AND `setsale` = 0 AND `owner` = ?i ORDER BY `update` DESC', $_SESSION['uid']);
|
||||
while ($row = $data->fetch_assoc()) {
|
||||
$onecost = 0.1;
|
||||
?>
|
||||
<TR>
|
||||
<TD align=center><IMG SRC="i/sh/<?= $row['img'] ?>">
|
||||
|
Loading…
Reference in New Issue
Block a user