refactor(core): MP-25 Move User and AuthToken to core-domain
This commit is contained in:
@@ -46,6 +46,7 @@ kotlin {
|
||||
|
||||
api(projects.core.coreUtils)
|
||||
api(projects.core.coreDomain)
|
||||
api(project(":frontend:core:domain"))
|
||||
|
||||
// Kotlinx core dependencies (coroutines, serialization, datetime)
|
||||
implementation(libs.bundles.kotlinx.core)
|
||||
|
||||
@@ -39,21 +39,3 @@ data class PingData(
|
||||
val service: String
|
||||
)
|
||||
|
||||
/**
|
||||
* Minimale User- und Auth-Models für Shared-Kernel (Quick-Fix für Build).
|
||||
* Hinweis: Für MP-25 können diese in :frontend:core:domain verschoben/ausgebaut werden.
|
||||
*/
|
||||
@Serializable
|
||||
data class AuthToken(
|
||||
val accessToken: String,
|
||||
val tokenType: String = "Bearer",
|
||||
val expiresAtEpochMillis: Long? = null
|
||||
)
|
||||
|
||||
@Serializable
|
||||
data class User(
|
||||
val id: String,
|
||||
val username: String,
|
||||
val displayName: String? = null,
|
||||
val roles: List<String> = emptyList()
|
||||
)
|
||||
|
||||
+2
-2
@@ -1,8 +1,8 @@
|
||||
package at.mocode.shared.presentation.actions
|
||||
|
||||
import at.mocode.shared.presentation.state.Notification
|
||||
import at.mocode.shared.domain.model.User
|
||||
import at.mocode.shared.domain.model.AuthToken
|
||||
import at.mocode.frontend.core.domain.models.User
|
||||
import at.mocode.frontend.core.domain.models.AuthToken
|
||||
|
||||
sealed class AppAction {
|
||||
// Auth Actions
|
||||
|
||||
+2
-2
@@ -1,8 +1,8 @@
|
||||
package at.mocode.shared.presentation.state
|
||||
|
||||
import kotlinx.serialization.Serializable
|
||||
import at.mocode.shared.domain.model.User
|
||||
import at.mocode.shared.domain.model.AuthToken
|
||||
import at.mocode.frontend.core.domain.models.User
|
||||
import at.mocode.frontend.core.domain.models.AuthToken
|
||||
|
||||
@Serializable
|
||||
data class AppState(
|
||||
|
||||
Reference in New Issue
Block a user