Re: [web2py] Re: AWS Elastic Beanstalk installation Recipe

2014-05-26 Thread kato
I do not know would be helpful, but there is recipe for Beanstalk. 
Please use the Google translater, because it is Japanese.

http://docs1.erp2py.com/web2py_deploy/aws_beanstalk/aws_beanstalk.html#id4



2014年5月24日土曜日 12時47分38秒 UTC-3 Diogo Munaro:
>
> But how could I manage migrates? How could I make migrates on deploy?
> Em 24/05/2014 04:02, "Massimo Di Pierro" > 
> escreveu:
>
>> There is nothing equivalent to this in web2py. You just remove that line.
>>
>> On Thursday, 22 May 2014 12:43:59 UTC-5, Diogo Munaro wrote:
>>>
>>>
>>> Hey Massimo, and how could I replace 
>>>
>>>
>>>  command: "django-admin.py syncdb --noinput"
>>>
>>> ?
>>>
>>> I need migrate=False because I have a loadbalancer with elastic beanstalk
>>>
>>>
>>> Em quinta-feira, 25 de julho de 2013 11h45min05s UTC-3, Aladdin Teng 
>>> escreveu:

 Thank you very much.

 On Thursday, July 25, 2013 8:53:33 PM UTC+8, Massimo Di Pierro wrote:
>
> The instructions should be almost identical except that:
>
> 1) you do not pip install Django
> 2) you do not ever call django-admin
> 3) instead you download and unzip web2py. The web2py folder plays the 
> role of the mysite folder in the example
> 4) you do not edit any django config file (there is no django!)
> 5) instead you edit db.py and you replace db= DAL(...) with
>
>import os
>uri = “mysql://%(RDS_USERNAME)s:%(RDS_PASSWORD)s@%(RDS_HOSTNAME)
> s:%(RDS_PORT)s/%(RDS_DB_NAME)s” % os.environ
>db = DAL(uri, pool_size=10)
>session.connect(request, response db=db) # sessions in DB!
>
> 6) before you commit and push you must create a file 
> web2py/application.py which contains
> 
> import sys
> import os
> path = os.path.dirname(os.path.abspath(__file__))
> os.chdir(path)
> sys.path = [path] + [p for p in sys.path if not p == path]
> sys.stdout = sys.stderr
> import gluon.main
> application = gluon.main.wsgibase
> 
>
> This should work. If you try it please post your findings. 
>
> Caveat 1. You must get web2py from web2py_src.zip from the web site 
> and not from the Git report else the web2py git repo will conflict with 
> the 
> git repo you are supposed to create according to this tutorial.
>
> Caveat 2. From:http://blog.uptill3.com/2012/08/25/python-on-elastic-
> beanstalk.html
> "It's critical to understand that the Elastic Beanstalk images are all 
> ephemeral, in the 'old' style of AWS AMIs. This means that nothing on an 
> instances filesystem will survive through a deployment, redeployment, or 
> stoppage of the environment/instance. " This means that 
> session/tickets/uploads must all go to the file system. web2py admin will 
> be useful. You also needs to setup sticky sessions and I am not sure 
> whether AWS does it automatically or not.
>
>
> On Wednesday, 17 July 2013 11:14:20 UTC-5, Aladdin Teng wrote:
>>
>> Hi!
>>
>> Is there an update on this demo?
>> I am looking into AWS deployment too.
>>
>> Thanks.
>>
>> On Saturday, October 13, 2012 9:52:03 AM UTC+8, Massimo Di Pierro 
>> wrote:
>>>
>>> I will try a demo asap but I do not have an account so it will take 
>>> a tille time. In principle everything in eb is not django specific and 
>>> should work with web2py almost out of them box.
>>>
>>> On Tuesday, 9 October 2012 11:42:35 UTC-5, CST International Mike 
>>> wrote:

 Hi 

 I trying to find an AWS Elastic Beanstalk Web2py installation 
 recipe.

 Amazon have a Django version http://docs.amazonwebservices.
 com/elasticbeanstalk/latest/dg/create_deploy_Python_django.html

 My Linux\web2py skill are a little weak and rusty. ( over a year 
 now)

 Regards Michael





  -- 
