
<form id="userForm" class="form-horizontal col-xs-12" action="/user/do_update" method="post">
	<input name="id" th:value="${user.id}" type="hidden"/>
	<input name="org.id" th:value="${user.org.id}" type="hidden"/>

	<div class="space-12"></div>

	<div class="form-group">
		<label class="col-xs-2 control-label no-padding-right"><font color="red">* </font>用户名：</label>
		<div class="col-xs-9">
			<input name="name" th:value="${user.name}" type="text" class="form-control"/>
		</div>
	</div>

	<div class="form-group">
		<label class="col-xs-2 control-label no-padding-right"><font color="red">* </font>手机：</label>
		<div class="col-xs-9">
			<input name="phone" th:value="${user.phone}" type="text" maxlength="11"  class="form-control"/>
		</div>
	</div>

	<div class="form-group" th:if="${globalUser.loginName} == 'admin'" >
		<label class="col-xs-2 control-label no-padding-right">超级管理员：</label>
		<div class="col-xs-9 radio">
			<label>
			  <input name="admin" type="radio" th:checked="${user?.admin} == true" class="ace" value="true"/>
			  <span class="lbl">是</span>
			</label>
			 <label>
			   <input name="admin" type="radio" th:checked="${user?.admin} == false"  class="ace" value="false" />
			   <span class="lbl">否</span>
			</label>
		</div>
	</div>

	<!-- <div class="form-group">
		<label class="col-xs-2 control-label no-padding-right">用户类型：</label>
			<div class="col-xs-9">
				<label>
					<select class="selector" name="userType.id" tag:option="userType" th:value="${user.userType.id}"></select>
				</label>
			</div>
	</div> -->

	<div class="form-group">
	    <label class="col-xs-2 control-label no-padding-right">角色：</label>
	    <div class="col-xs-9 form-input-group userRole_align">
	    	<span th:each="role,iterStatus:${user.roles}">
				<label>
					<input th:name="'roles['+${iterStatus.index}+'].id'" type="checkbox"  th:checked="${role.check}" class="ace" th:value="${role.id}" />
						<span class="lbl" th:text="${role.name}"></span>
				</label>
	    		<label>
					<input th:name="'roles['+${iterStatus.index}+'].admin'" type="checkbox" class="ace" th:checked="${role.admin}" />
						<span class="lbl" th:text="''+${role.name}+'的管理员'"></span>
				</label>
	    	</span>
		</div>
	</div>


</form>
  <script src="/js/sys/user/userUpdate.js"></script>   
