Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: Basic structure for Council domain #333

Merged
merged 2 commits into from
Feb 3, 2025
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
@@ -0,0 +1,13 @@
package com.wafflestudio.csereal.core.council.api.v2

import com.wafflestudio.csereal.core.council.service.CouncilService
import org.springframework.web.bind.annotation.RequestMapping
import org.springframework.web.bind.annotation.RestController

@RestController
@RequestMapping("/api/v2/council")
class CouncilController(
private val councilService: CouncilService
) {
// ...
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package com.wafflestudio.csereal.core.council.database

import com.wafflestudio.csereal.common.config.BaseTimeEntity
import jakarta.persistence.Entity

@Entity(name = "council")
class CouncilEntity(
// ...
) : BaseTimeEntity() {
// ...
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package com.wafflestudio.csereal.core.council.database

import org.springframework.data.jpa.repository.JpaRepository

interface CouncilRepository : JpaRepository<CouncilEntity, Long> {
// ...
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package com.wafflestudio.csereal.core.council.dto

import java.time.LocalDateTime

data class CouncilDto(
val id: Long,
val createdAt: LocalDateTime?,
val modifiedAt: LocalDateTime?
// ...
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package com.wafflestudio.csereal.core.council.service

import com.wafflestudio.csereal.core.council.database.CouncilRepository
import org.springframework.stereotype.Service

@Service
class CouncilService(
private val councilRepository: CouncilRepository
) {
// ...
}
Loading