>> 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 a topic in the 
>> Google Groups "web2py-users" group.
>> To unsubscribe from this topic, visit 
>> https://groups.google.com/d/topic/web2py/qR6tx0Sa6i0/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to 
>> web2py+un...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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 web2py+u

Re: [web2py] SQLEDITABLE plugin

2014-07-07 Thread kato
I will add a postscript. you can write as below.

def demo031():
def record():
rows = db(db.employee_sheet.resigned == True).select(limitby=(0,3))
return [row.id for row in rows.sort(lambda row:row.employee_number)]

response.title = 'demo030'
response.view = 'plugin_sqleditable/sample.html'
editable = SQLEDITABLE(db.employee_sheet, record=record(),showid=False,

maxrow=5).process()
return dict(editable=editable)

If you use "primarykey" and multiple key fields, you need to write list of
list in "record" parameter.


2014-07-07 5:51 GMT-03:00 'kato' via web2py-users :

> Hi fabiano.
>
> It is not possible to pass a query currently.
> But "record" parameter is so callable, please set there.
> Please see to the demo5
> <http://docs1.erp2py.com/sqleditable/demo/demo_en.html#demo5> .
>
> thanks.
>
> 2014年7月6日日曜日 15時19分04秒 UTC-3 Fabiano Almeida:
>>
>> Hi kato!
>>
>> How to use SQLEDITABLE with a query?
>>
>> If I try this in your first example:
>>
>> query = db.employee_sheet.resigned == True
>> editable = SQLEDITABLE(query, showid=False, maxrow=5).process()
>>
>> Return error:
>>
>>
>> AttributeError: 'Query' object has no attribute '_id'
>>
>> How to filter table?
>>
>> Thanks,
>>
>> Fabiano
>>
>>
>>
>> 2014-07-01 10:12 GMT-03:00 'kato' via web2py-users <
>> web...@googlegroups.com>:
>>
>>> Hi.
>>>
>>> I tried to make SQLEDITABLE plugin.
>>>
>>> demo-page: http://docs1.erp2py.com/sqleditable/demo/demo_en.html
>>>
>>> It is similar as gluon/contrib/spreadsheet. But, it is easy to use more.
>>> If you are interested, please try.
>>>
>>> Thanks.
>>>
>>> --
>>> 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 web2py+un...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>  --
> 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 a topic in the
> Google Groups "web2py-users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/web2py/PQE1JJwv0Bc/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> web2py+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: web2py 2.15.0b1

2017-07-10 Thread kato
Hi.

I found a problem with python3.

File ".../web2py/gluon/validators.py", line 455, in options
items = [(k, self.labels[i]) for (i, k) in enumerate(self.theset)]
File ".../web2py/gluon/validators.py", line 455, in 
items = [(k, self.labels[i]) for (i, k) in enumerate(self.theset)]
TypeError: 'dict_values' object does not support indexing

line455
items = [(k, self.labels[i]) for (i, k) in enumerate(self.theset)]

Please change as follows.
items = [(k, list(self.labels)[i]) for (i, k) in enumerate(self.theset)]



-- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] Re: User-friendly checkbox/radio-button widget in gluon/sqlhtml.py

2011-08-23 Thread KATO Ryoichi
Well, actually I'm embarrassed that I didn't know about 
And yes, I'm pretty sure that the change can be more simple.

Primarily what I want is clickable option value(label) for radio/checkboxes.
Besides,
  * Preferably, more large clickable area (*1)
  * Dynamic style change (as shown on the demo)
  * IE6 support.
would be good for easy-to-use UI.

Regards,
---
(*1) In my current implementation,  and  are clickable.
But I think this is still a bit too small to click.
Perhaps making "container"(a box containing both  and label)
clickable is more easy-to use.
( in my example)


On Tue, Aug 23, 2011 at 22:25, Massimo Di Pierro
 wrote:
