[pricelist] clean style tags

This commit is contained in:
Tim Gröger 2021-04-17 14:17:42 +02:00
parent 6e74105f38
commit e2b46d96b9
1 changed files with 32 additions and 28 deletions

View File

@ -3,9 +3,9 @@
<q-page padding>
<q-table title="Tags" :rows="rows" :row-key="(row) => row.id" :columns="columns">
<template #top-right>
<q-btn color="primary" icon="mdi-plus" label="Hinzufügen">
<q-btn color="primary" icon="mdi-plus" round>
<q-tooltip> Tag hinzufügen </q-tooltip>
<q-menu v-model="popup" anchor="center middle" self="center middle" persistent>
<div>
<q-input
v-model="newTag.name"
filled
@ -16,6 +16,7 @@
/>
<q-color
:model-value="newTag.color"
flat
class="q-pa-sm"
@change="
(val) => {
@ -23,10 +24,9 @@
}
"
/>
<div class="row q-gutter-sm justify-around">
<q-btn v-close-popup label="Abbrechen" />
<q-btn label="Speichern" color="primary" @click="save" />
</div>
<div class="full-width row q-gutter-sm justify-around q-py-sm">
<q-btn v-close-popup flat label="Abbrechen" />
<q-btn flat label="Speichern" color="primary" @click="save" />
</div>
</q-menu>
</q-btn>
@ -51,9 +51,7 @@
@update:modelValue="updateTag(props.row)"
>
<template #default="scope">
<div class="fit row justify-around">
<q-input v-model="scope.value" :rules="[notExists]" dense filled />
</div>
</template>
</q-popup-edit>
</q-td>
@ -72,8 +70,13 @@
@update:modelValue="updateTag(props.row)"
>
<template #default="slot">
<div class="fit row justify-around">
<q-color :model-value="slot.value" @change="(val) => (slot.value = val)" />
<div class="full-width row justify-center">
<q-color
:model-value="slot.value"
class="full-width"
flat
@change="(val) => (slot.value = val)"
/>
</div>
</template>
</q-popup-edit>
@ -110,6 +113,7 @@ export default defineComponent({
name: 'name',
label: 'Name',
field: 'name',
align: 'left',
},
{
name: 'color',