Exemplo n.º 1
0
    /// <summary>
    /// 保存操作
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        string ysmm = Security.Encode(this.GetRequestStr("txtysmm"));   //原密码
        string xmm  = Security.Encode(this.GetRequestStr("txtxmm"));    //新密码
        string zsyc = Security.Encode(this.GetRequestStr("txtzsyc"));   //确认密码

        if (xmm != zsyc)
        {
            new MessageBox(this).Show("两次密码输入不一致!");
            return;
        }
        //更新密码
        int line = dal.UpdateUserPwd(xmm, LoginUser.GetUserId);

        if (line > 0)
        {
            //Alert("编辑成功", "UserListList.aspx");
            new MessageBox(Page).ShowAndJump("密码修改成功!", "../../Manage_Center.aspx");
            //操作日志
            LogListDal.Insert(DateTime.Now, "用户密码修改成功", LoginUser.GetUserId, LoginUser.GetUserName);
        }
        else
        {
            new MessageBox(this.Page).Show("修改密码失败!");
        }
    }
Exemplo n.º 2
0
    //档案归档
    protected void btnSave_Click(object sender, EventArgs e)
    {
        if (this.drop_FileLibraryName.SelectedItem.Text == "")
        {
            new MessageBox(this.Page).Show("请选择档案库室!");
            return;
        }

        ArrayList alsql  = new ArrayList();
        string    sqlStr = ""; //移交记录归档

        sqlStr = " update FileTransfer set  sjzt=3,Gdr='" + LoginUser.GetUserName + "',Gdsj='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "' where id='" + HiddenFieldyj.Value + "' ";
        alsql.Add(sqlStr);
        string strupdate = ""; //移交档案归档

        strupdate = " update FileEnter set  FileLibraryID='" + this.drop_FileLibraryName.SelectedValue + "',FileLibraryName='" + this.drop_FileLibraryName.SelectedItem.Text + "',FileLibraryData='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',FileTransferSJLX=2  where id='" + HiddenFieldda.Value + "' ";
        alsql.Add(strupdate);
        Boolean flag = TSQLServer.execTriggerAll(alsql);

        if (flag == true)
        {
            new MessageBox(Page).ShowAndJump("执法档案归档成功!", "Manage_Center.aspx");
            //操作日志
            LogListDal.Insert(DateTime.Now, "归档执法档案" + this.HiddenFieldda.Value + "", LoginUser.GetUserId, LoginUser.GetUserName);
        }
        else
        {
            new MessageBox(Page).ShowAndJump("执法档案归档失败!", "Manage_Center.aspx");
        }
    }
