mirror of
https://github.com/mealie-recipes/mealie.git
synced 2025-07-20 13:49:40 +02:00
feature/recipe-patch-improvements (#382)
* automated docs update * recipe rating component * recipe partial updates - closes #25 * use Vue.delete to update store * format * arrow functions * fix tests * format * initial context menu * localize * add confirmation dialog * context menu * fix bare exception * update line length * format all file with prettier * update changelog * download as json * update python dependencies * update javascript dependencies Co-authored-by: hay-kot <hay-kot@pm.me>
This commit is contained in:
parent
c196445e61
commit
be378cb20c
121 changed files with 18942 additions and 4765 deletions
|
@ -84,17 +84,14 @@
|
|||
></v-text-field>
|
||||
</v-col>
|
||||
<v-col cols="12" sm="12" md="3">
|
||||
<v-switch
|
||||
v-model="editedItem.admin"
|
||||
:label="$t('user.admin')"
|
||||
></v-switch>
|
||||
<v-switch v-model="editedItem.admin" :label="$t('user.admin')"></v-switch>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
|
||||
<v-card-actions>
|
||||
<v-btn color="info" text @click="resetPassword" v-if="!createMode">
|
||||
{{$t('user.reset-password')}}
|
||||
{{ $t("user.reset-password") }}
|
||||
</v-btn>
|
||||
<v-spacer></v-spacer>
|
||||
<v-btn color="grey" text @click="close">
|
||||
|
@ -110,12 +107,7 @@
|
|||
</v-toolbar>
|
||||
<v-divider></v-divider>
|
||||
<v-card-text>
|
||||
<v-data-table
|
||||
:headers="headers"
|
||||
:items="users"
|
||||
sort-by="calories"
|
||||
:search="search"
|
||||
>
|
||||
<v-data-table :headers="headers" :items="users" sort-by="calories" :search="search">
|
||||
<template v-slot:item.actions="{ item }">
|
||||
<v-btn class="mr-1" small color="error" @click="deleteItem(item)">
|
||||
<v-icon small left>
|
||||
|
@ -192,9 +184,7 @@ export default {
|
|||
|
||||
computed: {
|
||||
formTitle() {
|
||||
return this.createMode
|
||||
? this.$t("user.new-user")
|
||||
: this.$t("user.edit-user");
|
||||
return this.createMode ? this.$t("user.new-user") : this.$t("user.edit-user");
|
||||
},
|
||||
createMode() {
|
||||
return this.editedIndex === -1 ? true : false;
|
||||
|
@ -274,21 +264,20 @@ export default {
|
|||
resetPassword() {
|
||||
api.users.resetPassword(this.editedItem.id);
|
||||
},
|
||||
|
||||
|
||||
async createUser() {
|
||||
if(await api.users.create(this.editedItem)) {
|
||||
if (await api.users.create(this.editedItem)) {
|
||||
this.close();
|
||||
}
|
||||
},
|
||||
|
||||
async updateUser() {
|
||||
if(await api.users.update(this.editedItem)) {
|
||||
if (await api.users.update(this.editedItem)) {
|
||||
this.close();
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
||||
<style></style>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue