<?php defined('ByFeiWa') or exit('Access Invalid!');?>

<div class="page">
  <div class="fixed-bar">
    <div class="item-title">
      <div class="subject">
        <h3><?php echo $lang['feiwa_store_manage'];?></h3>
        <h5><?php echo $lang['feiwa_store_manage_subhead'];?></h5>
      </div>
      <?php echo $output['top_link'];?>
    </div>
  </div>
  <div class="explanation" id="explanation">
    <div class="title" id="checkZoom"><i class="fa fa-lightbulb-o"></i>
      <h4 title="<?php echo $lang['feiwa_prompts_title'];?>"><?php echo $lang['feiwa_prompts'];?></h4>
      <span id="explanationZoom" title="<?php echo $lang['feiwa_prompts_span'];?>"></span> </div>
    <ul>
      <li>此处可以对商家新申请的经营类目进行 审核/删除 操作。</li>
    </ul>
  </div>
  <div id="flexigrid"></div>
    <div class="ncap-search-ban-s" id="searchBarOpen"><i class="fa fa-search-plus"></i>高级搜索</div>
    <div class="ncap-search-bar">
      <div class="handle-btn" id="searchBarClose"><i class="fa fa-search-minus"></i>收起边栏</div>
      <div class="title">
        <h3>高级搜索</h3>
      </div>
      <form method="get" name="formSearch" id="formSearch">
        <div id="searchCon" class="content">
          <div class="layout-box">
            <dl>
              <dt>店铺ID</dt>
              <dd>
                <input type="text" value="" name="store_id" id="store_id" class="s-input-txt">
              </dd>
            </dl>
            <dl>
              <dt>店铺状态</dt>
              <dd>
                <select name="state" class="s-select">
                  <option value=""><?php echo $lang['feiwa_please_choose'];?></option>
                  <option value="0">审核中</option>
                  <option value="1">已审核</option>
                </select>
              </dd>
            </dl>
          </div>
        </div>
        <div class="bottom">
          <a href="javascript:void(0);" id="ncsubmit" class="ncap-btn ncap-btn-green">提交查询</a>
          <a href="javascript:void(0);" id="ncreset" class="ncap-btn ncap-btn-orange" title="撤销查询结果，还原列表项所有内容"><i class="fa fa-retweet"></i><?php echo $lang['feiwa_cancel_search'];?></a>
        </div>
      </form>
    </div>
</div>
<script type="text/javascript">
$(function(){
    // 高级搜索提交
    $('#ncsubmit').click(function(){
        $("#flexigrid").flexOptions({url: 'index.php?app=store&feiwa=get_bind_class_applay_xml&'+$("#formSearch").serialize(),query:'',qtype:''}).flexReload();
    });

    // 高级搜索重置
    $('#ncreset').click(function(){
        $("#flexigrid").flexOptions({url: 'index.php?app=store&feiwa=get_bind_class_applay_xml'}).flexReload();
        $("#formSearch")[0].reset();
    });
    $("#flexigrid").flexigrid({
        url: 'index.php?app=store&feiwa=get_bind_class_applay_xml',
        colModel : [
            {display: '操作', name : 'operation', width : 60, sortable : false, align: 'center', className: 'handle-s'},
            {display: '店铺ID', name : 'store_id', width : 40, sortable : true, align: 'center'},
            {display: '店铺名称', name : 'store_name', width : 120, sortable : false, align: 'left'},
            {display: '店主账号', name : 'seller_name', width : 80, sortable : true, align: 'left'},
            {display: '分佣比例', name : 'commis_rate', width : 60, sortable : false, align: 'left'},
            {display: '状态', name : 'state', width: 60, sortable : false, align : 'center'},
            {display: '经营类目', name : 'class', width: 400, sortable : false, align : 'left'}
            ],
        searchitems : [
            {display: '店铺ID', name : 'store_id', isdefault: true},
            {display: '分佣比例(%)', name : 'commis_rate'}
            ],
        sortname: "state",
        sortorder: "asc",
        title: '店铺列表'
    });
});
</script> 