示例#1
0
文件: Form1.cs 项目: SebCza17/BPMNWF
        private void buttonSubmit_Click(object sender, EventArgs e)
        {
            Model.RestApp                   restApp                = null;
            Model.DAO.ProcessDAO            processDAO             = null;
            Model.Entity.ProcessDefinitions processDefinitionsList = null;

            if (!textBoxUsername.Text.Equals("") || !textBoxPassword.Text.Equals(""))
            {
                restApp = new Model.RestApp(textBoxUsername.Text, textBoxPassword.Text);
            }

            if (restApp != null)
            {
                processDAO = new Model.DAO.ProcessDAO(restApp);
            }

            if (processDAO != null)
            {
                processDefinitionsList = processDAO.getProcessDefinitions();
            }

            if (processDefinitionsList != null)
            {
                Console.WriteLine("Good");
                ProcessDefForm processForm = new ProcessDefForm(restApp, processDefinitionsList);
                processForm.Show();

                this.Hide();
            }
            else
            {
                Console.WriteLine("Wrong Username or Password");
            }
        }
示例#2
0
        public ProcessDefForm(Model.RestApp restApp, Model.Entity.ProcessDefinitions processDefinitionsList)
        {
            InitializeComponent();

            this.restApp = restApp;

            fillListBoxProcess(processDefinitionsList);
        }
示例#3
0
        public ProcessForm(Model.RestApp restApp, Model.Entity.ProcessDefinition processDefinition)
        {
            InitializeComponent();

            this.restApp           = restApp;
            this.processDAO        = new Model.DAO.ProcessDAO(restApp);
            this.processDefinition = processDefinition;

            fillListBoxProcess();
        }
示例#4
0
        public TaskForm(Model.RestApp restApp, Model.Entity.ProcessInstance processInstance)
        {
            InitializeComponent();

            this.restApp         = restApp;
            this.processInstance = processInstance;
            this.taskDAO         = new Model.DAO.TaskDAO(restApp);
            formDAO = new Model.DAO.FormDAO(restApp);

            fillListBoxTask();
        }