[web2py] Angular 2 and web2py

2017-01-06 Thread 'John Philip' via web2py-users
Hi there, I searched for this however I could not find an answer. Is it possible to use Angular 2 in web2py ? thanks and regards, John -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py

Re: [web2py] Angular 2 and web2py

2017-01-06 Thread António Ramos
http://www.web2pyslices.com/slice/show/1894/web2py-and-angularjs-handlebars-delimiters 2017-01-06 10:27 GMT+00:00 'John Philip' via web2py-users < web2py@googlegroups.com>: > Hi there, > > I searched for this however I could not find an answer. Is it possible to > use Angular 2 in web2py ? > > th

Re: [web2py] Angular 2 and web2py

2017-01-06 Thread 'John Philip' via web2py-users
Hi Ramos, thanks for your quick reply. I did manage to get angular js working but I was wondering if it also works for Angular 2 since this is a bit different to Angular JS. thanks, John On Friday, January 6, 2017 at 11:41:07 AM UTC+1, Ramos wrote: > > > http://www.web2pyslices.com/slice/show

Re: [web2py] Angular 2 and web2py

2017-01-06 Thread António Ramos
I gave up on angular when i found Vuejs 2017-01-06 10:48 GMT+00:00 'John Philip' via web2py-users < web2py@googlegroups.com>: > Hi Ramos, > > thanks for your quick reply. I did manage to get angular js working but I > was wondering if it also works for Angular 2 since this is a bit different

Re: [web2py] Re: New feature in trunk conditional fields RFC

2017-01-06 Thread Meinolf
Hello How do i implement these conditional fields in a custom auth table? I tried the following but does not seem to hide the grade field. #Start of definition of custom Auth tables to be used instead of the default ones. auth = Auth(db) db.define_table(auth.settings.table_user_name,

[web2py] Re: Made with web2py

2017-01-06 Thread Marlysson Silva
Great project.. Can you explain the pytest plugin project? It is a plugin or a package to test web2py applications? I could like to contribute with more knowledgement of project Em quinta-feira, 5 de janeiro de 2017 18:32:17 UTC-3, Mathieu Clabaut escreveu: > > Hello everybody, > > This is ju

[web2py] Re: Creating table from a controller

