コード例 #1
0
        public IHttpActionResult DeleteSale(string ord_num)
        {
            IRepository <sales> sale_repo = Repos.get_sales_repo();

            if ((sale_repo as SalesRepositoryDB).removeSalesOrder(ord_num))
            {
                return(StatusCode(HttpStatusCode.OK));
            }

            return(StatusCode(HttpStatusCode.NotModified));
        }
コード例 #2
0
        public IHttpActionResult AddSales(sales addedSales)
        {
            IRepository <sales> sale_repo = Repos.get_sales_repo();

            if (sale_repo.Add(addedSales))
            {
                return(StatusCode(HttpStatusCode.Created));
            }

            return(StatusCode(HttpStatusCode.NotModified));
        }