Esempio n. 1
0
        private void MainForm_Load(object sender, EventArgs e)
        {
            FormClosing += MainForm_FormClosing;

            laborServiceInterface = new LoginUserService(db);
            loginUser             = laborServiceInterface.GetSingle(null);
            if (null == loginUser)
            {
                return;
            }

            ProjectsResponseData projectsResponse = new ProjectsResponseData();

            ProjectsResponseService.Response(loginUser, 1, 1000, ref projectsResponse);
            if (null == projectsResponse)
            {
                return;
            }
            if (null == projectsResponse.data)
            {
                return;
            }

            projectList = projectsResponse.data;
            ProjectListComboBoxLoadData();

            workers_pageUserControl.OnPageChanged += Workers_pageUserControl_OnPageChanged;
            manager_pageUserControl.OnPageChanged += Manager_pageUserControl_OnPageChanged;

            group_projects_comboBox.SelectedValueChanged   += Group_projects_comboBox_SelectedValueChanged;
            workers_projects_comboBox.SelectedValueChanged += Workers_projects_comboBox_SelectedValueChanged;
            manager_comboBox.SelectedValueChanged          += Manager_comboBox_SelectedValueChanged;
        }
Esempio n. 2
0
 private void LoginForm_Load(object sender, EventArgs e)
 {
     laborServiceInterface = new LoginUserService(db);
     loginUser             = laborServiceInterface.GetSingle(null);
     if (null == loginUser)
     {
         return;
     }
     if (loginUser.RememberMe == 0)
     {
         return;
     }
     username_textBox.Text        = loginUser.AccountName;
     password_textBox.Text        = loginUser.Password;
     remember_me_checkBox.Checked = true;
 }