Last change
on this file since a55ef91 was a55ef91, checked in by DimitarSlezenkovski <dslezenkovski@…>, 5 years ago |
Update & add service
|
-
Property mode
set to
100644
|
File size:
685 bytes
|
Line | |
---|
1 | using System.Linq;
|
---|
2 | using FarmatikoData.Models;
|
---|
3 | using FarmatikoServices.FarmatikoServiceInterfaces;
|
---|
4 | using Microsoft.AspNetCore.Mvc;
|
---|
5 |
|
---|
6 | namespace Farmatiko.Controllers
|
---|
7 | {
|
---|
8 | [ApiController]
|
---|
9 | [Route("[controller]/[action]")]
|
---|
10 | public class HealthcareWorkerController : Controller
|
---|
11 | {
|
---|
12 | private IHealthcareWorkerService _healthcareWorkerService;
|
---|
13 | public HealthcareWorkerController(IHealthcareWorkerService healthcareWorkerService)
|
---|
14 | {
|
---|
15 | _healthcareWorkerService = healthcareWorkerService;
|
---|
16 | }
|
---|
17 |
|
---|
18 | [HttpGet]
|
---|
19 | public IQueryable<HealthcareWorkers> Get()
|
---|
20 | {
|
---|
21 | return _healthcareWorkerService.GetAll();
|
---|
22 | }
|
---|
23 |
|
---|
24 | }
|
---|
25 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.