I need to edit a view in EspoCrm. Should i inherit it from excisting, or just edit? Used documentation, but nothing happens.
I added views and recordViews fields in custom/Espo/Custom/Resources/metadata/clientDefs/Contact.json
then created client/custom/src/views/Contact/record/detail.js
,
but it has no effect
Asked
Active
Viewed 2,212 times
0

Artem Y
- 113
- 1
- 7
1 Answers
2
Your custom/Espo/Custom/Resources/metadata/clientDefs/Contact.json
file has to contain such code
{
"recordViews": {
"detail": "custom:views/contact/record/detail"
}
}
Check if json is valid.
Rename your folder Contact to contact (lower case)
new path has to be client/custom/src/views/contact/record/detail.js
You need to inherit it from some class, 'view'
at least. But better is from 'crm:views/contact/record/detail'
, because you don't lose the main functionality. But it is not necessary. You can use general class 'views/record/detail'
as well.
In this case this file start with
Espo.define('custom:views/contact/record/detail', 'crm:views/contact/record/detail', function (Dep) {
Don't forget to rebuild EspoCRM in Administration.

LeiT
- 156
- 1
- 3
-
Thanks, it was very helpful – Artem Y Jun 29 '17 at 09:08