Thank you both for your replies.
I did as Martin suggests:
In the module file:
FREETIER1_NAVLIST=[STYLESHEETNAVID, SMARTLINKSNAVID, DOWNLOADVCARDNAVID,
QRCODENAVID, HEADLINENAVID]
In the controller:
navlist=[UPDATEACCOUNTNAVID]
if interfaceCategoryID==FREETIER1ID:
navlist= navlist + FREETIER1_NAVLIST
elif interfaceCategoryID==TIER1ID:
navlist=navlist + TIER1_NAVLIST
elif interfaceCategoryID==TIER2ID:
navlist=navlist + TIER2_NAVLIST
elif interfaceCategoryID==TIER3ID:
navlist=navlist + TIER3_NAVLIST
if form.vars.navID:
navlist=navlist + form.vars.navID
navs=db(db.nav.id.belongs(navlist)).select(orderby=db.nav.id)
It works , and I'll never forget the difference between a list and a tuple
;-)
The stupid thing is that I read about the difference between list and tuple
a dozen times.
The navID in form.vars.navID is a list:reference to table nav
Kind regards,
Annet
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.