Пример #1
0
 public DisciplineDepartmentModel(hr_DisciplineDepartment reward)
 {
     DisciplineDepartment = reward ?? new hr_DisciplineDepartment();
     DepartmentId         = DisciplineDepartment.DepartmentId;
     DecisionNumber       = DisciplineDepartment.DecisionNumber;
     DecisionName         = DisciplineDepartment.DecisionName;
     DecisionDate         = DisciplineDepartment.DecisionDate;
     Reason         = DisciplineDepartment.Reason;
     MoneyAmount    = DisciplineDepartment.MoneyAmount;
     Note           = DisciplineDepartment.Note;
     DecisionMaker  = DisciplineDepartment.DecisionMaker;
     IsApproved     = DisciplineDepartment.IsApproved;
     AttachFileName = DisciplineDepartment.AttachFileName;
     LevelRewardId  = DisciplineDepartment.LevelDisciplineId;
     FormRewardId   = DisciplineDepartment.FormDisciplineId;
     Id             = DisciplineDepartment.Id;
 }
Пример #2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="obj"></param>
        public void Update(hr_DisciplineDepartment obj)
        {
            var record = hr_DisciplineDepartmentServices.GetById(obj.Id);

            if (record == null)
            {
                return;
            }
            record.DecisionName      = obj.DecisionName;
            record.DepartmentId      = obj.DepartmentId;
            record.DecisionNumber    = obj.DecisionNumber;
            record.DecisionDate      = obj.DecisionDate;
            record.Reason            = obj.Reason;
            record.LevelDisciplineId = obj.LevelDisciplineId;
            record.MoneyAmount       = obj.MoneyAmount;
            record.Note             = obj.Note;
            record.DecisionMaker    = obj.DecisionMaker;
            record.AttachFileName   = obj.AttachFileName;
            record.FormDisciplineId = obj.FormDisciplineId;
            hr_DisciplineDepartmentServices.Update(record);
        }
Пример #3
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="obj"></param>
 public void Insert(hr_DisciplineDepartment obj)
 {
     hr_DisciplineDepartmentServices.Create(obj);
 }