예제 #1
0
        public virtual ApiEventResponseModel MapBOToModel(
            BOEvent boEvent)
        {
            var model = new ApiEventResponseModel();

            model.SetProperties(boEvent.Id, boEvent.ActualEndDate, boEvent.ActualStartDate, boEvent.BillAmount, boEvent.EventStatusId, boEvent.ScheduledEndDate, boEvent.ScheduledStartDate, boEvent.StudentNote, boEvent.TeacherNote);

            return(model);
        }
예제 #2
0
        public virtual BOEvent MapEFToBO(
            Event ef)
        {
            var bo = new BOEvent();

            bo.SetProperties(
                ef.Id,
                ef.ActualEndDate,
                ef.ActualStartDate,
                ef.BillAmount,
                ef.EventStatusId,
                ef.ScheduledEndDate,
                ef.ScheduledStartDate,
                ef.StudentNote,
                ef.TeacherNote);
            return(bo);
        }
예제 #3
0
        public virtual Event MapBOToEF(
            BOEvent bo)
        {
            Event efEvent = new Event();

            efEvent.SetProperties(
                bo.ActualEndDate,
                bo.ActualStartDate,
                bo.BillAmount,
                bo.EventStatusId,
                bo.Id,
                bo.ScheduledEndDate,
                bo.ScheduledStartDate,
                bo.StudentNote,
                bo.TeacherNote);
            return(efEvent);
        }
예제 #4
0
        public virtual BOEvent MapModelToBO(
            int id,
            ApiEventRequestModel model
            )
        {
            BOEvent boEvent = new BOEvent();

            boEvent.SetProperties(
                id,
                model.ActualEndDate,
                model.ActualStartDate,
                model.BillAmount,
                model.EventStatusId,
                model.ScheduledEndDate,
                model.ScheduledStartDate,
                model.StudentNote,
                model.TeacherNote);
            return(boEvent);
        }