Example #1
0
        protected void btnEdit_Click(object sender, System.EventArgs e)
        {
            string RowGuid = Request["RowGuid"];
            string DWGuid  = Request["DWGuid"];

            UpdateUserName_2017.Text = this.DisplayName;
            UpdateUserGuid_2017.Text = this.UserGuid;
            IsHistory_2017.Text      = "0";
            UpdateTime_2017.Text     = DateTime.Now.ToString();
            Status_2017.Text         = OUStatus.通过; //"2";//0:编辑   1:待审核   2:通过
            DelFlag_2017.Text        = "0";
            //DWGuid_2017.Text = DWGuid;
            #region 地区的保存
            ZhuCeDi_2017.Text        = tvZCD.Text;
            ZhuCeDiCode_2017.Text    = tvZCD.Value;
            YunYingDi1_2017.Text     = tvYYD1.Text;
            YunYingDi1Code_2017.Text = tvYYD1.Value;
            YunYingDi2_2017.Text     = tvYYD2.Text;
            YunYingDi2Code_2017.Text = tvYYD2.Value;
            YunYingDi3_2017.Text     = tvYYD3.Text;
            YunYingDi3Code_2017.Text = tvYYD3.Value;
            #endregion

            oEditPage.SaveTableValues(RowGuid, tdContainer);

            #region 保存附件
            CL_SB.MisRowGuid  = DWGuid;
            CL_SB.MisTableID  = TableID;
            CL_SB.ProjectGuid = "";
            CL_SB.Comment     = DWGuid;
            CL_SB.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_SB.Save();

            CL_Logo.MisRowGuid  = DWGuid;
            CL_Logo.MisTableID  = TableID;
            CL_Logo.ProjectGuid = "";
            CL_Logo.Comment     = DWGuid;
            CL_Logo.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_Logo.Save();

            CL_GSJS.MisRowGuid  = DWGuid;
            CL_GSJS.MisTableID  = TableID;
            CL_GSJS.ProjectGuid = "";
            CL_GSJS.Comment     = DWGuid;
            CL_GSJS.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_GSJS.Save();

            CL_ZS.MisRowGuid  = DWGuid;
            CL_ZS.MisTableID  = TableID;
            CL_ZS.ProjectGuid = "";
            CL_ZS.Comment     = DWGuid;
            CL_ZS.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_ZS.Save();
            #endregion

            this.WriteAjaxMessage("refreshParent();alert('保存成功');");
        }
Example #2
0
        protected void btnAdd_Click(object sender, System.EventArgs e)
        {
            string RowGuid = Request["RowGuid"];
            string DWGuid  = Request["DWGuid"];

            UpdateUserName_2017.Text = this.DisplayName;
            UpdateUserGuid_2017.Text = this.UserGuid;
            IsHistory_2017.Text      = "0";
            UpdateTime_2017.Text     = DateTime.Now.ToString();
            Status_2017.Text         = OUStatus.编辑中;// "0";//1:编辑   2:待审核   3:通过
            DelFlag_2017.Text        = "0";
            DWGuid_2017.Text         = DWGuid;
            #region 地区的保存
            ZhuCeDi_2017.Text        = tvZCD.Text;
            ZhuCeDiCode_2017.Text    = tvZCD.Value;
            YunYingDi1_2017.Text     = tvYYD1.Text;
            YunYingDi1Code_2017.Text = tvYYD1.Value;
            YunYingDi2_2017.Text     = tvYYD2.Text;
            YunYingDi2Code_2017.Text = tvYYD2.Value;
            YunYingDi3_2017.Text     = tvYYD3.Text;
            YunYingDi3Code_2017.Text = tvYYD3.Value;
            #endregion
            oAddPage.SaveTableValues(RowGuid, tdContainer, Request.QueryString["ParentRowGuid"]);

            #region 保存附件
            CL_SB.MisRowGuid  = DWGuid;
            CL_SB.MisTableID  = TableID;
            CL_SB.ProjectGuid = "";
            CL_SB.Comment     = DWGuid;
            CL_SB.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_SB.Save();

            CL_Logo.MisRowGuid  = DWGuid;
            CL_Logo.MisTableID  = TableID;
            CL_Logo.ProjectGuid = "";
            CL_Logo.Comment     = DWGuid;
            CL_Logo.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_Logo.Save();

            CL_GSJS.MisRowGuid  = DWGuid;
            CL_GSJS.MisTableID  = TableID;
            CL_GSJS.ProjectGuid = "";
            CL_GSJS.Comment     = DWGuid;
            CL_GSJS.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_GSJS.Save();

            CL_ZS.MisRowGuid  = DWGuid;
            CL_ZS.MisTableID  = TableID;
            CL_ZS.ProjectGuid = "";
            CL_ZS.Comment     = DWGuid;
            CL_ZS.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_ZS.Save();
            #endregion
            //如果是父表,要转入多表编辑页面
            //if (oAddPage.TableDetail.TableType == 1)
            //{
            //    Response.Redirect("MultiPageTab.aspx?mode=Mode&TableID=" + oAddPage.TableDetail.TableID + "&RowGuid=" + RowGuid);
            //}
            //else
            //{
            //    this.WriteAjaxMessage ("refreshParent();");
            //}
            //Epoint.MisBizLogic2.Web.CodeGenerator.InitiateControl_AddPage(oAddPage, tdContainer);
            //this.WriteAjaxMessage("EP_ShowMessageDiv(" + tdContainer.ClientID + ",'数据保存成功')");
            string url = "RG_OU_Edit.aspx?RowGuid=" + RowGuid + "&DWGuid=" + DWGuid;
            this.WriteAjaxMessage("refreshParent();alert('添加成功');window.location.href='" + url + "';");
        }
