Example #1
0
        //构造函数
        public EmployeeForm(BathDBDataContext dc, Employee employee, EmployeeManagementForm form)
        {
            db     = dc;
            m_Form = form;
            if (employee != null)
            {
                newEmployee = false;
                m_Employee  = employee;
            }

            InitializeComponent();
        }
Example #2
0
        //员工管理
        private void btnEmployee_Click(object sender, EventArgs e)
        {
            var    db  = new BathDBDataContext(LogIn.connectionString);
            string pro = ((Button)sender).Text;

            if (!BathClass.getAuthority(db, LogIn.m_User, pro))
            {
                GeneralClass.printErrorMsg("权限不够,不能访问!");
                return;
            }
            EmployeeManagementForm employeeManagementForm = new EmployeeManagementForm();

            employeeManagementForm.ShowDialog();
        }
Example #3
0
 //员工管理
 private void btnEmployee_Click(object sender, EventArgs e)
 {
     var db = new BathDBDataContext(LogIn.connectionString);
     string pro = ((Button)sender).Text;
     if (!BathClass.getAuthority(db, LogIn.m_User, pro))
     {
         GeneralClass.printErrorMsg("权限不够,不能访问!");
         return;
     }
     EmployeeManagementForm employeeManagementForm = new EmployeeManagementForm();
     employeeManagementForm.ShowDialog();
 }