Retail_manager/RMDataManager/Controllers/InventoryController.cs
s459315 f118635029 Added admin endpoints
Added inventory and sales api endpoints
2022-08-02 19:32:39 +02:00

28 lines
652 B
C#

using RMDataManagerLibrary.DataAcccess;
using RMDataManagerLibrary.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;
namespace RMDataManager.Controllers
{
[Authorize]
public class InventoryController : ApiController
{
public List<InventoryModel> Get()
{
InventoryData data = new InventoryData();
return data.GetInventory();
}
public void Post(InventoryModel item)
{
InventoryData data = new InventoryData();
data.SaveInventoryRecord(item);
}
}
}