<%@page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<script type="text/javascript" src="<c:url value='/resources/js/admin/userAttr.js' />"></script>
<!-- 사용자 속성 관리 -->
<div class="main-wrapper">
    <div class="title-bar">
    	<span class="title">사용자 속성 관리</span>
    </div>
    <div id="wrapper">
	    <div class="col-md-4">
	    	<div class="left-content">
	    		<div class="form-group col-md-12 pd0">
					<div class="col-md-5 pdl0">
						<select class="form-control input-sm" id="sltUser">
							<option value="userId">아이디</option>
							<option value="userName">이름</option>
						</select>
					</div>
					<div class="col-md-5 pd0">
						<input type="text" class="form-control input-sm" id="txtSearch" placeholder="">
					</div>
					<div class="col-md-2 text-right pdr0">
						<button class="btn btn-default btn-sm" id="btnSearch">조회</button>
					</div>
		    	</div>
		    	<div class="form-group col-md-12 pd0 mg0">
		    		<div class="table-wrapper-md">
			    		<table class="table table-bordered table-hover table-row-click">
							<thead>
								<tr>
									<td class="table-header">아이디</td>
									<td class="table-header">이름</td>
								</tr>
							</thead>
							<tbody id="table_user">
							</tbody>
						</table>
					</div>
				</div>
				<div class="form-group col-md-12 pd0 mg0">
			    	<nav class="text-center nav-pagination">
					  <ul class="pagination pagination-sm" id="ulPagination">
					  </ul>
					</nav>
				</div>
	    	</div>
	    </div>
	    <div class="col-md-8">
	    	<div class="right-content row">	
	    		<div class="form-group col-md-12" id="userAttrDetailEmpty">
	    			* 사용자를 선택해주세요.
	    		</div>			
				<div class="col-md-12" id="userAttrDetail">
					<div class="panel panel-default">
						<div class="panel-heading">
							사용자 속성
						<div class="btn-group" role="group" aria-label="..." style="float: right; top: -6px;">
							<button type="button" class="btn btn-default btn-sm" id="btnNew" title="추가">
								<span class="glyphicon glyphicon-plus">&nbsp;추가</span>
							</button>
						</div>
						</div>
						<div class="panel-body">
							<div id="noUserAttr">
								<div class="form-group col-md-12">
									<span>* 사용자 속성이 존재하지 않습니다.</span>
								</div>
							</div>
							<div id="divUserAttr" style="display: none">
							</div>
						</div>	
					</div>
				</div>
				
			</div>
    	</div>
    </div>
</div>

<div class="modal fade" id="addAttrModal" tabindex="-1" role="dialog">
  <div class="modal-dialog" role="document">
    <div class="modal-content">
      <div class="modal-header">
      	⊙ 사용자 속성 추가
      </div>
      <div class="modal-body">
      	<div class="row">
			<div class="col-md-12">
				<div class="form-group col-md-12" style="display: none">
					<div class="col-md-2 text-right content-title">
						<label>userId</label>
					</div>
					<div class="col-md-4">
						<input type="text" id="txtUserId"/>
					</div>
					<div class="col-md-2 text-right content-title">
						<label>userOrder</label>
					</div>
					<div class="col-md-4">
						<input type="text" id="txtUserOrder"/>
					</div>
				</div>
				<div class="form-group col-md-12">
					<div class="col-md-2 text-right content-title">
						<label>소속</label>
					</div>
					<div class="col-md-10">
						<select class="form-control input-sm" id="sltHospital">
							<option value="">선택</option>
				        </select>
					</div>
				</div>
				<div class="form-group col-md-12">
					<div class="col-md-2 text-right content-title">
						<label>직무</label>
					</div>
					<div class="col-md-10">
						<select class="form-control input-sm" id="sltDuty">
							<option value="">선택</option>
				        </select>
					</div>
				</div>
				<div class="col-md-12">
					<div class="col-md-2 text-right content-title">
						<label>업무</label>
					</div>
					<div class="col-md-10">
						<select class="form-control input-sm" id="sltWork">
							<option value="">선택</option>
				        </select>
					</div>
				</div>
			</div>
		</div>
      </div>
      <div class="modal-footer text-center">
        <button type="button" class="btn btn-default btn-sm" id="btnSave">
        	<span class="glyphicon glyphicon-ok-circle">&nbsp;적용</span>     
        </button>
        <button type="button" class="btn btn-default btn-sm" data-dismiss="modal">
        	<span class="glyphicon glyphicon-remove-circle">&nbsp;취소</span>
        </button>
      </div>
    </div>
  </div>
</div>

<script type="text/javascript">
$(document).ready(function () {
	var manager = new mplus_admin_manager();
	manager.init();	
});
</script>