I am using the Windows web2py.exe binary version Version
2.4.7-stable+timestamp.2013.05.29.16.40.45.
I need to know if web2py.exe supports multilingual, case-independed
matches, such as
SELECT FIELD LIKE 'à' -- should match when field value is 'À' (uppercase)
and field is defined as FIELD TEXT C
Earlier today I posted a message to this group via google groups web
interface. My message still isn't showing in google groups, but it is in
the osdir archive of google groups? Is this normal or is google groups web
interface not trustworthy? Link to my OP
http://osdir.com/ml/web2py/2013-06/m
In the same page I placed three embedded components, each one with its own
separate .load file which index.html loads with LOAD().
1) form_years, SQLFORM.factory whose controller returns
dict(form_years=form_years)
2) grid_course, SQLFORM.grid whose controller returns
dict(grid_course=grid_cours
Pierro wrote:
>
> The code in
>
> ###
> # RELOAD COMPONENTS grid_course AND grid_pricelist BUT HOW?
> ###
>
> should be
>
> response.js = "jQuery('#grid_course,#grid_pricelist').reload()"
>
> could it be easier?
&
e equivalent, but more cryptic
";".join("$('#"+x+"').load('/"+"/".join([request.application, request.
controller])+"/"+x+".load')" for x in ["grid_course","grid_pricelist"])
All they do is setting res
I will check but I doubt it's a bug, jQuery doesn't have a reload function,
js does.
>
>>>
--
---
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+unsubsc
I do have that function. Maybe that function itself is giving me a clue, on
the fifth line
var statement = "jQuery('#" + target + "').get(0).reload();";
so adding .get(0) after jQuery() enables reload(), of course...
On Sunday, June 16, 2013 10:34:28 PM UTC+2, st
Yes, this works too
response.js =
"$('#grid_course').get(0).reload();$('#grid_pricelist').get(0).reload()"
On Sunday, June 16, 2013 10:41:26 PM UTC+2, step wrote:
>
> I do have that function. Maybe that function itself is giving me a clue,
> on t
Given three tables, bc, b and c:
define_table('bc', Field('b'), Field('c'),
Field('b_id', 'reference b', writable=False),
Field('c_id', 'reference c', writable=False))
define_table('b', Field('x'), Field('y'),
format='b drops %(x)s and %(y)s')
define_table('c', Field('x'), Field('y'),
How can I change SQLFORM.grid's submit button's label from python and
without resorting to javascript? I tried
SQLFORM.grid(..., formargs=dict(submit_button=T('new
label'),formname='grid')
but it generated an error:
File "gluon/sqlhtml.py", line 2066, in grid
**sqlformargs)
TypeError: ty
How can I change from python the href value of SQLFORM.grid's back icon
button which is automatically added to the create/update/view form?
SQLFORM.grid sets the value to the referer's URL, but I ran into a
situation where that setting is grossly illogical, so I need to work around
the default s
d.showbuttontext ==
False
On Friday, July 12, 2013 6:53:13 PM UTC+2, Anthony wrote:
>
> Maybe something like:
>
> if request.args[-3] in ['view', 'edit']:
> grid.element('[title=Back]').parent['_href'] = URL(...)
>
> Anthony
>
> On Fr
Incidentally, Anthony why did you use request.args[-3] instead of
request.args[0]? What's the reasoning behind the negative index idiom that
I see in use throughout the gluon files?
--
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsu
is it possible to display just one error message of a list:string input
right after the last input control, using SQLFORM.grid?
With SQLFORM,grid create/update form, when a list:string field with
validators has errors it should be possible to hide the error display on
all list inputs but the la
rst().before($(this));
else this.style.display='none';
});
}
});
{{pass}}
{{=grid}}
On Saturday, August 3, 2013 12:52:16 AM UTC+2, step wrote:
>
> is it possible to display just one error message of a list:string input
> right after the
On Sunday, 4 August 2013 16:40:57 UTC-5, step wrote:
>>
>> Answering my own question, with jQuery I found a way to display just a
>> single error message div for a list:string type field. I added this code to
>> the view:
>> {{if grid.update_form or grid.create_fo
I too have this problem, word by word as described. I haven't been able to
spot a pattern. I'm running web2py source on Windows XP (rocket).
On Monday, August 5, 2013 8:26:59 AM UTC+2, David Marko wrote:
>
> I have this problem for years. Working on Windows 7/8 , python 2.7.5 and
> latest web2p
For starters, this thread pretty much answers my question,
https://groups.google.com/forum/?fromgroups#!searchin/web2py/build$20web2py.exe/web2py/Lirvj_J8q1U/vC1kWqXoDSMJ
However, I wonder what is the official method to build web2py.exe, and also
if other people have devised or derived their
I discovered one way to make a true copy of some list of HTML helpers. I
would like to know if there are other more, web2py / pythonic ways to do
it. So for instance:
form = SQLFORM.factory()
trs = form.elements('')
trs_true_copy = map(lambda x: TAG(x.xml()),trs)
which works just fine, though i
And in fact it isn't a true copy because after the mapping the so called
trs_true_copy has lost all the SQLFORM specific data, like links to
form.vars, etc. So I don't know of a way to make a true copy, and I'm
asking for one. Thanks.
On Saturday, August 17, 2013 2:19:39 PM UT
;m curious though, what and why do you need it?
>
> On Saturday, August 17, 2013 2:33:09 PM UTC+2, step wrote:
>>
>> And in fact it isn't a true copy because after the mapping the so called
>> trs_true_copy has lost all the SQLFORM specific data, like links to
.field1, db.t1.field2, db.*t2*.field2...]
> if "something" in request.get_vars: #or any other thing that "marks" this
> as the request for the "newly ordered" form
> fields = [db.t1.field1, db.*t3*.field1, db.t1.field2, db.*t3*.field2
> ...]
>
> f
;
when form factory is working on t2, which makes perfect sense again since
table1_field is not in t2.
On Sunday, August 18, 2013 4:12:45 PM UTC+2, step wrote:
>
> Brilliantly simple, I should have thought of it. Meanwhile I coded a
> jQuery version and it's simple indee
My bad, your answer works perfectly (tested). I hadn't noticed HOW you
specify fields in the signature, **fields* instead of fields=
On Sunday, August 18, 2013 5:33:46 PM UTC+2, step wrote:
>
> I'm having trouble finding the right fields= format for SQLFORM.factory.
> When f
It's fixed, at least for me, I had the same issue that Jim S. reported.
On Tuesday, August 27, 2013 1:33:48 PM UTC+2, Massimo Di Pierro wrote:
>
> Thanks. Please check the latest trunk. I think it is now fixed.
>
--
---
You received this message because you are subscribed to the Google Groups
This issue is now fixed in trunk
2013-09-01
https://github.com/web2py/web2py/commit/085b4a0d15b173d84d92e2ed2b6db30923d2f643
Thanks Massimo
On Wednesday, August 7, 2013 12:57:14 PM UTC+2, step wrote:
>
> Thank yOU for looking into this. Will you post a follow-up to this thread
> or
Sorry for resurrecting such an old thread, but I wanted to add my solution
to a very similar issue.
It might seem obvious to expert web2py users; I found out that when some
compute fields weren't updating in my app it was due to unordered
cross-dependencies. In other words, if the computation of
Keeping namespaces in separate files makes distributing localized components
easier, like in the wiki plugin example in the OP. OTOH
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issu
nice and comprehensive intro in the first linked post!
--
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 subscribe
Niphlod, can you please explain why you're using method _select instead of
select in your code below? In there no need to connect to SQL to set
all_courses?
On Tuesday, September 24, 2013 3:35:34 PM UTC+2, Niphlod wrote:
>
> you can do that with
>
> all_courses = db(db.courses.id>0)._select(db.c
>
>
> http://web2py.com/books/default/chapter/29/06/the-database-abstraction-layer#belongs
>
> let me know if something is not clear
>
> Il giorno mercoledì 25 settembre 2013 07:11:27 UTC+2, step ha scritto:
>>
>> Niphlod, can you please explain why you're using method
Devs ignore my question if you think it has nothing to do with this issue,
but I came looking for a similar pattern. Ever since I upgraded from 2.6.1
to 2.6.3 and now 2.6.4 I have noticed cases where submitting a form POSTs
to the wrong target page. In all cases '#' is the form action. My views
Disregard my previous post, mine's definitely a different issue. Sorry for
intruding.
On Wednesday, September 25, 2013 6:48:34 PM UTC+2, step wrote:
>
> Devs ignore my question if you think it has nothing to do with this issue,
> but I came looking for a similar pattern. Ever si
One gotcha In Windows 7 and Vista, when the working directory path ends with a
symbolic link, the current parent path reference, .., will refer to the parent
directory of the symbolic link rather than that of its target. This difference
could break the importer code if it's playing with .. path
I want to use SQLFORM.grid with selectable checkboxes to serve a custom
export function. Unlike web2py's default exportformats manager, which
triggers each exporter function to an tag, I want my exporter to
trigger when the user clicks the form submit button. So the user flow
involves ticking
t;text/tab-separated-values"
filename = '.'.join(('SPRING', file_ext))
response.headers['Content-Type'] = content_type
response.headers['Content-Disposition'] = \
'attachment;filename=' + filename + ';'
response.js = 'alert("here we
Back in August I was able to build a working web2py_no_console.exe
following your instructions, but not anymore.
Now the build is still successful but the resulting web2py_no_console.exe
errors out when option -t (taskbar) is passed on the command line
start "" web2py_no_console.exe -i 127.0.0.1
Sorry, it's line 17 of web2py.py that I uncommented, not gluon\main.py
import gluon.import_all # This should be uncommented for py2exe.py
On Tuesday, October 1, 2013 6:12:21 PM UTC+2, step wrote:
>
> I noticed a comment on line 17 of gluon\main.py, uncommented the line and
>
t now.
>
> On Tuesday, October 1, 2013 6:37:49 PM UTC+2, step wrote:
>>
>> Sorry, it's line 17 of web2py.py that I uncommented, not gluon\main.py
>> import gluon.import_all # This should be uncommented for py2exe.py
>>
>> On Tuesday, October 1, 2013 6:12:
Some options.
In Windows you can run TASKEND to kill a process by pid or process name.
Getting the pid using just standard Windows commands is complicated, though.
You could download the freeware pstools suite from www. sysinternals.com and
feel more at home. Pstools is a collection of command-li
I discovered and reported in
http://code.google.com/p/pyfpdf/issues/detail?id=66 an issue with
gluon/contrib/FPFD. Basically, rendering HTML tags as PDF may trigger
a utf8 codec error because fpdf/html.py sets the bullet character as
'\x95'. As a work-around I have replaced '\x95' with '*'.
-
est='S'))
}}
{{=HTML(BODY(UL([text('à'),text('€')])))}}
On Monday, October 28, 2013 9:46:10 PM UTC+1, Richard wrote:
>
> did you user your_string.decode('utf8') before passing to FPDF??
>
> I think you have mistake in your code, you should pr
; Please let follow this on the fpdf site:
>>
>> http://code.google.com/p/pyfpdf/issues/detail?id=66
>>
>> Thanks for reporting it!
>>
>> Mariano Reingart
>> http://www.sistemasagiles.com.ar
>> http://reingart.blogspot.com
>>
>>
>> On Tue, Oct
Can a single component update more than one target?
I want to click on a link and have it update two targets at once, is this
possible?
The single-target cookbook is relatively simple:
views/default/index.load:
{{=A(('fix
it'),_href=URL(c='archive',f='op',args='fix'),cid='archive_op_fix')}}
On Wednesday, November 6, 2013 7:55:23 PM UTC+1, Derek wrote:
>
> You'll most likely need to use ajax() from web2py.js and use 'eval' and
> return the javascript to run.
>
>>
Well if I change op() in controllers/archive.py to return a script like
this:
def op():
status = ''
if reque
on(event){
> ajax('update_span', [ ], ':eval')
> ...
>
>
> in the controller:
> def update_span():
> return "$('#to_be_updated').html('fubar');"
>
>
>
> On Wednesday, November 6, 2013 3:25:11 PM UTC-5, step wr
Enhancement request: please add class row_buttons to the TH element that
corresponds to a TD.row_buttons element.
Work-arounds in lie of this feature are possible, as jQuery code, or python
code involving elements(). But work-arounds need to be repeated for each
output TABLE() or loaded table c
I just realized that SQLFORM.grid can display button columns on both sides
(buttons_placement='both'), so here is a revised jQuery work-around to
account for that case:
$('.web2py_table').each(function(){
$(this).find('td.row_buttons').each(function(){
$(this).closest('table').find('t
REQ is for TH not TD.
On Monday, November 25, 2013 7:46:41 PM UTC+1, Massimo Di Pierro wrote:
>
> It appears to be there already (sqlhtml.py line 2475):
>
> row_buttons = TD(_class='row_buttons',_nowrap=True)
>
> On Sunday, 24 November 2013 04:19:20 UTC-6, step wrot
Yes! Good luck Massimo and web2py, go go go
On Saturday, January 4, 2014 5:08:38 AM UTC+1, Massimo Di Pierro wrote:
>
> Web2py/me have been nominated for the Edison Award. Please wish web2py
> (and me) good luck. :-)
>
>
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
My app shows the download link of a filename that includes character hex
BA, a.k.a masculine ordinal indicator (ref.
http://www.fileformat.info/info/unicode/char/ba/index.htm)
The code that builds the download link
A(_href=urllib.quote(URL('archive','download',args('mail_group','csv',
filename))
Is using a byte-compiled routes.pyc supported? In my tests when I place
just routes.pyc into web2py-trunk and start the server I get an invalid
request due to mismatched routing. Then if I replace routes.pyc with
routes.py and restart the server everything works allright. So it seems
that using
In upgrading from 2.6.4 to 2.8.2 my custom-built web2py_no_console.exe
failed starting the rocket server with a 'can't import module http' python
error. It's something seemingly unrelated to the other posters' issues, but
I'm sharing how I was able to fix it, maybe it will help someone.
Essentia
em with
> these lines
>
>
> https://github.com/web2py/web2py/blob/master/extras/build_web2py/setup_exe.py#L100
>
> BTW: we're moving towards bbfreeze packed binaries, and they seem to work
> well with bbreeze 0.13
>
> On Tuesday, February 4, 2014 12:50:
Just a heads up to those who localized their apps and upgrade to a recent
web2py version - I noticed this change in upgrading from 2.6.4 to 2.8.2.
A number of error messages in file gluon/validators.py have changed by
capitalizing the error message, e.g., 'value not in database' became 'Value
no
es
> in here
> https://github.com/web2py/web2py/blob/7bc603f38053ec80cbce9f25c4413aae550c7b4f/gluon/languages.py,
>
> with look ups done for completely lower-cased messages?
>
>
> Kiran Subbaramanhttp://subbaraman.wordpress.com/about/
"Or" is
>> now "+ Or". The "plus sign" is a character, not an icon (unlike the Add
>> Record button, which uses an icon for "+")
>> There are tooltips as well. "Start building a new search", "Add this to
>> the search
On Thursday, February 6, 2014 2:02:00 PM UTC+1, Anthony wrote:
>
>
> I think most if not all messages generated in gluon code are customizable
> via the API as well as translatable. If you are aware of messages that are
> not, please point them out.
>
What do you mean by customizable via the A
I think we are talking about the same messages. When you wrote that
"[gluon] messages are customizable via the API and translatable" I thought
you were describing something more than the process of grabbing all T(x)s
in gluon code and entering a translation for each x in file
languages/.py.
In
59 matches
Mail list logo