public HttpResponseMessage GetMonthlyDiscountFactorBond(HttpRequestMessage request, int MonthlyDiscountFactorBond_Id)
        {
            return(GetHttpResponse(request, () =>
            {
                HttpResponseMessage response = null;

                MonthlyDiscountFactorBond monthlydiscountfactorbond = _IFRS9Service.GetMonthlyDiscountFactorBond(MonthlyDiscountFactorBond_Id);

                // notice no need to create a seperate model object since MonthlyDiscountFactorBond entity will do just fine
                response = request.CreateResponse <MonthlyDiscountFactorBond>(HttpStatusCode.OK, monthlydiscountfactorbond);

                return response;
            }));
        }
        public HttpResponseMessage DeleteMonthlyDiscountFactorBond(HttpRequestMessage request, [FromBody] int MonthlyDiscountFactorBond_Id)
        {
            return(GetHttpResponse(request, () =>
            {
                HttpResponseMessage response = null;

                // not that calling the WCF service here will authenticate access to the data
                MonthlyDiscountFactorBond monthlydiscountfactorbond = _IFRS9Service.GetMonthlyDiscountFactorBond(MonthlyDiscountFactorBond_Id);

                if (monthlydiscountfactorbond != null)
                {
                    _IFRS9Service.DeleteMonthlyDiscountFactorBond(MonthlyDiscountFactorBond_Id);

                    response = request.CreateResponse(HttpStatusCode.OK);
                }
                else
                {
                    response = request.CreateErrorResponse(HttpStatusCode.NotFound, "No monthlydiscountfactorbond found under that Id.");
                }

                return response;
            }));
        }
        public HttpResponseMessage UpdateMonthlyDiscountFactorBond(HttpRequestMessage request, [FromBody] MonthlyDiscountFactorBond monthlydiscountfactorbondModel)
        {
            return(GetHttpResponse(request, () =>
            {
                var monthlydiscountfactorbond = _IFRS9Service.UpdateMonthlyDiscountFactorBond(monthlydiscountfactorbondModel);

                return request.CreateResponse <MonthlyDiscountFactorBond>(HttpStatusCode.OK, monthlydiscountfactorbond);
            }));
        }