Changeset 0a694bb for Farmatiko/Controllers/AdminController.cs
- Timestamp:
- 02/07/21 16:25:56 (4 years ago)
- Branches:
- master
- Children:
- e0cdea2
- Parents:
- ac51326
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Farmatiko/Controllers/AdminController.cs
rac51326 r0a694bb 44 44 [HttpPost] 45 45 [Route("api/pharmacyhead/add")] 46 public async Task<IActionResult> AddPharmacyHead([FromBody]PharmacyHead pharmacyHead)46 public async Task<IActionResult> AddPharmacyHead([FromBody]PharmacyHeadDto pharmacyHead) 47 47 { 48 await _service.AddPharmacyHead(pharmacyHead); 49 return Ok("Pharmacy added."); 48 bool Success = await _service.AddPharmacyHead(pharmacyHead); 49 if (Success) 50 return Ok("Pharmacy added."); 51 return BadRequest(); 50 52 } 51 53 52 [Http Delete]54 [HttpPost] 53 55 [Route("api/pharmacyhead/delete/{Id}")] 54 56 public async Task<IActionResult> RemovePharmacyHead([FromRoute] int Id) … … 57 59 return Ok(); 58 60 } 59 [Http Delete]61 [HttpPost] 60 62 [Route("api/pharmacyhead/requests/{Id}")] 61 63 public IActionResult RejectRequest([FromRoute] int Id)
Note:
See TracChangeset
for help on using the changeset viewer.