Hello,
I have defined in custom/Espo/Custom/Resources/metadata/entitydef a view for a field. Then the field appear to show fine on my detailed view in terms of format and the fact that it inherits the properties from foreign field.
Can someone help on inserting data in the field based on a name/id that also appear on the detail view and belongs to the same entity as the field?
Here is my custom field view:
Espo.define('custom:views/obiectiv-de-investitii/fields/judet', 'views/fields/link', function (Dep) {
return Dep.extend({
template: 'customb-inv/detail',
setup: function() {
Dep.prototype.setup.call(this);
this.listenTo(this.model, 'change:judet', function () {
actionSetfield();
}, this);
},
actionSetfield: function() {
$.ajax({
url: url,
success: function() {
var elem = $('#judet');
elem.html('<h3>Test</h3>');
}.bind(this)
});
},
afterRender: function() {
Dep.prototype.afterRender.call(this);
}
});
});
Thanks.
I have defined in custom/Espo/Custom/Resources/metadata/entitydef a view for a field. Then the field appear to show fine on my detailed view in terms of format and the fact that it inherits the properties from foreign field.
Can someone help on inserting data in the field based on a name/id that also appear on the detail view and belongs to the same entity as the field?
Here is my custom field view:
Espo.define('custom:views/obiectiv-de-investitii/fields/judet', 'views/fields/link', function (Dep) {
return Dep.extend({
template: 'customb-inv/detail',
setup: function() {
Dep.prototype.setup.call(this);
this.listenTo(this.model, 'change:judet', function () {
actionSetfield();
}, this);
},
actionSetfield: function() {
$.ajax({
url: url,
success: function() {
var elem = $('#judet');
elem.html('<h3>Test</h3>');
}.bind(this)
});
},
afterRender: function() {
Dep.prototype.afterRender.call(this);
}
});
});
Thanks.
Comment