Fixes obsolete texts or add translations. Fixes #813

This commit is contained in:
Denny Bresch 2019-08-12 09:49:48 +02:00 committed by Martin Edenhofer
parent 19ca528635
commit 29c9d3546b
15 changed files with 37 additions and 31 deletions

View file

@ -243,7 +243,7 @@ class App.ControllerGenericDescription extends App.ControllerModal
head: 'Description' head: 'Description'
content: => content: =>
marked(@description) marked(App.i18n.translateContent(@description))
onSubmit: => onSubmit: =>
@close() @close()

View file

@ -149,7 +149,8 @@ class BotAdd extends App.ControllerModal
error: (xhr) => error: (xhr) =>
data = JSON.parse(xhr.responseText) data = JSON.parse(xhr.responseText)
@formEnable(e) @formEnable(e)
@el.find('.alert').removeClass('hidden').text(data.error || 'Unable to save Bot.') error_message = App.i18n.translateContent(data.error || 'Unable to save Bot.')
@el.find('.alert').removeClass('hidden').text(error_message)
) )
class BotEdit extends App.ControllerModal class BotEdit extends App.ControllerModal
@ -196,7 +197,8 @@ class BotEdit extends App.ControllerModal
error: (xhr) => error: (xhr) =>
data = JSON.parse(xhr.responseText) data = JSON.parse(xhr.responseText)
@formEnable(e) @formEnable(e)
@el.find('.alert').removeClass('hidden').text(data.error || 'Unable to save changes.') error_message = App.i18n.translateContent(data.error || 'Unable to save changes.')
@el.find('.alert').removeClass('hidden').text(error_message)
) )
App.Config.set('Telegram', { prio: 5100, name: 'Telegram', parent: '#channels', target: '#channels/telegram', controller: Index, permission: ['admin.channel_telegram'] }, 'NavBarAdmin') App.Config.set('Telegram', { prio: 5100, name: 'Telegram', parent: '#channels', target: '#channels/telegram', controller: Index, permission: ['admin.channel_telegram'] }, 'NavBarAdmin')

View file

@ -153,8 +153,8 @@ class Index extends App.ControllerSubContent
syncChanges: => syncChanges: =>
@loader = new App.ControllerModalLoading( @loader = new App.ControllerModalLoading(
head: 'Get latest translations' head: App.i18n.translateContent('Get latest translations')
message: 'Getting latest translations from i18n.zammad.com' message: App.i18n.translateContent('Getting latest translations from i18n.zammad.com')
container: @el.closest('.content') container: @el.closest('.content')
) )
hide = => hide = =>

View file

