mirror of
https://github.com/MewoLab/AquaDX.git
synced 2025-10-26 04:22:38 +00:00
[+] Add "type" field to settings/get
This commit is contained in:
parent
2d229b82c3
commit
44bab8c0c7
@ -7,6 +7,7 @@ import icu.samnyan.aqua.net.db.AquaNetUserRepo
|
|||||||
import icu.samnyan.aqua.net.db.AquaUserServices
|
import icu.samnyan.aqua.net.db.AquaUserServices
|
||||||
import org.springframework.web.bind.annotation.RestController
|
import org.springframework.web.bind.annotation.RestController
|
||||||
import kotlin.reflect.full.findAnnotation
|
import kotlin.reflect.full.findAnnotation
|
||||||
|
import kotlin.reflect.jvm.jvmErasure
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@API("/api/v2/settings")
|
@API("/api/v2/settings")
|
||||||
@ -22,7 +23,8 @@ class SettingsApi(
|
|||||||
val fieldDesc = fields.map { (f, an) -> mapOf(
|
val fieldDesc = fields.map { (f, an) -> mapOf(
|
||||||
"key" to f.name,
|
"key" to f.name,
|
||||||
"name" to an.name,
|
"name" to an.name,
|
||||||
"desc" to an.desc
|
"desc" to an.desc,
|
||||||
|
"type" to f.returnType.jvmErasure.simpleName
|
||||||
) }
|
) }
|
||||||
|
|
||||||
@API("get")
|
@API("get")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user