{% load i18n %}





<ol class="breadcrumb">
        <li>{% trans "进销存报表" %}</li>
        <li>{% trans "库存盘点汇总" %}</li>
</ol>

<script type="text/javascript">
    $(document).ready(function(){

        
        

        $('.btn-qry').click(function(){
            var product_id=$('#product_id').val();
            
            var params=[];

            if(params.length==0){
                bootbox.alert("{% trans '请先输入查询条件！'%}");
            }else{
                $.RefreshContent('{{request.path}}?'+params.join('&'));
            }
        });

       
        var table=$('#tb').DataTable({
            dom: 'Bfrtip',
            autoWidth: false,
            buttons: [{extend:'excelHtml5',text:'导出到Excel'}],           
            language:lng,           
            data:{{data|safe}}
        });       
        
        table.columns().every( function () {                        
            var that = this;             
            $('input', this.footer() ).on( 'keyup change clear', function () {
                if ( that.search() !== this.value ) {
                    that.search( this.value ).draw();
                }
            });
        });  
    });
</script>

<!--<form role="form"  class="form-inline" style="margin-top:35px;">
	<div>
		<select>
			<option></option>
		</select>
	</div>
    <div style="float:right;">
        <span class='input-group-btn'>
            <a type="button" class='btn btn-primary btn-qry'>
                <span class='glyphicon glyphicon-search' style='padding-right:5px;'></span>{% trans '查找' %}
            </a>
        </span>
    </div>
</form>-->
<div class="clearfix"></div>
<div id="inventory-list" class="table-responsive">
    <div class='x_panel'>
    <table id="tb" class="table table-striped table-bordered dt-responsive" width="100%" >
        <thead>
            <tr>
                <th  style='width:15%'>{% trans "经销商" %}</th>
                <th  style='width:20%'>{% trans "产品名称" %}</th>
                <th  style='width:8%'>{% trans "类型" %}</th>
                <th  style='width:8%'>{% trans "数量" %}</th>
            </tr>            
        </thead>
        <tbody></tbody>
        <tfoot>
            <th><input type="text" placeholder="{% trans "经销商" %}"></th>
            <th><input type="text" placeholder="{% trans "产品名称" %}"></th>
            <th><input type="text" placeholder="{% trans "类型" %}"></th>
            <th><input type="text" placeholder="{% trans "数量" %}"></th>          
        </tfoot>
    </table>    
    </div>
</div>
