<div class="row">
    <div class="col-md-11"><h4 class="text-left mt-3">Play Session Single User List</h4></div>

    <div class="col-md-1"><a href="<?= base_url('record') ?>" class="btn btn-sm btn-warning mt-1">Back</a></div>
</div>

<hr>

<table id="single_user" class="table table-bordred table-striped">
    <thead>

        <tr>
            <th>Single User</th>
            <th>Gender</th>
            <th>Audience&nbsp;Type</th>
            <th>Admin&nbsp;Name</th>
            <th>Date&nbsp;Time</th>



            <th style="min-width: 100px">Detail</th>
        </tr>

    </thead>
    <tbody>
        <?php
        if (isset($list_single_user) and $list_single_user) {
            foreach ($list_single_user as $value) {
                ?>
                <tr id="<?= $value['sessionId'] ?>">
                    <td class="text-left"><?= $value['name'] ?></td>
                    <td class="text-left"><?= $value['singleModeGender'] ?></td>
                    <td class="text-left"><?= $value['audienceType'] ?></td>
                    <td class="text-left"><p id="type_<?= $value['sessionId'] ?>"><?= $value['userName'] ?></p></td><!-- comment -->
                    <td class="text-left"><?= date('d-m-Y h:i:s a', strtotime($value['createAt'])) ?></td>


                    <td class="text-left">
                        <div class="" id="<?= 'spinner_' . $value['sessionId'] ?>" style="display: none;margin-top: 2px;">
                            <span class="success"><i class="fa fa-spinner fa-spin"></i></span>
                        </div>
                        <button type="button"  class="btn btn-primary btn-sm get_session_detail" value="<?= $value['sessionId'] ?>">Detail</button>

                    </td>
                </tr>
                <?php
            }
        } else {
            ?>


            <tr >

                <td class="text-center" colspan="6">No data</td>

            </tr>

        <?php }
        ?>

    </tbody>

</table>


