using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using SysCore;
using SysCore.Model;
using SysCore.DAL;
using SysCore.Control;

public partial class System_SystemFrame_ModuleLeft : System.Web.UI.Page
{
    public Hashtable xview = new Hashtable();
    string category = "";
    protected void Page_Load(object sender, EventArgs e)
    {
        new LoginState().CheckLogin();
        if (!Page.IsPostBack)
            InitPage();
    }
    public void InitPage()
    {
        if (Request["category"] != null)
        {
            category = Request.QueryString["category"];
            Module m = new ModuleDAL().GetByCode(category);
            string prev_page = "ModuleLeft.aspx?category=" + m.category;
            xview.Add("prev_page", prev_page);
        }
        SystemModule sm = new SystemModule();
        string html_module = sm.LoadModule(category);
        //Response.Write("已加载模块");
        if (html_module.Equals("Read_Serial_Number_Fail"))
        {
            xview.Add("module_list", "<script type='text/javascript'>alert('序列号出错!');parent.G('AmysqlContent').src = '../../Install/Key/Default.aspx';</script>");
        }
        else
        {
            xview.Add("module_list", html_module);
        }
        
            
    }
}