fix link multiple field
This commit is contained in:
@@ -289,7 +289,7 @@ Espo.define('views/fields/link-multiple', 'views/fields/base', function (Dep) {
|
||||
addLinkHtml: function (id, name) {
|
||||
var $container = this.$el.find('.link-container');
|
||||
var $el = $('<div />').addClass('link-' + id).addClass('list-group-item').attr('data-id', id);
|
||||
$el.html(this.getHelper().stripTags(name) + ' ');
|
||||
$el.html(this.getHelper().stripTags(name || id) + ' ');
|
||||
$el.prepend('<a href="javascript:" class="pull-right" data-id="' + id + '" data-action="clearLink"><span class="glyphicon glyphicon-remove"></a>');
|
||||
$container.append($el);
|
||||
|
||||
@@ -297,7 +297,8 @@ Espo.define('views/fields/link-multiple', 'views/fields/base', function (Dep) {
|
||||
},
|
||||
|
||||
getDetailLinkHtml: function (id) {
|
||||
return '<a href="#' + this.foreignScope + '/view/' + id + '">' + this.getHelper().stripTags(this.nameHash[id]) + '</a>';
|
||||
var name = this.nameHash[id] || id;
|
||||
return '<a href="#' + this.foreignScope + '/view/' + id + '">' + this.getHelper().stripTags(name) + '</a>';
|
||||
},
|
||||
|
||||
getValueForDisplay: function () {
|
||||
|
||||
Reference in New Issue
Block a user