@ -48,8 +48,8 @@ class Widget extends App.Controller
maintanaceRestartAuto: (data) => maintanaceRestartAuto: (data) =>
return if @messageRestartAuto return if @messageRestartAuto
@messageRestartAuto = new App.SessionMessage( @messageRestartAuto = new App.SessionMessage(
head: 'Zammad is restarting...' head: App.i18n.translateContent('Zammad is restarting...')
message: 'Some system settings have changed, Zammad is restarting. Please wait until Zammad is back again.' message: App.i18n.translateContent('Some system settings have changed, Zammad is restarting. Please wait until Zammad is back again.')
keyboard: false keyboard: false
backdrop: false backdrop: false
buttonClose: false buttonClose: false
@ -64,8 +64,8 @@ class Widget extends App.Controller
maintanaceRestartManual: (data) => maintanaceRestartManual: (data) =>
return if @messageRestartManual return if @messageRestartManual
@messageRestartManual = new App.SessionMessage( @messageRestartManual = new App.SessionMessage(
head: 'Zammad need a restart!' head: App.i18n.translateContent('Zammad need a restart!')
message: 'Some system settings have changed, please restart all Zammad processes! If you want to do this automatically, set environment variable APP___RESTART___CMD="/path/to/your___app___script.sh restart".' message: App.i18n.translateContent('Some system settings have changed, please restart all Zammad processes! If you want to do this automatically, set environment variable APP___RESTART___CMD="/path/to/your___app___script.sh restart".')
keyboard: false keyboard: false
backdrop: false backdrop: false
buttonClose: false buttonClose: false
@ -79,8 +79,8 @@ class Widget extends App.Controller
maintanaceConfigChanged: (data) => maintanaceConfigChanged: (data) =>
return if @messageConfigChanged return if @messageConfigChanged
@messageConfigChanged = new App.SessionMessage( @messageConfigChanged = new App.SessionMessage(
head: 'Config has changed' head: App.i18n.translateContent('Config has changed')
message: 'The configuration of Zammad has changed, please reload your browser.' message: App.i18n.translateContent('The configuration of Zammad has changed, please reload your browser.')
keyboard: false keyboard: false
backdrop: true backdrop: true
buttonClose: false buttonClose: false
@ -99,8 +99,8 @@ class Widget extends App.Controller
return if localAppVersion[1] isnt 'true' return if localAppVersion[1] isnt 'true'
message = => message = =>
@messageAppVersion = new App.SessionMessage( @messageAppVersion = new App.SessionMessage(
head: 'New Version' head: App.i18n.translateContent('New Version')
message: 'A new version of Zammad is available, please reload your browser.' message: App.i18n.translateContent('A new version of Zammad is available, please reload your browser.')
keyboard: false keyboard: false
backdrop: true backdrop: true
buttonClose: false buttonClose: false

View file

@ -55,6 +55,7 @@ class App.Macro extends App.Model
] ]
@description = ''' @description = '''
Macros are.... Macros make it easy to automate common, multi-step tasks within Zammad.
You can use macros in Zammad to automate recurring sequences, saving time (and nerves). This allows a combined sequence of actions on the ticket to be executed with just one click.
''' '''

View file

@ -20,7 +20,7 @@ class App.Organization extends App.Model
Using **Organisations** you can **group** customers. This has among others two important benefits: Using **Organisations** you can **group** customers. This has among others two important benefits:
1. As an **Agent** you do not only have an overview of the open tickets for one person but an **overview over their whole organisation**. 1. As an **Agent** you do not only have an overview of the open tickets for one person but an **overview over their whole organisation**.
2. As a **Customer** you can also check the **Tickets which your colleagues created** and modify their tickets (if your organization is set to "shared", which can be defined per organization)). 2. As a **Customer** you can also check the **Tickets which your colleagues created** and modify their tickets (if your organization is set to "shared", which can be defined per organization).
''' '''
uiUrl: -> uiUrl: ->

View file

@ -81,7 +81,7 @@ class App.Overview extends App.Model
@description = ''' @description = '''
You can create **overviews** for your agents and your customers. These could for instance serve as a sort of work list for items for which your agents would work. You can create **overviews** for your agents and your customers. These could for instance serve as a sort of work list for items for which your agents would work.
You can also create overvies and limit them to specific agents or to groups of agents. You can also create overviews and limit them to specific agents or to groups of agents.
''' '''
uiUrl: -> uiUrl: ->

View file

@ -14,9 +14,12 @@ class App.Trigger extends App.Model
@configure_overview = [ @configure_overview = [
'name', 'name',
] ]
###
@description = '''
Trigger are....
@description = '''
Every time a customer creates a new ticket, they automatically receive a confirmation email to assure them that their issue has been submitted successfully. This behavior is built into Zammad, but its also highly customizable, and you can set up other automated actions just like it.
Maybe you want to set a higher priority on any ticket with the word urgent in the title. Maybe you want to avoid sending auto-reply emails to customers from certain organizations. Maybe you want mark a ticket as pending whenever someone adds an internal note to a ticket.
Whatever it is, you can do it with triggers: actions that watch tickets for certain changes, and then fire off whenever those changes occur.
''' '''
###

View file

@ -288,11 +288,11 @@ class App.User extends App.Model
@outOfOfficeTextPlaceholder: -> @outOfOfficeTextPlaceholder: ->
today = new Date() today = new Date()
outOfOfficeText = 'Christmas holiday' outOfOfficeText = App.i18n.translateContent('Christmas holiday')
if today.getMonth() < 3 if today.getMonth() < 3
outOfOfficeText = 'Easter holiday' outOfOfficeText = App.i18n.translateContent('Easter holiday')
else if today.getMonth() < 9 else if today.getMonth() < 9
outOfOfficeText = 'Summer holiday' outOfOfficeText = App.i18n.translateContent('Summer holiday')
outOfOfficeText outOfOfficeText
outOfOfficeText: -> outOfOfficeText: ->

View file

@ -2,7 +2,7 @@
<fieldset> <fieldset>
<h1><%- @T('Wall') %></h1> <h1><%- @T('Wall') %></h1>
<p class="description"><%- @T('Choose which group %s will get added to.', 'wall postings') %></p> <p class="description"><%- @T('Choose the group in which wall postings will get added to.') %></p>
<div class="js-wall"> <div class="js-wall">
<h2><%= @channel.options.user.name %></h2> <h2><%= @channel.options.user.name %></h2>
<div data-page-id="<%= @channel.options.user.id %>" class="js-groups"></div> <div data-page-id="<%= @channel.options.user.id %>" class="js-groups"></div>
@ -11,7 +11,7 @@
<hr> <hr>
<h1><%- @T('Pages') %></h1> <h1><%- @T('Pages') %></h1>
<p class="description"><%- @T('Choose which group %s will get added to.', 'page postings') %></p> <p class="description"><%- @T('Choose the group in which page postings will get added to.') %></p>
<div class="js-pages"> <div class="js-pages">
<% if @channel.options.pages: %> <% if @channel.options.pages: %>
<% for page in @channel.options.pages: %> <% for page in @channel.options.pages: %>

View file

@ -23,7 +23,7 @@
</div> </div>
<div class="input form-group"> <div class="input form-group">
<div class="formGroup-label"> <div class="formGroup-label">
<label for=""><%- @T('Choose which group %s will get added to.', 'messages') %> <span>*</span></label> <label for=""><%- @T('Choose the group in which messages will get added to.') %> <span>*</span></label>
</div> </div>
<div class="controls"> <div class="controls">
<div class="js-messagesGroup"></div> <div class="js-messagesGroup"></div>

View file

@ -20,7 +20,7 @@
</div> </div>
<div class="input form-group"> <div class="input form-group">
<div class="formGroup-label"> <div class="formGroup-label">
<label for=""><%- @T('Choose which group %s will get added to.', 'messages') %> <span>*</span></label> <label for=""><%- @T('Choose the group in which messages will get added to.') %> <span>*</span></label>
</div> </div>
<div class="controls"> <div class="controls">
<div class="js-messagesGroup"></div> <div class="js-messagesGroup"></div>

View file

@ -24,11 +24,11 @@
</table> </table>
<h3><%- @T('Mentions Group') %></h3> <h3><%- @T('Mentions Group') %></h3>
<p class="description"><%- @T('Choose which group %s will get added to.', 'mentions') %></p> <p class="description"><%- @T('Choose the group in which mentions will get added to.') %></p>
<div class="js-mentionsGroup"></div> <div class="js-mentionsGroup"></div>
<h3><%- @T('Direct Messages Group') %></h3> <h3><%- @T('Direct Messages Group') %></h3>
<p class="description"><%- @T('Choose which group %s will get added to.', 'direct messages') %></p> <p class="description"><%- @T('Choose the group in which direct messages will get added to.') %></p>
<div class="js-directMessagesGroup"></div> <div class="js-directMessagesGroup"></div>
<h3><%- @T('Retweets') %></h3> <h3><%- @T('Retweets') %></h3>