Пример #1
0
        public Academy AddAcademy(AddAcademyRequest request)
        {
            Academy academy = null;

            if (request != null && request.Academy != null)
            {
                var dataAccess = new AcademyDataAccess(request.Context);

                academy = dataAccess.Add(request.Academy);
            }

            return(academy);
        }
Пример #2
0
        public Academy AddAcademy([FromBody] Academy academy)
        {
            if (academy != null)
            {
                var business = AcademyBusiness.Instance;
                var request  = new AddAcademyRequest(this.Context);
                request.Academy = academy;

                academy = business.AddAcademy(request);
            }

            return(academy);
        }