1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889 |
- <?php /** Created by Anton on 14.02.2020. */
- use app\models\entity\TmcStatus;
- use app\models\entity\Warehouse;
- ?>
- <link href="/tmc/css/main.min.css" rel="stylesheet">
- <style type="text/css">
- .main_content {
- top: 125px;
- padding: 0;
- display: inline-flex;
- }
- </style>
- <div class="menuTask loco-scrol-blue scroller">
- <div style="height: calc(100vh - 178px);" class="loko-div">
- <ul class="nav nav-tabs">
- <?php /** @var Warehouse $warehouse */ ?>
- <?php foreach ($warehouses as $warehouse): ?>
- <li>
- <a data-toggle="tab" href="panel<?= $warehouse->id ?>">
- <?= $warehouse->number . ' склад' ?>
- </a>
- </li>
- <?php endforeach; ?>
- </ul>
- <div class="tab-content">
- <?php foreach ($devices as $warehouseId => $warehouse): ?>
- <div id="panel<?= $warehouseId ?>" class="tab-pane">
- <div class="boxB4" style="padding: 15px 0;">
- <div class="inpBox">
- <input class="js-search" type="text" placeholder="Поиск">
- <img src="/images/find.svg" alt="">
- </div>
- </div>
- <h5>Стеллажи:</h5>
- <div class="boxB5">
- <div class="accordion">
- <?php foreach ($warehouse['stacks'] as $stackId => $stack): ?>
- <div class="trigger">
- <input type="checkbox" id="checkbox-<?= $i ?>" class="loco_checkbox"/>
- <label for="checkbox-<?= $i++ ?>" class="checkbox">
- <?= $stack['title']; ?>
- <t class="loco_info" style="float:right; margin-right: 35px">
- <b><?= count(array_filter($stack['tmcs'], function ($device) {
- return in_array($device['id_status'], [
- TmcStatus::TMC_STATUS_IN_STORAGE,
- TmcStatus::TMC_STATUS_IN_CHARGE
- ]);
- })) ?></b>
- </t>
- <t class="loco_info_red" style="float:right; margin-right: 5px">
- <b><?= count(array_filter($stack['tmcs'], function ($device) {
- return $device['id_status'] == TmcStatus::TMC_STATUS_ISSUED;
- })) ?></b></t>
- <t class="loco_info" style="padding: 5px; float:right; margin-right: 5px"><b><?= count($stack['tmcs']) ?></b></t>
- <i></i>
- </label>
- <div class="tmc-content loco-scrol-null scroller_null">
- <?php foreach ($stack['tmcs'] as $device): ?>
- <a href="tmc\detail\cell.php?id=<?= $device['storage'] ?>">
- <div>
- <h5>
- <?= $device['storage'] ?>
- <t class="loco_grey" style="float:right"><?= $device['name'] ?></t>
- </h5>
- <t class="<?= getColorByStatus((int)$device['id_status']) ?>">
- <?= $device['status'] ?>
- </t>
- <?php if ($device['user']): ?>
- <t class="loco_grey" style="float:right"><?= $device['user'] ?></t>
- <?php endif; ?>
- </div>
- </a>
- <?php endforeach; ?>
- </div>
- </div>
- <?php endforeach; ?>
- </div>
- </div>
- </div>
- <?php endforeach; ?>
- </div>
- </div>
- </div>
- <div role="log" aria-live="assertive" aria-relevant="additions" class="ui-helper-hidden-accessible"></div>
- <script type="application/javascript" src="tmc/js/storage.js"></script>
- <script type="application/javascript" src="tmc/js/search.js"></script>
|