2017-01-06 Thread Marlysson Silva
You can use the variable_db_conection.define_table(...) into your controller , using the data received from form submitted .. def create_table(): data = some_request_data_object variable_db.define_table(data['table_name'], Field(data['field_name'],'type'), Field(data['fi

[web2py] Re: import csv (referenced fields)

2017-01-06 Thread Marlysson Silva
What structure of the table ? She need start with name of tabel , following by next line being the name of field names .. Em sexta-feira, 6 de janeiro de 2017 01:18:42 UTC-3, Adam Jed escreveu: > > Hi, > > I have defined tables: > > db.define_table('BL', > Field('name'), >

[web2py] Re: Made with web2py

2017-01-06 Thread Mathieu Clabaut
The idea is to make a pytest plugin, that would allow to run unit_test, webclient and splinter (webclient with javascript enabled UI) tests. I have a version working (see branch master of the aforementioned github project, and the README.md) , but which is still too much coupled with the applicatio

[web2py] Re: Made with web2py

2017-01-06 Thread Marlysson Silva
Great , I will watch your project , I miss too of tests in web2py personal applications .. Em sexta-feira, 6 de janeiro de 2017 08:56:21 UTC-3, Mathieu Clabaut escreveu: > > The idea is to make a pytest plugin, that would allow to run unit_test, > webclient and splinter (webclient with javascr

[web2py] Re: IS_IN_SET or IS_IN_DB to create a sublist based on part of a table

2017-01-06 Thread Anthony
See http://stackoverflow.com/questions/8146260/best-practice-for-populating-dropdown-based-on-other-dropdown-selection-in-web2p/8152910#8152910. Anthony On Thursday, January 5, 2017 at 11:18:46 PM UTC-5, Pierre Corbeil wrote: > > Trying to migrate my old access environment to web2py. I have imp

[web2py] Re: import csv (referenced fields)

2017-01-06 Thread Anthony
Are you saying the CSV files contain string values rather than the integer record IDs in each reference field (e.g., an entry in PL.BL_name is actually a value from the "name" field of BL rather than the integer record ID from BL)? If that is the case, I don't think the built-in import methods

[web2py] Re: Creating table from a controller

2017-01-06 Thread Anthony
On Friday, January 6, 2017 at 6:49:15 AM UTC-5, Marlysson Silva wrote: > > You can use the variable_db_conection.define_table(...) into your > controller , using the data received from form submitted .. > > def create_table(): > > data = some_request_data_object > > variable_db.define_tab

[web2py] Re: Creating table from a controller

2017-01-06 Thread Anthony
On Thursday, January 5, 2017 at 11:18:46 PM UTC-5, Leonardo Dutra wrote: > > Hi guys, > I need to create a table in my db from a controller, such as: > I have my controller and after to submit a form it will create a new table > automatically, it's possible? > If they have better suggestions, ple

[web2py] Re: What is the simplest way to password protect a video?

2017-01-06 Thread Joe
Thanks very much Anthony, that works perfectly! On Thursday, January 5, 2017 at 12:28:58 AM UTC+8, Anthony wrote: > > Would a digitally signed URL provide sufficient protection (no need for a > password in that case): > http://web2py.com/books/default/chapter/29/04/the-core#Digitally-signed-urls

[web2py] Re: Creating table from a controller

2017-01-06 Thread Anthony
On Friday, January 6, 2017 at 8:08:14 AM UTC-5, Anthony wrote: > > On Thursday, January 5, 2017 at 11:18:46 PM UTC-5, Leonardo Dutra wrote: >> >> Hi guys, >> I need to create a table in my db from a controller, such as: >> I have my controller and after to submit a form it will create a new >> ta

[web2py] Self-hosted web analytics solutions for Web2py

2017-01-06 Thread Joe
I am interested in using a self-hosted web analytics solutions on Pythonanywhere for my Web2py apps. I asked this question on the Pythonanywhere forum, they suggested to ask here. Can anyone suggest the best solution for this and let me know the easiest way to install it on the server? Thanks.

Re: [web2py] Angular 2 and web2py

2017-01-06 Thread Anthony
No reason you can't use Angular 2 with web2py, as web2py handles the back end and Angular 2 is a front end framework. The only potential issue is if you are using web2py templates that include Angular template code, you need to change the template delimiters in either web2py or Angular, as alrea

[web2py] Re: LOAD Component returns "invalid function"

2017-01-06 Thread Anthony
On Thursday, January 5, 2017 at 11:07:52 PM UTC-5, briann...@gmail.com wrote: > > Please help with the following: > > In CONTROLLER: > > def get_author(*args): > > See http://web2py.com/books/default/chapter/29/04/the-core#Dispatching. In web2py, actions are functions that take no arguments --

[web2py] Re: Custom forms, I don't undersand

2017-01-06 Thread Jim S
Create the form the way you normally would: in your controller: form = SQLFORM.factory() or form = SQLFORM(.) or grid = SQLFORM.grid(...) form = grid.update_form then in your view, instead of {{=form}} put in something like this: {{=form.custom.begin}} inserts the tag

[web2py] Re: Creating table from a controller

2017-01-06 Thread Marlysson Silva
Then the define_table is restricted to the "context" that they are within ? .. And not to the global object ( db connection ) Em sexta-feira, 6 de janeiro de 2017 10:03:00 UTC-3, Anthony escreveu: > > > On Friday, January 6, 2017 at 6:49:15 AM UTC-5, Marlysson Silva wrote: >> >> You can use the v

{Disarmed} Re: [web2py] Made with web2py

2017-01-06 Thread Carlos Cesar Caballero Díaz
I can´t take a look to the site because Google blocks the platform for my country (Cuba), maybe later using a vpn... I am interested too in your tests plugin, so, "I am watching" :) Greetings. El 05/01/17 a las 16:32, Mathieu Clabaut escribió: Hello everybody, This is just to announce a new

Re: [web2py] Angular 2 and web2py

2017-01-06 Thread 'John Philip' via web2py-users
Thanks Anthony and Ramos for your help. Much appreciated! John On Friday, January 6, 2017 at 2:15:15 PM UTC+1, Anthony wrote: > > No reason you can't use Angular 2 with web2py, as web2py handles the back > end and Angular 2 is a front end framework. The only potential issue is if > you are usi

Re: [web2py] Self-hosted web analytics solutions for Web2py

2017-01-06 Thread Richard Vézina
You can look on the side of piwik : https://piwik.org/ If you only want to log your users activity and don't need that much of analytic you can have look at this slice : http://www.web2pyslices.com/slice/show/1618/basic-usage-statistics-log-what-your-users-do But it has a drawback which is that

Re: [web2py] Self-hosted web analytics solutions for Web2py

2017-01-06 Thread António Ramos
https://mixpanel.com 2017-01-06 15:12 GMT+00:00 Richard Vézina : > You can look on the side of piwik : https://piwik.org/ > > If you only want to log your users activity and don't need that much of > analytic you can have look at this slice : > > http://www.web2pyslices.com/slice/show/1618/basic-

[web2py] Custom Response.flash

2017-01-06 Thread LoveWeb2py
Hello, I have created my own response.flash Here is the code: def notification(message, mtype): a = "\n" a += "$(\"notify\").ready(function() {\n" a += "toastr.options.timeOut = 2000; // 1.5s\n" a += "toastr.{mtype}('{message}');\n".format(mtype=mtype, message=message) a +=

Re: [web2py] Custom Response.flash

2017-01-06 Thread Richard Vézina
Why doing that? You can't just style differently the actual web2py flash popup in the web2py.css file to achieve what you want? I mean flash message is flash message... Richard On Fri, Jan 6, 2017 at 10:43 AM, LoveWeb2py wrote: > Hello, > > I have created my own response.flash > > Here is the c

Re: [web2py] Custom Response.flash

2017-01-06 Thread LoveWeb2py
Hi Richard, I'm trying to use this: https://github.com/CodeSeven/toastr and it's working okay right now, but I feel like there has to be a better way. If I just use response.flash = 'message' and change the css I'd have to change the javascript as well (I think) and I also wouldn't be able to

[web2py] 'ascii' codec can't decode byte 0xc3 in position 28: ordinal not in range(128)

2017-01-06 Thread Gael Princivalle
Hello. I'm made a new application in a new web2py installation 2.14.6. The db is PostGis. It's a mountain bike meeting platform. There's only one user for the moment, myself ☺. Here is an event: https://www.mtbconnection.com/en/mtb_ride?event_id=1 You can see that the event description is: Per

[web2py] Re: 'ascii' codec can't decode byte 0xc3 in position 28: ordinal not in range(128)

2017-01-06 Thread Gael Princivalle
PostGis is in utf8. I've tried to force the utf8 codification like that: description = title + ' ' + event.description.encode("utf-8") Same error. Il giorno venerdì 6 gennaio 2017 17:27:17 UTC+1, Gael Princivalle ha scritto: > > Hello. > > I'm made a new application in a new web2py installa

[web2py] Re: 'ascii' codec can't decode byte 0xc3 in position 28: ordinal not in range(128)

2017-01-06 Thread Leonel Câmara
Is it possible the python file itself where you controller is, is not in utf-8? -- 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

Re: [web2py] Custom Response.flash

2017-01-06 Thread António Ramos
to catch all users attention i use https://limonte.github.io/sweetalert2/ 2017-01-06 16:05 GMT+00:00 LoveWeb2py : > Hi Richard, > > I'm trying to use this: https://github.com/CodeSeven/toastr > > and it's working okay right now, but I feel like there has to be a better > way. > > If I just use r

Re: [web2py] Re: FPDF

2017-01-06 Thread Edwood
It should work unless there is something in the HTML markup messing with the output. I tried this similar code with file output instead of stream and it did what you expected (as I understood it): from gluon.contrib.pyfpdf import FPDF, HTMLMixin from datetime import datetime class MyFPDF(FPDF,

[web2py] Re: 'ascii' codec can't decode byte 0xc3 in position 28: ordinal not in range(128)

2017-01-06 Thread Gael Princivalle
I edit the controller with notepad ++. Format is UTF-8 without BOM. I've also tried to save it with the web2py amministrative interface, same error. Il giorno venerdì 6 gennaio 2017 18:08:13 UTC+1, Leonel Câmara ha scritto: > > Is it possible the python file itself where your controller is, is n

[web2py] Re: Custom Response.flash

2017-01-06 Thread Anthony
> > The problem is when I call it using auth.messages.logged_in = > notification('Signed In', 'success') I get two pop ups of the message. > > I suspect this has something to do with the way .flash is defined in > web2py.js because when I comment out > > main_hook: function () { >

[web2py] Lost Password ends up with 'Invalid reset password' Error

2017-01-06 Thread David Manns
I don't know how long this has been broken. Login is working, password change is working. Noticed this in my local test environment, on Windows, running latest 2.14.6 web2py with local sqlite test database. The reset email is sent out, and looks like: Click on the link http://127.0.0.1:8000/in

[web2py] auth on GAE 'unable to send email'

2017-01-06 Thread David Manns
Running 2.14.6 in production on GAE. Notice can't send the verification's so can't register or recover passwords. (have another problem with lost passwords which reported separately). Using all the standard setup to initialize auth.settings.mailer in db.py AND that same auth.settings.mailer is

[web2py] Re: Made with web2py

2017-01-06 Thread Pierre
nice design and interesting concept too may I ask where do you host it ? i visited *bback.me* this morning and now access is refused...I'll be back -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https: