fix(minor): handle importing of doctype when links are missing
This commit is contained in:
parent
ebc961cf84
commit
5d2a1ea47a
1 changed files with 2 additions and 1 deletions
|
|
@ -302,7 +302,8 @@ class BaseDocument(object):
|
|||
try:
|
||||
return self.meta.get_field(fieldname).options
|
||||
except AttributeError:
|
||||
print('Unable to find options for {}'.format(fieldname))
|
||||
if self.doctype == 'DocType':
|
||||
return dict(links='DocType Link', actions='DocType Action').get(fieldname)
|
||||
raise
|
||||
|
||||
def get_parentfield_of_doctype(self, doctype):
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue