当前位置: 首页>>代码示例>>C#>>正文


C# HyoaClass.Hyoa_global.Saveflowhistoryinfo_cl_global方法代码示例

本文整理汇总了C#中HyoaClass.Hyoa_global.Saveflowhistoryinfo_cl_global方法的典型用法代码示例。如果您正苦于以下问题:C# HyoaClass.Hyoa_global.Saveflowhistoryinfo_cl_global方法的具体用法?C# HyoaClass.Hyoa_global.Saveflowhistoryinfo_cl_global怎么用?C# HyoaClass.Hyoa_global.Saveflowhistoryinfo_cl_global使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在HyoaClass.Hyoa_global的用法示例。


在下文中一共展示了HyoaClass.Hyoa_global.Saveflowhistoryinfo_cl_global方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Button_Save_Click

    ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    //保存
    protected void Button_Save_Click(object sender, EventArgs e)
    {
        if (this.Session["hyuid"].ToString() == "")
            this.Response.Redirect("login.aspx");

        string ls_tip = "保存成功!";

        #region 新建时先进行一次保存
        HyoaClass.Hyoa_global Hyoa_global = new HyoaClass.Hyoa_global();
        string sql = "";
        if (this.txtop.Value == "add")
        {
            //处理特殊字符
            this.hy_bt.Text = ReplaceString_Tszf(this.hy_bt.Text);
            if (Session["conntype"].ToString() == "SQL")
            {
                //edited by xf 20140625
                sql = "insert into hyc_" + this.hy_tableid.Text + " (DOCID,hy_mudelid,hy_tableid,hy_flowid,hy_flowname,hy_curtacheid,hy_curtachename,hy_curclrid,hy_curclrname,hy_djrid,hy_djrname,hy_djrbmid,hy_djrbmname,hy_djsj,hy_bt,hy_readuserlist,hy_readdatelist,hy_clrylist,hy_cyrylist) values (";
                sql += "'" + this.txtdocid.Value + "','" + this.hy_mudelid.Text + "','" + this.hy_tableid.Text + "','" + this.hy_flowid.Text + "','" + this.hy_flowname.Text + "'";
                sql += ",'" + this.hy_curtacheid.Text + "','" + this.hy_curtachename.Text + "','" + this.hy_curclrid.Text + "','" + this.hy_curclrname.Text + "','" + this.hy_djrid.Text + "'";
                sql += ",'" + this.hy_djrname.Text + "','" + this.hy_djrbmid.Text + "','" + this.hy_djrbmname.Text + "','" + this.hy_djsj.Text + "','" + this.hy_bt.Text + "'";
                sql += ",'','','," + Session["hyuid"].ToString() + ",',',') ";
            }
            if (Session["conntype"].ToString() == "ORACLE")
            {
                //edited by xf 20140625
                sql = "insert into hyc_" + this.hy_tableid.Text + " (DOCID,hy_mudelid,hy_tableid,hy_flowid,hy_flowname,hy_curtacheid,hy_curtachename,hy_curclrid,hy_curclrname,hy_djrid,hy_djrname,hy_djrbmid,hy_djrbmname,hy_djsj,hy_bt,hy_readuserlist,hy_readdatelist,hy_clrylist,hy_cyrylist) values (";
                sql += "'" + this.txtdocid.Value + "','" + this.hy_mudelid.Text + "','" + this.hy_tableid.Text + "','" + this.hy_flowid.Text + "','" + this.hy_flowname.Text + "'";
                sql += ",'" + this.hy_curtacheid.Text + "','" + this.hy_curtachename.Text + "','" + this.hy_curclrid.Text + "','" + this.hy_curclrname.Text + "','" + this.hy_djrid.Text + "'";
                sql += ",'" + this.hy_djrname.Text + "','" + this.hy_djrbmid.Text + "','" + this.hy_djrbmname.Text + "',to_date('" + this.hy_djsj.Text + "','YYYY-MM-DD HH24:MI:SS'),'" + this.hy_bt.Text + "'";
                sql += ",'','','," + Session["hyuid"].ToString() + ",',',') ";
            }
            Hyoa_global.ExcuteSQL(sql);

            //插入历史处理表
            Hyoa_global.Saveflowhistoryinfo_cl_global(this.txtdocid.Value, this.hy_flowid.Text, this.hy_flowname.Text, this.hy_curtacheid.Text, this.hy_curtachename.Text, this.Session["hyuid"].ToString(), this.Session["hyuname"].ToString(), "", "", "", this.hy_djsj.Text, "");
        }
        #endregion

        //更新内容
        sql = "update hyc_" + this.hy_tableid.Text + " set hy_tableid='" + hy_tableid.Text + "',hy_bt='" + hy_bt.Text + "' ";

        #region 根据“需要保存的字段”来进行保存
        if (txtsavefields.Text != "")
        {
            string[] lv_savefields = txtsavefields.Text.Split(',');
            string[] lv_savefields_sx = txtsavefields_sx.Text.Split(',');
            string fielddocvalue = "";
            for (int i = 0; i < lv_savefields.Length; i++)
            {
                if (lv_savefields_sx[i].ToString() == "0")  //文本
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        fielddocvalue = ReplaceString_Tszf(fielddocvalue);
                        sql += ",hyc_" + lv_savefields[i].ToString() + "='" + fielddocvalue + "'";
                    }
                }
                if (lv_savefields_sx[i].ToString() == "1")  //日期
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        if (Session["conntype"].ToString() == "SQL")
                        {
                            if (fielddocvalue == "")
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=null";
                            else
                                sql += ",hyc_" + lv_savefields[i].ToString() + "='" + fielddocvalue + "'";
                        }
                        if (Session["conntype"].ToString() == "ORACLE")
                        {
                            if (fielddocvalue == "")
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=null";
                            else
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=to_date('" + fielddocvalue + "','YYYY-MM-DD HH24:MI:SS')";
                        }
                    }
                }
                if (lv_savefields_sx[i].ToString() == "3")  //数值
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        if (fielddocvalue == "")
                            sql += ",hyc_" + lv_savefields[i].ToString() + "=0";
                        else
                            sql += ",hyc_" + lv_savefields[i].ToString() + "=" + fielddocvalue;
                    }
                }
                if (lv_savefields_sx[i].ToString() == "5")  //口令
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        fielddocvalue = ReplaceString_Tszf(fielddocvalue);
                        sql += ",hyc_" + lv_savefields[i].ToString() + "='" + fielddocvalue + "'";
