// GET: api/ProductType
        public List<ProductType> Get()
        {
            ProductTypeFacade facade = new ProductTypeFacade(db);
            List<ProductType> AllProductTypes = facade.Get();

            return AllProductTypes;
        }
 public void Post([FromBody]ProductType producttype)
 {
     ProductTypeFacade facade = new ProductTypeFacade(db);
     if (facade.Get(producttype.ID) == null)
     {
         facade.Insert(producttype);
     }
     else
     {
         facade.Update(producttype);
     }
 }
 // GET: api/ProductType/5
 public ProductType Get(int id)
 {
     ProductTypeFacade facade = new ProductTypeFacade(db);
     return facade.Get(id);
 }