Compare commits

..

No commits in common. "63a50f92e7ac13245a9cfa54bd7cacf3bb7ff9cb" and "2a6a39916a03c0466e63354e9f5ad7924cb59b6b" have entirely different histories.

6 changed files with 963 additions and 969 deletions

View File

@ -5,7 +5,6 @@
import { RunnerCardService, RunnerService } from "@odit/lfk-client-js"; import { RunnerCardService, RunnerService } from "@odit/lfk-client-js";
import Select from "svelte-select"; import Select from "svelte-select";
import Toastify from "toastify-js"; import Toastify from "toastify-js";
import { createEventDispatcher } from "svelte";
export let edit_modal_open; export let edit_modal_open;
export let current_cards; export let current_cards;
export let runner = {}; export let runner = {};
@ -22,10 +21,6 @@
$: runners = []; $: runners = [];
$: enabled = true; $: enabled = true;
$: processed_last_submit = true; $: processed_last_submit = true;
const dispatch = createEventDispatcher();
function dataUpdated() {
dispatch('dataUpdated',);
}
RunnerService.runnerControllerGetAll().then((val) => { RunnerService.runnerControllerGetAll().then((val) => {
runners = val.map((r) => { runners = val.map((r) => {
return { label: getRunnerLabel(r), value: r }; return { label: getRunnerLabel(r), value: r };
@ -70,7 +65,6 @@
}).showToast(); }).showToast();
current_cards[current_cards.findIndex((c) => c.id === id)] = result; current_cards[current_cards.findIndex((c) => c.id === id)] = result;
current_cards = current_cards; current_cards = current_cards;
dataUpdated();
}) })
.catch((err) => { .catch((err) => {
// //

View File

@ -54,7 +54,6 @@
bind:runner bind:runner
bind:editable bind:editable
bind:original_data bind:original_data
on:dataUpdated={(handler.setRows(current_cards))}
/> />
{/if} {/if}

View File

@ -9,12 +9,15 @@
on:input={() => { on:input={() => {
setTimeout(() => { setTimeout(() => {
if (`${selected}`.trim()) { if (`${selected}`.trim()) {
if(selected==="all"){ const value = selected;
handler.filter('', 'enabled') handler.filter(value, (card) => {
} if (
else{ card.enabled === value ||
handler.filter(selected, 'enabled') value === "all"
} )
return card;
return "";
});
} }
}, 50); }, 50);
}} }}
@ -22,8 +25,8 @@
name="statusfilter" name="statusfilter"
id="statusfilter" id="statusfilter"
> >
<option value="all">{$_('all')}</option> <option value="all">Alle</option>
<option value="true">{$_("enabled")}</option> <option value={true}>{$_("enabled")}</option>
<option value="false">{$_("disabled")}</option> <option value={false}>{$_("disabled")}</option>
</select> </select>
</th> </th>

View File

@ -26,7 +26,7 @@
name="groupfilter" name="groupfilter"
id="groupfilter" id="groupfilter"
> >
<option value="all">{$_('all')}</option> <option value="all">Alle</option>
{#each groups as g} {#each groups as g}
<option value={g.value}>{g.label}</option> <option value={g.value}>{g.label}</option>
{/each} {/each}

View File

@ -472,6 +472,5 @@
"you-have-to-provide-an-organization": "Du musst eine Organisation angeben", "you-have-to-provide-an-organization": "Du musst eine Organisation angeben",
"you-have-to-save-your-changes-to-generate-a-link": "Du musst deine Änderungen speichern, um einen Link zu generieren.", "you-have-to-save-your-changes-to-generate-a-link": "Du musst deine Änderungen speichern, um einen Link zu generieren.",
"you-must-create-at-least-one-card-or-cancel": "Du musst mindestens eine Blankokarte erstellen (oder abbrechen).", "you-must-create-at-least-one-card-or-cancel": "Du musst mindestens eine Blankokarte erstellen (oder abbrechen).",
"zip-postal-code": "Postleitzahl", "zip-postal-code": "Postleitzahl"
"all": "Alle"
} }

View File

@ -472,6 +472,5 @@
"you-have-to-provide-an-organization": "You have to provide an organization", "you-have-to-provide-an-organization": "You have to provide an organization",
"you-have-to-save-your-changes-to-generate-a-link": "You have to save your changes to generate a link.", "you-have-to-save-your-changes-to-generate-a-link": "You have to save your changes to generate a link.",
"you-must-create-at-least-one-card-or-cancel": "You must create at least one card (or cancel).", "you-must-create-at-least-one-card-or-cancel": "You must create at least one card (or cancel).",
"zip-postal-code": "ZIP/ postal code", "zip-postal-code": "ZIP/ postal code"
"all": "all"
} }