Added German translation
the build was successful Details

+ fixed missing translation
This commit is contained in:
konrad 2017-11-22 16:09:22 +01:00 committed by kolaente
parent 5dce42e65e
commit 8d5db903f8
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
4 changed files with 62 additions and 16 deletions

View File

@ -71,7 +71,7 @@
methods: {
insertOrUpdateAuthor: function () {
if (this.author.Lastname === '') {
this.error = {message: 'Please provide at least a lastname.'}
this.error = {message: this.translate('authors').errorNoTitle}
} else {
this.loading = true
@ -81,7 +81,7 @@
HTTP.post('authors/' + this.author.ID, {author: this.author})
.then(response => {
this.loading = false
this.success = 'The author was successfully updated!'
this.success = this.translate('authors').updatedSuccess
this.error = ''
})
.catch(e => {
@ -92,7 +92,7 @@
HTTP.put('authors', {author: this.author})
.then(response => {
this.loading = false
this.success = 'The author was successfully inserted!'
this.success = this.translate('authors').insertedSuccess
this.error = ''
})
.catch(e => {

View File

@ -55,9 +55,9 @@
</multiselect>
</div>
<div class="field" v-if="addPublisherForm">
<label v-lang.books.newPublisher></label>
<label v-lang.publishers.newPublisher></label>
<a class="ui green icon button add-publisher-btn" @click="toggleAddPublisher()"><i class="list icon"></i></a>
<input name="name" :placeholder="langBooks.newPublisher" type="text" v-model="book.PublisherFull.Name" class="add-publisher">
<input name="name" :placeholder="langPublishers.newPublisher" type="text" v-model="book.PublisherFull.Name" class="add-publisher">
</div>
<div class="field">
@ -76,14 +76,14 @@
<template v-for="(inputModel, index) in addAuthorForm">
<div class="field" v-if="addAuthorForm">
<label v-lang.books.newAuthor></label>
<label v-lang.authors.newAuthor></label>
<a class="ui red icon button add-publisher-btn" @click="removeAuthor(index)"><i class="cancel icon"></i></a>
<input name="name" :placeholder="langBooks.gridColumns.authors" v-model="newAuthors[inputModel.modelName]" type="text" class="add-publisher">
</div>
</template>
<div class="field">
<a class="ui green icon button" @click="addAddAuthor()"><i class="plus icon"></i> <span v-lang.books.newAuthor></span></a>
<a class="ui green icon button" @click="addAddAuthor()"><i class="plus icon"></i> <span v-lang.author.newAuthor></span></a>
</div>
<div class="inline fields">
@ -139,6 +139,9 @@
langBooks () {
return this.translate('books')
},
langPublishers () {
return this.translate('publishers')
},
langGeneral () {
return this.translate('general')
}
@ -223,7 +226,7 @@
},
insertNewBook: function () {
if (this.book.Title === '') {
this.error = {message: 'Please provide at least a title.'}
this.error = {message: this.translate('books').errorNoTitle}
} else {
this.loading = true
@ -267,7 +270,7 @@
HTTP.post('books/' + this.book.ID, {book: this.book})
.then(response => {
this.loading = false
this.success = 'The book was successfully updated!'
this.success = this.translate('books').updatedSuccess
this.error = ''
})
.catch(e => {
@ -278,7 +281,7 @@
HTTP.put('books', {book: this.book})
.then(response => {
this.loading = false
this.success = 'The book was successfully inserted!'
this.success = this.translate('books').insertedSuccess
this.error = ''
})
.catch(e => {

View File

@ -10,7 +10,11 @@ export default {
edit: 'Bearbeiten',
cancel: 'Abbrechen',
approve: 'Ja!',
action: 'Aktion'
action: 'Aktion',
submit: 'Senden',
selectOne: 'Wähle einen aus',
selectOneOrMore: 'Wähle einen oder mehr',
name: 'Name'
},
login: {
title: 'Einloggen',
@ -36,6 +40,41 @@ export default {
add: 'Buch hinzufügen',
deleteHeader: 'Buch löschen',
deleteMsg: 'Bist du sicher dass du dieses Buch löschen willst? <b>Das kann nicht Rückgängig gemacht werden!</b>',
deleteSuccess: 'Das Buch wurde erfolgreich gelöscht'
deleteSuccess: 'Das Buch wurde erfolgreich gelöscht.',
gridColumns: {
title: 'Titel',
isbn: 'ISBN',
year: 'Jahr',
price: 'Preis',
authors: 'Autor',
publisher: 'Verlag',
quantity: 'Menge',
status: 'Status'
},
errorNoTitle: 'Bitte gib mindestens einen Titel an.',
updatedSuccess: 'Das Buch wurde erfolgreich geupdated!',
insertedSuccess: 'Das Buch wurde erfolgreich erstellt!'
},
authors: {
title: 'Autorenübersicht',
newAuthor: 'Neuen Autor hinzufügen',
deleteHeader: 'Autor löschen',
deleteMsg: 'Bist du sicher dass du diesen Autor löschen willst? <b>Das kann nicht Rückgängig gemacht werden!</b>',
deleteSuccess: 'Der Autor wurde erfolgreich gelöscht.',
forename: 'Vorname',
lastname: 'Nachname',
errorNoName: 'Bitte gibt mindestens einen Nachnamen an.',
updatedSuccess: 'Der Autor wurde erfolgreich geupdated!',
insertedSuccess: 'Der Autor wurde erfolgreich erstellt!'
},
publishers: {
title: 'Verlagsübersicht',
newPublisher: 'Neuen Verlag hinzufügen',
deleteHeader: 'Verlag löschen',
deleteText: 'Bist du sicher dass du diesen Verlag löschen willst? <b>Das kann nicht Rückgängig gemacht werden!</b>',
deleteSuccess: 'Der Verlag wurde erfolgreich gelöscht.',
errorNoName: 'Bitte gib einen Namen ein.',
updatedSuccess: 'Der Verlag wurde erfolgreich geupdated!',
insertedSuccess: 'Der Verlag wurde erfolgreich erstellt!'
}
}

View File

@ -51,8 +51,9 @@ export default {
quantity: 'Quantity',
status: 'Status'
},
newPublisher: 'Add new publisher',
newAuthor: 'Add new author'
errorNoTitle: 'Please provide at least a title.',
updatedSuccess: 'The book was successfully updated!',
insertedSuccess: 'The book was successfully inserted!'
},
authors: {
title: 'Authors overview',
@ -61,7 +62,10 @@ export default {
deleteMsg: 'Are you sure you want to delete this author? <b>This cannot be undone!</b>',
deleteSuccess: 'The author was deleted successfully.',
forename: 'Forename',
lastname: 'Lastname'
lastname: 'Lastname',
errorNoName: 'Please provide at least a lastname.',
updatedSuccess: 'The author was successfully updated!',
insertedSuccess: 'The author was successfully inserted!'
},
publishers: {
title: 'Publishers overview',
@ -70,7 +74,7 @@ export default {
deleteText: 'Are you sure you want to delete this publisher? <b>This cannot be undone!</b>',
deleteSuccess: 'The publisher was deleted successfully.',
errorNoName: 'Please provide a name.',
updatedSuccess: 'The publisher was successfully updated!'
updatedSuccess: 'The publisher was successfully updated!',
insertedSuccess: 'The publisher was successfully inserted!'
}
}