Skip to content

EspoCRM – Open Source CRM Application

case additional list layouts

Yurii6d3c1b8bb7b1
diff --git a/application/Espo/Modules/Crm/Resources/layouts/Case/list.json b/application/Espo/Modules/Crm/Resources/layouts/Case/list.json
index b2b2f91736..51260f7301 100644
--- a/application/Espo/Modules/Crm/Resources/layouts/Case/list.json
+++ b/application/Espo/Modules/Crm/Resources/layouts/Case/list.json
@@ -1,8 +1,8 @@
[
- {"name":"name", "link": true},
- {"name":"number", "widthPx": 100},
- {"name":"status", "width": 11},
- {"name":"priority", "width": 11},
- {"name":"account", "width": 18},
- {"name":"assignedUser", "width": 14}
-]
\ No newline at end of file
+ {"name": "name", "link": true},
+ {"name": "number", "widthPx": 100},
+ {"name": "status", "width": 11},
+ {"name": "priority", "width": 11},
+ {"name": "account", "width": 18},
+ {"name": "assignedUser", "width": 14}
+]
diff --git a/application/Espo/Modules/Crm/Resources/layouts/Case/listForAccount.json b/application/Espo/Modules/Crm/Resources/layouts/Case/listForAccount.json
new file mode 100644
index 0000000000..e3d6c3a6ed
--- /dev/null
+++ b/application/Espo/Modules/Crm/Resources/layouts/Case/listForAccount.json
@@ -0,0 +1,6 @@
+[
+ {"name": "name", "link": true},
+ {"name": "number", "width": 15},
+ {"name": "status", "width": 16},
+ {"name": "priority", "width": 16}
+]
diff --git a/application/Espo/Modules/Crm/Resources/layouts/Case/listForContact.json b/application/Espo/Modules/Crm/Resources/layouts/Case/listForContact.json
new file mode 100644
index 0000000000..e3d6c3a6ed
--- /dev/null
+++ b/application/Espo/Modules/Crm/Resources/layouts/Case/listForContact.json
@@ -0,0 +1,6 @@
+[
+ {"name": "name", "link": true},
+ {"name": "number", "width": 15},
+ {"name": "status", "width": 16},
+ {"name": "priority", "width": 16}
+]
diff --git a/application/Espo/Modules/Crm/Resources/layouts/Case/listSmall.json b/application/Espo/Modules/Crm/Resources/layouts/Case/listSmall.json
index 630c81384f..55f9ded54d 100644
--- a/application/Espo/Modules/Crm/Resources/layouts/Case/listSmall.json
+++ b/application/Espo/Modules/Crm/Resources/layouts/Case/listSmall.json
@@ -1,6 +1,7 @@
[
- {"name":"name", "link": true},
- {"name":"number", "width": 18},
- {"name":"status", "width": 19},
- {"name":"priority", "width": 19}
-]
\ No newline at end of file
+ {"name": "name", "link": true},
+ {"name": "number", "width": 14},
+ {"name": "status", "width": 14},
+ {"name": "priority", "width": 14},
+ {"name": "account", "width": 22}
+]
diff --git a/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Account.json b/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Account.json
index 7052229403..a167f73bb3 100644
--- a/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Account.json
+++ b/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Account.json
@@ -78,6 +78,9 @@
"rowActionsView": "crm:views/record/row-actions/relationship-target",
"layout": "listForTarget",
"view": "crm:views/record/panels/target-lists"
+ },
+ "cases": {
+ "layout": "listForAccount"
}
},
"filterList": [
diff --git a/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Case.json b/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Case.json
index 4ddbb3bc2c..a19e301c9a 100644
--- a/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Case.json
+++ b/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Case.json
@@ -113,6 +113,12 @@
},
"listPortal": {
"type": "list"
+ },
+ "listForAccount": {
+ "type": "listSmall"
+ },
+ "listForContact": {
+ "type": "listSmall"
}
},
"iconClass": "fas fa-briefcase"
diff --git a/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Contact.json b/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Contact.json
index 8604803a33..2e38a46590 100644
--- a/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Contact.json
+++ b/application/Espo/Modules/Crm/Resources/metadata/clientDefs/Contact.json
@@ -75,7 +75,8 @@
"id": "contactId",
"name": "contactName"
},
- "selectHandler": "handlers/select-related/same-account"
+ "selectHandler": "handlers/select-related/same-account",
+ "layout": "listForContact"
},
"targetLists": {
"create": false,