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


C# HyoaClass.Hyoa_flowfield.Update方法代码示例

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


在下文中一共展示了HyoaClass.Hyoa_flowfield.Update方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的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 = "保存成功!";

        HyoaClass.Hyoa_global Hyoa_global = new HyoaClass.Hyoa_global();

        //判断是否已存在该字段
        HyoaClass.Hyoa_flowfield Hyoa_flowfield = new HyoaClass.Hyoa_flowfield();
        Hyoa_flowfield.hy_tableid = this.txttableid.Text;
        Hyoa_flowfield.hy_mudelid = this.txtmudelid.Text;
        Hyoa_flowfield.hy_flowid = this.txtflowid.Text;
        Hyoa_flowfield.hy_fieldid = this.txtfieldid.Text;
        Hyoa_flowfield.hy_fieldname = this.txtfieldname.Text;
        Hyoa_flowfield.hy_fieldtype = this.ddlfieldtype.SelectedValue;
        Hyoa_flowfield.hy_ifreadonly = this.ddlifreadonly.SelectedValue;
        Hyoa_flowfield.hy_defaultvaluetype = System.Int32.Parse(this.ddldefaultvaluetype.SelectedValue);
        Hyoa_flowfield.hy_defaultvalue = this.txtdefaultvalue.Text;
        Hyoa_flowfield.hy_optiontype = System.Int32.Parse(this.ddloptiontype.SelectedValue);
        Hyoa_flowfield.hy_options = this.txtoptions.Text;
        Hyoa_flowfield.hy_onclick = this.txtonclick.Text;
        Hyoa_flowfield.hy_ondblclick = this.txtondblclick.Text;
        Hyoa_flowfield.hy_onchange = this.txtonchange.Text;
        Hyoa_flowfield.hy_onkeydown = this.txtonkeydown.Text;
        Hyoa_flowfield.hy_onkeyup = this.txtonkeyup.Text;
        Hyoa_flowfield.hy_onfocus = this.txtonfocus.Text;
        Hyoa_flowfield.hy_onblur = this.txtonblur.Text;
        Hyoa_flowfield.hy_sqlfield = "";
        Hyoa_flowfield.hy_class = this.txtclass.Text;
        Hyoa_flowfield.hy_width = this.txtwidth.Text;
        Hyoa_flowfield.hy_height = this.txtheight.Text;
        Hyoa_flowfield.hy_tdnums = System.Int32.Parse(this.ddltdnums.SelectedValue);
        Hyoa_flowfield.hy_config = "";
        Hyoa_flowfield.hy_sort = float.Parse(this.txtsort.Text);
        Hyoa_flowfield.hy_wordlimit = System.Int32.Parse(this.txtwordlimit.Text);
        Hyoa_flowfield.hy_required = this.ddlrequired.SelectedValue;
        Hyoa_flowfield.hy_align = this.ddlalign.SelectedValue;
        Hyoa_flowfield.hy_ifhiddle = this.ddlifhiddle.SelectedValue;
        Hyoa_flowfield.hy_ifdbsybt = this.ddlifdbsybt.SelectedValue;
        Hyoa_flowfield.hy_field1 = "";
        Hyoa_flowfield.hy_field2 = "";
        Hyoa_flowfield.hy_field3 = "";
        Hyoa_flowfield.hy_field4 = "";
        Hyoa_flowfield.hy_field5 = "";

        //新文档时
        if (this.txtop.Value == "add")
        {
            DataTable dt = Hyoa_flowfield.GetSQLfieldBymudelidAndFieldidAndTableid(this.txtmudelid.Text, this.txtfieldid.Text, this.txttableid.Text);
            if (dt.Rows.Count > 0)
            {
                Response.Write("<script>alert('该字段ID在当前表单中已存在,请重新输入!');</script>");
                return;
            }
            Hyoa_flowfield.ID = Hyoa_global.GetRandom();
            Hyoa_flowfield.Insert();
            CreateSQLField();
        }
        else
        {
            Hyoa_flowfield.ID = this.txtdocid.Value;
            Hyoa_flowfield.Update();
            EditSQLField();
        }
        //处理完成后的提示及跳转
        if (this.txtifpop.Value == "")
        {
            Response.Write("<script>alert('" + ls_tip + "');window.location='" + this.txturl.Value + "'</script>");
        }
        else
        {
            Response.Write("<script>alert('" + ls_tip + "');self.close();</script>");
        }
    }
开发者ID:wjszxli,项目名称:hyoav10_gdcrm,代码行数:77,代码来源:main_flowfield.aspx.cs

