Improved translation feature.
This commit is contained in:
parent
9ee0bbb895
commit
b8111353ba
32 changed files with 180 additions and 116 deletions
|
@ -2,7 +2,7 @@ class App.Controller extends Spine.Controller
|
||||||
|
|
||||||
# add @title methode to set title
|
# add @title methode to set title
|
||||||
title: (name) ->
|
title: (name) ->
|
||||||
$('html head title').html( Config.product_name + ' - ' + T(name) )
|
$('html head title').html( Config.product_name + ' - ' + Ti(name) )
|
||||||
|
|
||||||
# add @notify methode to create notification
|
# add @notify methode to create notification
|
||||||
notify: (data) ->
|
notify: (data) ->
|
||||||
|
@ -166,7 +166,7 @@ class App.Controller extends Spine.Controller
|
||||||
|
|
||||||
name_new = name
|
name_new = name
|
||||||
if attribute.translate
|
if attribute.translate
|
||||||
name_new = T(name)
|
name_new = Ti(name)
|
||||||
attribute.options.push {
|
attribute.options.push {
|
||||||
name: name_new,
|
name: name_new,
|
||||||
value: item.id,
|
value: item.id,
|
||||||
|
@ -399,10 +399,6 @@ class App.Controller extends Spine.Controller
|
||||||
if row.callback
|
if row.callback
|
||||||
object[row.name]['name'] = row.callback(object[row.name]['name'])
|
object[row.name]['name'] = row.callback(object[row.name]['name'])
|
||||||
|
|
||||||
# check if translation is needed
|
|
||||||
if row.translate
|
|
||||||
object[row.name]['name'] = T( object[row.name]['name'] )
|
|
||||||
|
|
||||||
# @log 'table', 'header', header, 'overview', data_types, 'objects', objects
|
# @log 'table', 'header', header, 'overview', data_types, 'objects', objects
|
||||||
table = App.view('generic/table')(
|
table = App.view('generic/table')(
|
||||||
header: header,
|
header: header,
|
||||||
|
|
|
@ -13,6 +13,7 @@ class Index extends App.ControllerLevel2
|
||||||
]
|
]
|
||||||
page: {
|
page: {
|
||||||
title: 'Channels',
|
title: 'Channels',
|
||||||
|
head: 'Channels',
|
||||||
sub_title: 'Management'
|
sub_title: 'Management'
|
||||||
nav: '#channels',
|
nav: '#channels',
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,6 +19,7 @@ class Index extends App.ControllerLevel2
|
||||||
]
|
]
|
||||||
@page = {
|
@page = {
|
||||||
title: 'System',
|
title: 'System',
|
||||||
|
head: 'System',
|
||||||
sub_title: 'Settings'
|
sub_title: 'Settings'
|
||||||
nav: '#settings/system',
|
nav: '#settings/system',
|
||||||
}
|
}
|
||||||
|
@ -32,6 +33,7 @@ class Index extends App.ControllerLevel2
|
||||||
]
|
]
|
||||||
@page = {
|
@page = {
|
||||||
title: 'Security',
|
title: 'Security',
|
||||||
|
head: 'Security',
|
||||||
sub_title: 'Settings'
|
sub_title: 'Settings'
|
||||||
nav: '#settings/security',
|
nav: '#settings/security',
|
||||||
}
|
}
|
||||||
|
@ -45,6 +47,7 @@ class Index extends App.ControllerLevel2
|
||||||
]
|
]
|
||||||
@page = {
|
@page = {
|
||||||
title: 'Ticket',
|
title: 'Ticket',
|
||||||
|
head: 'Ticket',
|
||||||
sub_title: 'Settings'
|
sub_title: 'Settings'
|
||||||
nav: '#settings/ticket',
|
nav: '#settings/ticket',
|
||||||
}
|
}
|
||||||
|
|
|
@ -148,7 +148,8 @@ class App.i18n extends App.Ajax
|
||||||
|
|
||||||
constructor: ->
|
constructor: ->
|
||||||
@set('de')
|
@set('de')
|
||||||
window.T = @translate
|
window.T = @translate_content
|
||||||
|
window.Ti = @translate_inline
|
||||||
|
|
||||||
set: (locale) =>
|
set: (locale) =>
|
||||||
@map = {}
|
@map = {}
|
||||||
|
@ -162,21 +163,47 @@ class App.i18n extends App.Ajax
|
||||||
console.log 'error', error, statusText, xhr.statusCode
|
console.log 'error', error, statusText, xhr.statusCode
|
||||||
)
|
)
|
||||||
|
|
||||||
|
translate_inline: (string, args...) =>
|
||||||
|
@translate(string, args...)
|
||||||
|
|
||||||
|
translate_content: (string, args...) =>
|
||||||
|
translated = @translate(string, args...)
|
||||||
|
# replace = '<span class="translation" contenteditable="true" data-text="' + @escape(string) + '">' + translated + '<span class="icon-edit"></span>'
|
||||||
|
replace = '<span class="translation" contenteditable="true" data-text="' + @escape(string) + '">' + translated + ''
|
||||||
|
# if !@_translated
|
||||||
|
# replace += '<span class="missing">XX</span>'
|
||||||
|
replace += '</span>'
|
||||||
|
|
||||||
translate: (string, args...) =>
|
translate: (string, args...) =>
|
||||||
|
|
||||||
|
# return '' on undefined
|
||||||
|
return '' if string is undefined
|
||||||
|
|
||||||
# return translation
|
# return translation
|
||||||
if @map[string] isnt undefined
|
if @map[string] isnt undefined
|
||||||
|
@_translated = true
|
||||||
translated = @map[string]
|
translated = @map[string]
|
||||||
else
|
else
|
||||||
|
@_translated = false
|
||||||
translated = string
|
translated = string
|
||||||
|
|
||||||
# search %s
|
# search %s
|
||||||
for arg in args
|
for arg in args
|
||||||
translated = translated.replace(/%s/, arg)
|
translated = translated.replace(/%s/, arg)
|
||||||
|
|
||||||
|
# escape
|
||||||
|
translated = @escape(translated)
|
||||||
|
|
||||||
# return translated string
|
# return translated string
|
||||||
return translated
|
return translated
|
||||||
|
|
||||||
|
escape: (string) ->
|
||||||
|
string = ('' + string)
|
||||||
|
.replace(/&/g, '&')
|
||||||
|
.replace(/</g, '<')
|
||||||
|
.replace(/>/g, '>')
|
||||||
|
.replace(/\x22/g, '"')
|
||||||
|
|
||||||
class App.Run extends Spine.Controller
|
class App.Run extends Spine.Controller
|
||||||
constructor: ->
|
constructor: ->
|
||||||
super
|
super
|
||||||
|
@ -204,6 +231,26 @@ class App.Run extends Spine.Controller
|
||||||
window.Session['UISeletion'] = @getSelected() + ''
|
window.Session['UISeletion'] = @getSelected() + ''
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# $('.translation [contenteditable]')
|
||||||
|
$('.translation')
|
||||||
|
.live 'focus', ->
|
||||||
|
$this = $(this)
|
||||||
|
$this.data 'before', $this.html()
|
||||||
|
console.log('11111before', $this.html())
|
||||||
|
return $this
|
||||||
|
.live 'blur keyup paste', ->
|
||||||
|
# .live 'blur', ->
|
||||||
|
$this = $(this)
|
||||||
|
if $this.data('before') isnt $this.html()
|
||||||
|
$this.data 'before', $this.html()
|
||||||
|
$this.trigger('change')
|
||||||
|
console.log('111changed', $this.html(), $this.attr('data-text') )
|
||||||
|
a = $this.html()
|
||||||
|
a = ('' + a)
|
||||||
|
.replace(/<.+?>/g, '')
|
||||||
|
$this.html(a)
|
||||||
|
return $this
|
||||||
|
|
||||||
# @ws = new WebSocket("ws://localhost:3001/");
|
# @ws = new WebSocket("ws://localhost:3001/");
|
||||||
|
|
||||||
# Set event handlers.
|
# Set event handlers.
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="page-header">
|
<div class="page-header">
|
||||||
<h1><%= T('New Ticket') %> <small></small></h1>
|
<h1><%- T('New Ticket') %> <small></small></h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<form class="form-horizontal">
|
<form class="form-horizontal">
|
||||||
|
@ -16,6 +16,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-actions">
|
<div class="form-actions">
|
||||||
<button type="reset" class="btn cancel"><%= T('Cancel') %></button> <button type="submit" class="btn btn-primary submit"><%= T('Create') %></button>
|
<button type="reset" class="btn cancel"><%- T('Cancel') %></button> <button type="submit" class="btn btn-primary submit"><%- T('Create') %></button>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
|
|
@ -7,9 +7,9 @@
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<%= @ticket.group.name %> -
|
<%= @ticket.group.name %> -
|
||||||
<%= T(@ticket.ticket_state.name) %> -
|
<%- T(@ticket.ticket_state.name) %> -
|
||||||
<%= T(@ticket.ticket_priority.name) %> -
|
<%- T(@ticket.ticket_priority.name) %> -
|
||||||
<%= @ticket.humanTime %>
|
<%- @ticket.humanTime %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -26,24 +26,24 @@
|
||||||
<div class="span8 well-muted article-message <% if article.internal is true: %> internal<% end %>">
|
<div class="span8 well-muted article-message <% if article.internal is true: %> internal<% end %>">
|
||||||
<% if article.from: %>
|
<% if article.from: %>
|
||||||
<div>
|
<div>
|
||||||
<strong title="<%= T('From') %>: <%= article.from %>"><%= article.from %></strong>
|
<strong title="<%- Ti('From') %>: <%= article.from %>"><%= article.from %></strong>
|
||||||
<% if article.actions: %>
|
<% if article.actions: %>
|
||||||
<% for action in article.actions: %>
|
<% for action in article.actions: %>
|
||||||
-
|
-
|
||||||
<a href="#" data-type="<%= action.type %>" class="<% if action.class: %><%= action.class %><% end %>"><%= action.name %></a>
|
<a href="#" data-type="<%= action.type %>" class="<% if action.class: %><%= action.class %><% end %>"><%= action.name %></a>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
- <%= article.humanTime %> ago
|
- <%- article.humanTime %> <%- T('ago') %>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if article.to: %>
|
<% if article.to: %>
|
||||||
<div title="<%= T('To') %>: <%= article.to %>"><%= article.to %></div>
|
<div title="<%- Ti('To') %>: <%= article.to %>"><%= article.to %></div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if article.cc: %>
|
<% if article.cc: %>
|
||||||
<div title="<%= T('Cc') %>: <%= article.cc %>"><%= article.cc %></div>
|
<div title="<%- Ti('Cc') %>: <%= article.cc %>"><%= article.cc %></div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if article.subject: %>
|
<% if article.subject: %>
|
||||||
<div title="<%= T('Subject') %>: <%= article.subject %>"><%= article.subject %></div>
|
<div title="<%- Ti('Subject') %>: <%= article.subject %>"><%= article.subject %></div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if article.attachments: %>
|
<% if article.attachments: %>
|
||||||
<div>
|
<div>
|
||||||
|
@ -71,7 +71,7 @@
|
||||||
|
|
||||||
<div class="keepleft" id="file-uploader"></div>
|
<div class="keepleft" id="file-uploader"></div>
|
||||||
|
|
||||||
<button type="submit" class="btn btn-primary submit"><%= T('Submit') %></button>
|
<button type="submit" class="btn btn-primary submit"><%- T('Submit') %></button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -85,8 +85,8 @@
|
||||||
<div class="well">
|
<div class="well">
|
||||||
<h3>Actions</h3>
|
<h3>Actions</h3>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#" data-type="history">History</a></li>
|
<li><a href="#" data-type="history"><%- T('History') %></a></li>
|
||||||
<li><a href="#" data-type="merge">Merge</a></li>
|
<li><a href="#" data-type="merge"><%- T('Merge') %></a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
<form class="form-horizontal">
|
<form class="form-horizontal">
|
||||||
<div class="modal-header">
|
<div class="modal-header">
|
||||||
<a href="#" class="close">×</a>
|
<a href="#" class="close">×</a>
|
||||||
<h3><%= T(@head) %></h3>
|
<h3><%- T(@head) %></h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
<%- @form %>
|
<%- @form %>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<button class="btn btn-primary submit"><%= T('Submit') %></button>
|
<button class="btn btn-primary submit"><%- T('Submit') %></button>
|
||||||
<button class="btn secondary cancel"><%= T('Cancel') %></button>
|
<button class="btn secondary cancel"><%- T('Cancel') %></button>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="page-header">
|
<div class="page-header">
|
||||||
<h1><%= @head %> <small><a href="#" data-type="settings" class="icon-edit"></a></small></h1>
|
<h1><%- T(@head) %> <small><a href="#" data-type="settings" class="icon-edit"></a></small></h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span3">
|
<div class="span3">
|
||||||
<h2><%= T(@head) %></h2>
|
<h2><%- T(@head) %></h2>
|
||||||
<dl>
|
<dl>
|
||||||
<% for item in @items: %>
|
<% for item in @items: %>
|
||||||
<dt><span class="user-data" data-id="<%= item.created_by_id %>">"<%= item.created_by.realname %>"</span></dt>
|
<dt><span class="user-data" data-id="<%= item.created_by_id %>">"<%= item.created_by.realname %>"</span></dt>
|
||||||
<dd><%= T(item.history_type.name) %> <span data-id="<%= item.o_id %>"><a data-type="edit" href="#"><%= item.history_object.name %> (<%= item.ticket.title %>)</a></span>.</dd>
|
<dd><%- T(item.history_type.name) %> <span data-id="<%= item.o_id %>"><a data-type="edit" href="#"><%= item.history_object.name %> (<%= item.ticket.title %>)</a></span>.</dd>
|
||||||
<% end %>
|
<% end %>
|
||||||
</dl>
|
</dl>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span3">
|
<div class="span3">
|
||||||
<h2><%= T(@head) %></h2>
|
<h2><%- T(@head) %></h2>
|
||||||
<ul>
|
<ul>
|
||||||
<% for item in @items: %>
|
<% for item in @items: %>
|
||||||
<li><span data-id="<%= item.o_id %>"><a data-type="edit" href="#"><%= item.history_object.name %> (<%= item.ticket.title %>)</a></span></li>
|
<li><span data-id="<%= item.o_id %>"><a data-type="edit" href="#"><%= item.history_object.name %> (<%= item.ticket.title %>)</a></span></li>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span3">
|
<div class="span3">
|
||||||
<h2><%= T(@head) %></h2>
|
<h2><%- T(@head) %></h2>
|
||||||
<ul>
|
<ul>
|
||||||
<% for item in @items: %>
|
<% for item in @items: %>
|
||||||
<li><a href="<%= item.link %>" title="<%= item.summary %>" target="_blank"><%= item.title %>"</a></li>
|
<li><a href="<%= item.link %>" title="<%= item.summary %>" target="_blank"><%= item.title %>"</a></li>
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span9">
|
<div class="span9">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span5">
|
<div class="span6">
|
||||||
<h2><%= T(@overview.meta.name) %> <small><a href="#" data-type="settings" class="icon-edit"></a></small></h2>
|
<h2><%- T(@overview.meta.name) %> <small><a href="#" data-type="settings" class="icon-edit"></a></small></h2>
|
||||||
</div>
|
</div>
|
||||||
<div class="span4">
|
<div class="span3">
|
||||||
<div class="pagination">
|
<div class="pagination">
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<div class="modal-header">
|
<div class="modal-header">
|
||||||
<a href="#" class="close">×</a>
|
<a href="#" class="close">×</a>
|
||||||
<h3><%= T('Edit') %>: <%= T(@overview.meta.name) %></h3>
|
<h3><%- T('Edit') %>: <%- T(@overview.meta.name) %></h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
<form class="form-horizontal">
|
<form class="form-horizontal">
|
||||||
|
@ -8,6 +8,6 @@
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<button class="btn btn-primary submit"><%= T('Submit') %></button>
|
<button class="btn btn-primary submit"><%- T('Submit') %></button>
|
||||||
<button class="btn cancel"><%= T('Cancel') %></button>
|
<button class="btn cancel"><%- T('Cancel') %></button>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
<form class="form-horizontal">
|
<form class="form-horizontal">
|
||||||
<div class="modal-header">
|
<div class="modal-header">
|
||||||
<a href="#" class="close">×</a>
|
<a href="#" class="close">×</a>
|
||||||
<h3><%= T(@head) %></h3>
|
<h3><%- T(@head) %></h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
<%- @form %>
|
<%- @form %>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<button class="btn btn-primary submit"><%= T('Submit') %></button>
|
<button class="btn btn-primary submit"><%- T('Submit') %></button>
|
||||||
<button class="btn cancel"><%= T('Cancel') %></button>
|
<button class="btn cancel"><%- T('Cancel') %></button>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="page-header">
|
<div class="page-header">
|
||||||
<h1><%= T(@head) %> <small><%= T('Management') %></small></h1>
|
<h1><%- T(@head) %> <small><%- T('Management') %></small></h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
@ -23,12 +23,12 @@
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<% for note in @notes: %>
|
<% for note in @notes: %>
|
||||||
<p><%= T(note) %></p>
|
<p><%- T(note) %></p>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<% if @buttons: %>
|
<% if @buttons: %>
|
||||||
<% for button in @buttons: %>
|
<% for button in @buttons: %>
|
||||||
<p><a data-type="<%= button['data-type'] %>" class="btn <%= button['class'] %>"><%= T(button.name) %></a></p>
|
<p><a data-type="<%= button['data-type'] %>" class="btn <%= button['class'] %>"><%- T(button.name) %></a></p>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
<form class="form-horizontal">
|
<form class="form-horizontal">
|
||||||
<div class="modal-header">
|
<div class="modal-header">
|
||||||
<a href="#" class="close">×</a>
|
<a href="#" class="close">×</a>
|
||||||
<h3><%= T(@head) %></h3>
|
<h3><%- T(@head) %></h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
<%- @form %>
|
<%- @form %>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<button class="btn btn-primary submit"><%= T('Submit') %></button>
|
<button class="btn btn-primary submit"><%- T('Submit') %></button>
|
||||||
<button class="btn cancel"><%= T('Cancel') %></button>
|
<button class="btn cancel"><%- T('Cancel') %></button>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="page-header">
|
<div class="page-header">
|
||||||
<h1><%= T(@page.head) %> <small><%= T(@page.sub_head) %></small></h1>
|
<h1><%- T(@page.head) %> <small><%- T(@page.sub_head) %></small></h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
@ -7,7 +7,7 @@
|
||||||
<ul class="nav nav-tabs nav-stacked">
|
<ul class="nav nav-tabs nav-stacked">
|
||||||
<% if @menus: %>
|
<% if @menus: %>
|
||||||
<% for menu in @menus: %>
|
<% for menu in @menus: %>
|
||||||
<li class="<%= menu['class'] %>"><a href="<%= @page.nav %>/<%= menu.target %>" data-toggle="tabnav" data-target="<%= menu['target'] %>" ><%= T(menu.name) %></a></li>
|
<li class="<%= menu['class'] %>"><a href="<%= @page.nav %>/<%= menu.target %>" data-toggle="tabnav" data-target="<%= menu['target'] %>" ><%- T(menu.name) %></a></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
<div class="control-group <%= @attribute.item_class %>">
|
<div class="control-group <%= @attribute.item_class %>">
|
||||||
<label class="control-label" for="<%= @attribute.id %>"><%= T(@attribute.display) %><% if !@attribute.null: %> *<% end %></label>
|
<label class="control-label" for="<%= @attribute.id %>"><%- T(@attribute.display) %><% if !@attribute.null: %> *<% end %></label>
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
<%- @item %>
|
<%- @item %>
|
||||||
<span class="help-inline"></span>
|
<span class="help-inline"></span>
|
||||||
<span class="help-block"><%= T(@attribute.help) %> <%- @attribute.link %></span>
|
<span class="help-block"><% if @attribute.help: %><%- T(@attribute.help) + ' ' %><% end %><%- @attribute.link %></span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="hero-unit">
|
<div class="hero-unit">
|
||||||
<h2><%= @head %> <small><%= @head_small %></small></h2>
|
<h2><%- T(@head) %> <small><%- T(@head_small) %></small></h2>
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<p>
|
<p>
|
||||||
<%- @message %>
|
<%- @message %>
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
<th><input type="checkbox" value="" name="bulk_all"/></th>
|
<th><input type="checkbox" value="" name="bulk_all"/></th>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% for row in @header: %>
|
<% for row in @header: %>
|
||||||
<th><%= T(row) %></th>
|
<th><%- T(row) %></th>
|
||||||
<% end %>
|
<% end %>
|
||||||
<!--
|
<!--
|
||||||
<th>Destory</th>
|
<th>Destory</th>
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
<% if row.link: %>
|
<% if row.link: %>
|
||||||
<a href="#" data-type="edit"><%= object[row.name]['name'] %></a>
|
<a href="#" data-type="edit"><%= object[row.name]['name'] %></a>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
<span <% if row.class: %>class="<%= row.class %>"<% end %> <% if row.data && row.data.id: %>data-id="<%= object[row.name]['id'] %>"<% end %>><%= object[row.name]['name'] %></span>
|
<span <% if row.class: %>class="<%= row.class %>"<% end %> <% if row.data && row.data.id: %>data-id="<%= object[row.name]['id'] %>"<% end %>><% if row.translate: %><%- T(object[row.name]['name']) %><% else if row.callback: %><%- object[row.name]['name'] %><% else: %><%= object[row.name]['name'] %><% end %></span>
|
||||||
<% end %>
|
<% end %>
|
||||||
</td>
|
</td>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<ul class="nav nav-tabs">
|
<ul class="nav nav-tabs">
|
||||||
<% for tab in @tabs: %>
|
<% for tab in @tabs: %>
|
||||||
<li><a href="#<%= tab.target %>" data-toggle="tab"><%= tab.name %></a></li>
|
<li><a href="#<%= tab.target %>" data-toggle="tab"><%- T(tab.name) %></a></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="tab-content"></div>
|
<div class="tab-content"></div>
|
|
@ -1,38 +1,38 @@
|
||||||
<div class="hero-unit">
|
<div class="hero-unit">
|
||||||
|
|
||||||
<h1>Getting started!<small></small></h1>
|
<h1><%- T('Getting started!') %><small></small></h1>
|
||||||
|
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<ol>
|
<ol>
|
||||||
<li>Create Admin</li>
|
<li><%- T('Create Admin') %></li>
|
||||||
<li>Invite Agents</li>
|
<li><%- T('Invite Agents') %></li>
|
||||||
<li>Configure Channels</li>
|
<li><%- T('Configure Channels') %></li>
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<% if @master_user: %>
|
<% if @master_user: %>
|
||||||
<div class="span6 master_user">
|
<div class="span6 master_user">
|
||||||
<h2>Master Agent</h2>
|
<h2>M<%- T('Master Agent') %></h2>
|
||||||
<form class="form-stacked">
|
<form class="form-stacked">
|
||||||
<%- @form_master %>
|
<%- @form_master %>
|
||||||
<button class="btn btn-primary submit">Next...</button>
|
<button class="btn btn-primary submit"><%- T('Next...') %></button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<div class="span6 agent_user hide">
|
<div class="span6 agent_user hide">
|
||||||
<h2>Invite Agents</h2>
|
<h2><%- T('Invite Agents') %></h2>
|
||||||
<form class="form-stacked">
|
<form class="form-stacked">
|
||||||
<%- @form_agent %>
|
<%- @form_agent %>
|
||||||
<button class="btn btn-primary submit">Send Invitation</button>
|
<button class="btn btn-primary submit"><%- T('Send Invitation') %></button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div class="span6">
|
<div class="span6">
|
||||||
<h2>Tour</h2>
|
<h2><%- T('Tour') %></h2>
|
||||||
<p>
|
<p>
|
||||||
Learn all about ...
|
<%- T('Learn all about ...') %>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -6,15 +6,15 @@
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<p><%= T('Sign in with') %></p>
|
<p><%- T('Sign in with') %></p>
|
||||||
<form id="login" class="form-search">
|
<form id="login" class="form-search">
|
||||||
<input name="username" type="text" class="input span3" placeholder="<%= T('Username or email') %>" value="<%= @item.username %>" autocapitalize="off"/>
|
<input name="username" type="text" class="input span3" placeholder="<%- Ti('Username or email') %>" value="<%= @item.username %>" autocapitalize="off"/>
|
||||||
<input name="password" type="password" class="input span3" placeholder="<%= T('Password') %>"/>
|
<input name="password" type="password" class="input span3" placeholder="<%- Ti('Password') %>"/>
|
||||||
<button class="btn btn-primary" type="submit"><%= T('Sign in') %></button>
|
<button class="btn btn-primary" type="submit"><%- T('Sign in') %></button>
|
||||||
<div>
|
<div>
|
||||||
<span class="small"><input name="remember_me" value="1" type="checkbox"/> <%= T('Remember me') %></span>
|
<span class="small"><input name="remember_me" value="1" type="checkbox"/> <%- T('Remember me') %></span>
|
||||||
<span class="small">·</span>
|
<span class="small">·</span>
|
||||||
<a href="#reset_password" class="small"><%= T('Forgot password?') %></a>
|
<a href="#reset_password" class="small"><%- T('Forgot password?') %></a>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
@ -24,16 +24,16 @@
|
||||||
<% if !_.isEmpty(@auth_providers): %>
|
<% if !_.isEmpty(@auth_providers): %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<p>--- <%= T('or') %> ---</p>
|
<p>--- <%- T('or') %> ---</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<p><%= T('Sign in using') %></p>
|
<p><%- T('Sign in using') %></p>
|
||||||
<ul>
|
<ul>
|
||||||
<% for auth_provider in @auth_providers: %>
|
<% for auth_provider in @auth_providers: %>
|
||||||
<li><a href="<%= auth_provider.url %>"><%= T(auth_provider.name) %></a></li>
|
<li><a href="<%= auth_provider.url %>"><%- T(auth_provider.name) %></a></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
@ -42,14 +42,14 @@
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<p>--- <%= T('or') %> ---</p>
|
<p>--- <%- T('or') %> ---</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<p><%= T('New to') %> <%= Config.product_name %>, <%= T('join today!') %></p>
|
<p><%- T('New to') %> <%= Config.product_name %>, <%- T('join today!') %></p>
|
||||||
<p><a href="#signup" class="btn"><%= T('Sign up') %></a>
|
<p><a href="#signup" class="btn"><%- T('Sign up') %></a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -6,53 +6,53 @@
|
||||||
<% for item in @navbar_left: %>
|
<% for item in @navbar_left: %>
|
||||||
<% if item.child: %>
|
<% if item.child: %>
|
||||||
<li class="dropdown">
|
<li class="dropdown">
|
||||||
<a href="<%= item.target %>" class="dropdown-toggle" data-toggle="dropdown"><%= T(item.name) %> <b class="caret"></b></a>
|
<a href="<%= item.target %>" class="dropdown-toggle" data-toggle="dropdown"><%- T(item.name) %> <b class="caret"></b></a>
|
||||||
<ul class="dropdown-menu">
|
<ul class="dropdown-menu">
|
||||||
<% for item in item.child: %>
|
<% for item in item.child: %>
|
||||||
<% if item.divider: %>
|
<% if item.divider: %>
|
||||||
<li class="divider"></li>
|
<li class="divider"></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if item.navheader: %>
|
<% if item.navheader: %>
|
||||||
<li class="nav-header"><%= T(item.navheader) %></li>
|
<li class="nav-header"><%- T(item.navheader) %></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<li><a href="<%= item.target %>"><%= T(item.name) %><% if item['count'] isnt undefined: %> <span class="count">(<%= item['count'] %>)</span><% end %></a></li>
|
<li><a href="<%= item.target %>"><%- T(item.name) %><% if item['count'] isnt undefined: %> <span class="count">(<%= item['count'] %>)</span><% end %></a></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
<li><a href="<%= item.target %>"><%= T(item.name) %></a></li>
|
<li><a href="<%= item.target %>"><%- T(item.name) %></a></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
<form class="navbar-search pull-left">
|
<form class="navbar-search pull-left">
|
||||||
<input class="search-query" type="search" value="" placeholder="Search"/>
|
<input class="search-query" type="search" value="" placeholder="<%- Ti('Search') %>"/>
|
||||||
</form>
|
</form>
|
||||||
<% if @user: %>
|
<% if @user: %>
|
||||||
<ul class="nav pull-right">
|
<ul class="nav pull-right">
|
||||||
<% for item in @navbar_right: %>
|
<% for item in @navbar_right: %>
|
||||||
<% if item.child: %>
|
<% if item.child: %>
|
||||||
<li class="dropdown">
|
<li class="dropdown">
|
||||||
<a href="<%= item.target %>" class="dropdown-toggle" data-toggle="dropdown"><%= T(item.name) %> <b class="caret"></b></a>
|
<a href="<%= item.target %>" class="dropdown-toggle" data-toggle="dropdown"><%- T(item.name) %> <b class="caret"></b></a>
|
||||||
<ul class="dropdown-menu">
|
<ul class="dropdown-menu">
|
||||||
<% for item in item.child: %>
|
<% for item in item.child: %>
|
||||||
<% if item.divider: %>
|
<% if item.divider: %>
|
||||||
<li class="divider"></li>
|
<li class="divider"></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if item.navheader: %>
|
<% if item.navheader: %>
|
||||||
<li class="nav-header"><%= T(item.navheader) %></li>
|
<li class="nav-header"><%- T(item.navheader) %></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<li><a href="<%= item.target %>"><%= T(item.name) %><% if item['count'] isnt undefined: %> <span class="count">(<%= item['count'] %>)</span><% end %></a></li>
|
<li><a href="<%= item.target %>"><%- T(item.name) %><% if item['count'] isnt undefined: %> <span class="count">(<%= item['count'] %>)</span><% end %></a></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
<li><a href="<%= item.target %>"><%= T(item.name) %></a></li>
|
<li><a href="<%= item.target %>"><%- T(item.name) %></a></li>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
<ul class="nav pull-right">
|
<ul class="nav pull-right">
|
||||||
<li><a href="#login"><%= T('Sign in') %></a></li>
|
<li><a href="#login"><%- T('Sign in') %></a></li>
|
||||||
</ul>
|
</ul>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
<div class="hero-unit">
|
<div class="hero-unit">
|
||||||
<h2>Forgot your password?<small></small></h2>
|
<h2><%- T('Forgot your password?') %><small></small></h2>
|
||||||
|
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<form>
|
<form>
|
||||||
<p>
|
<p>
|
||||||
<%- @form %>
|
<%- @form %>
|
||||||
</p>
|
</p>
|
||||||
<a href="#/" class="btn cancel">Cancel</a>
|
<a href="#/" class="btn cancel"><%- T('Cancel') %></a>
|
||||||
<button class="btn btn-primary submit">Submit</button>
|
<button class="btn btn-primary submit"><%- T('Submit') %></button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
|
@ -1,11 +1,11 @@
|
||||||
<div class="hero-unit">
|
<div class="hero-unit">
|
||||||
<h2>Choose your new password.<small></small></h2>
|
<h2><%- T('Choose your new password.') %><small></small></h2>
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<form>
|
<form>
|
||||||
<p>
|
<p>
|
||||||
<%- @form %>
|
<%- @form %>
|
||||||
</p>
|
</p>
|
||||||
<button class="btn btn-primary submit">Submit</button>
|
<button class="btn btn-primary submit"><%- T('Submit') %></button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<form class="">
|
<form class="">
|
||||||
<h2><%= T(@setting.title) %></h2>
|
<h2><%- T(@setting.title) %></h2>
|
||||||
<p><%= T(@setting.description) %></p>
|
<p><%- T(@setting.description) %></p>
|
||||||
<%- @form %>
|
<%- @form %>
|
||||||
<button type="submit" class="btn"><%= T('Submit') %></button>
|
<button type="submit" class="btn"><%- T('Submit') %></button>
|
||||||
</form>
|
</form>
|
||||||
<hr/>
|
<hr/>
|
|
@ -1,13 +1,13 @@
|
||||||
<div class="hero-unit">
|
<div class="hero-unit">
|
||||||
<h1><%= T('Join') %> <%= Config.product_name %><small></small></h1>
|
<h1><%- T('Join') %> <%= Config.product_name %><small></small></h1>
|
||||||
|
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<form class="form-horizontal">
|
<form class="form-horizontal">
|
||||||
<p>
|
<p>
|
||||||
<%- @form %>
|
<%- @form %>
|
||||||
</p>
|
</p>
|
||||||
<a href="#/" class="btn cancel"><%= T('Cancel') %></a>
|
<a href="#/" class="btn cancel"><%- T('Cancel') %></a>
|
||||||
<button class="btn btn-primary submit"><%= T('Create my account') %></button>
|
<button class="btn btn-primary submit"><%- T('Create my account') %></button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
|
@ -1,11 +1,11 @@
|
||||||
<div class="well">
|
<div class="well">
|
||||||
<h3>Templates</h3>
|
<h3><%- T('Templates') %></h3>
|
||||||
<%- @form %>
|
<%- @form %>
|
||||||
<!--<button type="submit" class="btn" data-type="template_edit">Edit</button>-->
|
<!--<button type="submit" class="btn" data-type="template_edit"><%- T('Edit') %></button>-->
|
||||||
<button type="submit" class="btn" data-type="template_delete">Delete</button>
|
<button type="submit" class="btn" data-type="template_delete"><%- T('Delete') %></button>
|
||||||
<button type="submit" class="btn" data-type="template_select">Apply</button>
|
<button type="submit" class="btn" data-type="template_select"><%- T('Apply') %></button>
|
||||||
<hr/>
|
<hr/>
|
||||||
<label class="" for="template_name">Save as Template</label>
|
<label class="" for="template_name"><%- T('Save as Template') %></label>
|
||||||
<input type="text" name="template_name" id="template_name" class="span2" value="<%= @template.name %>"/>
|
<input type="text" name="template_name" id="template_name" class="span2" value="<%= @template.name %>"/>
|
||||||
<button type="submit" class="btn" data-type="template_save">Save</button>
|
<button type="submit" class="btn" data-type="template_save"><%- T('Save') %></button>
|
||||||
</div>
|
</div>
|
|
@ -1,19 +1,19 @@
|
||||||
<div class="well">
|
<div class="well">
|
||||||
<h3><%= T('Customer') %></h3>
|
<h3><%- T('Customer') %></h3>
|
||||||
<% if @user.image: %>
|
<% if @user.image: %>
|
||||||
<img class="thumbnail" src="<%- @user.image %>" alt="">
|
<img class="thumbnail" src="<%- @user.image %>" alt="">
|
||||||
<% end %>
|
<% end %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="customer-info" title="<%= T('Name') %>"><%= @user['realname'] %></div>
|
<div class="customer-info" title="<%- Ti('Name') %>"><%= @user['realname'] %></div>
|
||||||
</div>
|
</div>
|
||||||
<% for row in @data: %>
|
<% for row in @data: %>
|
||||||
<% if @user[row.name] || row.name is 'note': %>
|
<% if @user[row.name] || row.name is 'note': %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<% if row.tag isnt 'textarea': %>
|
<% if row.tag isnt 'textarea': %>
|
||||||
<div class="customer-info" title="<%= T(row.display) %>"><%- window.linkify( @user[row.name] ) %></div>
|
<div class="customer-info" title="<%- Ti(row.display) %>"><%- window.linkify( @user[row.name] ) %></div>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
<div class="customer-info" title="<%= T(row.display) %>">
|
<div class="customer-info" title="<%- Ti(row.display) %>">
|
||||||
<strong><%= T(row.display) %></strong><br/>
|
<strong><%- T(row.display) %></strong><br/>
|
||||||
<textarea class="customer-info" rows="3" name="<%= row.name %>" data-type=edit><%= @user[row.name] %></textarea>
|
<textarea class="customer-info" rows="3" name="<%= row.name %>" data-type=edit><%= @user[row.name] %></textarea>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
@ -23,7 +23,7 @@
|
||||||
<% if !_.isEmpty(@user['accounts']): %>
|
<% if !_.isEmpty(@user['accounts']): %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="customer-info">
|
<div class="customer-info">
|
||||||
<strong><%= T('Linked Accounts') %></strong><br/>
|
<strong><%- T('Linked Accounts') %></strong><br/>
|
||||||
<% for account of @user['accounts']: %>
|
<% for account of @user['accounts']: %>
|
||||||
<a href="<%= @user['accounts'][account]['link'] %>" target="_blank"><%= account %></a>
|
<a href="<%= @user['accounts'][account]['link'] %>" target="_blank"><%= account %></a>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
@ -34,14 +34,14 @@
|
||||||
<% for link in @user['links']: %>
|
<% for link in @user['links']: %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="customer-info">
|
<div class="customer-info">
|
||||||
<strong><%= T(link['title']) %></strong><br/>
|
<strong><%- T(link['title']) %></strong><br/>
|
||||||
<% for item in link['items']: %>
|
<% for item in link['items']: %>
|
||||||
<% if item['url']: %>
|
<% if item['url']: %>
|
||||||
<a href="<%= item['url'] %>" title="<%= T(item['title']) %>" style="<%= item['style'] %>" data-type="<%= item['data'] %>" class="<%= item['class'] %>" <% if link.new_window: %>target="_blank"<% end %>>
|
<a href="<%= item['url'] %>" title="<%- Ti(item['title']) %>" style="<%= item['style'] %>" data-type="<%= item['data'] %>" class="<%= item['class'] %>" <% if link.new_window: %>target="_blank"<% end %>>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
<span title="<%= T(item['title']) %>" style="<%= item['style'] %>" data-type="<%= item['data'] %>" class="<%= item['class'] %>">
|
<span title="<%- Ti(item['title']) %>" style="<%= item['style'] %>" data-type="<%= item['data'] %>" class="<%= item['class'] %>">
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= T(item['name']) %> <% if item['count'] isnt undefined: %><span class="count">(<%= item['count'] %>)</span><% end %>
|
<%- T(item['name']) %> <% if item['count'] isnt undefined: %><span class="count">(<%= item['count'] %>)</span><% end %>
|
||||||
<% if item['url']: %>
|
<% if item['url']: %>
|
||||||
</a>
|
</a>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
<% for row in @data: %>
|
<% for row in @data: %>
|
||||||
<% if @user[row.name]: %>
|
<% if @user[row.name]: %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="customer-info" title="<%= T(row.display) %>"><%- window.linkify( @user[row.name] ) %></div>
|
<div class="customer-info" title="<%- T(row.display) %>"><%- window.linkify( @user[row.name] ) %></div>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if !_.isEmpty(@user['accounts']): %>
|
<% if !_.isEmpty(@user['accounts']): %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="customer-info">
|
<div class="customer-info">
|
||||||
<strong><%= T('Linked Accounts') %></strong><br/>
|
<strong><%- T('Linked Accounts') %></strong><br/>
|
||||||
<% for account of @user['accounts']: %>
|
<% for account of @user['accounts']: %>
|
||||||
<a href="<%= @user['accounts'][account]['link'] %>" target="_blank"><%= account %></a>
|
<a href="<%= @user['accounts'][account]['link'] %>" target="_blank"><%= account %></a>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
@ -19,14 +19,14 @@
|
||||||
<% for link in @user['links']: %>
|
<% for link in @user['links']: %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="customer-info">
|
<div class="customer-info">
|
||||||
<strong><%= T(link['title']) %></strong><br/>
|
<strong><%- T(link['title']) %></strong><br/>
|
||||||
<% for item in link['items']: %>
|
<% for item in link['items']: %>
|
||||||
<% if item['url']: %>
|
<% if item['url']: %>
|
||||||
<a href="<%= item['url'] %>" title="<%= T(item['title']) %>" style="<%= item['style'] %>" data-type="<%= item['data'] %>" class="<%= item['class'] %>" <% if link.new_window: %>target="_blank"<% end %>>
|
<a href="<%= item['url'] %>" title="<%- T(item['title']) %>" style="<%= item['style'] %>" data-type="<%= item['data'] %>" class="<%= item['class'] %>" <% if link.new_window: %>target="_blank"<% end %>>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
<span title="<%= T(item['title']) %>" style="<%= item['style'] %>" data-type="<%= item['data'] %>" class="<%= item['class'] %>">
|
<span title="<%- T(item['title']) %>" style="<%= item['style'] %>" data-type="<%= item['data'] %>" class="<%= item['class'] %>">
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= T(item['name']) %> <% if item['count'] isnt undefined: %><span class="count">(<%= item['count'] %>)</span><% end %>
|
<%- T(item['name']) %> <% if item['count'] isnt undefined: %><span class="count">(<%= item['count'] %>)</span><% end %>
|
||||||
<% if item['url']: %>
|
<% if item['url']: %>
|
||||||
</a>
|
</a>
|
||||||
<% else: %>
|
<% else: %>
|
||||||
|
|
|
@ -189,6 +189,23 @@ footer {
|
||||||
padding-right: 10px;
|
padding-right: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.translation {
|
||||||
|
border: 1px dotted #F92;
|
||||||
|
-webkit-border-radius: 3px;
|
||||||
|
-moz-border-radius: 3px;
|
||||||
|
border-radius: 3px;
|
||||||
|
}
|
||||||
|
.translation:hover {
|
||||||
|
}
|
||||||
|
|
||||||
|
.translation .icon-edit {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.translation:hover .icon-edit {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* noty changes
|
* noty changes
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in a new issue