HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/SBogers10/topswtw.komma.pro/app/storage/views/3c7c1f332d0860ba6f30cab307e190fd
<p class="select-links">
    <?php echo Lang::get('kms::actions.select'); ?><br/>
    <a href="#" id="shipmentSelectAll">alles</a>
    <?php foreach($shops as $shop): ?>
        <a href="#" id="shipmentSelectShop"
           onclick="selectOrders(<?php echo $shop->id; ?>)"><?php echo $shop->short_name; ?></a>

    <?php endforeach; ?>
</p>
<p class="select-links">
    <?php echo Lang::get('kms::actions.deselect'); ?><br/>
    <a href="#" id="shipmentDeselectAll">alles</a>
    <?php foreach($shops as $shop): ?>
        <a href="#" id="shipmentDeselectShop"
           onclick="deselectOrders(<?php echo $shop->id; ?>)"><?php echo $shop->short_name; ?></a>
    <?php endforeach; ?>
</p>

<table width="100%" cellspacing="0" cellpadding="0" border="0" id="shipmentOrderSelectTable">
    <tr>
        <th align="left"></th>
        <th align="left">#</th>
        <th align="left"><?php echo Lang::get('kms::global.shop'); ?></th>
        <th align="left"><?php echo Lang::get('kms::global.name'); ?></th>
        <th align="left"><?php echo Lang::get('kms::global.price'); ?></th>
        <th align="left"><?php echo Lang::get('kms::global.date'); ?></th>
        <th align="left"><?php echo Lang::get('kms::global.status'); ?></th>
    </tr>


    <?php foreach($orders as $order): ?>
        <tr class="shop-<?php echo $order->shop_id; ?>">
            <td><input type="checkbox" name="order_<?php echo $order->id; ?>" value="1"/></td>
            <td><?php echo $order->order_number; ?></td>
            <td><?php echo $shops[$order->shop_id]->short_name; ?></td>
            <td><?php echo $order->getFullInvoiceName(); ?></td>
            <td>&euro;&nbsp;<?php echo price($order->getTotalToPay()); ?></td>
            <td><?php echo helper_localize_date($order->ordered_at); ?></td>
            <td><?php echo Lang::get('kms::orders.'.$order->status); ?></td>
            <td>
                <a href="<?php echo route('kms.orders.edit', ['orders' => $order->id]); ?>">    <?php echo Lang::get('kms::actions.view'); ?></a>
            </td>
        </tr>
    <?php endforeach; ?>
</table>

<script>
    $(function () {
        function selectAllShipments() {
            $("#shipmentOrderSelectTable input[type='checkbox']").prop('checked', true);
        }

        function deselectAllShipments() {
            $("#shipmentOrderSelectTable input[type='checkbox']").prop('checked', false);
        }


        $("#shipmentSelectAll").click(selectAllShipments);
        $("#shipmentDeselectAll").click(deselectAllShipments);
    });
    function selectOrders(shop) {
        $("#shipmentOrderSelectTable tr.shop-" + shop + "  input[type='checkbox']").prop('checked', true);
    }
    function deselectOrders(shop) {
        $("#shipmentOrderSelectTable tr.shop-" + shop + "  input[type='checkbox']").prop('checked', false);
    }
</script>