Added Remove Button to CostCentre in IncomingInvoices
This commit is contained in:
@@ -352,20 +352,30 @@ const createIncomingInvoice = async () => {
|
|||||||
label="Kostenstelle"
|
label="Kostenstelle"
|
||||||
class=" mb-3"
|
class=" mb-3"
|
||||||
>
|
>
|
||||||
<USelectMenu
|
<InputGroup>
|
||||||
:options="dataStore.getCostCentresComposed"
|
<USelectMenu
|
||||||
option-attribute="label"
|
:options="dataStore.getCostCentresComposed"
|
||||||
value-attribute="id"
|
option-attribute="label"
|
||||||
searchable
|
value-attribute="id"
|
||||||
:search-attributes="['label']"
|
searchable
|
||||||
searchable-placeholder="Suche..."
|
:search-attributes="['label']"
|
||||||
v-model="item.costCentre"
|
searchable-placeholder="Suche..."
|
||||||
>
|
v-model="item.costCentre"
|
||||||
<template #label>
|
>
|
||||||
{{dataStore.getCostCentresComposed.find(account => account.id === item.costCentre) ? dataStore.getCostCentresComposed.find(account => account.id === item.costCentre).label : "Keine Kostenstelle ausgewählt" }}
|
<template #label>
|
||||||
</template>
|
{{dataStore.getCostCentresComposed.find(account => account.id === item.costCentre) ? dataStore.getCostCentresComposed.find(account => account.id === item.costCentre).label : "Keine Kostenstelle ausgewählt" }}
|
||||||
|
</template>
|
||||||
|
|
||||||
|
</USelectMenu>
|
||||||
|
<UButton
|
||||||
|
variant="outline"
|
||||||
|
color="rose"
|
||||||
|
v-if="item.costCentre"
|
||||||
|
icon="i-heroicons-x-mark"
|
||||||
|
@click="item.costCentre = null"
|
||||||
|
/>
|
||||||
|
</InputGroup>
|
||||||
|
|
||||||
</USelectMenu>
|
|
||||||
</UFormGroup>
|
</UFormGroup>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -324,20 +324,29 @@ const updateIncomingInvoice = async () => {
|
|||||||
label="Kostenstelle"
|
label="Kostenstelle"
|
||||||
class=" mb-3"
|
class=" mb-3"
|
||||||
>
|
>
|
||||||
<USelectMenu
|
<InputGroup>
|
||||||
:options="dataStore.getCostCentresComposed"
|
<USelectMenu
|
||||||
option-attribute="label"
|
:options="dataStore.getCostCentresComposed"
|
||||||
value-attribute="id"
|
option-attribute="label"
|
||||||
searchable
|
value-attribute="id"
|
||||||
:search-attributes="['label']"
|
searchable
|
||||||
searchable-placeholder="Suche..."
|
:search-attributes="['label']"
|
||||||
v-model="item.costCentre"
|
searchable-placeholder="Suche..."
|
||||||
>
|
v-model="item.costCentre"
|
||||||
<template #label>
|
>
|
||||||
{{dataStore.getCostCentresComposed.find(account => account.id === item.costCentre) ? dataStore.getCostCentresComposed.find(account => account.id === item.costCentre).label : "Keine Kostenstelle ausgewählt" }}
|
<template #label>
|
||||||
</template>
|
{{dataStore.getCostCentresComposed.find(account => account.id === item.costCentre) ? dataStore.getCostCentresComposed.find(account => account.id === item.costCentre).label : "Keine Kostenstelle ausgewählt" }}
|
||||||
|
</template>
|
||||||
|
|
||||||
</USelectMenu>
|
</USelectMenu>
|
||||||
|
<UButton
|
||||||
|
variant="outline"
|
||||||
|
color="rose"
|
||||||
|
v-if="item.costCentre"
|
||||||
|
icon="i-heroicons-x-mark"
|
||||||
|
@click="item.costCentre = null"
|
||||||
|
/>
|
||||||
|
</InputGroup>
|
||||||
</UFormGroup>
|
</UFormGroup>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user