[web2py] Re: menu.py loop

2012-01-25 Thread Web2Py Freak
oh Dam , i didnt see that , Thank you anthony :) its working well now

[web2py] Re: menu.py loop

2012-01-25 Thread Anthony
On Wednesday, January 25, 2012 9:23:51 AM UTC-5, Web2Py Freak wrote: > > it keep giving me en error in the response.menu failed to compile file > because: > SyntaxError at line 30 at char 7 > invalid syntax (C:/web2py/applications/a3zif/models/menu.py, line > 30) , this is my code : > > > ins

[web2py] Re: menu.py loop

2012-01-25 Thread Web2Py Freak
it keep giving me en error in the response.menu failed to compile file because: SyntaxError at line 30 at char 7 invalid syntax (C:/web2py/applications/a3zif/models/menu.py, line 30) , this is my code : instruments = db().select(db.Instruments.ALL) myins = [] for ins in instruments: myins.appe

[web2py] Re: menu.py loop

2012-01-25 Thread Anthony
> > response.menu = [ > (T('Home'), False, URL('default','index'), []) > (T('Instruments'), False, URL('default','Instruments'), [myins])] You have put myins inside a list, but it is already a list. Instead: response.menu = [ (T('Home'), False, URL('default','index'), []) (

Re: [web2py] Re: menu.py loop

2012-01-25 Thread Johann Spies
On 25 January 2012 12:04, Web2Py Freak wrote: > i Fixed a bug its now > > instruments = db().select(db.Instruments.ALL) > myins = [] > for ins in instruments: > myins.append((T(ins.Instrument_name), False, > URL('default','Instruments',args=ins.Instrument_name),) > response.menu = [ >(T('

[web2py] Re: menu.py loop

2012-01-25 Thread Web2Py Freak
i Fixed a bug its now instruments = db().select(db.Instruments.ALL) myins = [] for ins in instruments: myins.append((T(ins.Instrument_name), False, URL('default','Instruments',args=ins.Instrument_name),) response.menu = [ (T('Home'), False, URL('default','index'), []) (T('Instruments')