Exemplo n.º 1
0
 private void BindEmployeeSetByEmployeeID(int employeeID)
 {
     try
     {
         _ItsView.ResultMessage = string.Empty;
         EmployeeSalary employeeSalary;
         EmployeeSalary temp = _IEmployeeAccountSetFacade.GetEmployeeAccountSetByEmployeeID(employeeID);
         if (temp != null)
         {
             employeeSalary       = temp;
             _ItsView.Description = employeeSalary.AccountSet.Description;
         }
         else
         {
             employeeSalary            = new EmployeeSalary(employeeID);
             employeeSalary.AccountSet = _IAccountSetFacade.GetWholeAccountSetByPKID(_ItsView.AccountSetID);
         }
         employeeSalary.Employee = _IEmployeeFacade.GetEmployeeBasicInfoByAccountID(employeeID);
         _ItsView.EmployeeSalary = employeeSalary;
     }
     catch (Exception ex)
     {
         _ItsView.ResultMessage = "<span class='fontred'>" + ex.Message + "</span>";
     }
 }
        /// <summary>
        /// 复制事件,将AccountSet对象,付给SessionCopyAccountSet
        /// </summary>
        private void btnCopyClick(string strAccountSetID)
        {
            int accountSetID;

            if (!int.TryParse(strAccountSetID, out accountSetID))
            {
                return;
            }
            _IAccountSetListView.SessionCopyAccountSet = _IAccountSetFacade.GetWholeAccountSetByPKID(accountSetID);
        }
        public Model.PayModule.AccountSet GetAccountSet(string name)
        {
            Model.PayModule.AccountSet accountSet = _IAccountSetFacade.GetAccountSetByName(name);

            if (accountSet != null)
            {
                return(_IAccountSetFacade.GetWholeAccountSetByPKID(accountSet.AccountSetID));
            }
            return(null);
        }
Exemplo n.º 4
0
 public void DataBind(int accountSetId)
 {
     try
     {
         Model.PayModule.AccountSet theDataToBind = _IAccountSetFacade.GetWholeAccountSetByPKID(accountSetId);
         _IAccountSetView.AccountSetName     = theDataToBind.AccountSetName;
         _IAccountSetView.Description        = theDataToBind.Description;
         _IAccountSetView.AccountSetItemList = theDataToBind.Items;
     }
     catch
     {
         _IAccountSetView.Message = "初始化信息失败";
     }
 }