コード例 #1
0
        protected void Save()
        {
            Node nd = new Node(this.NodeID);

            //使用ccbpm内置的节点表单
            if (this.RB_FixFrm.Checked)
            {
                if (this.RB_Frm_0.Checked == true)
                {
                    nd.FormType = NodeFormType.FreeForm;
                    nd.DirectUpdate();
                }
                else
                {
                    nd.FormType = NodeFormType.FixForm;
                    nd.DirectUpdate();
                }
                if (this.RB_CurrentForm.Checked)
                {
                    nd.NodeFrmID = "";
                    nd.DirectUpdate();
                }
                if (this.RB_OtherForms.Checked)
                {
                    nd.NodeFrmID = "ND" + this.DDL_Frm.SelectedValue;
                    nd.DirectUpdate();
                }
            }
            //使用嵌入式表单
            if (this.RB_SelfForm.Checked)
            {
                nd.FormType = NodeFormType.SelfForm;
                nd.FormUrl  = this.TB_CustomURL.Text;
                nd.DirectUpdate();
            }
            //使用SDK表单
            if (this.RB_SDKForm.Checked)
            {
                nd.FormType = NodeFormType.SDKForm;
                nd.FormUrl  = this.TB_FormURL.Text;
                nd.DirectUpdate();
            }
            //绑定多表单
            if (this.RB_SheetTree.Checked)
            {
                if (this.RB_tree.Checked == true)
                {
                    nd.FormType = NodeFormType.SheetTree;
                    nd.DirectUpdate();
                }
                else
                {
                    nd.FormType = NodeFormType.DisableIt;
                    nd.DirectUpdate();
                }
            }

            //如果公文表单选择了
            if (this.RB_WebOffice.Checked)
            {
                nd.FormType = NodeFormType.WebOffice;
                nd.Update();

                //按钮标签.
                BtnLab btn = new BtnLab(this.NodeID);

                if (this.RB_WebOffice_Frm2.Checked)
                {
                    btn.WebOfficeWorkModel = WebOfficeWorkModel.FrmFirst;
                }
                else
                {
                    btn.WebOfficeWorkModel = WebOfficeWorkModel.WordFirst;
                }

                btn.Update();
            }
        }