This commit is contained in:
xds
2025-10-31 15:31:55 +03:00
parent 040da34ff7
commit 7972ea0fdf
117 changed files with 3691 additions and 2013 deletions

View File

@@ -1,23 +1,19 @@
package space.luminic.finance.models
import org.springframework.data.annotation.Id
import org.springframework.data.mongodb.core.mapping.DBRef
import org.springframework.data.mongodb.core.mapping.Document
import org.springframework.data.annotation.CreatedDate
import org.springframework.data.annotation.LastModifiedDate
import java.time.Instant
@Document(collection = "subscriptions")
data class Subscription(
@Id val id: String? = null,
@DBRef val user: User? = null,
var id: Int? = null,
val user: User,
val endpoint: String,
val auth: String,
val p256dh: String,
var isActive: Boolean,
val createdAt: Instant = Instant.now(),
)
@CreatedDate val createdAt: Instant? = null,
@LastModifiedDate val updatedAt: Instant? = null,
)
data class SubscriptionDTO (
val endpoint: String,
val keys: Map<String, String>
)