Web_ScienceManage/ProjectBookAdd.aspx.cs

(开头部分) 6KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Model;
using BLL;
using DAL;
using System.Data;
using System.Data.SqlClient;
using System.Configuration;

public partial class ProjectBookAdd : System.Web.UI.Page
{
    public string dh = "项目预约填写";//导航
    public Users users = new Users();
    public static string connectionString = ConfigurationManager.ConnectionStrings["DBConn"].ConnectionString; 
    protected void Page_Load(object sender, EventArgs e)
    {

        if (Session["Users"] != null)
        {
            users = (Users)Session["Users"];
        }
        else
        {
            users = new Users();
            Response.Write("<script>parent.window.location.href='login.aspx'</script>");
        }
        if (Request.QueryString["menuId"] != null)
        {
            List<Authority> listAut = AuthorityBLL.AllData(" and RoleId=" + users.RoleId);

            for (int i = 0; i < listAut.Count; i++)
            {
                if (listAut.Count != 0)
                {
                    if (listAut[i].ModuleId == Convert.ToInt32(Request.QueryString["menuId"]))
                    {
                        if (listAut[i].IsVisible != "是")
                        {
                            Response.Redirect("error.aspx");
                        }
                    }
                }
            }
        }
        if (!IsPostBack)
        {
            string sql = string.Format(@"select max(bookid) from ProjectBook");
            int bookid = DBHelper.GetIntScalar2(sql);
            
            lblProjectNum.Text = "0" + (bookid+ 1).ToString();
            lblUserName.Text = UsersBLL.GetIdByUsers(users.UserId).RealName;
            if (Request.QueryString["uid"] != null)
            {
                sql = "SELECT  * FROM ProjectBook where bookid="+Request.QueryString["uid"]+"";
                DataTable dt = DBHelper.GetDataSet(sql);
                DataRow dr = dt.Rows[0];
后面还有 114 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。