protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { SafeSC.Submit_Begin(this.ViewState); if (string.IsNullOrEmpty(Request.QueryString["AppID"])) { function.WriteErrMsg("未指定公文ID"); } else { //只有上一级经办人有权限继续指定流程 //M_MisProLevel fMod = freeBll.GetLastStep(AppID); //if (!fMod.ReferUser.Contains("," + buser.GetLogin().UserID + ",")) function.WriteErrMsg("只有上一级经办人才有权限修改该流程"); if (StepID > 0)//修改步骤 { return_Btn.Visible = true; freeMod = freeBll.SelReturnModel(StepID); moa = boa.SelReturnModel(AppID); //-----Auth if (!moa.IsFreePro) { function.WriteErrMsg("非自由流程,不允许自指定步骤"); } if (freeMod.BackOption != AppID) { function.WriteErrMsg("公文与步骤数据不匹配,取消访问!!!"); } if (moa.CurStepNum >= freeMod.stepNum) { function.WriteErrMsg("该步骤已执行,不允许修改!!!"); } //----- ReferUser_T.Text = buser.GetUserNameByIDS(freeMod.ReferUser); ReferUser_Hid.Value = freeMod.ReferUser; CCUser_T.Text = buser.GetUserNameByIDS(freeMod.CCUser); CCUser_Hid.Value = freeMod.CCUser; } else { //-----Auth2(只允许创建下一步) if (freeBll.GetStep(AppID) - CurStepNum > 1) { Free_Div.Visible = false; remind2.Visible = true; } } Page.ClientScript.RegisterStartupScript(this.GetType(), "disFoo", "ShowFoo();", true); DataBind();//绑定已有步骤 } } }