Skip to content

Commit

Permalink
#1 - fix css
Browse files Browse the repository at this point in the history
  • Loading branch information
obriensystems committed Mar 2, 2021
1 parent f5b8cdc commit 5469482
Show file tree
Hide file tree
Showing 8 changed files with 27 additions and 7 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,9 @@ Event Stream
launch
http://127.0.0.1:8081/event/

API
http://127.0.0.1:8081/event/health/

swagger
http://127.0.0.1:8081/event/swagger-ui.html#/health-api-controller/health

Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ default HealthApiDelegate getDelegate() {
@ApiResponses(value = {
@ApiResponse(code = 200, message = "ok", response = Health.class),
@ApiResponse(code = 200, message = "Unexpected error") })
@RequestMapping(value = "/health/",
@RequestMapping(value = "/health",
produces = { "application/json" },
method = RequestMethod.GET)
default ResponseEntity<Health> health() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import java.util.Optional;

@Controller
@RequestMapping("${openapi.backendATBStub.base-path:/v1}")
@RequestMapping("/")
public class HealthApiController implements HealthApi {

private final HealthApiDelegate delegate;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public class HealthApiDelegateService implements HealthApiDelegate {
public ResponseEntity<Health> health() {
Health health = new Health();
health.setKey("state");
health.setValue("ok");
health.setValue("OK");
return ResponseEntity.ok(health);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ ApiInfo apiInfo() {
}

@Bean
public Docket customImplementation(ServletContext servletContext, @Value("${openapi.eventstream.base-path:/v1}") String basePath) {
public Docket customImplementation(ServletContext servletContext, @Value("") String basePath) {
return new Docket(DocumentationType.SWAGGER_2)
.select()
.apis(RequestHandlerSelectors.basePackage("systems.eventstream.field"))
Expand Down
3 changes: 2 additions & 1 deletion src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ server.port=8081
spring.jackson.date-format=systems.eventstream.field.swagger.RFC3339DateFormat
spring.jackson.serialization.WRITE_DATES_AS_TIMESTAMPS=false

welcome.message=Event Stream
welcome.message=Event Stream
spring.thymeleaf.cache=false
15 changes: 15 additions & 0 deletions src/main/resources/static/css/main.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
body {
padding-top: 5rem;
}
.starter-template {
padding: 3rem 1.5rem;
text-align: center;
}

h1{
color:#6060FF;
}

h2{
color:#FF6060;
}
4 changes: 2 additions & 2 deletions src/main/resources/templates/welcome.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
</nav>
<main role="main" class="container">
<div class="starter-template">
<h1>Event Stream</h1>
<h1>Report</h1>
<h2>
<span th:text="'Hello, ' + ${message}"></span>
<span th:text="'Details for: ' + ${message}"></span>
</h2>
</div>
<ol>
Expand Down

0 comments on commit 5469482

Please sign in to comment.