<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<form class="layui-form whitebg pb10 pt10" action="" id="data_form">  
	<div class="tab-pane active">     
		<div class="panel-body">
			<div class="wrapper wrapper-content">
				<div class="panel-form animated fadeInRight wp60 fc">
					<div class="layui-form-item dn	has-error" >   
						<label class="layui-form-label">id</label>  
						<div class="layui-input-block">
							<input type="text" name="id" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.id }" >
						</div>  
					</div>
					<!--管理员看到的  -->
					<c:if test="${admin eq 'admin' }">
						<div class="form-group">
			                <div class="layui-form-item">          
			                    <label class="layui-form-label">商户</label>
			                    <div class="layui-input-block">
			                        <select name="merchantCode" id="merchantCode" lay-filter="selectMerchantCode">  
			                            <option value="">请选择</option>
			                            <c:forEach items="${merchantBaseInfoList }" var="mb">
			                                 <option value="${mb.merchantCode }" <c:if test="${mb.merchantCode eq merchantMenber.merchantCode }">selected="selected"</c:if>>${mb.alias }</option>
			                            </c:forEach>
			                        </select>              
			                    </div>
			                </div>
			            </div>
			            
			            <!-- <div class="form-group">
                            <div class="layui-form-item">          
                                <label class="layui-form-label">门店</label>
                                <div class="layui-input-block">
                                    <select name="storeId" id="storeId">  
                                        <option value="">请选择</option>
                                    </select>              
                                </div>
                            </div>
                        </div> -->
					</c:if>
					<!--不是管理员看到的  -->
					<c:if test="${admin ne 'admin' }">
					   <div class="form-group">
                            <div class="layui-form-item">          
                                <label class="layui-form-label">门店</label>
                                <div class="layui-input-block">
                                    <select name="storeId" id="storeId">  
                                        <option value="">请选择</option>
                                        <c:forEach items="${merchantStoreList }" var="ms">
                                            <option value="${ms.storeId }" <c:if test="${ms.storeId eq merchantMenber.storeId }">selected="selected"</c:if>>${ms.storeName }</option>
                                            
                                        </c:forEach>
                                    </select>              
                                </div>
                            </div>
                        </div>
					</c:if>
					
					<%-- <div class="layui-form-item dn	has-error" >   
						<label class="layui-form-label">storeId</label>  
						<div class="layui-input-block">
							<input type="text" name="storeId" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.storeId }" >
						</div>  
					</div>
					<div class="layui-form-item dn	has-error" >   
						<label class="layui-form-label">storeName</label>  
						<div class="layui-input-block">
							<input type="text" name="storeName" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.storeName }" >
						</div>  
					</div> --%>
					
					
					<%-- <div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">状态</label>  
						<div class="layui-input-block">
							<input type="text" name="status" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.status }" >
						</div>  
					</div> --%>
					<%-- <div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">createDt</label>  
						<div class="layui-input-block">
							<input type="text" name="createDt" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.createDt }" >
						</div>  
					</div> --%>
					<%-- <div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">memberCode</label>  
						<div class="layui-input-block">
							<input type="text" name="memberCode" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.memberCode }" >
						</div>  
					</div> --%>
					<div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">姓名</label>  
						<div class="layui-input-block">
							<input type="text" name="nickName" id="nickName" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.nickName }" >
						</div>  
					</div>
					<div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">手机号</label>  
						<div class="layui-input-block">
							<input type="text" name="phone" id="phone" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.phone }" >
						</div>  
					</div>
					
					<div class="layui-form-item layui-form-text" onclick="uploadImage()">
		                <label class="layui-form-label">logo</label>
		                <div class="layui-input-block"  >
		                    <div class="layui-upload-drag w300 h200 postionr">
		                        <i class="layui-icon"> </i>    
		                        <img src="${merchantMenber.logo}" id="demo1" onerror="this.src=''" class="positiona top0 left0 w300 h200 dblock">      
		                        <input type="hidden" name="logo" value="${merchantMenber.logo}"   id="logo">
		                    </div>
		                </div>
		            </div>
					<%-- <div class="layui-form-item    has-error" >   
                        <label class="layui-form-label">logo</label>  
                        <div class="layui-input-block">
                            <input type="text" name="logo"  lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.logo }" >
                        </div>  
                    </div> --%>
					
					<div class="form-group">
                            <div class="layui-form-item">          
                                <label class="layui-form-label">会员状态</label>
                                <div class="layui-input-block">
                                    <select name="status" id="status">
                                        <option value="">请选择</option>
                                         <option value="1" <c:if test="${merchantMenber.status eq '1' }">selected="selected"</c:if>>显示</option>
                                          <option value="0" <c:if test="${merchantMenber.status eq '0' }">selected="selected"</c:if>>不显示</option>
                                    </select>              
                                </div>
                            </div>
                        </div>
					<%-- <div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">openid</label>  
						<div class="layui-input-block">
							<input type="text" name="openid" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.openid }" >
						</div>  
					</div>
					<div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">alipayUserId</label>  
						<div class="layui-input-block">
							<input type="text" name="alipayUserId" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.alipayUserId }" >
						</div>  
					</div> --%>
					<%-- <div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">comsumeMoney</label>  
						<div class="layui-input-block">
							<input type="text" name="comsumeMoney" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.comsumeMoney }" >
						</div>  
					</div>
					<div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">profitMoney</label>  
						<div class="layui-input-block">
							<input type="text" name="profitMoney" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.profitMoney }" >
						</div>  
					</div> --%>
					<%-- <div class="layui-form-item 	has-error" >   
						<label class="layui-form-label">orderNumber</label>  
						<div class="layui-input-block">
							<input type="text" name="orderNumber" lay-verify="title" autocomplete="off" placeholder="请输入内容" class="layui-input" value="${merchantMenber.orderNumber }" >
						</div>  
					</div> --%>
					<c:if test="${admin eq 'admin' }">
	                   <input type="hidden" id="isAdmin" value="1">
					</c:if>
					<c:if test="${admin ne 'admin' }">
	                   <input type="hidden" id="isAdmin" value="0">
					</c:if>
				</div>
			</div>
		</div>  
	</div>
</form>
<script type="text/javascript">
    //form表单样式
    layui.use(['layer', 'form'], function() {    
        var layer = layui.layer,
            form = layui.form;
        form.render();
    });
</script> 

