Hello,
is it possible to sort NULLS last with orderby desc?
orderby=~db.table.last_login
I want the empty last_login last in desc sorting.
On postgresql:
ORDER BY sort_expression1 [ASC | DESC] [NULLS { FIRST | LAST }]
Thanks,
Mike
--
Resources:
- http://web2py.com
- http://web2py.com/book
Am Donnerstag, 24. November 2016 14:07:07 UTC+1 schrieb Leonel Câmara:
>
> You can actually use login_user which just takes a user Row and makes it
> be the logged in user, which is what login_bare and the other login methods
> use after verifying the password. I think this is a bad idea even
Strictly speaking I want the original login_bare plus an
login_bare_without_password, which allows login only with username. This is
only for intranet use.
Mike
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
-
Hello,
for an intranet page with special login I need an additional "login_bare",
firstly without password.
To test ist, I try in model:
from gluon.tools import Auth
class MC_Auth(Auth):
def mc_login_bare(self, username, password):
"""
logins user
"""
Am Freitag, 27. Mai 2016 06:48:31 UTC+2 schrieb Anthony:
>
> def list_order_type():
> if 'edit' in request.args:
> record = db.foobar(request.args(-1, cast=int))
> older_than_an_hour = record.created_on < request.now - datetime.
> timedelta(hours=1)
>
Hello,
I try to find a solutiuon for a hopefully simple problem.
Example:
db.define_table("foobar",
Field("uuid", "string"),
Field("text", "string"),
Field('created_on', "datetime", default=request.now))
def list_order_type():
form = SQLFORM.grid(db.foobar)
return
Hello Massimo,
Am Sonntag, 27. März 2016 17:18:42 UTC+2 schrieb Massimo Di Pierro:
>
> Hello Mike,
>
> could you explain your patch to web2py-developers? it is quite extensive.
>
>
I think you misunderstood me (or I didn't explain it well).
This "patch" is only a summary of what I found in
Hello all and Anthony,
Am Freitag, 20. November 2015 07:52:05 UTC+1 schrieb Bart:
>
> Hi Anthony,
>
> This solution you mention is, with some minor changes, still working in
> the current version. I've managed to get the change working in the 2.12.3
> version of web2py.js:
> Change function
Am Montag, 18. Januar 2016 18:06:32 UTC+1 schrieb Anthony:
>
> Maybe this will work:
> http://www.web2py.com/books/default/chapter/29/06/the-database-abstraction-layer#Custom-Field-types--experimental-
>
This looks good. Don't know why I didn't see this before...
This seems to work:
from
Hello,
I need to map *a new* boolean field in a real postgresql bolean field.
In an old post from 2012 I found this:
> I understand the problem. You can chance the DB type (and you did) but
> web2py still tries to put an 'F' or a 'T' in there.
>
> I modified trunk so that this can be
Hi,
in a form i have
TD(INPUT(_id='keyword', _name='keyword', _onkeyup=ajax(URL('callback',
['keyword', 'stype']), 'target');), _name=search_type)))
If a text is entered, callback is called an some text is displayed in
target. This works.
But now I want to sign the URL.
If I add
', _name='keyword', _onkeyup=ajax(URL('callback',
['keyword', 'stype'], user_signature=True), 'target');), _name=
search_type)))
Regards
On Wednesday, March 19, 2014 1:59:38 PM UTC+1, Mike Constabel wrote:
Hi,
in a form i have
TD(INPUT(_id='keyword', _name='keyword', _onkeyup=ajax(URL
/04/the-core?search=signed#Digitally-signed-urls
BTW: auth.requires_signature() takes hash_vars as a parameter too.
On Wednesday, March 19, 2014 10:18:38 PM UTC+1, Mike Constabel wrote:
Doesn't work. The generated HTML code:
input id=keyword name=keyword onkeyup=ajax(URL(#x27;callback#x27
Hi,
I try to generate multiple SOLIDFORMS from table rows.
Simple example in pseudo code:
x = db(y.z).select()
for d in x:
form=CAT(form, SOLIDFORM(d))
return dict(form=form)
This works for me:
Model:
#simplified, the tables are much longer in real
db.define_table(foo_analysis_type,
Hi,
Am Montag, 10. Februar 2014 16:05:49 UTC+1 schrieb viniciusban:
Maybe I missed something, but what is a SOLIDFORM?
Sorry, forget to mention it.
SOLIDFORM is an extended SQLFORM
http://dev.s-cubism.com/plugin_solidform
--
Resources:
- http://web2py.com
- http://web2py.com/book
Am Montag, 10. Februar 2014 16:21:57 UTC+1 schrieb Cliff Kachinske:
Have you tried it without the showid arg?
Yes, same error.
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
-
Yes. same error.
Am Montag, 10. Februar 2014 16:21:57 UTC+1 schrieb Cliff Kachinske:
Have you tried it without the showid arg?
On Monday, February 10, 2014 3:12:36 AM UTC-5, Mike Constabel wrote:
Hi,
I try to generate multiple SOLIDFORMS from table rows.
Simple example in pseudo code
17 matches
Mail list logo