> here there is substantial JS to add to web2py_ajax and perhaps we can
> make it more compact. What is more specifically the problem that you
> want to solve? Be able to check/uncheck clicking on option value
> instead of checkbox/radio button?
>
>
>
> On Aug 23, 6:34 am, ryo1kato  wrote:
>> Hi,
>>
>> I'm frustrated that I can't check/select the checkboxes / radio-
>> buttons
>> by clicking on their labels rather than the box/buttons.
>> So, here's my own solution for web2py,
>> because I couldn't find any by quick googling.
>>
>> *http://bit.ly/nsNAmq(deep link inhttp://code.google.com/)
>>
>> * Demo is available on here:http://ryo1kato.appspot.com/checkbox/default/
>>     (Tested on IE6, Firefox5,6, GoogleChrome13)
>>
>> ...It's quite possible you have better solution, because
>> I'm pretty new to both web2py and HTML/JavaScript.
>> However, I'm happy if this feature is supported as web2py's default.
>> (perhaps by someone's better implementation...)
>>
>> --
>> R.Kato



-- 
R.Kato


Re: [web2py] Re: User-friendly checkbox/radio-button widget in gluon/sqlhtml.py

2011-08-24 Thread KATO Ryoichi
I've re-implemented the code using , as Anthony advised.
http://code.google.com/r/ryo1kato-web2py/source/list?name=better-checkbox2
And demo is updated also
http://ryo1kato.appspot.com/checkbox

The code is shorter, but still ugly. But I couldn't figure out how to
improve even more,
despite I (briefly) studied a little bit more about HTML4, CSS and JavaScript.
(hope there's 'parent' selector, and ":checked" support in IE6...)

Any idea?
--
R.Kato

On Tue, Aug 23, 2011 at 23:35, Anthony  wrote:
> I think using input text would be a good
> start (certainly a lot simpler). web2py already uses that to label fields in
> SQLFORMs and for the "Remember me" checkbox on login forms. The base.css
> even sets the cursor to 'pointer' for all label elements, so you get a
> pointer whenever you hover over a label.
>
> To enable more sophisticated effects (e.g., dynamic style changes), maybe
> wrap the  and  in a  container with a special class, as
> suggested, and leave it up to the developer to add additional effects via
> CSS/jQuery.
>
> Anthony
>
> On Tuesday, August 23, 2011 9:44:03 AM UTC-4, ryo1kato wrote:
>>
>> Well, actually I'm embarrassed that I didn't know about 
>> And yes, I'm pretty sure that the change can be more simple.
>>
>> Primarily what I want is clickable option value(label) for
>> radio/checkboxes.
>> Besides,
>>   * Preferably, more large clickable area (*1)
>>   * Dynamic style change (as shown on the demo)
>>   * IE6 support.
>> would be good for easy-to-use UI.
>>
>> Regards,
>> ---
>> (*1) In my current implementation,  and > ...> are clickable.
>> But I think this is still a bit too small to click.
>> Perhaps making "container"(a box containing both  and label)
>> clickable is more easy-to use.
>> ( in my example)
>>
>> On Tue, Aug 23, 2011 at 22:25, Massimo Di Pierro
>>  wrote:
>> > here there is substantial JS to add to web2py_ajax and perhaps we can
>> > make it more compact. What is more specifically the problem that you
>> > want to solve? Be able to check/uncheck clicking on option value
>> > instead of checkbox/radio button?
>> >
>> >
>> >
>> > On Aug 23, 6:34 am, ryo1kato  wrote:
>> >> Hi,
>> >>
>> >> I'm frustrated that I can't check/select the checkboxes / radio-
>> >> buttons
>> >> by clicking on their labels rather than the box/buttons.
>> >> So, here's my own solution for web2py,
>> >> because I couldn't find any by quick googling.
>> >>
>> >> *http://bit.ly/nsNAmq(deep link inhttp://code.google.com/)
>> >>
>> >> * Demo is available on
>> >> here:http://ryo1kato.appspot.com/checkbox/default/
>> >>     (Tested on IE6, Firefox5,6, GoogleChrome13)
>> >>
>> >> ...It's quite possible you have better solution, because
>> >> I'm pretty new to both web2py and HTML/JavaScript.
>> >> However, I'm happy if this feature is supported as web2py's default.
>> >> (perhaps by someone's better implementation...)
>> >>
>> >> --
>> >> R.Kato
>>
>> --
>> R.Kato
>



-- 
R.Kato


Re: [web2py] Re: User-friendly checkbox/radio-button widget in gluon/sqlhtml.py

2011-08-24 Thread KATO Ryoichi
Sure!

(I'm not sure about coding style, but perhaps
it's better not to touch  web2py_ajax.js for this kind of fix?)

On Thu, Aug 25, 2011 at 00:01, Massimo Di Pierro
 wrote:
> Your idea is really good. I think I have a solution in trunk that only
> requires a change to sqlhtml.py and that will also allow to style the
> options using pure css. Can you try it?
>
> massimo
>
> On Aug 24, 9:36 am, KATO Ryoichi  wrote:
>> I've re-implemented the code using , as Anthony advised.
>>    http://code.google.com/r/ryo1kato-web2py/source/list?name=better-chec...
>> And demo is updated also
>>    http://ryo1kato.appspot.com/checkbox
>>
>> The code is shorter, but still ugly. But I couldn't figure out how to
>> improve even more,
>> despite I (briefly) studied a little bit more about HTML4, CSS and 
>> JavaScript.
>> (hope there's 'parent' selector, and ":checked" support in IE6...)
>>
>> Any idea?
>> --
>> R.Kato
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> On Tue, Aug 23, 2011 at 23:35, Anthony  wrote:
>> > I think using input text would be a good
>> > start (certainly a lot simpler). web2py already uses that to label fields 
>> > in
>> > SQLFORMs and for the "Remember me" checkbox on login forms. The base.css
>> > even sets the cursor to 'pointer' for all label elements, so you get a
>> > pointer whenever you hover over a label.
>>
>> > To enable more sophisticated effects (e.g., dynamic style changes), maybe
>> > wrap the  and  in a  container with a special class, as
>> > suggested, and leave it up to the developer to add additional effects via
>> > CSS/jQuery.
>>
>> > Anthony
>>
>> > On Tuesday, August 23, 2011 9:44:03 AM UTC-4, ryo1kato wrote:
>>
>> >> Well, actually I'm embarrassed that I didn't know about 
>> >> And yes, I'm pretty sure that the change can be more simple.
>>
>> >> Primarily what I want is clickable option value(label) for
>> >> radio/checkboxes.
>> >> Besides,
>> >>   * Preferably, more large clickable area (*1)
>> >>   * Dynamic style change (as shown on the demo)
>> >>   * IE6 support.
>> >> would be good for easy-to-use UI.
>>
>> >> Regards,
>> >> ---
>> >> (*1) In my current implementation,  and > >> ...> are clickable.
>> >> But I think this is still a bit too small to click.
>> >> Perhaps making "container"(a box containing both  and label)
>> >> clickable is more easy-to use.
>> >> ( in my example)
>>
>> >> On Tue, Aug 23, 2011 at 22:25, Massimo Di Pierro
>> >>  wrote:
>> >> > here there is substantial JS to add to web2py_ajax and perhaps we can
>> >> > make it more compact. What is more specifically the problem that you
>> >> > want to solve? Be able to check/uncheck clicking on option value
>> >> > instead of checkbox/radio button?
>>
>> >> > On Aug 23, 6:34 am, ryo1kato  wrote:
>> >> >> Hi,
>>
>> >> >> I'm frustrated that I can't check/select the checkboxes / radio-
>> >> >> buttons
>> >> >> by clicking on their labels rather than the box/buttons.
>> >> >> So, here's my own solution for web2py,
>> >> >> because I couldn't find any by quick googling.
>>
>> >> >> *http://bit.ly/nsNAmq(deeplink inhttp://code.google.com/)
>>
>> >> >> * Demo is available on
>> >> >> here:http://ryo1kato.appspot.com/checkbox/default/
>> >> >>     (Tested on IE6, Firefox5,6, GoogleChrome13)
>>
>> >> >> ...It's quite possible you have better solution, because
>> >> >> I'm pretty new to both web2py and HTML/JavaScript.
>> >> >> However, I'm happy if this feature is supported as web2py's default.
>> >> >> (perhaps by someone's better implementation...)
>>
>> >> >> --
>> >> >> R.Kato
>>
>> >> --
>> >> R.Kato
>>
>> --
>> R.Kato



-- 
R.Kato


Re: [web2py] Re: User-friendly checkbox/radio-button widget in gluon/sqlhtml.py

2011-08-24 Thread KATO Ryoichi
No, we don't need jQuery. Just using plain JavaScript, and it's for
dynamic style update.
And yes, If we only want to check/uncheck by click on labels, 
is sufficient.

On Thu, Aug 25, 2011 at 00:18, Bruno Rocha  wrote:
> I dont understand why we do need jquery to take this action?
> just incluce  and this wiill be done! or not?



-- 
R.Kato


Re: [web2py] Re: User-friendly checkbox/radio-button widget in gluon/sqlhtml.py

2011-08-24 Thread KATO Ryoichi
> I say don't use Javascript if it can be done with a simple html 
> element.
Right, but I couldn't figure out how for dynamic style update; what's
"formstyle"?
Anyway, I should shut up and wait when someone skilled than me is
working for similar thing ;-)

On Thu, Aug 25, 2011 at 00:32, Anthony  wrote:
> I say don't use Javascript if it can be done with a simple html 
> element. I think Bruno is working on a patch for that (plus more flexible
> formstyle):
> https://groups.google.com/d/msg/web2py-developers/N8GfwA3p4jk/XULfOX5PlmYJ.
>
> Anthony
> On Wednesday, August 24, 2011 11:26:17 AM UTC-4, ryo1kato wrote:
>>
>> No, we don't need jQuery. Just using plain JavaScript, and it's for
>> dynamic style update.
>> And yes, If we only want to check/uncheck by click on labels, 
>> is sufficient.
>>
>> On Thu, Aug 25, 2011 at 00:18, Bruno Rocha  wrote:
>> > I dont understand why we do need jquery to take this action?
>> > just incluce  and this wiill be done! or not?
>>
>> --
>> R.Kato
>



-- 
R.Kato


Re: [web2py] Re: User-friendly checkbox/radio-button widget in gluon/sqlhtml.py

2011-08-24 Thread KATO Ryoichi
> Yes, using  will make the labels clickable, but won't do dynamic
> style updating. I like the idea of dynamic styling, but just not sure it
> belongs in the core framework code -- then users who don't like it or want
> to implement it differently will have to disable it. Maybe if it's optional,
> and the code is relatively simple.
That's sounds reasonable. Core could should be kept simple.

But, is there easy way to do dynamic style update without modifying sqlhtml.py?
(Of course I can if I completely rewrite my own widget...)
How about putting callbacks and class:
   LABEL(INPUT(..., _class=XXX, _onclick=YYY), _class=xxx, _onclick=yyy, ...)

(or smarter way to do this?)

On Thu, Aug 25, 2011 at 01:04, Anthony  wrote:
> On Wednesday, August 24, 2011 11:50:38 AM UTC-4, ryo1kato wrote:
>>
>> > I say don't use Javascript if it can be done with a simple html 
>> > element.
>> Right, but I couldn't figure out how for dynamic style update;
>
>
> Yes, using  will make the labels clickable, but won't do dynamic
> style updating. I like the idea of dynamic styling, but just not sure it
> belongs in the core framework code -- then users who don't like it or want
> to implement it differently will have to disable it. Maybe if it's optional,
> and the code is relatively simple.
>
>
>>
>> what's "formstyle"?
>
>
> See http://web2py.com/book/default/chapter/07#SQLFORM (scroll down a bit).
> It defaults to table format, but can also be set to ul or divs. However,
> radio buttons and checkboxes are always in tables, regardless of formstyle
> -- we want to make that more flexible.
>
> Anthony
>



-- 
R.Kato


[web2py] SQLEDITABLE plugin

2014-07-01 Thread &#x27;kato' via web2py-users
Hi.

I tried to make SQLEDITABLE plugin.

demo-page: http://docs1.erp2py.com/sqleditable/demo/demo_en.html

It is similar as gluon/contrib/spreadsheet. But, it is easy to use more.
If you are interested, please try.

Thanks.

-- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: SQLEDITABLE plugin

2014-07-03 Thread &#x27;kato' via web2py-users
Hi all.

Thank you for your quick reply.

kato

2014年7月1日火曜日 20時35分06秒 UTC-3 JorgeH:
>
>
> Cool!!
>
> Great work
>
> On Tuesday, July 1, 2014 8:12:29 AM UTC-5, kato wrote:
>>
>> Hi.
>>
>> I tried to make SQLEDITABLE plugin.
>>
>> demo-page: http://docs1.erp2py.com/sqleditable/demo/demo_en.html
>>
>> It is similar as gluon/contrib/spreadsheet. But, it is easy to use more.
>> If you are interested, please try.
>>
>> Thanks.
>>
>

-- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [web2py] SQLEDITABLE plugin

2014-07-07 Thread &#x27;kato' via web2py-users
Hi fabiano.

It is not possible to pass a query currently. 
But "record" parameter is so callable, please set there. 
Please see to the demo5 
<http://docs1.erp2py.com/sqleditable/demo/demo_en.html#demo5> .

thanks.

2014年7月6日日曜日 15時19分04秒 UTC-3 Fabiano Almeida:
>
> Hi kato!
>
> How to use SQLEDITABLE with a query?
>
> If I try this in your first example:
>
> query = db.employee_sheet.resigned == True
> editable = SQLEDITABLE(query, showid=False, maxrow=5).process()
>
> Return error:
>
> AttributeError: 'Query' object has no attribute '_id'
>
> How to filter table?
>
> Thanks,
>
> Fabiano
>
>
>
> 2014-07-01 10:12 GMT-03:00 'kato' via web2py-users <
> web...@googlegroups.com >:
>
>> Hi.
>>
>> I tried to make SQLEDITABLE plugin.
>>
>> demo-page: http://docs1.erp2py.com/sqleditable/demo/demo_en.html
>>
>> It is similar as gluon/contrib/spreadsheet. But, it is easy to use more.
>> If you are interested, please try.
>>
>> Thanks.
>>
>> -- 
>> 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 web2py+un...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: SQLEDITABLE: redirect after submit

2014-07-09 Thread &#x27;kato' via web2py-users
Hi.

You can write same as SQLFORM.

example.
def demo070():
response.title = 'demo070'
response.view = 'plugin_sqleditable/sample.html'
editable = SQLEDITABLE(db.employee_sheet, showid=False, maxrow=5)
if editable.accepts(request.vars, session):
response.flash = T('editable accepted')
elif editable.errors:
response.flash = T('editable has errors')
else:
response.flash = T('please fill out the editable')
return dict(editable=editable)

def demo071():
response.title = 'demo071'
response.view = 'plugin_sqleditable/sample.html'
editable = SQLEDITABLE(db.employee_sheet, showid=False, maxrow=5)
if editable.process().accepted:
response.flash = T('editable accepted')
elif editable.errors:
response.flash = T('editable has errors')
else:
response.flash = T('please fill out the editable')
return dict(editable=editable)

2014年7月8日火曜日 20時00分59秒 UTC-3 Fabiano Almeida:
>
> Hi,
>
> Has like 'accepted' attribute in SQLEDITABLE?
>
> I need redirect to other page after 'ok' click.
>
> Thanks,
>
> Fabiano.
>

-- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: SQLEDITABLE: redirect after submit

2014-07-09 Thread &#x27;kato' via web2py-users
I was a little wrong. If you want to redirect, and will not work because 
such in the ajax. 
Please write as the following.

def demo050():
response.title = 'demo050'
response.view = 'plugin_sqleditable/sample.html'
editable = SQLEDITABLE(db.employee_sheet, showid=False, maxrow=5, 
deletable=True).process(next=URL('static', 'success.html'))
return dict(editable=editable)



2014年7月9日水曜日 8時52分21秒 UTC-3 kato:
>
> Hi.
>
> You can write same as SQLFORM.
>
> example.
> def demo070():
> response.title = 'demo070'
> response.view = 'plugin_sqleditable/sample.html'
> editable = SQLEDITABLE(db.employee_sheet, showid=False, maxrow=5)
> if editable.accepts(request.vars, session):
> response.flash = T('editable accepted')
> elif editable.errors:
> response.flash = T('editable has errors')
> else:
> response.flash = T('please fill out the editable')
> return dict(editable=editable)
>
> def demo071():
> response.title = 'demo071'
> response.view = 'plugin_sqleditable/sample.html'
> editable = SQLEDITABLE(db.employee_sheet, showid=False, maxrow=5)
> if editable.process().accepted:
> response.flash = T('editable accepted')
> elif editable.errors:
> response.flash = T('editable has errors')
> else:
> response.flash = T('please fill out the editable')
> return dict(editable=editable)
>
> 2014年7月8日火曜日 20時00分59秒 UTC-3 Fabiano Almeida:
>>
>> Hi,
>>
>> Has like 'accepted' attribute in SQLEDITABLE?
>>
>> I need redirect to other page after 'ok' click.
>>
>> Thanks,
>>
>> Fabiano.
>>
>

-- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.