<!-- Form elements -->

<div class="grid_12">

    <div class="float-right">

        <a href="<?= base_url() ?>authorization/admin_users" class="button">

            <span>قائمة المستخدمين<img src="<?= base_url() ?>global/modules/admin/images/plus-small.gif" width="12" height="9" alt="New new" /></span>

        </a>

    </div>

    <div class="module">

        <h2><span><?php echo lang('visitor_name'); ?></span></h2>

        <div class="module-body">

            <?php echo form_open('visitors/admin_visitors/show', array('id' => 'visitor_display')) ?>

            <?php echo $this->template->flash_msg(); ?>

            <p>

                <label><?php echo lang('visitor_name'); ?>:

                    <?php echo $user_detail->user_username ?></label>

            </p>

            <p>

                <label><?php echo lang('visitor_mail'); ?>:

                    <?php echo $user_detail->user_email ?></label>

            </p>

            <p>

                <label><?php echo lang('date') ?>:

                    <?php echo $user_detail->user_created_date ?></label>

            </p>



            <p>

                <label><?php echo lang('sales_count') ?>:

                    <?php echo $user_detail->sales_count ?></label>

            </p>









            <?php if ($user_sales == FALSE) { ?>



                <br/>

                <span class="notification n-attention"><?php echo lang('msg_empty'); ?></span>

            <?php } else { ?>                             

                <!--<div class="module">-->

                <h2><span><?= lang('sales_list'); ?></span></h2>

                <!--<div class="module-table-body">-->

                <table id="pageTable" >

                    <thead>

                        <tr>

                            <th><?= lang('sal_bo_id') ?></th>

                            <th><?= lang('sal_pay_price') ?></th>

                            <th><?= lang('sal_id') ?></th>                                                                

                            <th><?= lang('sal_created_date') ?></th>                            

                            <th><?= lang('sal_last_update') ?></th>



                        </tr>

                    </thead>

                    <tbody>

                        <?php

                        $i = 0;

                        foreach ($user_sales as $row) {

                            $i++;

                            ?>

                            <tr <?php if ($i % 2 == 0) echo "class='alt'" ?>>

                                <td><?= $row['bo_name'] ?></td>

                                <td>

                                    <?= $row['sal_pay_price'] ?>

                                    <?php

                                    if ($row['sal_before_discount'] != 0) {

                                        echo '(بعد الخصم)';

                                    }

                                    ?>

                                </td>

                                <td><?= $row['sal_id'] ?></td>                                                                        

                                <td><?= $row['sal_created_date'] ?></td>                                

                                <td><?= $row['sal_last_update'] ?></td>                                    

                            </tr>

                        <?php } ?>

                    </tbody>

                </table>

                <div class="pager" id="pagePager">

                    <div>

                        <?php echo $this->pagination->create_links(); ?>

                    </div>

                </div>



                <div style="clear: both"></div>

                <!--</div>  End .module-table-body -->

                <!--</div>   End .module -->



            <?php } ?>

        </div> <!-- End .module-body -->

    </div>  <!-- End .module -->

    <div style="clear:both;"></div>

</div> <!-- End .grid_12 -->



