[web2py] Paginate

2015-06-22 Thread KevC
Hi community. I am trying paginate a query well is a sub query, I have differents field from differents tables and I inserted these in a form, I make a query and I got many results, What can I do to show this results for example, 10 per page? I hope that you can help me. My best regards. -

[web2py] Dropdown

2015-05-26 Thread KevC
I have a problem. I´m working with a dropdown, when I choose a option it get a FORM, and I have a field for all forms. If I choose a option my fields erase. I wanna get that variable. What can I do? For example, this is a form: Title: Data warehouse Type: | Article |

[web2py] blob field

2015-05-21 Thread KevC
Hi! I have a problem while I wanna download a file from database. I dont wanna save the file in the folder 'uploads', I wanna save it in my database. I use this example. db.define_table('libro', Field('titulo','string', requires=IS_NOT_EMPTY(error_message='Introduzca título'),label='Titulo'

[web2py] request

2015-05-20 Thread KevC
Hi community! I have a question about how use variables. I wanna use a "INPUT" like a variable, I don't wanna the strings or integer or text, etc that there is in the "INPUT". I only use the INPUT, I need to do a comparison. What can I do? Maybe Can I use a "request"? But, How? Thanks My best

[web2py] Using "for"

2015-05-12 Thread KevC
Hi! I got a problem, I wanna print a list or string on a 'view' using a 'for' but the view only show me the last number or letter. For example: My controller... for i in 'hola': print i return locals() My view... {{=i}} The view only show me the letter 'a'. Other example: a = [1

[web2py] function

2015-05-12 Thread KevC
Hi community! I want to call a function inside other function, What can I do? For example: def function_1(): y = 'This is an example' (I wanna here my function "function_2") return locals() def function_2(): x = 'Hello world' return locals() My best regards. -- Resourc

[web2py] Show tables

2015-05-06 Thread KevC
Hi community! I want to crate a sub consulting and show it a user, Can I use a SQLFORM grid or is there other way? I wanna show two tables and the users must to have permissions like create, edit, delete, etc. His own records. This two tables that I want to show, It is a many to many relation,

[web2py] Show tables

2015-04-28 Thread KevC
Hi! I want to show two or more tables. Can I use "SQLForm.grid"? If so, Can you give me an example? Please. Or, Can I do it other way? Best regards. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.goog

[web2py] upload field

2015-04-25 Thread KevC
Hi! I want to upload a file type .PDF in upload field but I only aceept this type of file. What can I do? I hope you can help me. Best regards. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.co

[web2py] SQLFORM, add field with button

2015-04-17 Thread KevC
Hi community. I want to know if you could help me. I started to use web2py, but I don't know some things. I want to create fields with a button on SQLFORM and HTML. For example, I have author table and book table, but a book can get several authors and I need to create differents "INPUT" on the F

[web2py] Add field with button on SQLFORM

2015-04-17 Thread KevC
Hi community! Good afternoon, my name is Kevin. I want to know if you could help me. I started to use web2py, but I don't know some things. I want to create fields with a button on SQLFORM and HTML. For example, I have author table and book table, but a book can get several authors and I need