-
Notifications
You must be signed in to change notification settings - Fork 46
/
Copy pathCompanyController.java
32 lines (24 loc) · 1.04 KB
/
CompanyController.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
package com.intuit.developer.sampleapp.webhooks.controllers;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import com.intuit.developer.sampleapp.webhooks.domain.CompanyConfig;
import com.intuit.developer.sampleapp.webhooks.service.CompanyConfigService;
/**
* Controller class for company config enpoints
* @author dderose
*
*/
@RestController
public class CompanyController {
@Autowired
private CompanyConfigService companyConfigService;
@RequestMapping(value = "/companyConfigs", method = RequestMethod.GET)
public ResponseEntity<Iterable<CompanyConfig>> listAllRealmConfigs() {
Iterable<CompanyConfig> log = companyConfigService.getAllCompanyConfigs();
return new ResponseEntity<>(log, HttpStatus.OK);
}
}