Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
@RequestMapping("api/v1/events")
public class EventController {

@GetMapping
@GetMapping("/community")
public List<EventModel> getAllCommunityEvents() {
// Placeholder implementation
return List.of();
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package com.api.demo.controllers;

import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HomeController {

@GetMapping("/")
public Map<String, Object> index() {
// Get all available routes in the application
// Build response with welcome message and routes
Map<String, Object> response = new LinkedHashMap<>();
response.put("message", "🚀 Welcome to The Evynt Event Planning API");
response.put("version", "v1.0");
response.put("description", "Event planning application with user management and event creation");

return response;
}

}
21 changes: 21 additions & 0 deletions event-planner/api/demo/src/main/resources/application-local.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
spring:
h2:
console:
enabled: true
datasource:
url: jdbc:postgresql://localhost:5432/postgres
username: postgres
password: postgres
jpa:
hibernate:
ddl-auto: update
database-platform: org.hibernate.dialect.PostgreSQLDialect
show-sql: true
sql:
init:
# Disable SQL initialization
mode: never
config:
active:
on-profile: local
import: optional:file:.env.properties
22 changes: 22 additions & 0 deletions event-planner/api/demo/src/main/resources/application-prod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
spring:
profiles: prod
h2:
console:
enabled: true
datasource:
url: ${SPRING_DATASOURCE_URL}
username: ${SPRING_DATASOURCE_USERNAME}
password: ${SPRING_DATASOURCE_PASSWORD}
jpa:
hibernate:
ddl-auto: update
database-platform: org.hibernate.dialect.PostgreSQLDialect
show-sql: true
sql:
init:
# Disable SQL initialization
mode: never
config:
active:
on-profile: prod
import: optional:file:.env.properties
Empty file.
22 changes: 4 additions & 18 deletions event-planner/api/demo/src/main/resources/application.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,5 @@
spring:
h2:
console:
enabled: true
datasource:
url: ${SPRING_DATASOURCE_URL}
username: ${SPRING_DATASOURCE_USERNAME}
password: ${SPRING_DATASOURCE_PASSWORD}
jpa:
hibernate:
ddl-auto: update
database-platform: org.hibernate.dialect.PostgreSQLDialect
show-sql: true
sql:
init:
# Disable SQL initialization
mode: never
config:
import: optional:file:.env.properties
profiles:
active:
- ${SPRING_PROFILES_ACTIVE}

Empty file.