public IActionResult Post(StaffModel staffModel)
        {
            try {
                var staff = _mapper.Map <Staff>(staffModel);
                //  var location = _linkGenerator.GetPathByAction("staff-members/{id}", "Staff", new { id = staff.Staff_Id });

                //if (string.IsNullOrWhiteSpace(location)) {

                //    return BadRequest("Could not show current staff");
                //}

                assignmentQueries.Add(staff);
                if (assignmentQueries.saveChangestoDatabase())
                {
                    return(Ok(staffModel));
                    //return Created($"/api/Staff/staff-members/{staff.Staff_Id}", _mapper.Map<StaffModel>(staff));
                }
                else
                {
                    return(BadRequest("Data Can not be added"));
                }
            } catch (Exception) {
                return(this.StatusCode(StatusCodes.Status500InternalServerError, "Sever not responding"));
            };
        }
 public IActionResult PostInventory(InventoryModel inventoryModel)
 {
     try
     {
         Inventory inventory = _mapper.Map <Inventory>(inventoryModel);
         assignmentQueries.Add(inventory);
         assignmentQueries.saveChangestoDatabase();
         return(Ok(_mapper.Map <InventoryModel>(inventory)));
     }
     catch (Exception)
     {
         return(StatusCode(StatusCodes.Status500InternalServerError, "Server Error"));
     }
 }