Continue to implement opinion

improve target reference
Improve Tests for Opinion
fix SQL:upsert_opinion
This commit is contained in:
2020-02-14 01:26:47 +01:00
parent 60bd24e653
commit 471013984c
42 changed files with 683 additions and 137 deletions

View File

@@ -1,14 +1,11 @@
package fr.dcproject.entity.request
import fr.dcproject.entity.CitizenRef
import fr.postgresjson.entity.EntityI
import io.ktor.application.ApplicationCall
interface Request
interface RequestBuilder<E: EntityI> : Request {
fun create(): E
interface RequestBuilder<E> {
suspend fun getContent(call: ApplicationCall): E
}
interface RequestBuilderWithCreator<C: CitizenRef, E: EntityI> : Request {
fun create(citizen: C): E
}
suspend fun <E> ApplicationCall.getContent(builder: RequestBuilder<E>) = builder.getContent(this)