<div class="layui-side admin-side" id="admin-side">
	<div class="layui-side-scroll" id="admin-navbar">
		<ul class="layui-nav layui-nav-tree" lay-filter="navbar">
			<li class="layui-nav-item <!--{if in_array(request()->controller(), ['Index'])}-->layui-nav-itemed<!--{/if}-->">
				<a class="layui-nav-parent" href="{echo url('index/index')}">控制台</a>
			</li>
			<li class="layui-nav-item <!--{if in_array(request()->controller(), ['Trade'])}-->layui-nav-itemed<!--{/if}-->">
				<a class="layui-nav-parent" href="javascript:;">交易管理</a>
				<dl class="layui-nav-child">
					<dd class="<!--{if url() == '/merchant/trade/index'}-->layui-this<!--{/if}-->"><a href="{echo url('trade/index')}">交易列表</a></dd>
				</dl>
			</li>
			<li class="layui-nav-item <!--{if in_array(request()->controller(), ['Store', 'Person', 'Device', 'Qrcode'])}-->layui-nav-itemed<!--{/if}-->">
				<a class="layui-nav-parent" href="javascript:;">门店管理</a>
				<dl class="layui-nav-child">
					<dd class="<!--{if url() == '/merchant/store/index'}-->layui-this<!--{/if}-->"><a href="{echo url('store/index')}">门店列表</a></dd>
					<dd class="<!--{if url() == '/merchant/person/index'}-->layui-this<!--{/if}-->"><a href="{echo url('person/index')}">店员列表</a></dd>
					<dd class="<!--{if url() == '/merchant/device/index'}-->layui-this<!--{/if}-->"><a href="{echo url('device/index')}">终端设备</a></dd>
					<dd class="<!--{if url() == '/merchant/qrcode/index'}-->layui-this<!--{/if}-->"><a href="{echo url('qrcode/index')}">收款码管理</a></dd>
				</dl>
			</li>
			<li class="layui-nav-item <!--{if in_array(request()->controller(), ['Goods', 'GoodsCat'])}-->layui-nav-itemed<!--{/if}-->">
				<a class="layui-nav-parent" href="javascript:;">商品管理</a>
				<dl class="layui-nav-child">
					<dd class="<!--{if url() == '/merchant/goods/index'}-->layui-this<!--{/if}-->"><a href="{echo url('goods/index')}">商品管理</a></dd>
					<dd class="<!--{if url() == '/merchant/goods_cat/index'}-->layui-this<!--{/if}-->"><a href="{echo url('goodsCat/index')}">商品分类</a></dd>
				</dl>
			</li>
			<li class="layui-nav-item <!--{if in_array(request()->controller(), ['Order'])}-->layui-nav-itemed<!--{/if}-->">
				<a class="layui-nav-parent" href="{echo url('order/index')}">订单管理</a>
			</li>
			<li class="layui-nav-item <!--{if in_array(request()->controller(), ['User', 'Bill'])}-->layui-nav-itemed<!--{/if}-->">
				<a class="layui-nav-parent" href="javascript:;">会员营销</a>
				<dl class="layui-nav-child">
					<dd class="<!--{if url() == '/merchant/user/index'}-->layui-this<!--{/if}-->"><a href="{echo url('user/index')}">会员管理</a></dd>
					<dd class="<!--{if url() == '/merchant/user/charge'}-->layui-this<!--{/if}-->"><a href="{echo url('user/charge')}">充值方案</a></dd>
					<dd class="<!--{if url() == '/merchant/bill/charge'}-->layui-this<!--{/if}-->"><a href="{echo url('bill/charge')}">会员充值记录</a></dd>
					<dd class="<!--{if url() == '/merchant/bill/consume'}-->layui-this<!--{/if}-->"><a href="{echo url('bill/consume')}">会员消费记录</a></dd>
				</dl>
			</li>
			<li class="layui-nav-item <!--{if in_array(request()->controller(), ['Profile'])}-->layui-nav-itemed<!--{/if}-->">
				<a class="layui-nav-parent" href="javascript:;">基本信息</a>
				<dl class="layui-nav-child">
					<dd class="<!--{if url() == '/merchant/profile/index'}-->layui-this<!--{/if}-->"><a href="{echo url('profile/index')}">基本资料</a></dd>
				</dl>
			</li>
			<li class="layui-nav-item <!--{if in_array(request()->controller(), ['Weixin', 'Alipay'])}-->layui-nav-itemed<!--{/if}-->">
				<a class="layui-nav-parent" href="javascript:;">系统设置</a>
				<dl class="layui-nav-child">
					<dd class="<!--{if preg_match('/^\/merchant\/weixin/i', url())}-->layui-this<!--{/if}-->"><a href="{echo url('weixin/index')}">微信配置</a></dd>
					<dd class="<!--{if preg_match('/^\/merchant\/alipay/i', url())}-->layui-this<!--{/if}-->"><a href="{echo url('alipay/index')}">支付宝配置</a></dd>
				</dl>
			</li>
		</ul>
	</div>
</div>
<script type="text/javascript">
layui.use("element", function(){
	var element = layui.element;
	element.on("nav(navbar)", function(data){

	});
});
$("#admin-navbar").find("li.layui-nav-item").click(function(){
	$(this).siblings().removeClass("layui-nav-itemed");
});
</script>
