this code  from the docs...

@action('index')
@action.uses(auth.user)def index():

    return {"ok":1}

Here @action.uses(auth.user) tells py4web that this action requires a
logged in user and should redirect to login if no user is logged in.



this redirect is good for an full web2py app.

What if i have a SPA in vue ?

In case the user is not logged it it should not redirect to login page
because the apps is a outsider vue spa. How to return an error to vue spa ??

regards


António

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CAEM0BxNvNyYjk40qBKoUVF6cpD1%3DQuBaBA4b2dD2Rck0emFHoA%40mail.gmail.com.

Reply via email to