fix(list_view): check that a title field is set before trying to use it
Otherwise enabling the checkbox for `Warehouse` and trying to load `Stock Ledger Entry` results in `warehouse. as warehouse_` Signed-off-by: Akhil Narang <me@akhilnarang.dev>
This commit is contained in:
parent
c62e7334bc
commit
a1b4d44b62
1 changed files with 1 additions and 1 deletions
|
|
@ -209,7 +209,7 @@ frappe.views.ListView = class ListView extends frappe.views.BaseList {
|
|||
) {
|
||||
frappe.model.with_doctype(df.options, () => {
|
||||
const meta = frappe.get_meta(df.options);
|
||||
if (meta.show_title_field_in_link) {
|
||||
if (meta.show_title_field_in_link && meta.title_field) {
|
||||
this.link_field_title_fields[
|
||||
typeof f === "string" ? f : f.fieldname
|
||||
] = meta.title_field;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue