<%@ page language="java" errorPage="/error.jsp" pageEncoding="UTF-8"
	contentType="text/html; charset=UTF-8"%>
<%@ include file="/common/taglibs.jsp"%>
<!DOCTYPE html>
<html>
<head>
<title>企业饭卡</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<!-- bootstrap 3.0.2 -->
<%-- <link href="<c:url value='/styles/lib/bootstrap.min.css'/>" rel="stylesheet" type="text/css" />
<link href="<c:url value='/styles/lib/font-awesome.min.css'/>" rel="stylesheet" type="text/css" />
<link href='<c:url value='/styles/lib/ionicons.min.css' />' rel="stylesheet" type="text/css" />
<link href="<c:url value='/styles/lib/datatables/dataTables.bootstrap.css' />" rel="stylesheet" type="text/css" /> --%>
<link href="<c:url value='/scripts/lib/layui/layui.css'/>" rel="stylesheet" type="text/css" />
<link href="<c:url value='/styles/AdminLTE.css?2019-1-1'/>" rel="stylesheet" type="text/css" />
<link href="<c:url value='/styles/foodManger/addFome.css?2019-7-29'/>" rel="stylesheet" type="text/css" />
<link href="<c:url value='/styles/foodManger/foodManger.css?122'/>" rel="stylesheet" type="text/css" />
<script src="${ctx }/scripts/lib/jquery-1.8.2.min.js"></script>
<script type="text/javascript" src="<c:url value='/plugin/layer/layer.js'/>"></script>
<script type="text/javascript" src="<c:url value='/scripts/lib/layui/layui.js'/>"></script>
<%-- <script type="text/javascript" src="<c:url value='/scripts/bootstrap.min.js'/>"></script> --%>
<script type="text/javascript" src="<c:url value='/scripts/lib/template-native.js'/>"></script>

<script type="text/javascript" src="${ctx}/scripts/jquery/ajaxfileupload.js"></script>
<script type="text/javascript" src="${ctx}/scripts/admin/cjqt.js"></script>
</head>
<body>
	<input type="hidden" value="${virAccountInfo}" id="virAccountInfo">
	<input type="hidden" value="${ctx}" id="contextPath">
	<input type="hidden" id="funcid" value="${funcid}">
	<input type="hidden" value="${virtualArchitectureId}" id="virtualId_">
	<input type="hidden" value="${ctx}" id="contextPath" />
	<input type="hidden" value="${updateAct}" id="updateAct" />
	<input type="hidden" value="${deleteAct}" id="deleteAct" />

	<%-- 因为js中无法直接调用自定义的权限校验标签 --%>
	<%-- 判断当前用户是否有相应权限,如果有权限则在JSP页面新增隐藏input标签,方便js代码调用 --%>

	<%-- 是否有修改权限 --%>
	<perm:hasPermission permCode="pc:virfood:foodmanager">
	<input type="hidden" value="1" id="perm-approve" />
