<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<Domain.SysUsers>" %>

<style type="text/css">
	#sysUserForm table th {
		font-weight: normal;
		text-align: right;
	}
</style>

<form id="sysUserForm" class="easyui-form" method="post" data-options="novalidate:true">
	<input type="hidden" name="ID" value="<%: Model.ID %>" />
	<table style="margin: 20px auto;" cellpadding="3">
		<tr>
			<th><label for="txtAccount"><%: Html.Language("Account")%>：</label></th>
			<td><input id="txtAccount" name="Account" class="easyui-validatebox textbox text" data-options="required:true,validType:'length[3,20]'" value="<%: Model.Account %>" /></td>
		</tr>
		<%--<tr>
			<th><label for="selSysHotelGroup"><%: Html.Language("SysHotelGroupName")%>：</label></th>
			<td>
				<select id="selSysHotelGroup" name="SysHotelGroupID" class="easyui-combotree" style="width:180px;" 
					data-options="
						lines:true,
						editable:false,
						bodyCls:'easyui-tree-no-icon',
						url:'/SysHotel/LoadGroupTree2/',
						panelHeight: 'auto',
						required: true,
						onSelect: selSysHotelGroupOnSelect,
						value: <%: Model.SysHotelGroup != null ? Model.SysHotelGroup.ID.ToString() : "''" %>
					">
				</select>
			</td>
		</tr>--%>
		<tr>
			<th><label for="selRole"><%: Html.Language("RoleName")%>：</label></th>
			<td>
				<select id="selRole" name="RoleID" class="easyui-combobox" style="width:180px;" 
					data-options="
						editable: false,
						valueField: 'ID',
						textField: 'Name',
						url: '/SysRole/LoadAll',
						panelHeight: 'auto',
						required: true,
						value: <%: Model.Role != null ? Model.Role.ID.ToString() : "''" %>
					">
				</select>
			</td>
		</tr>
		<tr>
			<th><label for="selGroup"><%: Html.Language("Floor")%>：</label></th>
			<td>
				<select id="selGroup" name="GroupID" class="easyui-combotree" style="width:180px;" 
					data-options="
						lines:true,
						editable:false,
						bodyCls:'easyui-tree-no-icon',
						url:'/Group/LoadGroupTree2?hotelID='+<%: Model.HotelID != null ? Model.HotelID : 0 %>,
						panelHeight: 'auto',
						required: true,
						value: <%: Model.Group != null ? Model.Group.ID.ToString() : "''" %>
					">
				</select>
			</td>
		</tr>
		<tr>
			<th><label><%: Html.Language("StartUsing")%>：</label></th>
			<td>
				<input type="radio" name="ActiveIndicator" value="true" <%: Model.ActiveIndicator ? "checked='checked'" : "" %> /><%: Html.Language("Yes")%>
				<input type="radio" name="ActiveIndicator" value="false" <%: !Model.ActiveIndicator ? "checked='checked'" : "" %> /><%: Html.Language("No")%>
			</td>
		</tr>
		<tr>
			<th><label for="txtSort"><%: Html.Language("Sort")%>：</label></th>
			<td><input id="txtSort" name="Sort" class="easyui-numberspinner text" value="1" style="width:60px;" data-options="required:true,min:1,value:<%: Model.Sort %>" /></td>
		</tr>
		<tr>
			<th style="vertical-align: top;"><label for="txtRemark"><%:Html.Language("Remark")%>：</label></th>
			<td><textarea id="txtRemark" name="Remark" class="easyui-validatebox textbox text" data-options="validType:length[0,200]" cols="30" rows="5"><%: Model.Remark %></textarea></td>
		</tr>
	</table>
</form>