<%@ Page Language="C#" MasterPageFile="~/Views/Shared/MasterPage.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	<%: Html.Language("RolesMgmt")%>
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

	<div title='<%: Html.Language("RolesMgmt")%>' class="easyui-panel" data-options="fit:true,border:false" >
		
		<div class="easyui-layout" data-options="fit:true">
			<div data-options="region:'north',border:false">
				<div class="datagrid-toolbar">
					<a href="javascript:void(0)" class="easyui-linkbutton" data-options="iconCls:'icon-reload',plain:true" onclick="loadRoles()"><%: Html.Language("Refresh")%></a> 
					<a href="javascript:void(0)" class="easyui-linkbutton" data-options="iconCls:'icon-add',plain:true" onclick="add()"><%: Html.Language("New")%></a>
					<a href="javascript:void(0)" class="easyui-linkbutton" data-options="iconCls:'icon-edit',plain:true" onclick="edit()"><%: Html.Language("Edit")%></a>
					<a href="javascript:void(0)" class="easyui-linkbutton" data-options="iconCls:'icon-remove',plain:true" onclick="delData()"><%: Html.Language("Delete")%></a>
				</div>
			</div>
			
			<div data-options="region:'center',border:false">
				<table id="rolelist" class="role-list" width="100%"></table>
			</div>
		</div>
	</div>
	<div id="dialog" class="easyui-window"   style="padding: 5px;"
		data-options="
			closed: true,
			modal: true,
			collapsible: false,
			minimizable: false,
			maximizable: false
		">
		<div class="easyui-panel dlg-content" style="margin-bottom:5px;"></div>
		<div class="dlg-footer" style="text-align:right; padding:5px 5px 0 0;">
			<a class="easyui-linkbutton dlg-btn-save" data-options="iconCls:'icon-save'" href="javascript:void(0)"><%: Html.Language("Save")%></a>
			<a class="easyui-linkbutton dlg-btn-cancel" data-options="iconCls:'icon-cancel'" href="javascript:void(0)" onclick="$('#dialog').window('close');"><%: Html.Language("Cancel")%></a>
		</div>
	</div>
</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="ScriptContent" runat="server">
	<script type="text/javascript" src="/Scripts/sys-role-index.js"></script>
    <% switch ((int)Session["isCN"]){case 1: %>
    <script type="text/javascript" src="/Scripts/en-US.js"></script>
    <% break; case 2: %>
    <script type="text/javascript" src="/Scripts/zh-TW.js"></script>
    <% break;default: %>
    <script type="text/javascript" src="/Scripts/zh-CN.js"></script>
    <% break; } %>
	<style type="text/css">
		.role-list {
			border-collapse:collapse;	
		}
		.role-list tr {
			cursor:default;	
		}
		.role-list .selected, 
		.role-list tr:hover {
			background:#d3e1f1;
		}
		.role-list .item-header{
			width:50px;
			height:50px;
			text-align:center;
			vertical-align:middle;
		}
		.role-list h3{
			margin:7px 0px;
		}
	</style>
</asp:Content>