This commit is contained in:
2024-03-07 11:26:18 +01:00
parent 5cbfbff4ac
commit 5783fb1f2e
3 changed files with 30 additions and 2 deletions

View File

@@ -43,6 +43,8 @@ const historyItems = computed(() => {
items = dataStore.historyItems.filter(i => i.inventoryitem === elementId)
} else if(type === "product") {
items = dataStore.historyItems.filter(i => i.product === elementId)
} else if(type === "profile") {
items = dataStore.historyItems.filter(i => i.profile === elementId)
}
return items
@@ -76,6 +78,8 @@ const addHistoryItem = async () => {
addHistoryItemData.value.inventoryitem = elementId
} else if(type === "product") {
addHistoryItemData.value.product = elementId
} else if(type === "profile") {
addHistoryItemData.value.profile = elementId
}

View File

@@ -5,11 +5,14 @@
const templateColumns = [
{
key: 'employeeNumber',
label: "MA-Nummer:",
sortable: true
},{
key: 'fullName',
label: "Name:",
sortable: true
},
{
},{
key: "email",
label: "E-Mail:",
sortable: true

View File

@@ -1,4 +1,6 @@
<script setup>
import HistoryDisplay from "~/components/HistoryDisplay.vue";
const dataStore = useDataStore()
const route = useRoute()
@@ -23,10 +25,14 @@ setupPage()
:items="[
{
label: 'Informationen'
},{
label: 'Logbuch'
},{
label: 'Zeiterfassung'
},{
label: 'Vertragsdaten'
},{
label: 'Dokumente'
}
]"
>
@@ -74,8 +80,23 @@ setupPage()
v-model="itemInfo.employeeNumber"
/>
</UFormGroup>
<UFormGroup
label="E-Mail"
class="w-120"
>
<UInput
v-model="itemInfo.email"
/>
</UFormGroup>
</InputGroup>
</div>
<div v-if="item.label === 'Logbuch'">
<HistoryDisplay
type="profile"
v-if="itemInfo"
:element-id="itemInfo.id"
/>
</div>
<div v-if="item.label === 'Vertragsdaten'">
<Toolbar>
<UButton