Skip to content

Commit

Permalink
fix(ux): make OM and IM long fields collapsible
Browse files Browse the repository at this point in the history
  • Loading branch information
s-aga-r committed Nov 18, 2024
1 parent 947f79a commit 4415239
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 9 deletions.
15 changes: 12 additions & 3 deletions mail_client/mail_client/doctype/incoming_mail/incoming_mail.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
"dmarc_description",
"section_break_qijk",
"message",
"section_break_vtax",
"amended_from"
],
"fields": [
Expand Down Expand Up @@ -119,8 +120,10 @@
"fieldtype": "Column Break"
},
{
"collapsible": 1,
"fieldname": "section_break_eomq",
"fieldtype": "Section Break"
"fieldtype": "Section Break",
"label": "Body"
},
{
"fieldname": "display_name",
Expand Down Expand Up @@ -149,8 +152,10 @@
"fieldtype": "Column Break"
},
{
"collapsible": 1,
"fieldname": "section_break_qijk",
"fieldtype": "Section Break"
"fieldtype": "Section Break",
"label": "Message"
},
{
"fieldname": "spf_description",
Expand Down Expand Up @@ -426,13 +431,17 @@
"label": "Incoming Mail Log",
"no_copy": 1,
"read_only": 1
},
{
"fieldname": "section_break_vtax",
"fieldtype": "Section Break"
}
],
"in_create": 1,
"index_web_pages_for_search": 1,
"is_submittable": 1,
"links": [],
"modified": "2024-11-16 15:35:14.385560",
"modified": "2024-11-18 13:33:53.161839",
"modified_by": "Administrator",
"module": "Mail Client",
"name": "Incoming Mail",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ def create_incoming_mail(
except Exception:
frappe.log_error(
title="Submit Incoming Mail",
message=frappe.get_traceback(with_context=False),
message=frappe.get_traceback(with_context=True),
)

return doc
Expand Down
20 changes: 15 additions & 5 deletions mail_client/mail_client/doctype/outgoing_mail/outgoing_mail.json
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,11 @@
"fieldtype": "Section Break"
},
{
"collapsible": 1,
"collapsible_depends_on": "eval: doc.__islocal",
"fieldname": "section_break_ijwo",
"fieldtype": "Section Break"
"fieldtype": "Section Break",
"label": "Body"
},
{
"default": "Draft",
Expand Down Expand Up @@ -128,8 +131,10 @@
"fieldtype": "Column Break"
},
{
"collapsible": 1,
"fieldname": "section_break_kops",
"fieldtype": "Section Break"
"fieldtype": "Section Break",
"label": "Message"
},
{
"fieldname": "body_plain",
Expand All @@ -152,8 +157,11 @@
"options": "Mail Header"
},
{
"collapsible": 1,
"collapsible_depends_on": "eval: doc.custom_headers.length > 0",
"fieldname": "section_break_atoq",
"fieldtype": "Section Break"
"fieldtype": "Section Break",
"label": "Custom Headers"
},
{
"fieldname": "amended_from",
Expand Down Expand Up @@ -316,8 +324,10 @@
{
"fieldname": "raw_message",
"fieldtype": "Code",
"hidden": 1,
"label": "Raw Message",
"no_copy": 1
"no_copy": 1,
"read_only": 1
},
{
"fieldname": "section_break_ubzr",
Expand Down Expand Up @@ -461,7 +471,7 @@
"index_web_pages_for_search": 1,
"is_submittable": 1,
"links": [],
"modified": "2024-11-16 15:35:03.128521",
"modified": "2024-11-18 13:28:37.419469",
"modified_by": "Administrator",
"module": "Mail Client",
"name": "Outgoing Mail",
Expand Down

0 comments on commit 4415239

Please sign in to comment.