aboutsummaryrefslogtreecommitdiff
path: root/kvision-modules
diff options
context:
space:
mode:
authorRobert Jaros <rjaros@finn.pl>2020-02-09 00:01:31 +0100
committerRobert Jaros <rjaros@finn.pl>2020-02-09 00:01:31 +0100
commitf8ff7ea49d2154d249c79a8c9591614793213e9e (patch)
treea89b957e33e621f1cb1fda103d145c77187cec74 /kvision-modules
parent62d0118f8d35c202babfff661e1bbff4d4465498 (diff)
downloadkvision-f8ff7ea49d2154d249c79a8c9591614793213e9e.tar.gz
kvision-f8ff7ea49d2154d249c79a8c9591614793213e9e.tar.bz2
kvision-f8ff7ea49d2154d249c79a8c9591614793213e9e.zip
Fix constructor parameters order
Diffstat (limited to 'kvision-modules')
-rw-r--r--kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemote.kt8
-rw-r--r--kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemoteInput.kt6
2 files changed, 7 insertions, 7 deletions
diff --git a/kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemote.kt b/kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemote.kt
index 0c1df008..550de427 100644
--- a/kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemote.kt
+++ b/kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemote.kt
@@ -50,10 +50,10 @@ import pl.treksoft.kvision.utils.SnOn
*/
@Suppress("TooManyFunctions")
open class SelectRemote<T : Any>(
- value: String? = null,
serviceManager: KVServiceManager<T>,
function: suspend T.(String?, String?, String?) -> List<RemoteOption>,
stateFunction: (() -> String)? = null,
+ value: String? = null,
name: String? = null,
multiple: Boolean = false,
ajaxOptions: AjaxOptions? = null,
@@ -160,7 +160,7 @@ open class SelectRemote<T : Any>(
private val idc = "kv_form_SelectRemote_$counter"
final override val input: SelectRemoteInput<T> = SelectRemoteInput(
- value, serviceManager, function, stateFunction, multiple, ajaxOptions, preload,
+ serviceManager, function, stateFunction, value, multiple, ajaxOptions, preload,
setOf("form-control")
).apply {
this.id = idc
@@ -268,18 +268,18 @@ open class SelectRemote<T : Any>(
* It takes the same parameters as the constructor of the built component.
*/
fun <T : Any> Container.selectRemote(
- value: String? = null,
serviceManager: KVServiceManager<T>,
function: suspend T.(String?, String?, String?) -> List<RemoteOption>, stateFunction: (() -> String)? = null,
+ value: String? = null,
name: String? = null, multiple: Boolean = false, ajaxOptions: AjaxOptions? = null, preload: Boolean = false,
label: String? = null, rich: Boolean = false, init: (SelectRemote<T>.() -> Unit)? = null
): SelectRemote<T> {
val selectRemote =
SelectRemote(
- value,
serviceManager,
function,
stateFunction,
+ value,
name,
multiple,
ajaxOptions,
diff --git a/kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemoteInput.kt b/kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemoteInput.kt
index 391b53ef..96277728 100644
--- a/kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemoteInput.kt
+++ b/kvision-modules/kvision-bootstrap-select-remote/src/main/kotlin/pl/treksoft/kvision/form/select/SelectRemoteInput.kt
@@ -55,10 +55,10 @@ external fun decodeURIComponent(encodedURI: String): String
*/
@UseExperimental(ImplicitReflectionSerializer::class)
open class SelectRemoteInput<T : Any>(
- value: String? = null,
serviceManager: KVServiceManager<T>,
function: suspend T.(String?, String?, String?) -> List<RemoteOption>,
private val stateFunction: (() -> String)? = null,
+ value: String? = null,
multiple: Boolean = false,
ajaxOptions: AjaxOptions? = null,
private val preload: Boolean = false,
@@ -190,10 +190,10 @@ open class SelectRemoteInput<T : Any>(
* It takes the same parameters as the constructor of the built component.
*/
fun <T : Any> Container.selectRemoteInput(
- value: String? = null,
serviceManager: KVServiceManager<T>,
function: suspend T.(String?, String?, String?) -> List<RemoteOption>,
stateFunction: (() -> String)? = null,
+ value: String? = null,
multiple: Boolean = false,
ajaxOptions: AjaxOptions? = null,
preload: Boolean = false,
@@ -201,10 +201,10 @@ fun <T : Any> Container.selectRemoteInput(
): SelectRemoteInput<T> {
val selectRemoteInput =
SelectRemoteInput(
- value,
serviceManager,
function,
stateFunction,
+ value,
multiple,
ajaxOptions,
preload,