[fix] [patch] check in_list_view for Custom DocTypes

This commit is contained in:
Anand Doshi 2013-07-17 12:41:19 +05:30
parent 55da1ff98a
commit 1ba072fa9b

View File

@ -2,7 +2,7 @@ import webnotes
from webnotes.model import no_value_fields
def execute():
for dt in webnotes.conn.sql("""select name from `tabDocType` where custom=1"""):
for dt in webnotes.conn.sql_list("""select name from `tabDocType` where custom=1"""):
dtbean = webnotes.bean("DocType", dt)
if any((df.in_list_view for df in dtbean.doclist.get({"doctype": "DocField", "parent": dt}))):