On Nov 27, 11:50 am, Count László de Almásy <calm...@gmail.com> wrote:
> ok, fair enough. does generic views have the machinery to replicate
> the admin interface?

Generic views take most of the pain out of CRUD, and also take care of
producing and validating forms. You can also steal some of the nice
javascript widgets out of the admin code. You've still got to do the
templating yourself, though, which means that most of the
functionality that you can presently put into admin.py (things like
how the changelists are displayed and filtered, how the forms are laid
out, not to mention admin actions) you'll have to do yourself. I don't
believe you can do inline formsets with generic views, which is
unfortunate, but it's not hard with a simple custom view.

All in all, I've found that doing my own admin functionality really
isn't hard at all, and you suddenly have a huge amount of freedom; the
only real pain in the ass is that you're starting from scratch with
the html and css. Boring!

Eric

>
> On Nov 26, 7:28 pm, Skylar Saveland <skylar.savel...@gmail.com> wrote:
>
>
>
> > Yep, still a bad idea.  Permissions are by table not by row.  Use
> > generic views for basic CRUD.
>
> > Count László de Almásy wrote:
>
> > > i've seen notes in some django documentation that implies that using /
> > > admin/ for non-trusted users is not a good idea. which is unfortunate
> > > since it seems like the admin interface is about 95% of what i want
> > > for my users to be able to view and manipulate their sales
> > > transactions data over the web. each user has their own table in the
> > > db for transactions, and they can do whatever they want to their own
> > > data. i wouldn't want them to be able to touch anyone else's tables,
> > > but it seems like django has a permissions system to restrict that.
>
> > > with the latest django, is it still considered a bad idea to do this?
> > > if so, what is the alternative, writing custom views to mimic what the
> > > admin interface does?

--

You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.


Reply via email to