Exemplo n.º 1
0
 public FrmAddEmployee(AdminMsg LoginUser)
 {
     be        = new BEmployee(LoginUser.SqlConn);
     SystemMsg = LoginUser;
     InitializeComponent();
     BOperation = new BOperationRecord(LoginUser.SqlConn);
     log        = new Log(PublicValues.LogFilePath);
 }
Exemplo n.º 2
0
 public FrmAllot(AdminMsg LoginUser)
 {
     InitializeComponent();
     be       = new BEmployee(LoginUser.SqlConn);
     LoginMsg = LoginUser;
     InitializeComponent();
     BOperation   = new BOperationRecord(LoginUser.SqlConn);
     BAllotHandle = new BAllotHandle(LoginUser);
     log          = new Log(PublicValues.LogFilePath);
 }
Exemplo n.º 3
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="user_id"></param>
        /// <param name="user_name"></param>
        /// <returns></returns>
        public BUser GetSubUser(string user_id, string user_name)
        {
            BUser user = null;
            SubuserFullinfoGetRequest req = new SubuserFullinfoGetRequest();

            req.Fields  = "subuser_email,user_email";
            req.SubNick = user_name;
            SubuserFullinfoGetResponse response = client.Execute(req, this.Access_Token.Access_Token1);

            if (response.IsError)
            {
                throw new KMJXCException("在" + this.MallType.Name + "没有找到用户" + user_name, ExceptionLevel.ERROR);
            }

            if (response.SubFullinfo != null)
            {
                user                  = new BUser();
                user.Mall_Name        = user_name;
                user.Mall_ID          = response.SubFullinfo.SubId.ToString();
                user.Type             = this.MallType;
                user.Parent           = new BUser();
                user.Parent.Mall_ID   = response.SubFullinfo.UserId.ToString();
                user.Parent.Mall_Name = response.SubFullinfo.UserNick;
                user.Parent.Type      = this.MallType;
                user.Parent.Parent    = null;
                BEmployee employee = new BEmployee();
                user.EmployeeInfo   = employee;
                employee.Department = response.SubFullinfo.DepartmentName;
                employee.Duty       = response.SubFullinfo.DutyName;
                employee.Email      = response.SubFullinfo.SubuserEmail;
                employee.Gendar     = response.SubFullinfo.Sex.ToString();
                employee.Name       = response.SubFullinfo.EmployeeName;
                employee.Phone      = response.SubFullinfo.OfficePhone;
            }
            return(user);
        }
Exemplo n.º 4
0
        public Employee Get(int id)
        {
            BEmployee be = new BEmployee(this.repo);

            return(be.getEmployee(id));
        }
Exemplo n.º 5
0
        public IEnumerable <Employee> Get()
        {
            BEmployee be = new BEmployee(this.repo);

            return(be.getEmployee());
        }
Exemplo n.º 6
0
 public EmployeeController()
 {
     employees = new BEmployee();
 }
Exemplo n.º 7
0
 public FrmMainConsole(AdminMsg msg)
 {
     InitializeComponent();
     this.SystemMsg = msg;
     bEmployee      = new BEmployee(msg.SqlConn);
 }