//.........这里部分代码省略.........
开发者ID:wjszxli,项目名称:hyoav10_gdcrm,代码行数:101,代码来源:main.aspx.cs

示例2: Button_Save_Click


//.........这里部分代码省略.........
                Hyoa_flowmain.hy_field96 = 0;
            else
                Hyoa_flowmain.hy_field96 = float.Parse(this.hy_field96.Text);

            if (this.hy_field97.Text == "")
                Hyoa_flowmain.hy_field97 = 0;
            else
                Hyoa_flowmain.hy_field97 = float.Parse(this.hy_field97.Text);

            if (this.hy_field98.Text == "")
                Hyoa_flowmain.hy_field98 = 0;
            else
                Hyoa_flowmain.hy_field98 = float.Parse(this.hy_field98.Text);

            if (this.hy_field99.Text == "")
                Hyoa_flowmain.hy_field99 = 0;
            else
                Hyoa_flowmain.hy_field99 = float.Parse(this.hy_field99.Text);

            if (this.hy_field100.Text == "")
                Hyoa_flowmain.hy_field100 = 0;
            else
                Hyoa_flowmain.hy_field100 = float.Parse(this.hy_field100.Text);

            Hyoa_flowmain.hy_iftx = this.hy_iftx.Text;
            Hyoa_flowmain.hy_zhtxsj = this.hy_zhtxsj.Text;
            Hyoa_flowmain.hy_readuserlist = this.hy_readuserlist.Text;
            #endregion

            Hyoa_flowmain.Insert();

            //插入历史处理表
            HyoaClass.Hyoa_global Hyoa_global_add = new HyoaClass.Hyoa_global();
            Hyoa_global_add.Saveflowhistoryinfo_cl_global(this.txtdocid.Value, this.hy_flowid.Text, this.hy_flowname.Text, this.hy_curtacheid.Text, this.hy_curtachename.Text, this.Session["hyuid"].ToString(), this.Session["hyuname"].ToString(), "", "", "", this.hy_djsj.Text, "");

        }

        #region 更新内容
        Hyoa_flowmain.DOCID = this.txtdocid.Value;
        Hyoa_flowmain.hy_curtacheid = this.hy_curtacheid.Text;
        Hyoa_flowmain.hy_curtachename = this.hy_curtachename.Text;
        Hyoa_flowmain.hy_curclrid = this.hy_curclrid.Text;
        Hyoa_flowmain.hy_curclrname = this.hy_curclrname.Text;

        Hyoa_flowmain.hy_bt = this.hy_bt.Text;

        Hyoa_flowmain.hy_content1 = this.hy_content1.Text;
        Hyoa_flowmain.hy_content2 = this.hy_content2.Text;
        Hyoa_flowmain.hy_content3 = this.hy_content3.Text;
        Hyoa_flowmain.hy_content4 = this.hy_content4.Text;
        Hyoa_flowmain.hy_content5 = this.hy_content5.Text;
        Hyoa_flowmain.hy_content6 = this.hy_content6.Text;
        Hyoa_flowmain.hy_content7 = this.hy_content7.Text;
        Hyoa_flowmain.hy_content8 = this.hy_content8.Text;
        Hyoa_flowmain.hy_content9 = this.hy_content9.Text;
        Hyoa_flowmain.hy_content10 = this.hy_content10.Text;
        Hyoa_flowmain.hy_content11 = this.hy_content11.Text;
        Hyoa_flowmain.hy_content12 = this.hy_content12.Text;
        Hyoa_flowmain.hy_content13 = this.hy_content13.Text;
        Hyoa_flowmain.hy_content14 = this.hy_content14.Text;
        Hyoa_flowmain.hy_content15 = this.hy_content15.Text;

        Hyoa_flowmain.hy_field1 = this.hy_field1.Text;
        Hyoa_flowmain.hy_field2 = this.hy_field2.Text;
        Hyoa_flowmain.hy_field3 = this.hy_field3.Text;
        Hyoa_flowmain.hy_field4 = this.hy_field4.Text;
