another parse_as_rest patch, thanks Denes
This commit is contained in:
1 parent
8a2c0c320e
commit
10a39fd52c
2 files changed
+5
-3
No files matched your search
+4
-2
@@ -7378,8 +7378,10 @@ def index():
|
||||
selfld = '_id'
|
||||
if db[table][field].type.startswith('reference '):
|
||||
refs = [ x.name for x in db[otable] if x.type == db[table][field].type ]
|
||||
if refs:
|
||||
selfld = refs[0]
|
||||
else:
|
||||
refs = [ x.name for x in db[table]._referenced_by if x.tablename==otable ]
|
||||
if refs:
|
||||
selfld = refs[0]
|
||||
if nested_select:
|
||||
try:
|
||||
dbset=db(db[table][field].belongs(dbset._select(db[otable][selfld])))
|
||||
|
||||
Reference in new issue
Block a user