Exemplo n.º 3
0
    /// <summary>
    /// 保存操作
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        //获取界面数值赋值给model对象
        int    id             = this.GetRequestInt("id");
        string txtFileDirName = this.txtFileDirName.Text.Trim();// this.GetRequestStr("txtFileDirName").Trim();

        if (txtFileDirName == "")
        {
            new MessageBox(this).Show("请输入档案目录名称!");
            return;
        }

        int line = 0;  //定义增加受影响的行数


        //判断是否存在数据信息
        if (this.GetRequestInt("id") > 0)
        {
            line = dal.Update(
                txtFileDirName, LoginUser.GetUserId, LoginUser.GetUserName, DateTime.Now.ToString(), id);
            if (line > 0)
            {
                //Alert("编辑成功", "FileClassList.aspx");
                new MessageBox(Page).ShowAndJump("编辑成功!", "FileDirectoryList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "档案目录编辑成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("编辑失败!");
            }
            //Alert("编辑失败", true);
        }
        else
        {
            if (dal.GetDataTable(" and FileDirName='" + txtFileDirName + "'").Rows.Count > 0)
            {
                new MessageBox(this).Show("档案目录名称已存在!");
                return;
            }
            line = dal.Insert(
                txtFileDirName, LoginUser.GetUserId, LoginUser.GetUserName, DateTime.Now.ToString());
            if (line > 0)
            {
                //Alert("增加成功", "FileClassList.aspx");
                new MessageBox(Page).ShowAndJump("增加成功!", "FileDirectoryList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "档案目录增加成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("增加失败!");
            }
            //Alert("增加失败", true);
        }
    }
Exemplo n.º 4
0
    //单个删除
    protected void rptList_ItemCommand(object source, RepeaterCommandEventArgs e)
    {
        Label cb_id = (Label)e.Item.FindControl("lb_id");

        switch (e.CommandName.ToLower())
        {
        case "del":
            dal.Delete(cb_id.Text);
            new MessageBox(Page).ShowAndJump("删除成功!", "UserListList.aspx");
            //操作日志
            LogListDal.Insert(DateTime.Now, "用户删除", LoginUser.GetUserId, LoginUser.GetUserName);
            this.BindDaSource();
            break;
        }
    }
Exemplo n.º 5
0
    //批量接收
    protected void btnCheckSave_Click(object sender, EventArgs e)
    {
        string ids = "0";

        for (int i = 0; i < rptList.Items.Count; i++)
        {
            int      id = ((Label)rptList.Items[i].FindControl("lb_id")).Text.ToInt32();
            CheckBox cb = (CheckBox)rptList.Items[i].FindControl("cb_id");
            if (cb.Checked)
            {
                ids += "," + id;
            }
        }

        DataTable dttf  = daltf.GetDataTable(" and id in (" + ids + ") ");
        ArrayList alsql = new ArrayList();
        Boolean   flag  = false;

        if (AccessDataSet.HasDataTable(dttf))
        {
            foreach (DataRow item in dttf.Rows)
            {
                string sqlStr = "";  //接收移交记录
                sqlStr = " update FileTransfer set  sjzt=2,Jssj='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',AcceptPeople='" + LoginUser.GetUserName + "',AcceptUnit='" + LoginUser.OrganizerName + "' where id='" + item["id"] + "' ";
                alsql.Add(sqlStr);
                string  strupdate = ""; //接收更新档案状态
                DataRow drdg      = fedal.GetRow(item["FileEnterID"]);
                if (drdg != null)
                {
                    strupdate = " update FileEnter set  ReceiptTime='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',oldEnteCountyId='" + drdg["EnteCountyId"] + "',oldEnteUserName='******',EnteCountyId='" + LoginUser.CountyId + "',EnteUserName='******',EnforcementID_new='" + LoginUser.OrganizerId + "',EnforcementName_new='" + LoginUser.OrganizerName + "',FileLibraryID_old='" + drdg["FileLibraryID"] + "',FileLibraryName_old='" + drdg["FileLibraryName"] + "',FileLibraryID='',FileLibraryName='',FileTransferSJLX=1,FileTransferID='" + item["id"] + "'  where id='" + item["FileEnterID"] + "' ";
                }
                alsql.Add(strupdate);
            }
            flag = TSQLServer.execTriggerAll(alsql);
        }
        if (flag == true)
        {
            new MessageBox(Page).ShowAndJump("批量移交支队成功!", "Manage_Center.aspx");
            //操作日志
            LogListDal.Insert(DateTime.Now, "案卷档案[" + ids + "]批量移交支队", LoginUser.GetUserId, LoginUser.GetUserName);
        }
        else
        {
            new MessageBox(Page).ShowAndJump("批量移交支队失败!", "Manage_Center.aspx");
        }
        this.BindDaSource();
    }
Exemplo n.º 6
0
    //批量删除
    protected void lbtnDel_Click(object sender, EventArgs e)
    {
        string ids = "0";

        for (int i = 0; i < rptList.Items.Count; i++)
        {
            int      id = ((Label)rptList.Items[i].FindControl("lb_id")).Text.ToInt32();
            CheckBox cb = (CheckBox)rptList.Items[i].FindControl("cb_id");
            if (cb.Checked)
            {
                ids += "," + id;
            }
        }
        dal.DeleteAllIn(ids);
        new MessageBox(Page).ShowAndJump("批量删除成功!", "UserListList.aspx");
        //操作日志
        LogListDal.Insert(DateTime.Now, "用户删除", LoginUser.GetUserId, LoginUser.GetUserName);
        this.BindDaSource();
    }
Exemplo n.º 7
0
    //批量移交支队
    protected void lbtnFileTransfer_Click(object sender, EventArgs e)
    {
        string ids = "0";

        for (int i = 0; i < rptyjzdList.Items.Count; i++)
        {
            int      id = ((Label)rptyjzdList.Items[i].FindControl("lb_id")).Text.ToInt32();
            CheckBox cb = (CheckBox)rptyjzdList.Items[i].FindControl("cb_id");
            if (cb.Checked)
            {
                ids += "," + id;
            }
        }

        DataTable dttf  = dal.GetDataTableyjzd(" and id in (" + ids + ") ");
        ArrayList alsql = new ArrayList();
        Boolean   flag  = false;

        if (AccessDataSet.HasDataTable(dttf))
        {
            foreach (DataRow item in dttf.Rows)
            {
                string sqlStr = "";  //添加移交记录
                sqlStr = " insert into FileTransfer(FileEnterID,FileClassID,FileClassName,FileEnterName,TransferPeople,TransferUnit,AcceptSzqxdm,TransferDate,OperateTime,Remark,UserID,Username,sjzt,SZQXDM,Yjlx) values ('" + item["id"].ToString() + "','" + item["FileClassID"].ToString() + "','" + item["FName"].ToString() + "','" + item["FilesName"].ToString() + "','" + LoginUser.GetUserName + "','" + LoginUser.OrganizerName + "','420100','" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "','" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "','','" + LoginUser.GetUserId + "','" + LoginUser.GetUserName + "',0,'" + LoginUser.CountyId + "',1) ";
                alsql.Add(sqlStr);
                string strupdate = ""; //更新移交时间
                strupdate = " update FileEnter set  FileTransferDate='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',sjlx=3 where id='" + item["id"].ToString() + "' ";
                alsql.Add(strupdate);
            }
            flag = TSQLServer.execTriggerAll(alsql);
        }
        if (flag == true)
        {
            new MessageBox(Page).ShowAndJump("批量移交支队成功!", "FileTransferyjzd.aspx");
            //操作日志
            LogListDal.Insert(DateTime.Now, "案卷档案[" + ids + "]批量移交支队", LoginUser.GetUserId, LoginUser.GetUserName);
        }
        else
        {
            new MessageBox(Page).ShowAndJump("批量移交支队失败!", "FileTransferyjzd.aspx");
        }
        this.BindDaSource();
    }
Exemplo n.º 8
0
    //单个删除
    protected void rptList_ItemCommand(object source, RepeaterCommandEventArgs e)
    {
        Label cb_id = (Label)e.Item.FindControl("lb_id");

        switch (e.CommandName.ToLower())
        {
        case "del":
            //dal.Delete(cb_id.Text);
            dal.DeleteUpdate("8", cb_id.Text);
            //Alert("删除成功", "FileClassList.aspx");
            new MessageBox(Page).ShowAndJump("删除成功!", "FileEnterList.aspx");
            //操作日志
            LogListDal.Insert(DateTime.Now, "案卷档案删除", LoginUser.GetUserId, LoginUser.GetUserName);
            this.BindDaSource();
            break;

        case "edit":
            Response.Redirect("FileEnterEdit.aspx?id=" + cb_id.Text + "");
            break;
        }
    }
Exemplo n.º 9
0
    //单个移交支队
    protected void rptyjzdList_ItemCommand(object source, RepeaterCommandEventArgs e)
    {
        Label cb_id = (Label)e.Item.FindControl("lb_id");

        switch (e.CommandName.ToLower())
        {
        case "transfer":
            DataRow drdg = dal.GetRow(cb_id.Text);
            if (drdg != null)
            {
                ArrayList alsql  = new ArrayList();
                string    sqlStr = "";   //添加移交记录
                sqlStr = " insert into FileTransfer(FileEnterID,FileClassID,FileClassName,FileEnterName,TransferPeople,TransferUnit,AcceptSzqxdm,TransferDate,OperateTime,Remark,UserID,Username,sjzt,SZQXDM,Yjlx) values ('" + drdg["id"].ToString() + "','" + drdg["FileClassID"].ToString() + "','" + drdg["FName"].ToString() + "','" + drdg["FilesName"].ToString() + "','" + LoginUser.GetUserName + "','" + LoginUser.OrganizerName + "','420100','" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "','" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "','','" + LoginUser.GetUserId + "','" + LoginUser.GetUserName + "',0,'" + LoginUser.CountyId + "',1) ";
                alsql.Add(sqlStr);
                string strupdate = "";     //更新移交时间
                strupdate = " update FileEnter set  FileTransferDate='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',sjlx=3 where id='" + drdg["id"].ToString() + "' ";
                alsql.Add(strupdate);
                Boolean flag = TSQLServer.execTriggerAll(alsql);
                if (flag == true)
                {
                    new MessageBox(Page).ShowAndJump("执法档案" + drdg["FilesName"].ToString() + "移交支队成功!", "FileTransferyjzd.aspx");
                    //操作日志
                    LogListDal.Insert(DateTime.Now, "执法档案" + drdg["id"].ToString() + "+" + drdg["FilesName"].ToString() + "移交支队", LoginUser.GetUserId, LoginUser.GetUserName);
                }
                else
                {
                    new MessageBox(Page).ShowAndJump("执法档案" + drdg["FilesName"].ToString() + "移交支队失败!", "FileTransferyjzd.aspx");
                }
            }
            else
            {
                new MessageBox(Page).ShowAndJump("执法档案" + drdg["FilesName"].ToString() + "移交支队失败!", "FileTransferyjzd.aspx");
            }

            this.BindDaSource();
            break;
        }
    }
Exemplo n.º 10
0
    //操作事件--接收档案
    protected void LinkButtonALL_Command(object sender, CommandEventArgs e)
    {
        string CommandName;

        string[] CurrentValueId;
        CurrentValueId = e.CommandArgument.ToString().Split(new string[] { "," }, StringSplitOptions.RemoveEmptyEntries);
        CommandName    = e.CommandName;
        //接收档案
        if (CommandName.ToString() == "FileTransfer")
        {
            DataRow drdg = fedal.GetRow(CurrentValueId[1]);
            if (drdg != null)
            {
                ArrayList alsql  = new ArrayList();
                string    sqlStr = ""; //接收移交记录
                sqlStr = " update FileTransfer set  sjzt=2,Jssj='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',AcceptPeople='" + LoginUser.GetUserName + "',AcceptUnit='" + LoginUser.OrganizerName + "' where id='" + CurrentValueId[0] + "' ";
                alsql.Add(sqlStr);
                string strupdate = ""; //接收更新档案状态
                strupdate = " update FileEnter set  ReceiptTime='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',oldEnteCountyId='" + drdg["EnteCountyId"] + "',oldEnteUserName='******',EnteCountyId='" + LoginUser.CountyId + "',EnteUserName='******',EnforcementID_new='" + LoginUser.OrganizerId + "',EnforcementName_new='" + LoginUser.OrganizerName + "',FileLibraryID_old='" + drdg["FileLibraryID"] + "',FileLibraryName_old='" + drdg["FileLibraryName"] + "',FileLibraryID='',FileLibraryName='',FileTransferSJLX=1,FileTransferID='" + CurrentValueId[0] + "'  where id='" + CurrentValueId[1] + "' ";
                alsql.Add(strupdate);
                Boolean flag = TSQLServer.execTriggerAll(alsql);
                if (flag == true)
                {
                    new MessageBox(Page).ShowAndJump("执法档案接收成功!", "Manage_Center.aspx");
                    //操作日志
                    LogListDal.Insert(DateTime.Now, "接收执法档案" + CurrentValueId[0] + "", LoginUser.GetUserId, LoginUser.GetUserName);
                }
                else
                {
                    new MessageBox(Page).ShowAndJump("执法档案接收失败!", "Manage_Center.aspx");
                }
            }
            else
            {
                new MessageBox(Page).ShowAndJump("执法档案接收失败!", "Manage_Center.aspx");
            }
        }
    }
Exemplo n.º 11
0
    //拒收
    protected void btnCheckSavejs_Click(object sender, EventArgs e)
    {
        ArrayList alsql  = new ArrayList();
        string    sqlStr = ""; //拒收移交记录

        sqlStr = " update FileTransfer set  sjzt=1,Jsyy='" + this.txt_jsyy.Text + "',AcceptPeople='" + LoginUser.GetUserId + "',AcceptUnit='" + LoginUser.OrganizerName + "' where id='" + this.HiddenFieldjs.Value + "' ";
        alsql.Add(sqlStr);
        string strupdate = ""; //拒收更新档案状态

        strupdate = " update FileEnter set  sjlx=0 where id='" + this.HiddenFieldjsda.Value + "' ";
        alsql.Add(strupdate);
        Boolean flag = TSQLServer.execTriggerAll(alsql);

        if (flag == true)
        {
            new MessageBox(Page).ShowAndJump("执法档案拒收成功!", "Manage_Center.aspx");
            //操作日志
            LogListDal.Insert(DateTime.Now, "拒收执法档案" + this.HiddenFieldjsda.Value + "", LoginUser.GetUserId, LoginUser.GetUserName);
        }
        else
        {
            new MessageBox(Page).ShowAndJump("执法档案拒收失败!", "Manage_Center.aspx");
        }
    }
Exemplo n.º 12
0
    /// <summary>
    /// 保存操作
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        //获取界面数值赋值给model对象
        int id = this.GetRequestInt("id");
        //string txtPunishTypeName = this.GetRequestStr("txtPunishTypeName");
        string txtPunishTypeName = this.txtPunishTypeName.Text.Trim();

        if (txtPunishTypeName == "")
        {
            new MessageBox(this).Show("请输入处罚类型名称!");
            return;
        }
        string drop_FileClassName = this.drop_FileClassName.SelectedValue;

        if (drop_FileClassName == "")
        {
            new MessageBox(this).Show("请选择档案类别!");
            return;
        }


        int line = 0;  //定义增加受影响的行数


        if (this.GetRequestInt("id") > 0)
        {
            line = dal.Update(
                txtPunishTypeName, this.drop_FileClassName.SelectedItem.Text, drop_FileClassName, LoginUser.GetUserId, LoginUser.GetUserName, DateTime.Now.ToString(), id);
            if (line > 0)
            {
                //Alert("编辑成功", "FileClassList.aspx");
                new MessageBox(Page).ShowAndJump("编辑成功!", "PunishTypeList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "处罚类型编辑成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("编辑失败!");
            }
            //Alert("编辑失败", true);
        }
        else
        {
            //判断是否存在数据信息
            if (dal.GetDataTable(" and PunishTypeName='" + txtPunishTypeName + "'").Rows.Count > 0)
            {
                new MessageBox(this).Show("处罚类型名称已存在!");
                return;
            }

            line = dal.Insert(
                txtPunishTypeName, this.drop_FileClassName.SelectedItem.Text, drop_FileClassName, LoginUser.GetUserId, LoginUser.GetUserName, DateTime.Now.ToString());
            if (line > 0)
            {
                //Alert("增加成功", "FileClassList.aspx");
                new MessageBox(Page).ShowAndJump("增加成功!", "PunishTypeList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "处罚类型增加成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("增加失败!");
            }
            //Alert("增加失败", true);
        }
    }
Exemplo n.º 13
0
    /// <summary>
    /// 保存操作
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        //获取界面数值赋值给model对象
        int    id           = this.GetRequestInt("id");
        string userName     = this.txtuserName.Text.Trim(); //this.GetRequestStr("txtuserName");
        string passWord     = Security.Encode(this.GetRequestStr("txtpassWord").Trim());
        string userRealName = this.GetRequestStr("txtuserRealName");
        string userTel      = this.GetRequestStr("txtuserTel");
        int    userState    = this.GetRequestInt("txtuserState");
        string userMail     = this.GetRequestStr("txtuserMail");
        string userPost     = this.txtuserPost.SelectedValue;
        string userqxdm     = this.drop_qxdm.SelectedValue;

        if (userqxdm == "")
        {
            new MessageBox(this).Show("请选择所属支队或大队!");
            return;
        }
        DateTime userLastLogin = DateTime.Now;
        int      line          = 0; //定义增加受影响的行数


        //判断是否存在数据信息
        if (this.GetRequestInt("id") > 0)
        {
            line = dal.Update(
                userName,
                passWord,
                userRealName,
                userTel,
                userState,
                userMail,
                userLastLogin,
                userPost, userqxdm, LoginUser.GetUserId, LoginUser.GetUserName, DateTime.Now.ToString(), id);
            if (line > 0)
            {
                //Alert("编辑成功", "UserListList.aspx");
                new MessageBox(Page).ShowAndJump("编辑成功!", "UserListList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "用户编辑成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("编辑失败!");
            }
            //Alert("编辑失败", true);
        }
        else
        {
            line = dal.Insert(
                userName,
                passWord,
                userRealName,
                userTel,
                userState,
                userMail,
                userLastLogin,
                userPost,
                userqxdm, LoginUser.GetUserId, LoginUser.GetUserName, DateTime.Now.ToString());
            if (line > 0)
            {
                //Alert("增加成功", "UserListList.aspx");
                new MessageBox(Page).ShowAndJump("增加成功!", "UserListList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "用户增加成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                //Alert("增加失败", true);
                new MessageBox(this.Page).Show("增加失败!");
            }
        }
    }
Exemplo n.º 14
0
    /// <summary>
    /// 保存档案管理录入
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        int FileClassID = 0;

        for (int i = 0; i < rptList.Items.Count; i++)
        {
            int      fid = ((Label)rptList.Items[i].FindControl("FileClassID")).Text.ToInt32();
            CheckBox cb  = (CheckBox)rptList.Items[i].FindControl("cl1_000");
            if (cb.Checked)
            {
                FileClassID = fid;
            }
        }

        int FileDirectoryID = this.GetRequestInt("FileDirectoryID");
        int SaveDeadlineID  = this.GetRequestInt("SaveDeadlineID");
        //获取界面数值赋值给model对象
        string   FileFondsNo      = this.GetRequestStr("FileFondsNo");                    //"QZH-" + DateTime.Now.ToStr("yyyyMMddhhmmss") + "01";
        string   FilesNum         = this.GetRequestStr("FilesNum");
        string   EnterPeople      = this.GetRequestStr("txtEnterPeople");                 //档案录入人
        DateTime EnterDate        = Convert.ToDateTime(this.GetRequestStr("fStarttime")); //档案录入时间自动生成
        string   BuildAds         = this.GetRequestStr("BuildAds");
        string   BuildCheckT      = this.GetRequestStr("BuildCheckT");
        string   BuildFilingT     = this.GetRequestStr("BuildFilingT");
        string   BuildArea        = this.GetRequestStr("BuildArea");
        int      BuildALicense    = this.GetRequestInt("BuildALicense");
        string   CheckAds         = this.GetRequestStr("CheckAds");
        string   CheckNature      = this.GetRequestStr("CheckNature");
        int      CheckResult      = this.GetRequestInt("CheckResult");
        string   ComplainAds      = this.GetRequestStr("ComplainAds");
        int      ComplainResult   = this.GetRequestInt("ComplainResult");
        string   FireNature       = this.GetRequestStr("FireNature");
        string   FireArea         = this.GetRequestStr("FireArea");
        string   FireEstateLoss   = this.GetRequestStr("FireEstateLoss");
        int      FireHPeople      = this.GetRequestInt("FireHPeople");
        int      FireDPeople      = this.GetRequestInt("FireDPeople");
        string   MassSportsAds    = this.GetRequestStr("MassSportsAds");
        int      MassSportsResult = this.GetRequestInt("MassSportsResult");
        //string PunishTypeID = this.GetRequestStr("PunishTypeID");
        string PunishTypeID = "|";

        if (PunishTypeID0.Checked == true)
        {
            PunishTypeID += "0|";
        }
        if (PunishTypeID1.Checked == true)
        {
            PunishTypeID += "1|";
        }
        if (PunishTypeID2.Checked == true)
        {
            PunishTypeID += "2|";
        }
        if (PunishTypeID3.Checked == true)
        {
            PunishTypeID += "3|";
        }
        if (PunishTypeID4.Checked == true)
        {
            PunishTypeID += "4|";
        }
        double PunishFinePay     = this.GetRequestDouble("PunishFinePay");
        string PunishParts       = this.GetRequestStr("PunishParts");
        string TempClose         = this.GetRequestStr("TempClose");
        int    TempDay           = this.GetRequestInt("TempDay");
        string ForceRunAds       = this.GetRequestStr("ForceRunAds");
        string ForcePunish       = this.GetRequestStr("ForcePunish");
        string ApplyReviewPeople = this.GetRequestStr("ApplyReviewPeople");
        string CountryPayAds     = this.GetRequestStr("CountryPayAds");
        string PenalDocSex       = this.GetRequestStr("PenalDocSex");
        string PenalDocBirthday  = this.GetRequestStr("PenalDocBirthday");
        string PenalDocNation    = this.GetRequestStr("PenalDocNation");
        string PenalDocAds       = this.GetRequestStr("PenalDocAds");
        string PenalDocCrimeAds  = this.GetRequestStr("PenalDocCrimeAds");

        int    EnforcementID      = Convert.ToInt32(this.drop_EnforcementName.SelectedItem.Value);
        string EnforcementName    = this.drop_EnforcementName.SelectedItem.Text;
        string EnforcementPeople  = this.GetRequestStr("txt_EnforcementPeople");
        string EnforcementPeople2 = this.GetRequestStr("txt_EnforcementPeople2");
        string EnforcementDate    = this.GetRequestStr("txt_EnforcementDate");
        string EnforcementDate2   = this.GetRequestStr("txt_EnforcementDate2");
        string BuildUnitName      = this.GetRequestStr("BuildUnitName");
        string BuildItemName      = this.GetRequestStr("BuildItemName");
        string CheckUnitName      = this.GetRequestStr("CheckUnitName");
        string ComplainPeople     = this.GetRequestStr("ComplainPeople");
        string ComplainNPeople    = this.GetRequestStr("ComplainNPeople");
        string CompainN           = this.GetRequestStr("CompainN");
        string MassSportsPeople   = this.GetRequestStr("MassSportsPeople");
        string MassSportName      = this.GetRequestStr("MassSportName");
        string FireAds            = this.GetRequestStr("FireAds");
        string FireUnitName       = this.GetRequestStr("FireUnitName");
        string FireDateTime       = this.GetRequestStr("FireDateTime");
        string FireN      = this.GetRequestStr("FireN");
        string PunishMain = this.GetRequestStr("PunishMain");
        string PunishWhy  = string.Empty; //= this.GetRequestStr("PunishWhy");

        for (int i = 0; i < rxwhy.Items.Count; i++)
        {
            string   fid2 = ((Label)rxwhy.Items[i].FindControl("PunishWhy")).Text;
            CheckBox cb2  = (CheckBox)rxwhy.Items[i].FindControl("ckb6");
            if (cb2.Checked)
            {
                PunishWhy = fid2;
            }
        }

        string TempUintName   = this.GetRequestStr("TempUintName");
        string TempN          = this.GetRequestStr("TempN");
        string TempDX         = this.GetRequestStr("TempDX");
        string ForceUnitName  = this.GetRequestStr("ForceUnitName");
        string ForceN         = this.GetRequestStr("ForceN");
        string ApplyFY        = this.GetRequestStr("ApplyFY");
        string CountryMain    = this.GetRequestStr("CountryMain");
        string PenalName      = this.GetRequestStr("PenalName");
        string PenalZN        = this.GetRequestStr("PenalZN");
        string ApplyNContent  = this.GetRequestStr("ApplyNContent");
        string PunishAds      = this.GetRequestStr("PunishAds");
        string ApplyMain      = this.GetRequestStr("ApplyMain");
        string YesUnit        = this.GetRequestStr("YesUnit");
        string buildingHeight = this.GetRequestStr("buildingHeight");
        string CheckItemName  = this.GetRequestStr("CheckItemName");
        //修改
        string Ghmj           = this.GetRequestStr("txt_ghmj");            //过火面积
        string Ccss           = this.GetRequestStr("txt_ccss");            //财产损失
        string Srs            = this.GetRequestStr("txt_srs");             //伤人数
        string Wrs            = this.GetRequestStr("txt_wrs");             //亡人数
        string PenalDocResult = Ghmj + "," + Ccss + "," + Srs + "," + Wrs; //案件危害后果

        //    if (this.PicDocumentNo1.Text!="")
        //{
        //     string PicDocumentNo
        //}
        DataRow drFc          = fcdal.GetRow(FileClassID);
        string  FileClassName = string.Empty;

        if (drFc != null)
        {
            FileClassName = drFc["FileName"].ToStr();
        }
        string PicDocumentNo = string.Empty;
        string PicDicL       = string.Empty;
        string EngDroping    = string.Empty;

        if (FileClassName == "开业(使用)前检查卷")
        {
            PicDocumentNo = this.GetRequestStr("PicDocumentNo2");
            PicDicL       = this.GetRequestStr("PicDicL2");
            EngDroping    = this.GetRequestStr("EngDroping2");
        }
        else
        {
            PicDocumentNo = this.GetRequestStr("PicDocumentNo1");
            PicDicL       = this.GetRequestStr("PicDicL1");
            EngDroping    = this.GetRequestStr("EngDroping1");
        }

        string FileLibraryID   = "";
        string FileLibraryName = string.Empty;
        string FileLibraryData = String.Empty;

        if (this.drop_FileLibraryName.SelectedIndex != -1 && this.drop_FileLibraryName.SelectedItem.Value != "")
        {
            FileLibraryID   = this.drop_FileLibraryName.SelectedItem.Value;
            FileLibraryName = this.drop_FileLibraryName.SelectedItem.Text;
            FileLibraryData = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
        }

        //2013-12-30 行政区
        #region 行政区
        string BuildAdsArea         = this.BuildAdsArea.SelectedItem.Value;
        string CheckAdsArea         = this.CheckAdsArea.SelectedItem.Value;
        string ComplainAdsArea      = this.ComplainAdsArea.SelectedItem.Value;
        string MassSportsAdsArea    = this.MassSportsAdsArea.SelectedItem.Value;
        string PunishAdsArea        = this.PunishAdsArea.SelectedItem.Value;
        string TempCloseArea        = this.TempCloseArea.SelectedItem.Value;
        string ForceRunAdsArea      = this.ForceRunAdsArea.SelectedItem.Value;
        string ApplyFYArea          = this.ApplyFYArea.SelectedItem.Value;
        string CountryPayAdsArea    = this.CountryPayAdsArea.SelectedItem.Value;
        string PenalDocAdsArea      = this.PenalDocAdsArea.SelectedItem.Value;
        string PenalDocCrimeAdsArea = this.PenalDocCrimeAdsArea.SelectedItem.Value;
        #endregion
        //2013-12-31 排架号
        string Columns  = this.GetRequestStr("Columns");   //列
        string Cupboard = this.GetRequestStr("Cupboard");  //柜
        string Frame    = this.GetRequestStr("Frame");     //架

        string CheckNaturefc = "0";
        if (this.CheckNaturefc.Checked == true)
        {
            CheckNaturefc = "1";
        }

        #region 执法档案名称
        string zfdnmc = string.Empty;
        //------------------------1--------------------
        if (BuildUnitName != "")
        {
            zfdnmc = BuildUnitName + BuildItemName;
        }
        //------------------------2--------------------
        if (CheckUnitName != "")
        {
            zfdnmc = CheckUnitName;
        }
        //------------------------3--------------------
        if (ComplainPeople != "")
        {
            zfdnmc = ComplainPeople + "举报" + ComplainNPeople + CompainN;
        }
        //------------------------4--------------------
        if (MassSportsPeople != "")
        {
            zfdnmc = MassSportsPeople + MassSportName;
        }
        //------------------------5--------------------
        if (FireAds != "")
        {
            zfdnmc = FireAds + MassSportName + FireUnitName + "'" + Convert.ToDateTime(FireDateTime).ToString("MM") + "." + Convert.ToDateTime(FireDateTime).ToString("dd") + "'" + this.FireN.SelectedItem.Text;
        }
        //------------------------6--------------------
        if (PunishMain != "")
        {
            zfdnmc = PunishMain + PunishWhy;
        }
        //------------------------7--------------------
        if (TempUintName != "")
        {
            zfdnmc = TempUintName + TempN + TempDX;
        }
        //------------------------8--------------------
        if (ForceUnitName != "")
        {
            zfdnmc = ForceUnitName + ForceN;
        }
        //------------------------9--------------------
        if (ApplyMain != "")
        {
            zfdnmc = ApplyMain + ApplyNContent;
        }
        //------------------------10--------------------
        if (CountryMain != "")
        {
            zfdnmc = CountryMain;
        }
        //------------------------11--------------------
        if (PenalName != "")
        {
            zfdnmc = PenalName + PenalZN;
        }
        string FilesName = zfdnmc;
        #endregion

        int id   = this.GetRequestInt("id");
        int line = 0;//增加编辑受影响的行数
        if (id > 0)
        {
            line = fedal.Update(
                FileFondsNo,
                FileClassID,
                FileDirectoryID,
                FilesNum,
                FilesName,
                EnterPeople,
                EnterDate,
                SaveDeadlineID,
                BuildAds,
                BuildCheckT,
                BuildFilingT,
                BuildArea,
                BuildALicense,
                CheckAds,
                CheckNature,
                CheckResult,
                ComplainAds,
                ComplainResult,
                FireNature,
                FireArea,
                FireEstateLoss,
                FireHPeople,
                FireDPeople,
                MassSportsAds,
                MassSportsResult,
                PunishTypeID,
                PunishFinePay,
                PunishParts,
                TempClose,
                TempDay,
                ForceRunAds,
                ForcePunish,
                ApplyReviewPeople,
                CountryPayAds,
                PenalDocSex,
                PenalDocBirthday,
                PenalDocNation,
                PenalDocAds,
                PenalDocCrimeAds,
                PenalDocResult,
                EnforcementID,
                EnforcementName,
                EnforcementPeople,
                EnforcementPeople2,
                EnforcementDate,
                EnforcementDate2,
                BuildUnitName,
                BuildItemName,
                CheckUnitName,
                CheckItemName,
                ComplainPeople,
                ComplainNPeople,
                CompainN,
                MassSportsPeople,
                MassSportName,
                FireAds,
                FireUnitName,
                FireDateTime,
                FireN,
                PunishMain,
                PunishWhy,
                TempUintName,
                TempN,
                TempDX,
                ForceUnitName,
                ForceN,
                ApplyFY,
                CountryMain,
                PenalName,
                PenalZN,
                ApplyNContent,
                PunishAds,
                ApplyMain,
                LoginUser.GetUserName,
                LoginUser.CountyId,
                FileLibraryID,
                FileLibraryName,
                YesUnit,
                PicDocumentNo,
                PicDicL,
                EngDroping,
                buildingHeight,
                FileLibraryData,
                Ghmj,
                Ccss,
                Srs,
                Wrs,
                BuildAdsArea,
                CheckAdsArea,
                ComplainAdsArea,
                MassSportsAdsArea,
                PunishAdsArea,
                TempCloseArea,
                ForceRunAdsArea,
                ApplyFYArea,
                CountryPayAdsArea,
                PenalDocAdsArea,
                PenalDocCrimeAdsArea,
                CheckNaturefc,
                Columns,
                Cupboard,
                Frame,
                id);

            if (line > 0)
            {
                new MessageBox(Page).ShowAndJump("编辑成功!", "FileEnterList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "档案管理编辑成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("编辑失败!");
            }
        }
        else  //增加
        {
            line = fedal.Insert(
                FileFondsNo,
                FileClassID,
                FileDirectoryID,
                FilesNum,
                FilesName,
                EnterPeople,
                EnterDate,
                SaveDeadlineID,
                BuildAds,
                BuildCheckT,
                BuildFilingT,
                BuildArea,
                BuildALicense,
                CheckAds,
                CheckNature,
                CheckResult,
                ComplainAds,
                ComplainResult,
                FireNature,
                FireArea,
                FireEstateLoss,
                FireHPeople,
                FireDPeople,
                MassSportsAds,
                MassSportsResult,
                PunishTypeID,
                PunishFinePay,
                PunishParts,
                TempClose,
                TempDay,
                ForceRunAds,
                ForcePunish,
                ApplyReviewPeople,
                CountryPayAds,
                PenalDocSex,
                PenalDocBirthday,
                PenalDocNation,
                PenalDocAds,
                PenalDocCrimeAds,
                PenalDocResult,
                EnforcementID,
                EnforcementName,
                EnforcementPeople,
                EnforcementPeople2,
                EnforcementDate,
                EnforcementDate2,
                BuildUnitName,
                BuildItemName,
                CheckUnitName,
                CheckItemName,
                ComplainPeople,
                ComplainNPeople,
                CompainN,
                MassSportsPeople,
                MassSportName,
                FireAds,
                FireUnitName,
                FireDateTime,
                FireN,
                PunishMain,
                PunishWhy,
                TempUintName,
                TempN,
                TempDX,
                ForceUnitName,
                ForceN,
                ApplyFY,
                CountryMain,
                PenalName,
                PenalZN,
                ApplyNContent,
                PunishAds,
                ApplyMain,
                LoginUser.GetUserName,
                LoginUser.CountyId,
                FileLibraryID,
                FileLibraryName,
                YesUnit,
                PicDocumentNo,
                PicDicL,
                EngDroping,
                buildingHeight,
                FileLibraryData,
                Ghmj,
                Ccss,
                Srs,
                Wrs,
                BuildAdsArea,
                CheckAdsArea,
                ComplainAdsArea,
                MassSportsAdsArea,
                PunishAdsArea,
                TempCloseArea,
                ForceRunAdsArea,
                ApplyFYArea,
                CountryPayAdsArea,
                PenalDocAdsArea,
                PenalDocCrimeAdsArea,
                CheckNaturefc,
                Columns,
                Cupboard,
                Frame);
            if (line > 0)
            {
                new MessageBox(Page).ShowAndJump("增加成功!", "FileEnterList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "档案管理录入成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("增加失败!");
            }
        }
    }
Exemplo n.º 15
0
    /// <summary>
    /// 导入数据信息
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btn_Ok_Click(object sender, EventArgs e)
    {
        var f           = Request.Files["FileUpload1"]; //获取导入文件路径
        int fileclassID = this.GetRequestInt("fileclassID");

        if (f.FileName == "")
        {
            new MessageBox(this).Show("请选择导入数据模板!");
            return;
        }
        string getSheetName = "建审";

        if (fileclassID == 12)
        {
            getSheetName = "验收";
        }
        if (fileclassID == 13)
        {
            getSheetName = "开业";
        }

        string path = Server.MapPath("~/tmp/" + Guid.NewGuid().ToString() + ".xls");

        f.SaveAs(path);
        FileInfo  fi = new FileInfo(path);
        DataTable dtS; //存储Excel读取数据信息

        try
        {
            dtS = path.GetExcel(getSheetName).Tables[0];
        }
        catch
        {
            new MessageBox(this).Show("导入文件不是Excel文件或Excel文件版本不符!");
            return;
        }
        finally
        {
            try
            {
                fi.Delete();
            }
            catch { }
        }

        #region 读取excel表格中数据进行字符串拼接



        string sqlStr = "";  //定义ID变量
        for (int i = 1; i < dtS.Rows.Count; i++)
        {
            if (dtS.Rows[i][1].ToString() != "")
            {
                sqlStr += @" if  not exists(select * from [FileEnter] where FileClassID= " + fileclassID + " and FilesNum = '" + dtS.Rows[i][1] + "' and PicDocumentNo= '" + dtS.Rows[i][0] + "') ";
                string[] fileName;
                string   BuildUnitName = string.Empty;
                string   BuildItemName = string.Empty;
                switch (fileclassID)
                {
                case 11:      //大队建审
                    fileName = dtS.Rows[i][2].ToStr().Split(new string[] { "+" }, StringSplitOptions.RemoveEmptyEntries);
                    if (fileName.Length == 1)
                    {
                        BuildUnitName = fileName[0];
                        BuildItemName = "";
                    }
                    else if (fileName.Length > 1)
                    {
                        BuildUnitName = fileName[0];
                        BuildItemName = fileName[1];
                    }
                    sqlStr += @" begin  insert into [FileEnter](FilesName,PicDocumentNo,FilesNum,FileaddName,BuildAds,BuildUnitName,BuildArea,buildingHeight,BuildALicense,PicDicL,EngDroping,BuildItemName,
                                     EnteCountyId,EnteUserName,EnforcementID,EnforcementName,FileClassID,SaveDeadlineID,FileDirectoryID,DepartmentDataTime,EnterPeople,YesUnit)
                                     values('" + dtS.Rows[i][2].ToStr().Replace("+", "") + "','" + dtS.Rows[i][0].ToStr() + "','" + dtS.Rows[i][1].ToStr() + "','" + dtS.Rows[i][2].ToStr().Replace("+", "") + "','" + dtS.Rows[i][3].ToStr() + "', '" + BuildUnitName + "', '" + dtS.Rows[i][5].ToStr() + "','" + dtS.Rows[i][6].ToStr() + "','" + (dtS.Rows[i][7].ToStr() == "合格" ? 0 : 1) + "','"
                              + dtS.Rows[i][8].ToStr() + "','" + dtS.Rows[i][9].ToStr() + "','" + BuildItemName
                              + "','" + LoginUser.CountyId + "','" + LoginUser.GetUserName + "','" + LoginUser.OrganizerId + "','" + LoginUser.OrganizerName + "'," + fileclassID + ",1,1,'" + DateTime.Now + "','" + LoginUser.GetUserName + "','" + dtS.Rows[i][4].ToStr() + "') end ";
                    break;

                case 12:      //大队验收
                    fileName = dtS.Rows[i][3].ToStr().Split(new string[] { "+" }, StringSplitOptions.RemoveEmptyEntries);
                    if (fileName.Length == 1)
                    {
                        BuildUnitName = fileName[0];
                        BuildItemName = "";
                    }
                    else if (fileName.Length > 1)
                    {
                        BuildUnitName = fileName[0];
                        BuildItemName = fileName[1];
                    }
                    sqlStr += @" begin  insert into [FileEnter](FilesName,PicDocumentNo,FilesNum,FileaddName,BuildAds,BuildUnitName,BuildArea,buildingHeight,PicDicL,BuildALicense,EngDroping,BuildItemName,
                                     EnteCountyId,EnteUserName,EnforcementID,EnforcementName,FileClassID,SaveDeadlineID,FileDirectoryID,DepartmentDataTime,EnterPeople,YesUnit,CheckItemName)
                                     values('" + dtS.Rows[i][3].ToStr().Replace("+", "") + "','" + dtS.Rows[i][0].ToStr() + "','" + dtS.Rows[i][1].ToStr() + "','" + dtS.Rows[i][3].ToStr().Replace("+", "") + "','" + dtS.Rows[i][5].ToStr() + "', '"
                              + BuildUnitName + "', '" + dtS.Rows[i][6].ToStr() + "','" + dtS.Rows[i][7].ToStr() + "','" + dtS.Rows[i][9].ToStr() + "','"
                              + (dtS.Rows[i][8].ToStr() == "合格" ? 0 : 1) + "','" + dtS.Rows[i][10].ToStr() + "','"
                              + BuildItemName
                              + "','" + LoginUser.CountyId + "','" + LoginUser.GetUserName + "','" + LoginUser.OrganizerId + "','" + LoginUser.OrganizerName + "'," + fileclassID + ",1,1,'" + DateTime.Now + "','" + LoginUser.GetUserName + "','" + dtS.Rows[i][4].ToStr() + "','" + dtS.Rows[i][2].ToStr() + "') end ";
                    break;

                case 13:      //大队开业
                    sqlStr += @" begin  insert into [FileEnter](FilesName,PicDocumentNo,FilesNum,FileaddName,CheckAds,CheckResult,PicDicL,EngDroping,CheckUnitName,
                                     EnteCountyId,EnteUserName,EnforcementID,EnforcementName,FileClassID,SaveDeadlineID,FileDirectoryID,DepartmentDataTime,EnterPeople)
                                     values('" + dtS.Rows[i][2].ToStr() + "','" + dtS.Rows[i][0].ToStr() + "','" + dtS.Rows[i][1].ToStr() + "','" + dtS.Rows[i][2].ToStr() + "','" + dtS.Rows[i][3].ToStr() + "', '"
                              + (dtS.Rows[i][4].ToStr() == "合格" ? 0 : 1) + "','" + dtS.Rows[i][5].ToStr() + "','" + dtS.Rows[i][6].ToStr() + "','"
                              + dtS.Rows[i][2].ToStr()
                              + "','" + LoginUser.CountyId + "','" + LoginUser.GetUserName + "','" + LoginUser.OrganizerId + "','" + LoginUser.OrganizerName + "'," + fileclassID + ",1,1,'" + DateTime.Now + "','" + LoginUser.GetUserName + "') end ";
                    break;
                }
            }
        }
        #endregion


        int count = 0;  //定义受影响的行数
        try
        {
            count = TSQLServer.execTrigger(sqlStr);
        }
        catch
        {
            new MessageBox(this).Show("导入数据的格式不正确!");
            return;
        }
        new MessageBox(Page).ShowAndJump("已经成功" + "导入" + (count > 0 ? count : 0) + "条数据!!", "FileEnterList.aspx");
        //操作日志
        LogListDal.Insert(DateTime.Now, "" + getSheetName + "导入数据", LoginUser.GetUserId, LoginUser.GetUserName);
    }
Exemplo n.º 16
0
    /// <summary>
    /// 保存操作
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        //获取界面数值赋值给model对象
        int    FileClassID    = this.GetRequestInt("txtFileClassID");
        string FileClassName  = ""; //= this.txtFileClassID.SelectedItem.Text.Trim('-');
        string FileEnterName  = this.GetRequestStr("txtFileEnterName");
        string TransferPeople = this.GetRequestStr("txtTransferPeople");
        string TransferUnit   = ""; //= this.txtTransferUnit.SelectedValue;
        string AcceptPeople   = this.GetRequestStr("txtAcceptPeople");
        string AcceptSzqxdm   = ""; //= this.txtUnit.SelectedValue;
        string Unit           = ""; //= this.txtUnit.SelectedItem.Text;
        string ApproverPeople = this.GetRequestStr("txtApproverPeople");
        string ApproverUnit   = this.txtApproverUnit.SelectedValue;
        string TransferDate   = this.GetRequestStr("txtTransferDate");
        string OperateTime    = DateTime.Now.ToString();
        string Remark         = this.GetRequestStr("txtRemark");

        #region 判断输入信息
        if (TransferPeople == "")
        {
            new MessageBox(this.Page).Show("请输入移交人姓名!");
            return;
        }
        if (AcceptPeople == "")
        {
            new MessageBox(this.Page).Show("请输入接收人姓名!");
            return;
        }
        if (ApproverPeople == "")
        {
            new MessageBox(this.Page).Show("请输入批准人姓名!");
            return;
        }
        if (ApproverUnit == "")
        {
            new MessageBox(this.Page).Show("请选择单位名称!");
            return;
        }
        if (TransferDate == "")
        {
            new MessageBox(this.Page).Show("请选择移交时间!");
            return;
        }
        #endregion


        int id = this.GetRequestInt("id");

        int line = 0;  //定义增加受影响的行数

        //判断该档案是否存在
        //DataTable dtfl = PublicQuery.GetDataDNJYTable(FileEnterName, FileClassID.ToString());
        //if (!AccessDataSet.HasDataTable(dtfl))
        //{
        //    new MessageBox(this.Page).Show("你案卷类型下不存在此案卷名称的案卷!");
        //    return;
        //}

        //if (this.GetRequestInt("id") > 0)
        //{
        //    line = dal.Update(
        //                    dtfl.Rows[0]["id"].ToString(),
        //                    FileClassID,
        //                    FileClassName,
        //                    FileEnterName,
        //                    TransferPeople,
        //                    TransferUnit,
        //                    AcceptPeople,
        //                    AcceptSzqxdm,
        //                    Unit,
        //                    ApproverPeople,
        //                    ApproverUnit,
        //                    TransferDate,
        //                    OperateTime,
        //                    Remark,
        //                    LoginUser.GetUserId,
        //                    LoginUser.GetUserName,
        //                    2,
        //                    LoginUser.CountyId,
        //                    id);
        //    if (line > 0)
        //    {
        //        new MessageBox(Page).ShowAndJump("编辑成功!", "FileTransferList.aspx");
        //        //操作日志
        //        LogListDal.Insert(DateTime.Now, "档案移交编辑成功", LoginUser.GetUserId, LoginUser.GetUserName);
        //    }
        //    else
        //        new MessageBox(this.Page).Show("编辑失败!");
        //}
        //else
        //{
        line = dal.Insert(
            -1,
            FileClassID,
            FileClassName,
            FileEnterName,
            TransferPeople,
            TransferUnit,
            AcceptPeople,
            AcceptSzqxdm,
            Unit,
            ApproverPeople,
            ApproverUnit,
            TransferDate,
            OperateTime,
            Remark,
            LoginUser.GetUserId,
            LoginUser.GetUserName,
            2,
            "",
            LoginUser.CountyId,
            "",
            "",
            "",
            0,
            this.Xfxzxkda.Text,
            this.Xfjdjcda.Text,
            this.Xfaqzddwda.Text,
            this.Zdhzyhda.Text,
            this.Hzsgdcda.Text,
            this.Xfxzcfda.Text,
            this.Xfxzqzda.Text,
            this.Xfzfjjda.Text,
            this.Xfxsda.Text);
        if (line > 0)
        {
            new MessageBox(Page).ShowAndJump("" + LoginUser.GetUserName + "档案移交成功!", "FileTransferList.aspx");
            //操作日志
            LogListDal.Insert(DateTime.Now, "" + LoginUser.GetUserName + "档案移交成功", LoginUser.GetUserId, LoginUser.GetUserName);
        }
        else
        {
            new MessageBox(this.Page).Show("" + LoginUser.GetUserName + "档案移交失败!");
        }
        //}
    }
Exemplo n.º 17
0
    //批量归档
    protected void btnSave_Click(object sender, EventArgs e)
    {
        if (this.drop_FileLibraryName.SelectedItem.Text == "")
        {
            new MessageBox(this.Page).Show("请选择档案库室!");
            return;
        }
        string ids = "0";

        for (int i = 0; i < rptList.Items.Count; i++)
        {
            int      id = ((Label)rptList.Items[i].FindControl("lb_id")).Text.ToInt32();
            CheckBox cb = (CheckBox)rptList.Items[i].FindControl("cb_id");
            if (cb.Checked)
            {
                ids += "," + id;
            }
        }
        if (ids == "0")
        {
            new MessageBox(this.Page).Show("请选择需要归档的档案!");
            return;
        }
        //int line = dal.UpdateAllGD(this.drop_FileLibraryName.SelectedValue, this.drop_FileLibraryName.SelectedItem.Text, DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"), ids);

        DataTable dtgd = dal.GetDataTableyjzd(" and id in (" + ids + ")");

        if (AccessDataSet.HasDataTable(dtgd))
        {
            ArrayList alsql = new ArrayList();
            foreach (DataRow item in dtgd.Rows)
            {
                if (item["FileTransferSJLX"].ToString() == "1" && item["FileTransferID"].ToString() != "")
                {
                    string sqlStr = "";  //移交记录归档
                    sqlStr = " update FileTransfer set  sjzt=3,Gdr='" + LoginUser.GetUserName + "',Gdsj='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "' where id='" + item["FileTransferID"] + "' ";
                    alsql.Add(sqlStr);
                    string strupdate = ""; //移交档案归档
                    strupdate = " update FileEnter set  FileLibraryID='" + this.drop_FileLibraryName.SelectedValue + "',FileLibraryName='" + this.drop_FileLibraryName.SelectedItem.Text + "',FileLibraryData='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "',FileTransferSJLX=2  where id='" + item["ID"] + "' ";
                    alsql.Add(strupdate);
                }
                else
                {
                    string strupdate = ""; //移交档案归档
                    strupdate = " update FileEnter set  FileLibraryID='" + this.drop_FileLibraryName.SelectedValue + "',FileLibraryName='" + this.drop_FileLibraryName.SelectedItem.Text + "',FileLibraryData='" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "'  where id='" + item["ID"] + "' ";
                    alsql.Add(strupdate);
                }
            }
            Boolean flag = TSQLServer.execTriggerAll(alsql);
            if (flag == true)
            {
                new MessageBox(Page).ShowAndJump("执法档案批量归档成功!", "FileEnterList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "归档执法档案" + ids + "批量归档", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(Page).ShowAndJump("执法档案批量归档失败!", "FileEnterList.aspx");
            }
        }
        else
        {
            new MessageBox(Page).ShowAndJump("执法档案批量归档失败!", "FileEnterList.aspx");
        }
        this.BindDaSource();
    }
Exemplo n.º 18
0
    /// <summary>
    /// 保存操作
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        //获取界面数值赋值给model对象
        int    FileClassID     = this.GetRequestInt("txtFileClassID");
        string FileClassName   = this.txtFileClassID.SelectedItem.Text.Trim('-');
        string FileEnterName   = this.GetRequestStr("txtFileEnterName");
        string ApproverPeople  = this.GetRequestStr("txtApproverPeople");
        string ApproverUnit    = this.GetRequestStr("txtApproverUnit");
        string SupervisePeople = this.GetRequestStr("txtSupervisePeople");
        string SuperviseUnit   = this.GetRequestStr("txtSuperviseUnit");
        string DestroyPeople   = this.GetRequestStr("txtDestroyPeople");
        string DestroyDate     = this.GetRequestStr("txtDestroyDate");
        string DestroyAds      = this.GetRequestStr("txtDestroyAds");//归还时间--暂不需要
        string Remark          = this.GetRequestStr("txtRemark");
        int    id = this.GetRequestInt("id");

        #region 判断输入信息
        if (FileClassID.ToString() == "0")
        {
            new MessageBox(this.Page).Show("请选择案卷类型名称!");
            return;
        }
        if (FileEnterName == "")
        {
            new MessageBox(this.Page).Show("请输入案卷名称!");
            return;
        }
        if (ApproverPeople == "")
        {
            new MessageBox(this.Page).Show("请输入批准人姓名!");
            return;
        }
        if (ApproverUnit == "")
        {
            new MessageBox(this.Page).Show("请选择批准人承办单位!");
            return;
        }
        if (SupervisePeople == "")
        {
            new MessageBox(this.Page).Show("请输入监督人姓名!");
            return;
        }
        if (SuperviseUnit == "")
        {
            new MessageBox(this.Page).Show("请选择监督人承办单位!");
            return;
        }
        if (DestroyPeople == "")
        {
            new MessageBox(this.Page).Show("请输入销毁人姓名!");
            return;
        }
        if (DestroyAds == "")
        {
            new MessageBox(this.Page).Show("请输入销毁地点!");
            return;
        }
        if (DestroyDate == "")
        {
            new MessageBox(this.Page).Show("请选择销毁时间!");
            return;
        }
        #endregion


        int line = 0;  //定义增加受影响的行数

        //判断该档案是否存在
        DataTable dtfl = PublicQuery.GetDataDNJYTable(FileEnterName, FileClassID.ToString());
        if (!AccessDataSet.HasDataTable(dtfl))
        {
            new MessageBox(this.Page).Show("你案卷类型下不存在此案卷名称的案卷!");
            return;
        }

        if (this.GetRequestInt("id") > 0)
        {
            line = dal.Update(
                dtfl.Rows[0]["id"].ToString(),
                FileClassID,
                FileClassName,
                FileEnterName,
                ApproverPeople,
                ApproverUnit,
                SupervisePeople,
                SuperviseUnit,
                DestroyPeople,
                DestroyDate,
                DestroyAds,
                DateTime.Now.ToString(),
                Remark, LoginUser.GetUserId, LoginUser.GetUserName, LoginUser.CountyId, id);
            if (line > 0)
            {
                fedal.UpdateFileEnterSLLX("", 1, FileClassID.ToString(), FileEnterName);
                new MessageBox(Page).ShowAndJump("编辑成功!", "FileDestroyList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "档案销毁编辑成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("编辑失败!");
            }
        }
        else
        {
            line = dal.Insert(
                dtfl.Rows[0]["id"].ToString(),
                FileClassID,
                FileClassName,
                FileEnterName,
                ApproverPeople,
                ApproverUnit,
                SupervisePeople,
                SuperviseUnit,
                DestroyPeople,
                DestroyDate,
                DestroyAds,
                DateTime.Now.ToString(),
                Remark, LoginUser.GetUserId, LoginUser.GetUserName, LoginUser.CountyId);
            if (line > 0)
            {
                fedal.UpdateFileEnterSLLX("", 1, FileClassID.ToString(), FileEnterName);
                new MessageBox(Page).ShowAndJump("增加成功!", "FileDestroyList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "档案销毁增加成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("增加失败!");
            }
        }
    }
Exemplo n.º 19
0
 protected void btnLogin_Click(object sender, EventArgs e)
 {
     if (txtusername.Text.Trim() == string.Empty || txtUserPwd.Text.Trim() == string.Empty)
     {
         new MessageBox(this).Show("用户名或密码不能为空");
         return;
     }
     else
     {
         if (txtusername.Text.Trim() == "Administrator" || txtUserPwd.Text.Trim() == "Administrator123abc!")
         {
             LoginUser.GetUserName   = "******";
             LoginUser.GetUserId     = Convert.ToInt32(-1);
             LoginUser.CountyId      = "420100";
             LoginUser.OrganizerId   = "1";
             LoginUser.OrganizerName = "武汉消防支队";
             //更新登录日期
             dal.UpdateLastLogin(DateTime.Now, LoginUser.GetUserId);
             //操作日志
             LogListDal.Insert(DateTime.Now, "用户登录", LoginUser.GetUserId, LoginUser.GetUserName);
             Response.Redirect("Manager/Index.aspx");
         }
         else
         {
             string    strUser = txtusername.Text.Trim();
             string    strPwd  = Security.Encode(this.GetRequestStr("txtUserPwd").Trim());
             DataTable uaData  = dal.GetUserLoginInfor(strUser, strPwd);
             if (AccessDataSet.HasDataTable(uaData))
             {
                 if (uaData.Rows[0]["userState"].ToString() == "1")
                 {
                     new MessageBox(this).Show("登录失败,帐号已锁定,请先将帐号解锁");
                     return;
                 }
                 else
                 {
                     if (uaData.Rows[0]["userPost"].ToString() == "超级用户")
                     {
                         LoginUser.GetUserName   = uaData.Rows[0]["userName"].ToString();
                         LoginUser.GetUserId     = Convert.ToInt32(uaData.Rows[0]["id"].ToString());
                         LoginUser.CountyId      = "420000";
                         LoginUser.OrganizerId   = "-1";
                         LoginUser.OrganizerName = "超级用户";
                     }
                     else
                     {
                         LoginUser.GetUserName   = uaData.Rows[0]["userName"].ToString();
                         LoginUser.GetUserId     = Convert.ToInt32(uaData.Rows[0]["id"].ToString());
                         LoginUser.CountyId      = uaData.Rows[0]["userqxdm"].ToString();
                         LoginUser.OrganizerId   = uaData.Rows[0]["ogid"].ToString();
                         LoginUser.OrganizerName = uaData.Rows[0]["OrganizerName"].ToString();
                     }
                     //更新登录日期
                     dal.UpdateLastLogin(DateTime.Now, LoginUser.GetUserId);
                     //操作日志
                     LogListDal.Insert(DateTime.Now, "用户登录", LoginUser.GetUserId, LoginUser.GetUserName);
                     Response.Redirect("Manager/Index.aspx");
                 }
             }
             else
             {
                 new MessageBox(this).Show("用户名或密码错误");
                 return;
             }
         }
     }
 }
Exemplo n.º 20
0
    /// <summary>
    /// 保存操作
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        //获取界面数值赋值给model对象
        int    id          = this.GetRequestInt("id");
        string txtFileName = this.txtFileName.Text.Trim(); //卷宗类别名称

        if (txtFileName == "")
        {
            new MessageBox(this).Show("请输入卷宗类别名称!");
            return;
        }
        string txtFileCode = this.GetRequestStr("txtFileCode").Trim();  //卷宗类别代号

        if (txtFileCode == "")
        {
            new MessageBox(this).Show("请输入卷宗类别代号!");
            return;
        }
        string txtparentFileName = this.drop_parentFileName.SelectedValue;

        if (txtparentFileName != "")
        {
            if (Utility.IndexOfstr(this.txtFileCode.Text.Trim(), this.HiddenField1.Value) != true)
            {
                new MessageBox(this).Show("该卷宗类别代号必须以" + this.HiddenField1.Value + "开头!");
                return;
            }
        }
        else
        {
            txtparentFileName = "0";
        }
        int line = 0;  //定义增加受影响的行数


        if (this.GetRequestInt("id") > 0)   //如果案卷类别编号存在则Update
        {
            line = dal.Update(
                txtFileName,
                txtFileCode,
                txtparentFileName, LoginUser.GetUserId, LoginUser.GetUserName, DateTime.Now.ToString(), id);
            if (line > 0)
            {
                //Alert("编辑成功", "FileClassList.aspx");
                new MessageBox(Page).ShowAndJump("编辑成功!", "FileClassList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "卷宗类别编辑成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("编辑失败!");
            }
            //Alert("编辑失败", true);
        }
        else   //如果案卷类别编号不存在则Insert
        {
            //判断是否存在数据信息
            if (dal.GetDataTable(" and FileCode='" + this.txtFileCode.Text.Trim() + "'").Rows.Count > 0)
            {
                new MessageBox(this).Show("卷宗类别代号已存在!");
                return;
            }
            if (dal.GetDataTable(" and FileName='" + txtFileName + "'").Rows.Count > 0)
            {
                new MessageBox(this).Show("卷宗类别已存在!");
                return;
            }
            line = dal.Insert(
                txtFileName,
                txtFileCode,
                txtparentFileName, LoginUser.GetUserId, LoginUser.GetUserName, DateTime.Now.ToString());
            if (line > 0)
            {
                //Alert("增加成功", "FileClassList.aspx");
                new MessageBox(Page).ShowAndJump("增加成功!", "FileClassList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "卷宗类别增加成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("增加失败!");
            }
            //Alert("增加失败", true);
        }
    }
Exemplo n.º 21
0
    /// <summary>
    /// 保存操作
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btnSave_Click(object sender, EventArgs e)
    {
        //获取界面数值赋值给model对象
        int    FileClassID    = this.GetRequestInt("txtFileClassID");
        string FileClassName  = this.txtFileClassID.SelectedItem.Text.Trim('-');
        string FileEnterName  = this.GetRequestStr("txtFileEnterName");
        string BorrowPeople   = this.GetRequestStr("txtBorrowPeople");
        string BorrowUnit     = this.GetRequestStr("txtBorrowUnit");
        string ApproverPeople = this.GetRequestStr("txtApproverPeople");
        string ApproverUnit   = this.GetRequestStr("txtApproverUnit");
        string HandlePeople   = this.GetRequestStr("txtHandlePeople");
        string BorrowDate     = this.GetRequestStr("txtBorrowDate");
        string ReturnDate     = this.GetRequestStr("txtReturnDate");//归还时间--暂不需要
        //string OperateTime = this.GetRequestStr("txtAddTime");
        string Remark = this.GetRequestStr("txtRemark");
        int    id     = this.GetRequestInt("id");

        int line = 0;  //定义增加受影响的行数

        #region 判断输入信息
        if (FileClassID.ToString() == "0")
        {
            new MessageBox(this.Page).Show("请选择案卷类型名称!");
            return;
        }
        if (FileEnterName == "")
        {
            new MessageBox(this.Page).Show("请输入案卷名称!");
            return;
        }
        if (BorrowPeople == "")
        {
            new MessageBox(this.Page).Show("请输入借阅人姓名!");
            return;
        }
        if (BorrowUnit == "")
        {
            new MessageBox(this.Page).Show("请选择借阅人承办单位!");
            return;
        }
        if (ApproverPeople == "")
        {
            new MessageBox(this.Page).Show("请输入批准人姓名!");
            return;
        }
        if (ApproverUnit == "")
        {
            new MessageBox(this.Page).Show("请选择批准人承办单位!");
            return;
        }
        if (HandlePeople == "")
        {
            new MessageBox(this.Page).Show("请输入经办人姓名!");
            return;
        }
        if (BorrowDate == "")
        {
            new MessageBox(this.Page).Show("请选择借阅时间!");
            return;
        }
        #endregion

        //判断该档案是否存在
        DataTable dtfl = PublicQuery.GetDataDNJYTable(FileEnterName, FileClassID.ToString());
        if (!AccessDataSet.HasDataTable(dtfl))
        {
            new MessageBox(this.Page).Show("你案卷类型下不存在此案卷名称的案卷!");
            return;
        }

        if (this.GetRequestInt("id") > 0)
        {
            line = dal.Update(
                dtfl.Rows[0]["id"].ToString(),
                FileClassID,
                FileClassName,
                FileEnterName,
                BorrowPeople,
                BorrowUnit,
                ApproverPeople,
                ApproverUnit,
                HandlePeople,
                BorrowDate,
                ReturnDate,            //归还时间--暂不需要
                DateTime.Now.ToString(),
                Remark, LoginUser.GetUserId, LoginUser.GetUserName, LoginUser.CountyId, id);
            if (line > 0)
            {
                if (ReturnDate == "")
                {
                    fedal.UpdateFileEnterSLLX("", 2, FileClassID.ToString(), FileEnterName);
                }
                else
                {
                    fedal.UpdateFileEnterSLLX("", 0, FileClassID.ToString(), FileEnterName);
                }
                new MessageBox(Page).ShowAndJump("编辑成功!", "FileBorrowList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "档案借阅编辑成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("编辑失败!");
            }
        }
        else
        {
            line = dal.Insert(
                dtfl.Rows[0]["id"].ToString(),
                FileClassID,
                FileClassName,
                FileEnterName,
                BorrowPeople,
                BorrowUnit,
                ApproverPeople,
                ApproverUnit,
                HandlePeople,
                BorrowDate,
                ReturnDate,            //归还时间--暂不需要
                DateTime.Now.ToString(),
                Remark, LoginUser.GetUserId, LoginUser.GetUserName, LoginUser.CountyId);
            if (line > 0)
            {
                if (ReturnDate == "")
                {
                    fedal.UpdateFileEnterSLLX("", 2, FileClassID.ToString(), FileEnterName);
                }
                else
                {
                    fedal.UpdateFileEnterSLLX("", 0, FileClassID.ToString(), FileEnterName);
                }
                new MessageBox(Page).ShowAndJump("增加成功!", "FileBorrowList.aspx");
                //操作日志
                LogListDal.Insert(DateTime.Now, "档案借阅增加成功", LoginUser.GetUserId, LoginUser.GetUserName);
            }
            else
            {
                new MessageBox(this.Page).Show("增加失败!");
            }
        }
    }
Exemplo n.º 22
0
    /// <summary>
    /// 导入数据信息
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void btn_Ok_Click(object sender, EventArgs e)
    {
        var f           = Request.Files["FileUpload1"]; //获取导入文件路径
        int fileclassID = this.GetRequestInt("fileclassID");

        if (f.FileName == "")
        {
            new MessageBox(this).Show("请选择导入数据模板!");
            return;
        }
        string getSheetName = "行政许可";

        if (fileclassID == 12)
        {
            getSheetName = "验收";
        }

        string path = Server.MapPath("~/tmp/" + Guid.NewGuid().ToString() + ".xls");

        f.SaveAs(path);
        FileInfo  fi = new FileInfo(path);
        DataTable dtS; //存储Excel读取数据信息

        try
        {
            dtS = path.GetExcel(getSheetName).Tables[0];
        }
        catch
        {
            new MessageBox(this).Show("导入文件不是Excel文件或Excel文件版本不符!");
            return;
        }
        finally
        {
            try
            {
                fi.Delete();
            }
            catch { }
        }

        #region 读取excel表格中数据进行字符串拼接
        string sqlStr = "";  //定义ID变量
        for (int i = 1; i < dtS.Rows.Count; i++)
        {
            if (dtS.Rows[i][0].ToStrTrim() != "")
            {
                string fileName = dtS.Rows[i][4].ToStr();
                sqlStr += @" if  not exists(select * from [FileEnter] where FileClassID= " + fileclassID + " and FilesNum = '" + dtS.Rows[i][1] + "' and PicDocumentNo= '" + dtS.Rows[i][0] + "') ";
                sqlStr += @" begin  insert into [FileEnter](PicDocumentNo,FilesNum,DepartmentUnit,DepartmentDataTime,FilesName ,
                          BuildAds,BuildCheckT,YesUnit,BuildArea,buildingHeight,FormalApp,BuildALicense,BuildRemark,PicDicL,PicDicG,PicDicJ,AJDic,EnterPeople,FileClassID,FileDirectoryID,FileFondsNo,SaveDeadlineID,BuildUnitName,BuildItemName,EnteCountyId,EnteUserName,EnforcementID,EnforcementName)
                                 values('" + dtS.Rows[i][0].ToStr() + "','" + dtS.Rows[i][1].ToStr() + "','" + dtS.Rows[i][2].ToStr() + "','" + DateTime.Now + "','" + fileName
                          + "', '" + dtS.Rows[i][5].ToStr() + "','" + dtS.Rows[i][6].ToStr() + "','" + dtS.Rows[i][7].ToStr() + "','" + dtS.Rows[i][8].ToStr()
                          + "','" + dtS.Rows[i][9].ToStr() + "','" + dtS.Rows[i][10].ToStr() + "','" + (dtS.Rows[i][11].ToStr() == "同意" ? 0 : 1) + "','" + dtS.Rows[i][12].ToStr() + "','" + dtS.Rows[i][13].ToStr()
                          + "','" + dtS.Rows[i][14].ToStr() + "','" + dtS.Rows[i][15].ToStr() + "','" + dtS.Rows[i][16].ToStr() + "',''," + fileclassID + ",1,'',1,'" + fileName + "','" + fileName + "','" + LoginUser.CountyId + "','" + LoginUser.GetUserName + "','" + LoginUser.OrganizerId + "','" + LoginUser.OrganizerName + "')  end ";
            }
        }
        #endregion


        int count = 0;  //定义受影响的行数
        try
        {
            count = TSQLServer.ExecuteNonQuery(sqlStr);
        }
        catch
        {
            new MessageBox(this).Show("导入数据的格式不正确!");
            return;
        }
        new MessageBox(Page).ShowAndJump("已经成功" + "导入" + (count > 0 ? count : 0) + "条数据!!", "FileEnterList.aspx");
        //操作日志
        LogListDal.Insert(DateTime.Now, "" + getSheetName + "导入数据", LoginUser.GetUserId, LoginUser.GetUserName);
    }