</perm:hasPermission>

	<div class="bread-wp">
		企业饭卡  > 饭卡管理
	</div>
	<div class="right-content">
		<div class="main-content-mode-wp clearfloat email-publish-wp ">
		<form:form  id="conditionform"  class="clearfloat">
		<c:if test="${fn:length(orgs) > 1}">
				<div class="part-wp">
					<span class="search-tips">校区</span>
					 <input class="default-select orgId " name="orgId" id="orgId" placeholder="请选择校区" autocomplete="off" />
	              	<span class="select_wrap _hide"></span>
				</div>		
			</c:if>
			<c:if test="${fn:length(orgs) == 1}">
			 <input type="hidden" id="orgId" name="orgId" value="${orgs[0].id}" org__id="${orgs[0].id}">
			</c:if>
			
		  <div class="part-wp">
			  <span class="search-tips">卡组名</span>
			   <input  class="large-input" type="text" name="user" lay-verify="userName" autocomplete="off" class="layui-input" placeholder="请输入卡组名">
		  </div>
			<div class="part-wp">
			<button class="search-btn btn-red" type="button" id="searchUser">查询</button>
			<button class="set-btn btn-white" type="button" id="resetSearch">重置</button>
			</div>
       </form:form>
		 <div class="main-operate-wp">
		 <button class="btn-add-blue add-ele-btn" type="button">新增</button>
     </div>
	 	 <table class="layui-hide" id="LAY_table_user" lay-filter="user"></table>  
		</div>
	</div>
	   <div class="alert">
      <div class="alert_con">
        <h2>饭卡信息编辑</h2>
        <div class="form_alert">
          <form   class="layui-form" action="" lay-filter="example" >
        <div class="layui-inline">
          <label class="layui-form-label txt_brown fs16 txt_orange">饭卡组名称：</label>
          <div class="layui-input-inline">
            <input type="text" name="username" lay-verify="required" autocomplete="off" 
            class="layui-input" placeholder="请输入饭卡名称" style="width:200px"
              id="username">
          </div>
        </div>
        <div class="layui-inline">
          <label class="layui-form-label txt_brown fs16 txt_orange">账号：</label>
          <div class="layui-input-inline">
            <input type="tel" name="mobile" lay-verify="required" autocomplete="off" style="width:200px"
            class="layui-input" placeholder="请输入手机号"
              id="mobile">
          </div>
        </div>
        <div class="layui-inline">
          <label class="layui-form-label txt_brown fs16 txt_orange">密码：</label>
          <div class="layui-input-inline">
            <input type="text" name="carNumber" lay-verify="required" autocomplete="off" class="layui-input" style="width:200px"
              placeholder="请输入密码" id="carNumber">
          </div>
        </div>
          <div class="layui-form-item">
      <label class="layui-form-label">饭卡类型：</label>
    	<div class="layui-input-block" id="cardType">
	       <input type="radio" name="price_type" value="1" checked="" title="通用" >
	       <input type="radio" name="price_type" value="0" title="企业" >      
    	</div>
  		</div>
  		<div class="layui-inline">
          <label class="layui-form-label txt_brown fs16 txt_orange">校区：</label>
          <div class="layui-input-inline">
            <c:if test="${fn:length(orgs) > 1}">
					<input class="default-select" name="organizationId" id="organizationId" autocomplete="off" />
	              	<span class="select_wrap _hide"></span>
			</c:if>
			<c:if test="${fn:length(orgs) == 1}">
					<input type='hidden' class="default-select single-orgid" name="organizationId" id="organizationId" org__id="${orgs[0].id}" autocomplete="off" value="${obj.id }" org__id='${obj.id }'/>
			</c:if>
          </div>
        </div>
        <div class="layui-inline" id="virtualItem">
          <label class="layui-form-label txt_brown fs16 txt_orange">企业：</label>
          <div class="layui-input-inline">
           	<c:if test="${not empty virAccountInfo}">
					<input class="default-select" disabled name="virtualId" id="virtualId" autocomplete="off" value="${virAccountInfo.virName}" com__id="${virAccountInfo.virId}" level="${virAccountInfo.level}" range_id="${virAccountInfo.range_id}" />
			</c:if>	
			<c:if test="${fn:length(virAccountInfo) == 0}">
				<input class="default-select" name="virtualId" id="virtualId"  autocomplete="off" />
		    <span class="select_wrap _hide"></span>
            </c:if>	
          </div>
        </div>
		
			  <div class="layui-inline">
				<c:if test="${fn:length(orgs) > 1}">
				<div class="part-wp part-wp-project" >
					 <label class="layui-form-label txt_brown fs16 txt_orange">附属校区：</label>
					  <div class="layui-input-inline">
					<input class="default-select  projectotherId" name="orgIdother"  autocomplete="off" />
	              	<span class="select_wrap _hide hideOtherPor"></span>
	              	<span class="delete_Project">删除</span>
	              	</div>
				</div>		
			</c:if>
			<c:if test="${fn:length(orgs) == 1}">
					 <input type="hidden" id="orgId" name="orgId" value="${orgs[0].id}" org__id="${orgs[0].id}">
			</c:if>
			 </div>
			<div class="layui-inline">
				<div id="addProject" class="addProject">+新增附属校区</div>
			</div>
        </form>
      </div>
      <div class="changeBtn">
        <button class="bt_blue_big_b_slot fs16 saveBtn">保存</button>
        <button class="bt_blue_big_b fs16 ml30 cancelBtn">取消</button>
      </div>
    </div>
  </div>
  	  <div class="alert3">
         <div class="alert_con">
        <h2>饭卡信息编辑</h2>
        <div class="form_alert">
          <form   class="layui-form-edit" action="" lay-filter="example" >
  		<div class="layui-inline">
          <label class="layui-form-label txt_brown fs16 txt_orange">校区：</label>
          <div class="layui-input-inline">
            <input type="text" name="foodName"  autocomplete="off"   class="detailProject" style="width:420px"
              id="foodName">
          </div>
           </div>
            <div class="layui-inline lookCompanyName">
          <label class="layui-form-label txt_brown fs16 txt_orange">公司名称：</label>
          <div class="layui-input-inline">
            <input type="text" name="companyName"  autocomplete="off"   class="detailProject" style="width:420px"
              id="companyName">
          </div>
          </div>
			  <div class="layui-inline">
				<c:if test="${fn:length(orgs) > 1}">
				<div class="part-wp part-wp-project-edit" >
					 <label class="layui-form-label txt_brown fs16 txt_orange">附属校区：</label>
					  <div class="layui-input-inline">
					<input class="default-select  EditOtherprojectEdit" name="orgIdEditother"  autocomplete="off" />
	              	<span class="select_wrap _hide edithideOtherPor"></span>
	              	<span class="save_editProject">保存</span>
	              	<span class="delete_editProject">删除</span>
	              	
	              	</div>
				</div>		
			</c:if>
			<c:if test="${fn:length(orgs) == 1}">
					 <input type="hidden" id="orgId" name="orgId" value="${orgs[0].id}" org__id="${orgs[0].id}">
			</c:if>
			 </div>
			<div class="layui-inline">
				<div id="addEditProject" class="addEditProject">+新增附属校区</div>
			</div>
        </form>
      </div>
      <div class="changeBtn">
        <button class="bt_blue_big_b fs16 mr50 cancelEditBtn completeBtn">完成</button>
      </div>
    </div>
  </div>
	<script type="text/html" id="indexTpl">
    {{d.LAY_TABLE_INDEX+1}}
	</script>
	<script type="text/javascript"
		src="<c:url value='/scripts/admin/foodManger/foodManger.js?1.8'/>"></script>
</body>
</html>