fix: unexpected/ missing props
This commit is contained in:
parent
5468766d87
commit
d803f3d490
@ -2,7 +2,7 @@
|
|||||||
import { _ } from "svelte-i18n";
|
import { _ } from "svelte-i18n";
|
||||||
import { clickOutside } from "../base/outsideclick";
|
import { clickOutside } from "../base/outsideclick";
|
||||||
|
|
||||||
export let modal_open;
|
let modal_open = false;
|
||||||
(function () {
|
(function () {
|
||||||
document.onkeydown = function (e) {
|
document.onkeydown = function (e) {
|
||||||
e = e || window.event;
|
e = e || window.event;
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<script>
|
<script>
|
||||||
import { _ } from "svelte-i18n";
|
import { _ } from "svelte-i18n";
|
||||||
|
|
||||||
export let detailsLink;
|
export let detailsLink = null;
|
||||||
export let detailsAction;
|
export let detailsAction = null;
|
||||||
export let deleteEnabled;
|
export let deleteEnabled;
|
||||||
export let deleteAction;
|
export let deleteAction;
|
||||||
</script>
|
</script>
|
||||||
|
@ -5,14 +5,14 @@
|
|||||||
import { createEventDispatcher } from "svelte";
|
import { createEventDispatcher } from "svelte";
|
||||||
import toast from "svelte-french-toast";
|
import toast from "svelte-french-toast";
|
||||||
export let modal_open;
|
export let modal_open;
|
||||||
export let delete_station;
|
export let delete_client;
|
||||||
const dispatch = createEventDispatcher();
|
const dispatch = createEventDispatcher();
|
||||||
function cancelDelete() {
|
function cancelDelete() {
|
||||||
modal_open = false;
|
modal_open = false;
|
||||||
dispatch("cancelDelete", { id: delete_station.id });
|
dispatch("cancelDelete", { id: delete_client.id });
|
||||||
}
|
}
|
||||||
function deleteClient() {
|
function deleteClient() {
|
||||||
StatsClientService.statsClientControllerRemove(delete_station.id, true)
|
StatsClientService.statsClientControllerRemove(delete_client.id, true)
|
||||||
.then((resp) => {
|
.then((resp) => {
|
||||||
toast($_("statsclient-deleted"));
|
toast($_("statsclient-deleted"));
|
||||||
location.replace("./");
|
location.replace("./");
|
||||||
|
@ -25,12 +25,7 @@
|
|||||||
{$_("create-a-new-statsclient")}
|
{$_("create-a-new-statsclient")}
|
||||||
</button>
|
</button>
|
||||||
{/if}
|
{/if}
|
||||||
<StatsClientsOverview
|
<StatsClientsOverview bind:current_clients />
|
||||||
bind:current_clients
|
|
||||||
bind:modal_open
|
|
||||||
bind:new_client
|
|
||||||
bind:copy_modal_open
|
|
||||||
/>
|
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
{#if store.state.jwtinfo.userdetails.permissions.includes("STATSCLIENT:CREATE")}
|
{#if store.state.jwtinfo.userdetails.permissions.includes("STATSCLIENT:CREATE")}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user