示例2: 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();
        HyoaClass.Hyoa_flowfield Hyoa_flowfield = new HyoaClass.Hyoa_flowfield();
        //新文档时
        if (this.txtop.Value == "add")
        {
            Hyoa_flowfield.ID = Hyoa_global.GetRandom();
            Hyoa_flowfield.hy_tableid = this.txttableid.Text;
            Hyoa_flowfield.hy_mudelid = this.txtmudelid.Text;
            Hyoa_flowfield.hy_flowid = this.txtflowid.Text;
            Hyoa_flowfield.hy_fieldid = this.txtfieldid.Text;
            Hyoa_flowfield.hy_fieldname = this.txtfieldname.Text;
            Hyoa_flowfield.hy_fieldtype = this.ddlfieldtype.SelectedValue;
            Hyoa_flowfield.hy_ifreadonly = this.ddlifreadonly.SelectedValue;
            Hyoa_flowfield.hy_defaultvaluetype = System.Int32.Parse(this.ddldefaultvaluetype.SelectedValue);
            Hyoa_flowfield.hy_defaultvalue = this.txtdefaultvalue.Text;
            Hyoa_flowfield.hy_optiontype = System.Int32.Parse(this.ddloptiontype.SelectedValue);

            if (ddloptiontype.SelectedValue == "1" && ddlwhichtable.SelectedIndex != 0)
            {
                if(this.ddlwhichtable.SelectedIndex==0)
                    Hyoa_flowfield.hy_options = this.txtoptions.Text;
                else
                    Hyoa_flowfield.hy_options = this.txtoptions.Text + " from hyp_flowmain where hy_tableid='" + ddlwhichtable.SelectedValue + "' order by " + this.txtsortby.Text + " " + this.ddlsorttype.SelectedValue;
            }
            else
            {
                Hyoa_flowfield.hy_options = this.txtoptions.Text;
            }

            Hyoa_flowfield.hy_onclick = this.txtonclick.Text;
            Hyoa_flowfield.hy_ondblclick = this.txtondblclick.Text;
            Hyoa_flowfield.hy_onchange = this.txtonchange.Text;
            Hyoa_flowfield.hy_onkeydown = this.txtonkeydown.Text;
            Hyoa_flowfield.hy_onkeyup = this.txtonkeyup.Text;
            Hyoa_flowfield.hy_sqlfield = this.ddlsqlfield.SelectedValue;
            Hyoa_flowfield.hy_class = this.txtclass.Text;
            Hyoa_flowfield.hy_width = this.txtwidth.Text;
            Hyoa_flowfield.hy_height = this.txtheight.Text;
            Hyoa_flowfield.hy_tdnums = System.Int32.Parse(this.ddltdnums.SelectedValue);
            Hyoa_flowfield.hy_config = "";
            Hyoa_flowfield.hy_sort = float.Parse(this.txtsort.Text);
            Hyoa_flowfield.hy_wordlimit = System.Int32.Parse(this.txtwordlimit.Text);
            Hyoa_flowfield.hy_required = this.ddlrequired.SelectedValue;
            Hyoa_flowfield.hy_align = this.ddlalign.SelectedValue;
            Hyoa_flowfield.hy_ifhiddle = this.ddlifhiddle.SelectedValue;

            Hyoa_flowfield.Insert();
        }
        else
        {
            Hyoa_flowfield.ID = this.txtdocid.Value;
            Hyoa_flowfield.hy_tableid = this.txttableid.Text;
            Hyoa_flowfield.hy_mudelid = this.txtmudelid.Text;
            Hyoa_flowfield.hy_flowid = this.txtflowid.Text;
            Hyoa_flowfield.hy_fieldid = this.txtfieldid.Text;
            Hyoa_flowfield.hy_fieldname = this.txtfieldname.Text;
            Hyoa_flowfield.hy_fieldtype = this.ddlfieldtype.SelectedValue;
            Hyoa_flowfield.hy_ifreadonly = this.ddlifreadonly.SelectedValue;
            Hyoa_flowfield.hy_defaultvaluetype = System.Int32.Parse(this.ddldefaultvaluetype.SelectedValue);
            Hyoa_flowfield.hy_defaultvalue = this.txtdefaultvalue.Text;
            Hyoa_flowfield.hy_optiontype = System.Int32.Parse(this.ddloptiontype.SelectedValue);

            if (ddloptiontype.SelectedValue == "1" && ddlwhichtable.SelectedIndex != 0)
                Hyoa_flowfield.hy_options = this.txtoptions.Text + " from hyp_flowmain where hy_tableid='" + ddlwhichtable.SelectedValue + "' order by " + this.txtsortby.Text + " " + this.ddlsorttype.SelectedValue;
            else
                Hyoa_flowfield.hy_options = this.txtoptions.Text;

            Hyoa_flowfield.hy_onclick = this.txtonclick.Text;
            Hyoa_flowfield.hy_ondblclick = this.txtondblclick.Text;
            Hyoa_flowfield.hy_onchange = this.txtonchange.Text;
            Hyoa_flowfield.hy_onkeydown = this.txtonkeydown.Text;
            Hyoa_flowfield.hy_onkeyup = this.txtonkeyup.Text;
            Hyoa_flowfield.hy_sqlfield = this.ddlsqlfield.SelectedValue;
            Hyoa_flowfield.hy_class = this.txtclass.Text;
            Hyoa_flowfield.hy_width = this.txtwidth.Text;
            Hyoa_flowfield.hy_height = this.txtheight.Text;
            Hyoa_flowfield.hy_tdnums = System.Int32.Parse(this.ddltdnums.SelectedValue);
            Hyoa_flowfield.hy_config = "";
            Hyoa_flowfield.hy_sort = float.Parse(this.txtsort.Text);
            Hyoa_flowfield.hy_wordlimit = System.Int32.Parse(this.txtwordlimit.Text);
            Hyoa_flowfield.hy_required = this.ddlrequired.SelectedValue;
            Hyoa_flowfield.hy_align = this.ddlalign.SelectedValue;
            Hyoa_flowfield.hy_ifhiddle = this.ddlifhiddle.SelectedValue;

            Hyoa_flowfield.Update();

            string lsupdate = "update hyt_flowfield set hy_flowid = '" + this.txtflowid.Text + "' where ID='" + this.txtdocid.Value + "'";
            HyoaClass.DAO dbupdate = new HyoaClass.DAO();
            dbupdate.Execute(lsupdate);
            dbupdate.Close();

        }
//.........这里部分代码省略.........
开发者ID:wjszxli,项目名称:Webapp,代码行数:101,代码来源:main_flowfield.aspx.cs


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