moved subscriptions and licences requests to subpages & renaming
This commit is contained in:
@@ -1,12 +1,9 @@
|
||||
<script>
|
||||
import InputField from "$lib/components/InputField.svelte";
|
||||
import SmallLoader from "$lib/components/SmallLoader.svelte";
|
||||
import { onMount } from "svelte";
|
||||
import { applyAction, enhance } from "$app/forms";
|
||||
import { page } from "$app/stores";
|
||||
import { receive, send } from "$lib/utils/helpers";
|
||||
import { t } from "svelte-i18n";
|
||||
import { fly } from "svelte/transition";
|
||||
|
||||
/** @type {import('../../routes/auth/about/[id]/$types').ActionData} */
|
||||
export let form;
|
||||
@@ -88,10 +85,6 @@
|
||||
);
|
||||
}
|
||||
|
||||
onMount(() => {
|
||||
console.dir(user);
|
||||
});
|
||||
|
||||
/**
|
||||
* Sets the active tab
|
||||
* @param {string} tab - The tab to set as active
|
||||
@@ -277,14 +270,14 @@
|
||||
name="licence_status"
|
||||
type="select"
|
||||
label={$t("status")}
|
||||
bind:value={user.drivers_licence.status}
|
||||
bind:value={user.licence.status}
|
||||
options={licenceStatusOptions}
|
||||
/>
|
||||
<InputField
|
||||
name="licence_number"
|
||||
type="text"
|
||||
label={$t("licence_number")}
|
||||
bind:value={user.drivers_licence.licence_number}
|
||||
bind:value={user.licence.licence_number}
|
||||
placeholder={$t("placeholder.licence_number")}
|
||||
toUpperCase={true}
|
||||
/>
|
||||
@@ -292,20 +285,20 @@
|
||||
name="issued_date"
|
||||
type="date"
|
||||
label={$t("issued_date")}
|
||||
bind:value={user.drivers_licence.issued_date}
|
||||
bind:value={user.licence.issued_date}
|
||||
placeholder={$t("placeholder.issued_date")}
|
||||
/>
|
||||
<InputField
|
||||
name="expiration_date"
|
||||
type="date"
|
||||
label={$t("expiration_date")}
|
||||
bind:value={user.drivers_licence.expiration_date}
|
||||
bind:value={user.licence.expiration_date}
|
||||
placeholder={$t("placeholder.expiration_date")}
|
||||
/>
|
||||
<InputField
|
||||
name="country"
|
||||
label={$t("country")}
|
||||
bind:value={user.drivers_licence.country}
|
||||
bind:value={user.licence.country}
|
||||
placeholder={$t("placeholder.issuing_country")}
|
||||
/>
|
||||
<div class="licence-categories">
|
||||
@@ -323,8 +316,8 @@
|
||||
name="licence_categories[]"
|
||||
value={JSON.stringify(category)}
|
||||
label={category.category}
|
||||
checked={user.drivers_licence.licence_categories != null &&
|
||||
user.drivers_licence.licence_categories.some(
|
||||
checked={user.licence.licence_categories != null &&
|
||||
user.licence.licence_categories.some(
|
||||
(cat) => cat.category === category.category
|
||||
)}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user