コード例 #1
0
        //废弃流程
        private void button10_Click_1(object sender, EventArgs e)
        {
            application_instance_id = textBox4.Text == "" ? "0001" : textBox4.Text;

            WfRunner appRunner = new WfRunner();

            appRunner.ProcessGUID   = process_guid;
            appRunner.AppInstanceID = application_instance_id;
            appRunner.AppName       = "ApiTest";
            appRunner.UserID        = textBox5.Text;
            appRunner.UserName      = textBox5.Text;

            var result = WebOpreation.Post("odata/DiscardProcess", Newtonsoft.Json.JsonConvert.SerializeObject(appRunner));

            rtext.Text += result + "\r\n";
        }
コード例 #2
0
        private void Withdraw(string usr, Button bt)
        {
            application_instance_id = textBox4.Text == "" ? "0001" : textBox4.Text;

            WfRunner appRunner = new WfRunner();

            appRunner.ProcessGUID   = process_guid;
            appRunner.AppInstanceID = application_instance_id;
            appRunner.AppName       = "ApiTest";
            appRunner.UserID        = usr;
            appRunner.UserName      = usr;

            var result = WebOpreation.Post("odata/WithdrawProcess", Newtonsoft.Json.JsonConvert.SerializeObject(appRunner));

            bt.BackColor = Color.AntiqueWhite;
            rtext.Text  += result + "\r\n";
        }
コード例 #3
0
        private void RunPro(string nextguid, string usr, string nextusr, Button bt)
        {
            application_instance_id = textBox4.Text == "" ? "0001" : textBox4.Text;

            WfRunner appRunner = new WfRunner();

            appRunner.ProcessGUID   = process_guid;
            appRunner.AppInstanceID = application_instance_id;
            appRunner.AppName       = "ApiTest";
            appRunner.UserID        = usr;
            appRunner.UserName      = usr;
            appRunner.NextActivityPerformers.Add(new Point {
                PathID = nextguid, UserID = nextusr, UserName = nextusr
            });
            var result = WebOpreation.Post("odata/RunProcess", Newtonsoft.Json.JsonConvert.SerializeObject(appRunner));

            bt.BackColor = Color.Green;
            rtext.Text  += result + "\r\n";
        }
コード例 #4
0
        private void button5_Click(object sender, EventArgs e)
        {
            application_instance_id = textBox4.Text == "" ? "0001" : textBox4.Text;

            WfRunner appRunner = new WfRunner();

            appRunner.ProcessGUID   = process_guid;
            appRunner.AppInstanceID = application_instance_id;
            appRunner.AppName       = "ApiTest";
            appRunner.UserID        = "usr1";
            appRunner.UserName      = "******";
            appRunner.NextActivityPerformers.Add(new Point {
                PathID = "fc8c71c5-8786-450e-af27-9f6a9de8560f", UserID = "usr2", UserName = "******"
            });
            var result = WebOpreation.Post("odata/StartProcess", Newtonsoft.Json.JsonConvert.SerializeObject(appRunner));

            s2.BackColor = Color.Green;

            rtext.Text += result + "\r\n";
        }
コード例 #5
0
        //跳转
        private void button4_Click(object sender, EventArgs e)
        {
            application_instance_id = textBox4.Text == "" ? "0001" : textBox4.Text;

            WfRunner appRunner = new WfRunner();

            appRunner.ProcessGUID          = process_guid;
            appRunner.AppInstanceID        = application_instance_id;
            appRunner.AppName              = "ApiTest";
            appRunner.UserID               = textBox2.Text;
            appRunner.UserName             = textBox2.Text;
            appRunner.JumpbackActivityGUID = textBox1.Text;
            appRunner.NextActivityPerformers.Add(new Point {
                PathID = textBox1.Text, UserID = textBox3.Text, UserName = textBox3.Text
            });

            var result = WebOpreation.Post("odata/JumpProcess", Newtonsoft.Json.JsonConvert.SerializeObject(appRunner));

            rtext.Text += result + "\r\n";
        }