Example #3
0
        protected void btnEdit_Click(object sender, System.EventArgs e)
        {
            string RowGuid = Request["RowGuid"];
            string DWGuid  = Request["DWGuid"];

            string   strSql = "SELECT distinct s_xiangmujl_guid,s_xiangmujl FROM VIEW_CurrentVersion WHERE dwGuid='" + DWGuid + "'";
            DataView dvUser = Epoint.MisBizLogic2.DB.ExecuteDataView(strSql);

            if (dvUser.Count == 0)
            {
                WriteAjaxMessage("该企业没有对应的项目,请联系系统管理员。");
                return;
            }
            //先将原来的设置为历史记录
            Epoint.MisBizLogic2.Data.MisGuidRow oRow = new Epoint.MisBizLogic2.Data.MisGuidRow(oEditPage.TableDetail.SQL_TableName, Request["RowGuid"]);
            oRow["IsHistory"] = "1";
            //oRow["UpdateUserName"] = this.DisplayName;
            //oRow["UpdateUserGuid"] = this.UserGuid;
            //oRow["UpdateTime"] = DateTime.Now;
            oRow.Update();
            //再新增一个即可
            UpdateUserName_2017.Text = this.DisplayName;
            UpdateUserGuid_2017.Text = this.UserGuid;
            IsHistory_2017.Text      = "0";
            UpdateTime_2017.Text     = DateTime.Now.ToString();
            Status_2017.Text         = EpointRegisterUser_Bizlogic.OUStatus.待审核;// "1";//0:编辑   1:待审核   2:通过
            DelFlag_2017.Text        = "0";
            //DWGuid_2017.Text = DWGuid;
            #region 地区的保存
            ZhuCeDi_2017.Text        = tvZCD.Text;
            ZhuCeDiCode_2017.Text    = tvZCD.Value;
            YunYingDi1_2017.Text     = tvYYD1.Text;
            YunYingDi1Code_2017.Text = tvYYD1.Value;
            YunYingDi2_2017.Text     = tvYYD2.Text;
            YunYingDi2Code_2017.Text = tvYYD2.Value;
            YunYingDi3_2017.Text     = tvYYD3.Text;
            YunYingDi3Code_2017.Text = tvYYD3.Value;
            #endregion
            //oEditPage.SaveTableValues(RowGuid, tdContainer);
            string newGuid = Guid.NewGuid().ToString();
            oAddPage.SaveTableValues(newGuid, tdContainer, Request.QueryString["ParentRowGuid"]);
            #region 保存附件
            CL_SB.MisRowGuid  = DWGuid;
            CL_SB.MisTableID  = TableID;
            CL_SB.ProjectGuid = "";
            CL_SB.Comment     = DWGuid;
            CL_SB.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_SB.Save();

            CL_Logo.MisRowGuid  = DWGuid;
            CL_Logo.MisTableID  = TableID;
            CL_Logo.ProjectGuid = "";
            CL_Logo.Comment     = DWGuid;
            CL_Logo.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_Logo.Save();

            CL_GSJS.MisRowGuid  = DWGuid;
            CL_GSJS.MisTableID  = TableID;
            CL_GSJS.ProjectGuid = "";
            CL_GSJS.Comment     = DWGuid;
            CL_GSJS.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_GSJS.Save();

            CL_ZS.MisRowGuid  = DWGuid;
            CL_ZS.MisTableID  = TableID;
            CL_ZS.ProjectGuid = "";
            CL_ZS.Comment     = DWGuid;
            CL_ZS.d_TiJiaoSJ  = DateTime.Now.ToString();
            CL_ZS.Save();
            #endregion

            #region 通知投资经理
            //先获取投资经理

            for (int m = 0; m < dvUser.Count; m++)
            {
                msg.WaitHandle_Insert(
                    Guid.NewGuid().ToString(),
                    "【审核】" + EnterpriseName_2017.Text + "企业信息",
                    "",
                    dvUser[m]["s_xiangmujl_guid"].ToString(),
                    dvUser[m]["s_xiangmujl"].ToString(),
                    Session["UserGuid"].ToString(),
                    Session["DisplayName"].ToString(),
                    "",
                    "EpointRegisterUser/Pages_RG/RG_OU/RG_OU_DetailForCheck.aspx?RowGuid=" + newGuid + "&DWGuid=" + DWGuid,
                    "",
                    "",
                    1,
                    "",
                    "",
                    ""
                    );
            }

            #endregion
            this.WriteAjaxMessage("refreshParent();alert('提交成功');window.close();");
        }