开发者ID:wjszxli,项目名称:Webapp,代码行数:67,代码来源:main.aspx.cs

示例3: Button_Save_Click

    ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    //保存
    protected void Button_Save_Click(object sender, EventArgs e)
    {
        if (this.Session["hyuid"].ToString() == "")
            this.Response.Redirect("login.aspx");

        string ls_tip = "保存成功!";

        //新文档时
        //新建时先进行一次保存
        HyoaClass.Hyoa_global Hyoa_global = new HyoaClass.Hyoa_global();
        string sql = "";
        if (this.txtop.Value == "add")
        {
            if (Session["conntype"].ToString() == "SQL")
            {
                sql = "insert into hyc_" + this.hy_tableid.Text + " (DOCID,hy_mudelid,hy_tableid,hy_flowid,hy_flowname,hy_curtacheid,hy_curtachename,hy_curclrid,hy_curclrname,hy_djrid,hy_djrname,hy_djrbmid,hy_djrbmname,hy_djsj,hy_bt,hy_readuserlist,hy_readdatelist) values (";
                sql += "'" + this.txtdocid.Value + "','" + this.hy_mudelid.Text + "','" + this.hy_tableid.Text + "','" + this.hy_flowid.Text + "','" + this.hy_flowname.Text + "'";
                sql += ",'" + this.hy_curtacheid.Text + "','" + this.hy_curtachename.Text + "','" + this.hy_curclrid.Text + "','" + this.hy_curclrname.Text + "','" + this.hy_djrid.Text + "'";
                sql += ",'" + this.hy_djrname.Text + "','" + this.hy_djrbmid.Text + "','" + this.hy_djrbmname.Text + "','" + this.hy_djsj.Text + "','" + this.hy_bt.Text + "'";
                sql += ",'','') ";
            }
            if (Session["conntype"].ToString() == "ORACLE")
            {
                sql = "insert into hyc_" + this.hy_tableid.Text + " (DOCID,hy_mudelid,hy_tableid,hy_flowid,hy_flowname,hy_curtacheid,hy_curtachename,hy_curclrid,hy_curclrname,hy_djrid,hy_djrname,hy_djrbmid,hy_djrbmname,hy_djsj,hy_bt,hy_readuserlist,hy_readdatelist) values (";
                sql += "'" + this.txtdocid.Value + "','" + this.hy_mudelid.Text + "','" + this.hy_tableid.Text + "','" + this.hy_flowid.Text + "','" + this.hy_flowname.Text + "'";
                sql += ",'" + this.hy_curtacheid.Text + "','" + this.hy_curtachename.Text + "','" + this.hy_curclrid.Text + "','" + this.hy_curclrname.Text + "','" + this.hy_djrid.Text + "'";
                sql += ",'" + this.hy_djrname.Text + "','" + this.hy_djrbmid.Text + "','" + this.hy_djrbmname.Text + "',to_date('" + this.hy_djsj.Text + "','YYYY-MM-DD HH24:MI:SS'),'" + this.hy_bt.Text + "'";
                sql += ",'','') ";
            }
            Hyoa_global.ExcuteSQL(sql);

            //插入历史处理表(如果是流程文档)
            if (txtifhaveflow.Value == "是")
            {
                Hyoa_global.Saveflowhistoryinfo_cl_global(this.txtdocid.Value, this.hy_flowid.Text, this.hy_flowname.Text, this.hy_curtacheid.Text, this.hy_curtachename.Text, this.Session["hyuid"].ToString(), this.Session["hyuname"].ToString(), "", "", "", this.hy_djsj.Text, "");
            }
        }

        //更新内容
        sql = "update hyc_" + this.hy_tableid.Text + " set hy_tableid='" + hy_tableid.Text + "' ";
        //根据“需要保存的字段”来进行保存
        if (txtsavefields.Text != "")
        {
            string[] lv_savefields = txtsavefields.Text.Split(',');
            string[] lv_savefields_sx = txtsavefields_sx.Text.Split(',');
            string fielddocvalue = "";
            for (int i = 0; i < lv_savefields.Length; i++)
            {
                if (lv_savefields_sx[i].ToString() == "0")  //文本
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        sql += ",hyc_" + lv_savefields[i].ToString() + "='" + fielddocvalue + "'";
                    }
                }
                if (lv_savefields_sx[i].ToString() == "1")  //日期
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        if (Session["conntype"].ToString() == "SQL")
                        {
                            if (fielddocvalue == "")
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=null";
                            else
                                sql += ",hyc_" + lv_savefields[i].ToString() + "='" + fielddocvalue + "'";
                        }
                        if (Session["conntype"].ToString() == "ORACLE")
                        {
                            if (fielddocvalue == "")
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=null";
                            else
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=to_date('" + fielddocvalue + "','YYYY-MM-DD HH24:MI:SS')";
                        }
                    }
                }
                if (lv_savefields_sx[i].ToString() == "3")  //数值
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        if (fielddocvalue == "")
                            sql += ",hyc_" + lv_savefields[i].ToString() + "=0";
                        else
                            sql += ",hyc_" + lv_savefields[i].ToString() + "=" + fielddocvalue;
                    }
                }
                if (lv_savefields_sx[i].ToString() == "5")  //口令
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        sql += ",hyc_" + lv_savefields[i].ToString() + "='" + fielddocvalue + "'";
                    }
                }
                if (lv_savefields_sx[i].ToString() == "6")  //编辑器
                {
//.........这里部分代码省略.........
开发者ID:wjszxli,项目名称:hyoav10_gdcrm,代码行数:101,代码来源:wap_main.aspx.cs

示例4: Button_Save_Click


//.........这里部分代码省略.........
                lssqlinsert2 += "," + "hyc_" + dtfield.Rows[ii]["hy_fieldid"].ToString();

                if (dtfield.Rows[ii]["hy_fieldtype"].ToString() == "文本" || dtfield.Rows[ii]["hy_fieldtype"].ToString() == "多行文本")
                {
                    TextBox txt1 = (TextBox)this.FindControl("txthyc_" + dtfield.Rows[ii]["hy_fieldid"].ToString());
                    lssqlinsert4 += ",'" + txt1.Text + "'";
                }
                if (dtfield.Rows[ii]["hy_fieldtype"].ToString() == "日期")
                {
                    TextBox txt1 = (TextBox)this.FindControl("txthyc_" + dtfield.Rows[ii]["hy_fieldid"].ToString());
                    if (Session["conntype"].ToString() == "SQL")
                    {
                        lssqlinsert4 += ",'" + txt1.Text + "'";
                    }
                    if (Session["conntype"].ToString() == "ORACLE")
                    {
                        lssqlinsert4 += ",to_date('" + txt1.Text + "','YYYY-MM-DD HH24:MI:SS')";
                    }
                }
                if (dtfield.Rows[ii]["hy_fieldtype"].ToString() == "对话框列表")
                {
                    DropDownList ddl1 = (DropDownList)this.FindControl("txthyc_" + dtfield.Rows[ii]["hy_fieldid"].ToString());
                    lssqlinsert4 += ",'" + ddl1.SelectedValue + "'";
                }
            }

            lssqlinsert = lssqlinsert1 + lssqlinsert2 + lssqlinsert3 + lssqlinsert4 + lssqlinsert5;
            //HyoaClass.Hyoa_global Hyoa_global = new HyoaClass.Hyoa_global();
            //Response.Write(lssqlinsert);
            Hyoa_global.ExcuteSQL(lssqlinsert);

            //插入历史处理表
            HyoaClass.Hyoa_global Hyoa_global_add = new HyoaClass.Hyoa_global();
            Hyoa_global_add.Saveflowhistoryinfo_cl_global(this.txtdocid.Value, this.hy_flowid.Text, this.hy_flowname.Text, this.hy_curtacheid.Text, this.hy_curtachename.Text, this.Session["hyuid"].ToString(), this.Session["hyuname"].ToString(), "", "", "", this.hy_djsj.Text, "");

        }

        //更新内容
        //Hyoa_flowmain.DOCID = this.txtdocid.Value;
        //Hyoa_flowmain.hy_curtacheid = this.hy_curtacheid.Text;
        //Hyoa_flowmain.hy_curtachename = this.hy_curtachename.Text;
        //Hyoa_flowmain.hy_curclrid = this.hy_curclrid.Text;
        //Hyoa_flowmain.hy_curclrname = this.hy_curclrname.Text;
        //Hyoa_flowmain.hy_bt = this.hy_bt.Text;

        //Hyoa_flowmain.hy_iftx = this.hy_iftx.Text;
        //Hyoa_flowmain.hy_zhtxsj = this.hy_zhtxsj.Text;
        //Hyoa_flowmain.hy_readuserlist = this.hy_readuserlist.Text;

        string lssqlfield2 = "SELECT * FROM hyt_flowfield WHERE (hy_tableid = 'Tabledcxt') AND (hy_mudelid = 'Mudeldcxt')";
        DataTable dtfield2 = Hyoa_global.GetDataTable_BASE(lssqlfield2); //得到所有配置域
        string lssqlupdate1 = "update hyc_" + this.hy_tableid.Text + " set hy_curtacheid = '" + this.hy_curtacheid.Text + "'";
        lssqlupdate1 += ",hy_curtachename='" + this.hy_curtachename.Text + "'";
        lssqlupdate1 += ",hy_curclrid='" + this.hy_curclrid.Text + "'";
        lssqlupdate1 += ",hy_curclrname='" + this.hy_curclrname.Text + "'";
        lssqlupdate1 += ",hy_bt='" + this.hy_bt.Text + "'";
        for (int ii = 0; ii < dtfield2.Rows.Count; ii++)
        {
           if (dtfield2.Rows[ii]["hy_fieldtype"].ToString() == "文本" || dtfield2.Rows[ii]["hy_fieldtype"].ToString() == "多行文本" || dtfield2.Rows[ii]["hy_fieldtype"].ToString() == "日期")
            {
                TextBox txt1 = (TextBox)this.FindControl("txthyc_" + dtfield2.Rows[ii]["hy_fieldid"].ToString());

                lssqlupdate1 += ",hyc_" + dtfield2.Rows[ii]["hy_fieldid"].ToString() + "='" + txt1.Text + "'";

            }
            if (dtfield2.Rows[ii]["hy_fieldtype"].ToString() == "对话框列表")
开发者ID:wjszxli,项目名称:hyoav10_gdcrm,代码行数:67,代码来源:main.aspx.cs

示例5: DataPlay

    //保存
    private void DataPlay()
    {
        //hy_json = "{\"success\":true,\"total\":\"60\",\"rows\":[{\"hy_mudelid\":\"111\",\"hy_mudelname\":\"1111\",\"hy_roleid\":\"111111\",\"hy_qqroleid\":\"111111\",\"hy_isenabled\":\"111111\"}]}";
        string hy_json = "";
        string ls_success = "true";    //调用方法成功
        string ls_flag = "0";   //失败
        string ls_tip = "保存成功!";
        string txtop = "";
        if (Request.Form["txtop"] != null)
            txtop = Request.Form["txtop"].ToString();

        string hy_bt = "";
        if (Request.Form["hy_bt"] != null)
            hy_bt = Request.Form["hy_bt"].ToString();

        //新文档时
        //新建时先进行一次保存
        HyoaClass.Hyoa_global Hyoa_global = new HyoaClass.Hyoa_global();
        string sql = "";
        if (txtop == "add")
        {
            //处理特殊字符
            hy_bt = ReplaceString_Tszf(hy_bt);
            if (Session["conntype"].ToString() == "SQL")
            {
                //edited by xf 20140625
                sql = "insert into hyc_" + Request.Form["hy_tableid"].ToString() + " (DOCID,hy_mudelid,hy_tableid,hy_flowid,hy_flowname,hy_curtacheid,hy_curtachename,hy_curclrid,hy_curclrname,hy_djrid,hy_djrname,hy_djrbmid,hy_djrbmname,hy_djsj,hy_bt,hy_readuserlist,hy_readdatelist,hy_clrylist,hy_cyrylist) values (";
                sql += "'" + Request.Form["txtdocid"].ToString() + "','" + Request.Form["hy_mudelid"].ToString() + "','" + Request.Form["hy_tableid"].ToString() + "','" + Request.Form["hy_flowid"].ToString() + "','" + Request.Form["hy_flowname"].ToString() + "'";
                sql += ",'" + Request.Form["hy_curtacheid"].ToString() + "','" + Request.Form["hy_curtachename"].ToString() + "','" + Request.Form["hy_curclrid"].ToString() + "','" + Request.Form["hy_curclrname"].ToString() + "','" + Request.Form["hy_djrid"].ToString() + "'";
                sql += ",'" + Request.Form["hy_djrname"].ToString() + "','" + Request.Form["hy_djrbmid"].ToString() + "','" + Request.Form["hy_djrbmname"].ToString() + "','" + Request.Form["hy_djsj"].ToString() + "','" + Request.Form["hy_bt"].ToString() + "'";
                sql += ",'','','," + Session["hyuid"].ToString() + ",',',') ";
            }
            if (Session["conntype"].ToString() == "ORACLE")
            {
                //edited by xf 20140625
                sql = "insert into hyc_" + Request.Form["hy_tableid"].ToString() + " (DOCID,hy_mudelid,hy_tableid,hy_flowid,hy_flowname,hy_curtacheid,hy_curtachename,hy_curclrid,hy_curclrname,hy_djrid,hy_djrname,hy_djrbmid,hy_djrbmname,hy_djsj,hy_bt,hy_readuserlist,hy_readdatelist,hy_clrylist,hy_cyrylist) values (";
                sql += "'" + Request.Form["txtdocid"].ToString() + "','" + Request.Form["hy_mudelid"].ToString() + "','" + Request.Form["hy_tableid"].ToString() + "','" + Request.Form["hy_flowid"].ToString() + "','" + Request.Form["hy_flowname"].ToString() + "'";
                sql += ",'" + Request.Form["hy_curtacheid"].ToString() + "','" + Request.Form["hy_curtachename"].ToString() + "','" + Request.Form["hy_curclrid"].ToString() + "','" + Request.Form["hy_curclrname"].ToString() + "','" + Request.Form["hy_djrid"].ToString() + "'";
                sql += ",'" + Request.Form["hy_djrname"].ToString() + "','" + Request.Form["hy_djrbmid"].ToString() + "','" + Request.Form["hy_djrbmname"].ToString() + "',to_date('" + Request.Form["hy_djsj"].ToString() + "','YYYY-MM-DD HH24:MI:SS'),'" + Request.Form["hy_bt"].ToString() + "'";
                sql += ",'','','," + Session["hyuid"].ToString() + ",',',') ";
            }
            Hyoa_global.ExcuteSQL(sql);

            //插入历史处理表(如果是流程文档)
            if (Request.Form["txtifhaveflow"].ToString() == "是")
            {
                Hyoa_global.Saveflowhistoryinfo_cl_global(Request.Form["txtdocid"].ToString(), Request.Form["hy_flowid"].ToString(), Request.Form["hy_flowname"].ToString(), Request.Form["hy_curtacheid"].ToString(), Request.Form["hy_curtachename"].ToString(), this.Session["hyuid"].ToString(), this.Session["hyuname"].ToString(), "", "", "", Request.Form["hy_djsj"].ToString(), "");
            }
        }
        //更新内容
        sql = "update hyc_" + Request.Form["hy_tableid"].ToString() + " set hy_tableid='" + Request.Form["hy_tableid"].ToString() + "',hy_bt='" + Request.Form["hy_bt"].ToString() + "' ";
        //根据“需要保存的字段”来进行保存
        if (Request.Form["txtsavefields"].ToString() != "")
        {
            string[] lv_savefields = Request.Form["txtsavefields"].ToString().Split(',');
            string[] lv_savefields_sx = Request.Form["txtsavefields_sx"].ToString().Split(',');
            string fielddocvalue = "";
            for (int i = 0; i < lv_savefields.Length; i++)
            {
                if (lv_savefields_sx[i].ToString() == "0")  //文本
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        fielddocvalue = ReplaceString_Tszf(fielddocvalue);
                        sql += ",hyc_" + lv_savefields[i].ToString() + "='" + fielddocvalue + "'";
                    }
                }
                if (lv_savefields_sx[i].ToString() == "1")  //日期
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        if (Session["conntype"].ToString() == "SQL")
                        {
                            if (fielddocvalue == "")
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=null";
                            else
                                sql += ",hyc_" + lv_savefields[i].ToString() + "='" + fielddocvalue + "'";
                        }
                        if (Session["conntype"].ToString() == "ORACLE")
                        {
                            if (fielddocvalue == "")
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=null";
                            else
                                sql += ",hyc_" + lv_savefields[i].ToString() + "=to_date('" + fielddocvalue + "','YYYY-MM-DD HH24:MI:SS')";
                        }
                    }
                }
                if (lv_savefields_sx[i].ToString() == "3")  //数值
                {
                    if (this.Request.Form[lv_savefields[i].ToString()] != null)
                    {
                        fielddocvalue = this.Request.Form[lv_savefields[i].ToString()].ToString();
                        if (fielddocvalue == "")
                            sql += ",hyc_" + lv_savefields[i].ToString() + "=0";
                        else
                            sql += ",hyc_" + lv_savefields[i].ToString() + "=" + fielddocvalue;
                    }
//.........这里部分代码省略.........
开发者ID:wjszxli,项目名称:hyoav10_gdcrm,代码行数:101,代码来源:mainsave.aspx.cs


注:本文中的HyoaClass.Hyoa_global.Saveflowhistoryinfo_cl_global方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。