Ejemplo n.º 1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        public static TimeSheetCodeModel Create(TimeSheetCodeModel model)
        {
            var entity = new hr_TimeSheetCode();

            model.FillEntity(ref entity);
            return(new TimeSheetCodeModel(hr_TimeSheetCodeServices.Create(entity)));
        }
Ejemplo n.º 2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        public static void Update(TimeSheetCodeModel model)
        {
            var record = hr_TimeSheetCodeServices.GetById(model.Id);

            if (record == null)
            {
                return;
            }
            model.FillEntity(ref record);
            record.EditedDate = DateTime.Now;

            hr_TimeSheetCodeServices.Update(record);
        }