Esempio n. 1
0
        /// <summary>
        /// Update payroll
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        public static PayrollInfoModel Update(PayrollInfoModel model)
        {
            var entity = new sal_PayrollInfo();

            // set entity props
            model.FillEntity(ref entity);
            // update
            return(new PayrollInfoModel(sal_PayrollInfoServices.Update(entity)));
        }
Esempio n. 2
0
        /// <summary>
        /// Create payroll
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        public static PayrollInfoModel Create(PayrollInfoModel model)
        {
            // init new entity
            var entity = new sal_PayrollInfo();

            // set entity props
            model.FillEntity(ref entity);
            // insert
            return(new PayrollInfoModel(sal_PayrollInfoServices.Create(entity)));
        }