Гравировка на новый лад.

This commit is contained in:
Igor Barkov [iwork] 2018-12-12 16:58:41 +02:00
parent b96f0eea92
commit 0f6247ccae

View File

@ -47,8 +47,11 @@ if ($_GET['sid'] && $_GET['rep']) {
}
if (input::post('goto') == 'remont') {
$remont_query = db::c()->query('SELECT * FROM `inventory` WHERE `type` < 12 AND `dressed` = 0 AND `isrep` = 1 AND `setsale` = 0 AND `duration` > 0 AND `owner` = ?i ORDER BY `update` DESC', $_SESSION['uid']);
$remont_query = db::c()->query('SELECT `name`,`duration`,`maxdur`,`img`,`id` FROM `inventory` WHERE `type` < 12 AND `dressed` = 0 AND `isrep` = 1 AND `setsale` = 0 AND `duration` > 0 AND `owner` = ?i ORDER BY `update` DESC', $_SESSION['uid']);
}
if (input::post('goto') == 'gravirovka') {
$gravirovka_query = db::c()->query('SELECT * FROM `inventory` WHERE `owner` = ?i AND `dressed` = 0 AND `type` = 3 AND `name` NOT LIKE "?S" AND `setsale` = 0 OR `text` <> "?s" ORDER by `update` DESC', $_SESSION['uid'], '%Букет%', '');
}
?>
@ -127,6 +130,23 @@ if (input::post('goto') == 'remont') {
</div>
</div>
<?php endwhile; endif; ?>
<?php if (input::post('goto') == 'gravirovka'):
while ($row = $gravirovka_query->fetch_assoc()): ?>
<div class="appblock">
<span class="legend"><?= $row['name'] ?></span>
<div style="text-align: center">
[<?= $row['text'] ?>]
<br><img src="i/sh/<?= $row['img'] ?>">
<br><? if (empty($row['text'])) { ?><A HREF="#"
onclick="AddCount(<?= $row['id'] ?>)">
Нанести надпись за 30 кр.</A><BR><? } else {
?><A HREF="?razdel=1&rep=<?= $row['id'] ?>&sid=2">Стереть надпись</A><BR><?
} ?>
</div>
</div>
<?php endwhile; endif; ?>
<TABLE width=100%>
<TR>
<FORM METHOD=POST ACTION="repair.php">