Fix/category link (#1087)

* fix and refactor chip links

* fix missing UI components for data management

* fix button text
This commit is contained in:
Hayden 2022-03-22 21:08:06 -08:00 committed by GitHub
commit 0f82523cdd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 27 additions and 28 deletions

View file

@ -14,6 +14,11 @@
mode="link"
rounded
:items="[
{
text: 'Recipes',
value: 'new',
to: '/group/data/recipes',
},
{
text: 'Foods',
value: 'url',
@ -55,6 +60,7 @@ export default defineComponent({
},
setup() {
const buttonLookup: { [key: string]: string } = {
recipes: "Recipes",
foods: "Foods",
units: "Units",
labels: "Labels",

View file

@ -56,16 +56,9 @@
</v-card>
</v-card-text>
</BaseDialog>
<BasePageTitle divider>
<template #header>
<v-img max-height="125" max-width="125" :src="require('~/static/svgs/manage-recipes.svg')"></v-img>
</template>
<template #title> Data Management </template>
</BasePageTitle>
<section>
<!-- Recipe Data Table -->
<BaseCardSectionTitle :icon="$globals.icons.primary" section title="Recipe Data">
<BaseCardSectionTitle :icon="$globals.icons.primary" title="Recipe Data">
Use this section to manage the data associated with your recipes. You can perform several bulk actions on your
recipes including exporting, deleting, tagging, and assigning categories.
</BaseCardSectionTitle>
@ -86,7 +79,7 @@
<v-divider class="mx-2"></v-divider>
<v-card-text class="mt-n5">
<v-checkbox
v-for="(itemValue, key) in headers"
v-for="(_, key) in headers"
:key="key"
v-model="headers[key]"
dense

View file

@ -63,12 +63,12 @@
<template v-if="!editState[rule.id]">
<div v-if="rule.categories">
<h4 class="py-1">{{ $t("category.categories") }}:</h4>
<RecipeChips :items="rule.categories" is-category small />
<RecipeChips :items="rule.categories" small />
</div>
<div v-if="rule.tags">
<h4 class="py-1">{{ $t("tag.tags") }}:</h4>
<RecipeChips :items="rule.tags" :is-category="false" small />
<RecipeChips :items="rule.tags" url-prefix="tags" small />
</div>
</template>
<template v-else>

View file

@ -267,7 +267,7 @@
:tag-selector="true"
:show-label="false"
/>
<RecipeChips v-else :items="recipe.tags" :is-category="false" />
<RecipeChips v-else :items="recipe.tags" url-prefix="tags" />
</v-card-text>
</v-card>
@ -355,7 +355,7 @@
:tag-selector="true"
:show-label="false"
/>
<RecipeChips v-else :items="recipe.tags" :is-category="false" />
<RecipeChips v-else :items="recipe.tags" url-prefix="tags"/>
</v-card-text>
</v-card>

View file

@ -176,7 +176,7 @@
</v-card-title>
<v-divider class="mx-2"></v-divider>
<v-card-text>
<RecipeChips :items="recipe.tags" :is-category="false" />
<RecipeChips :items="recipe.tags" url-prefix="tags" />
</v-card-text>
</v-card>
@ -219,7 +219,7 @@
</v-card-title>
<v-divider class="mx-2"></v-divider>
<v-card-text>
<RecipeChips :items="recipe.tags" :is-category="false" />
<RecipeChips :items="recipe.tags" url-prefix="tags" />
</v-card-text>
</v-card>