{template_user 'head.html'}
<style type="text/css">
    a.btn-warning:hover {
        background:#ec971f;
        margin:0px;
    }

</style>
<div class="index-bg">
    <div class="container">
        <div class="section2">


            <div class="row">



                <div class="user-content-table-nav">
                    <span class="pull-right">
                        {lang('balance')}：
                    {lang('unit')}<span style="font-size:2.0rem; color: #FF4A00;font-weight: :600;">{getmenoy()}</span>
                    <a href="{url('archive/consumption')}" class="btn btn-warning" style="display: inline-block; margin-left:55px;">{lang('recharge')}</a>

                    </span>
                    <ul>
                        <li><a href="{url('invoice/consumptionlist/manage/xfconsumption')}" class="active">{lang('records_of_consumption')}</a></li>
                    </ul>
                </div>
                <div class="blank30"></div>

                <div class="user-content">

                    <form name="listform" id="listform"  action="<?php echo uri();?>" method="post">
                        <div class="table-responsive">
                            <table class="table table-striped table-hover ">
                                <thead>
                                <tr class="th">
                                    <th class="orders-list-id"><!--oid-->{lang('id')}</th>
                                    <th class="orders-list-title">{lang('consumption_content')}</th>
                                    <th class="orders-list-title">{lang('consumption_amount')}</th>
                                    <th class="orders-list-adddate"><!--adddate-->{lang('adddate')}</th>
                                    <th class="">{lang('dosomething')}</th>
                                </tr>

                                </thead>
                                <tbody>
                                {loop $data $d}
                                <tr class="s_out">
                                    <td class="orders-list-id">{cut($d['id'])} </td>
                                    <td class="orders-list-title">{cut($d['content'])}</td>
                                    <td class="orders-list-title">{cut($d['menoy'])}</td>
                                    <td class="orders-list-adddate">{$d['adddate']}</td>
                                    <td class="">
                                        <?php if( $d['xftype'] == 1 ){  ?>
                                        <a href='{url("archive/orders/oid/".$d["oid"])}' target="_blank" title="{lang('look')}" class="btn btn-default">{lang('look')}</a>
                                        <?php }else if( $d['xftype'] == 2 ){ ?>
                                        <a href='{url("archive/consumption/oid/".$d["oid"])}' target="_blank" title="{lang('look')}" class="btn btn-default">{lang('look')}</a>
                                        <?php }else if( $d['xftype'] == 3 ){ ?>
                                        <a href='{url("archive/buytemplateorders/oid/".$d["oid"])}' target="_blank" title="{lang('look')}" class="btn btn-default">{lang('look')}</a>
                                        <?php } ?>
                                        <?php if(in_array($d["oid"],$invoicedata)){  ?>
                                         <a href='#' class="btn btn-default" disabled="disabled">发票已申请</a>
                                        <?php }else{ ?>
                                          <a href='{url("invoice/invoice/manage/invoice/oid/".$d["oid"]."/xftype/".$d["xftype"])}' class="btn btn-default btn-invoice">申请发票</a>
                                        <?php } ?>
                                    </td>
                                </tr>
                                {/loop}
                                </tbody>
                            </table>
                        </div>

                        <div class="blank30"></div>


                    </form>


                    <div class="pages">
                        <?php if(get('table')!='type' && front::get('case')!='field') echo pagination::html($record_count); ?>
                    </div>
                    <div class="blank30"></div>

                </div>
            </div>
        </div>
    </div>
    <div class="blank30"></div>
</div>
{template_user 'foot.html'}