Re: More user friendly delete confirmation template

2022-08-16 Thread Carlton Gibson
> Can we at least agree to put an id="..." onto the  element wrapping
that list.

That seems pretty minimal.   Do you want to open a PR so we can have a
look?

On Tue, 16 Aug 2022 at 21:58, Jacob Rief  wrote:

> Can we at least agree to put an id="..." onto the  element wrapping
> that list.
> That would help me to add some JS and CSS to the overwritten
> delete_selected_confirmation template without
> having to copy a huge block of HTML code from that template.
>
> – Jacob
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/1bbb2f37-765d-4bcf-83d6-7ddc04dd5edcn%40googlegroups.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAJwKpySp2t%2BCwMJ5Cea7Br8fE%2B9fBk7h7cEUh_cEme96ceF4ww%40mail.gmail.com.


Re: More user friendly delete confirmation template

2022-08-16 Thread Jacob Rief
Can we at least agree to put an id="..." onto the  element wrapping 
that list.
That would help me to add some JS and CSS to the overwritten 
delete_selected_confirmation template without
having to copy a huge block of HTML code from that template.

– Jacob

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/1bbb2f37-765d-4bcf-83d6-7ddc04dd5edcn%40googlegroups.com.


Re: Fellow Reports - August 2022

2022-08-16 Thread Mariusz Felisiak
Week ending August 14, 2022 

*Triaged: *
   https://code.djangoproject.com/ticket/33902 - UniqueConstraint's 
validation crashes with string expressions. (accepted) 
   https://code.djangoproject.com/ticket/33904 - Many-To-Many field is 
deleted/ignored from internal JavaScript “filter” interface (fixed) 
   https://code.djangoproject.com/ticket/33905 - Validation of check 
constraints against ranges involving PostgreSQL's lower()/upper() functions 
produces invalid SQL. (accepted) 
   https://code.djangoproject.com/ticket/33906 - TestCase inconsistent 
behavior on Db integrity error. (invalid) 
   https://code.djangoproject.com/ticket/33907 - UniqueConstraints voided 
when using GenericTabularInline (needsinfo) 
   https://code.djangoproject.com/ticket/33908 - ImageField model doesn't 
have upload_to() method (invalid) 
   https://code.djangoproject.com/ticket/33909 - Signals docs omits 
**kwargs param to @receiver decorator? (accepted) 
   https://code.djangoproject.com/ticket/33911 - Add hook for 
BaseModelAdmin.raw_id_fields (duplicate) 
   https://code.djangoproject.com/ticket/33910 - Clearly explain where 
'django.urls.reverse' gets its name (invalid) 
   https://code.djangoproject.com/ticket/33912 - In the admin, saving an 
object in a non-default DB with unique field fails when the default DB 
contains an object with the same unique field value but different PK 
(duplicate) 
   https://code.djangoproject.com/ticket/33913 - Django 4.1 class-based 
view, Chinese translation (invalid) 
   https://code.djangoproject.com/ticket/33914 - App level 
default_auto_field is ignored for m2m through tables (duplicate) 
   https://code.djangoproject.com/ticket/33915 - CheckboxSelectMultiple 
check first item (invalid) 
   https://code.djangoproject.com/ticket/33918 - __str__ method in Query 
object not wrapping strings in quotation marks (duplicate) 
   https://code.djangoproject.com/ticket/33917 - Optimize ModelBase.__new__ 
app_label setup (wontfix) 
   https://code.djangoproject.com/ticket/33920 - Document that 
LOGGING_CONFIG callback is not called when LOGGING dict is not set. 
(accepted) 
   https://code.djangoproject.com/ticket/33919 - Primary keys added in 
non-initial migration are not created as identity columns in PostgreSQL 
(accepted) 
   https://code.djangoproject.com/ticket/33921 - Removed 
LogoutView.get_next_page without any notice (accepted) 
   https://code.djangoproject.com/ticket/33923 - Swappable Model support 
for Group Model (duplicate) 

*Reviewed/committed: *
   https://github.com/django/django/pull/15925 - Fixed #33899 -- Fixed 
migration crash when removing indexed field on SQLite 3.35.5+. 
   https://github.com/django/django/pull/15927 - Added test for non-HTTP 
request on ASGIStaticFilesHandler. 
   https://github.com/django/django/pull/15916 - Fixed #31721 -- Allowed 
ModelForm meta to specify form fields. 
   https://github.com/django/django/pull/15930 - Fixed #33895 -- Fixed 
Case() crash with filters that match everything in When(). 
   https://github.com/django/django/pull/15931 - Fixed #33905 -- Fixed 
CheckConstraint() validation on range fields. 
   https://github.com/django/django/pull/15942 - Refs #26029 -- Doc'd 
django.core.files.storage.default_storage. 
   https://github.com/django/django/pull/15941 - Fixed #28975 -- Made 
PostGIS backend skip extension creation if installed. 
   https://github.com/django/django/pull/15945 - Replaced 
Expression.replace_references() with .replace_expressions(). 
   https://github.com/django/django/pull/15953 - Fixed #33924 -- Deprecated 
BaseGeometryWidget.map_height/map_width attributes. 
   https://github.com/django/django/pull/15955 - Fixed #33921 -- Added 
release note for 5b8699e723d9daf373fff46c6859fed2b780a9bd. 

*Reviewed: *
   https://github.com/django/django/pull/15822 - Refs #30213 -- Removed 
post-startup check for Watchman availability. 

*Authored: *
   https://github.com/django/django/pull/15933 - Fixed #33902 -- Fixed 
Meta.constraints validation crash with F() expressions. 
   https://github.com/django/djangoproject.com/pull/1194 - Increased 
FeedItem.link/Feed.public_url max_length to 1023 characters. 
   https://github.com/django/django/pull/15940 - Refs #33895 -- Fixed 
Case() crash with filters that match everything in When() on Oracle. 
   https://github.com/django/django/pull/15952 - Fixed #33919 -- Fixed 
adding AutoFields on PostgreSQL.

Best,
Mariusz

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/56f07bcd-d0cc-4e32-9657-bfb22b406f93n%40googlegroups.com.


Re: More user friendly delete confirmation template

2022-08-16 Thread אורי
אורי
u...@speedy.net


On Tue, Aug 16, 2022 at 3:55 PM 'Adam Johnson' via Django developers
(Contributions to Django itself)  wrote:

> Collapsing the list of to-be-deleted objects could also lead to cases of
> accidental removal of related objects. I think it's better to err on the
> side of overwhelming than hiding information.
>

When I delete a user in the admin, I see the objects that would be deleted
too. This is very important and I don't want to collapse this list. There
are usually about 5 objects to be deleted, and I want to see them all in
the HTML. The current interface is perfect and I don't want to change it.

Uri Rodberg, Speedy Net.

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CABD5YeGRseHj%2BMq9tWNSVMGXkp3QUUixZG688HhKWCLmcbQF5Q%40mail.gmail.com.


Re: More user friendly delete confirmation template

2022-08-16 Thread Jacob Rief
The least intrusive change would be to add an id="..." to the -element 
wrapping that list.
This at least allows me to add such a Javascript snippet into {% block 
extrahead %}.

– Jacob

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/c1127d9a-e1f9-45fc-9104-0b478f18ee6dn%40googlegroups.com.


Re: More user friendly delete confirmation template

2022-08-16 Thread Jacob Rief
On Tuesday, August 16, 2022 at 4:23:03 PM UTC+2 Carlton Gibson wrote:

>
> Then as Maxim points out, this is already possible with overriding the 
> template. 
>
>
That's what I did of course in the first place. It however turns out that 
you have to copy quite a bunch of boilerplate code, the complete {% block 
content %}, in order to add a tiny Javascript snippet.
Since Django templates can evolve considerably between versions, this can 
lead to other side effects after upgrading.
An alternative would be add a {% block objects_to_be_deleted %} around the 
list of objects-to-be-deleted. This at least would allow to simpler extend 
that template. 

> I would argue that if the list of objects is "overwhelming" / 
> "unsettling", then this is perhaps an indicator that the admin interface is 
> being used beyond its intended scope. The admin is designed for site 
> administrators, mostly developers. Yes, most projects seem to push it 
> beyond that, but we can't make it something for all people.
>
Well Django-CMS is built around the Django-Admin user interface and its 
users typically are not site administrators. Moreover, why would Django 
offer
a sophisticated permission framework, if the only users being "allowed" to 
work with the Django-Admin are "site administrators".

Side note, if you're unfamiliar with Django-CMS: Whenever you delete a 
CMS-page, you also delete its page-titles, placeholders and their plugins, 
which can lead to a really long list of objects to be deleted.

– Jacob

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/7c900403-5aca-47e0-9c4d-23c77b8b174dn%40googlegroups.com.


Re: More user friendly delete confirmation template

2022-08-16 Thread Carlton Gibson
These kinds of UI features are quite "maintenance-heavy" — they're hard to
test, and fragile — and so can consume a lot of time in review, perhaps
disproportionate, perhaps not. That on-top of Adam's points mean I'd lean
to -1 to begin. Maybe that's not the final answer, but I'd look for another
way first. (The particular change here isn't likely too difficult, but
that's the opening bias)

Then as Maxim points out, this is already possible with overriding the
template.

*But we don't really show how to do that*.
(I'm looking forward to Maxim's DjangoCon talk,
 partly for
this reason.)

I wonder if a *HowTo* in the docs on patterns for customising the admin,
beginning with the "The Admin is not your app" reminder, but showing how
you might override a template or two, or add a rich JS widget to a form, or
... (there are a few *kinds* of use-cases that come up I think)... — would
be a useful resource?
I've always had to search for a while each time I've wanted to do this in
the past.

To me this would seem like something we could add without needing to expand
the built-in functionality too much.

Kind regards,
Carlton


On Tue, 16 Aug 2022 at 15:54, 'Adam Johnson' via Django developers
(Contributions to Django itself)  wrote:

> The admin interface is not designed for such mass deletions. When deleting
> millions of objects, it can be necessary to paginate the deletion to avoid
> exhausting the resources of your database server. I don't think it's
> suitable for a view to try and do this.
>
> Btw in the case of sessions, use the 'clearsessions' management command:
> https://docs.djangoproject.com/en/4.1/ref/django-admin/#clearsessions .
> In the case of admin logs, I would use 'shell' with the ORM.
>
>
>
> On Tue, Aug 16, 2022 at 2:42 PM Danilov Maxim  wrote:
>
>> >> Collapsing the list of to-be-deleted objects could also lead to cases
>> of accidental removal of related objects. I think it's better to err on the
>> side of overwhelming than hiding information.
>>
>>
>>
>> But sometimes It is very painful to delete whole list of sessions (
>> database-backed
>> 
>> sessions) (4mlo) or Django admin logs (66mlo).
>>
>>
>>
>>
>>
>> Mit freundlichen Grüßen,
>>
>> DI Mag. Maxim Danilov
>>
>>
>>
>> +43(681)207 447 76 <+43(681)207%20447%2076>
>>
>> ma...@wpsoft.at
>>
>>
>>
>> *From:* 'Adam Johnson' via Django developers (Contributions to Django
>> itself) [mailto:django-developers@googlegroups.com]
>> *Sent:* Tuesday, August 16, 2022 2:55 PM
>> *To:* Django developers (Contributions to Django itself) <
>> django-developers@googlegroups.com>
>> *Subject:* Re: More user friendly delete confirmation template
>>
>>
>>
>> If the object to be deleted contains many relations, the user
>> is overwhelmed with a list of other objects to be deleted together with the
>> current object. Often those objects are just internal relations the user
>> never heard of, and this may be unsettling.
>>
>>
>>
>> I would argue that if the list of objects is "overwhelming" /
>> "unsettling", then this is perhaps an indicator that the admin interface is
>> being used beyond its intended scope. The admin is designed for site
>> administrators, mostly developers. Yes, most projects seem to push it
>> beyond that, but we can't make it something for all people.
>>
>>
>>
>> Collapsing the list of to-be-deleted objects could also lead to cases of
>> accidental removal of related objects. I think it's better to err on the
>> side of overwhelming than hiding information.
>>
>>
>>
>> On Tue, Aug 16, 2022 at 1:22 PM Danilov Maxim  wrote:
>>
>> Hi Jacob.
>>
>> On the one side - you can override this delete_confirmation.html and
>> delete_selected_confirmation.html I do it since dj 1.4
>>
>>
>>
>> On the other side I am agree with Jacob - it can be in Django by default.
>> – We can add “collapsed” div to wrap  with every objects list, or we
>> can add details/summary for that.
>>
>>
>>
>> Mit freundlichen Grüßen,
>>
>> DI Mag. Maxim Danilov
>>
>>
>>
>> +43(681)207 447 76 <+43(681)207%20447%2076>
>>
>> ma...@wpsoft.at
>>
>>
>>
>> *From:* django-developers@googlegroups.com [mailto:
>> django-developers@googlegroups.com] *On Behalf Of *Jacob Rief
>> *Sent:* Tuesday, August 16, 2022 1:57 PM
>> *To:* Django developers (Contributions to Django itself) <
>> django-developers@googlegroups.com>
>> *Subject:* More user friendly delete confirmation template
>>
>>
>>
>> Whenever a user attempts to delete an object inside the Django admin,
>>
>> a delete confirmation page is shown. If the object to be deleted contains
>>
>> many relations, the user is overwhelmed with a list of other objects to be
>>
>> deleted together with the current object. Often those objects are just
>>
>> internal relations the user never heard of, and this may be unsettling.
>>
>>
>>
>> I therefore propose to hide those related objects 

Re: More user friendly delete confirmation template

2022-08-16 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
The admin interface is not designed for such mass deletions. When deleting
millions of objects, it can be necessary to paginate the deletion to avoid
exhausting the resources of your database server. I don't think it's
suitable for a view to try and do this.

Btw in the case of sessions, use the 'clearsessions' management command:
https://docs.djangoproject.com/en/4.1/ref/django-admin/#clearsessions . In
the case of admin logs, I would use 'shell' with the ORM.



On Tue, Aug 16, 2022 at 2:42 PM Danilov Maxim  wrote:

> >> Collapsing the list of to-be-deleted objects could also lead to cases
> of accidental removal of related objects. I think it's better to err on the
> side of overwhelming than hiding information.
>
>
>
> But sometimes It is very painful to delete whole list of sessions (
> database-backed
> 
> sessions) (4mlo) or Django admin logs (66mlo).
>
>
>
>
>
> Mit freundlichen Grüßen,
>
> DI Mag. Maxim Danilov
>
>
>
> +43(681)207 447 76
>
> ma...@wpsoft.at
>
>
>
> *From:* 'Adam Johnson' via Django developers (Contributions to Django
> itself) [mailto:django-developers@googlegroups.com]
> *Sent:* Tuesday, August 16, 2022 2:55 PM
> *To:* Django developers (Contributions to Django itself) <
> django-developers@googlegroups.com>
> *Subject:* Re: More user friendly delete confirmation template
>
>
>
> If the object to be deleted contains many relations, the user
> is overwhelmed with a list of other objects to be deleted together with the
> current object. Often those objects are just internal relations the user
> never heard of, and this may be unsettling.
>
>
>
> I would argue that if the list of objects is "overwhelming" /
> "unsettling", then this is perhaps an indicator that the admin interface is
> being used beyond its intended scope. The admin is designed for site
> administrators, mostly developers. Yes, most projects seem to push it
> beyond that, but we can't make it something for all people.
>
>
>
> Collapsing the list of to-be-deleted objects could also lead to cases of
> accidental removal of related objects. I think it's better to err on the
> side of overwhelming than hiding information.
>
>
>
> On Tue, Aug 16, 2022 at 1:22 PM Danilov Maxim  wrote:
>
> Hi Jacob.
>
> On the one side - you can override this delete_confirmation.html and
> delete_selected_confirmation.html I do it since dj 1.4
>
>
>
> On the other side I am agree with Jacob - it can be in Django by default.
> – We can add “collapsed” div to wrap  with every objects list, or we
> can add details/summary for that.
>
>
>
> Mit freundlichen Grüßen,
>
> DI Mag. Maxim Danilov
>
>
>
> +43(681)207 447 76
>
> ma...@wpsoft.at
>
>
>
> *From:* django-developers@googlegroups.com [mailto:
> django-developers@googlegroups.com] *On Behalf Of *Jacob Rief
> *Sent:* Tuesday, August 16, 2022 1:57 PM
> *To:* Django developers (Contributions to Django itself) <
> django-developers@googlegroups.com>
> *Subject:* More user friendly delete confirmation template
>
>
>
> Whenever a user attempts to delete an object inside the Django admin,
>
> a delete confirmation page is shown. If the object to be deleted contains
>
> many relations, the user is overwhelmed with a list of other objects to be
>
> deleted together with the current object. Often those objects are just
>
> internal relations the user never heard of, and this may be unsettling.
>
>
>
> I therefore propose to hide those related objects behind a link named
>
> "Show related object to delete"
>
> If the user clicks on that link, the complete list of objects to be
> deleted is
>
> expanded into the confirmation page. This also prevents having to scroll
>
> down to the end of a potentially very long page in order to confirm the
>
> deletion by clicking on "Yes I'm sure".
>
>
>
> [image: Screenshot 2022-08-16 at 13.34.46.png]
>
>
>
> – Jacob
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/e59f0771-cb65-4564-ace4-50a7ffd96cf6n%40googlegroups.com
> 
> .
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/01d8b16a%24d5c5f640%248151e2c0%24%40wpsoft.at
> 

RE: More user friendly delete confirmation template

2022-08-16 Thread Danilov Maxim
>> Collapsing the list of to-be-deleted objects could also lead to cases of 
>> accidental removal of related objects. I think it's better to err on the 
>> side of overwhelming than hiding information.

 

But sometimes It is very painful to delete whole list of sessions ( 

 database-backed sessions) (4mlo) or Django admin logs (66mlo).

 

 

Mit freundlichen Grüßen,

DI Mag. Maxim Danilov

 

+43(681)207 447 76

  ma...@wpsoft.at

 

From: 'Adam Johnson' via Django developers (Contributions to Django itself) 
[mailto:django-developers@googlegroups.com] 
Sent: Tuesday, August 16, 2022 2:55 PM
To: Django developers (Contributions to Django itself) 

Subject: Re: More user friendly delete confirmation template

 

If the object to be deleted contains many relations, the user is overwhelmed 
with a list of other objects to be deleted together with the current object. 
Often those objects are just internal relations the user never heard of, and 
this may be unsettling.

 

I would argue that if the list of objects is "overwhelming" / "unsettling", 
then this is perhaps an indicator that the admin interface is being used beyond 
its intended scope. The admin is designed for site administrators, mostly 
developers. Yes, most projects seem to push it beyond that, but we can't make 
it something for all people.

 

Collapsing the list of to-be-deleted objects could also lead to cases of 
accidental removal of related objects. I think it's better to err on the side 
of overwhelming than hiding information.

 

On Tue, Aug 16, 2022 at 1:22 PM Danilov Maxim mailto:ma...@wpsoft.at> > wrote:

Hi Jacob.

On the one side - you can override this delete_confirmation.html and 
delete_selected_confirmation.html I do it since dj 1.4

 

On the other side I am agree with Jacob - it can be in Django by default. – We 
can add “collapsed” div to wrap  with every objects list, or we can add 
details/summary for that.

 

Mit freundlichen Grüßen,

DI Mag. Maxim Danilov

 

+43(681)207 447 76

  ma...@wpsoft.at

 

From: django-developers@googlegroups.com 
  
[mailto:django-developers@googlegroups.com 
 ] On Behalf Of Jacob Rief
Sent: Tuesday, August 16, 2022 1:57 PM
To: Django developers (Contributions to Django itself) 
mailto:django-developers@googlegroups.com> 
>
Subject: More user friendly delete confirmation template

 

Whenever a user attempts to delete an object inside the Django admin,

a delete confirmation page is shown. If the object to be deleted contains

many relations, the user is overwhelmed with a list of other objects to be

deleted together with the current object. Often those objects are just

internal relations the user never heard of, and this may be unsettling.

 

I therefore propose to hide those related objects behind a link named

"Show related object to delete"

If the user clicks on that link, the complete list of objects to be deleted is

expanded into the confirmation page. This also prevents having to scroll

down to the end of a potentially very long page in order to confirm the

deletion by clicking on "Yes I'm sure".

 



 

– Jacob

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com 
 .
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/e59f0771-cb65-4564-ace4-50a7ffd96cf6n%40googlegroups.com
 

 .

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com 
 .
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/01d8b16a%24d5c5f640%248151e2c0%24%40wpsoft.at
 

 .

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com 
 .
To view this discussion on the web visit 

Re: More user friendly delete confirmation template

2022-08-16 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
>
> If the object to be deleted contains many relations, the user
> is overwhelmed with a list of other objects to be deleted together with the
> current object. Often those objects are just internal relations the user
> never heard of, and this may be unsettling.
>

I would argue that if the list of objects is "overwhelming" / "unsettling",
then this is perhaps an indicator that the admin interface is being used
beyond its intended scope. The admin is designed for site administrators,
mostly developers. Yes, most projects seem to push it beyond that, but we
can't make it something for all people.

Collapsing the list of to-be-deleted objects could also lead to cases of
accidental removal of related objects. I think it's better to err on the
side of overwhelming than hiding information.

On Tue, Aug 16, 2022 at 1:22 PM Danilov Maxim  wrote:

> Hi Jacob.
>
> On the one side - you can override this delete_confirmation.html and
> delete_selected_confirmation.html I do it since dj 1.4
>
>
>
> On the other side I am agree with Jacob - it can be in Django by default.
> – We can add “collapsed” div to wrap  with every objects list, or we
> can add details/summary for that.
>
>
>
> Mit freundlichen Grüßen,
>
> DI Mag. Maxim Danilov
>
>
>
> +43(681)207 447 76
>
> ma...@wpsoft.at
>
>
>
> *From:* django-developers@googlegroups.com [mailto:
> django-developers@googlegroups.com] *On Behalf Of *Jacob Rief
> *Sent:* Tuesday, August 16, 2022 1:57 PM
> *To:* Django developers (Contributions to Django itself) <
> django-developers@googlegroups.com>
> *Subject:* More user friendly delete confirmation template
>
>
>
> Whenever a user attempts to delete an object inside the Django admin,
>
> a delete confirmation page is shown. If the object to be deleted contains
>
> many relations, the user is overwhelmed with a list of other objects to be
>
> deleted together with the current object. Often those objects are just
>
> internal relations the user never heard of, and this may be unsettling.
>
>
>
> I therefore propose to hide those related objects behind a link named
>
> "Show related object to delete"
>
> If the user clicks on that link, the complete list of objects to be
> deleted is
>
> expanded into the confirmation page. This also prevents having to scroll
>
> down to the end of a potentially very long page in order to confirm the
>
> deletion by clicking on "Yes I'm sure".
>
>
>
> [image: Screenshot 2022-08-16 at 13.34.46.png]
>
>
>
> – Jacob
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/e59f0771-cb65-4564-ace4-50a7ffd96cf6n%40googlegroups.com
> 
> .
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/01d8b16a%24d5c5f640%248151e2c0%24%40wpsoft.at
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAMyDDM0JL9DqgnoFSehXd5D8d4DjzEzvhrUWwbw5wqUBQdDF3Q%40mail.gmail.com.


RE: More user friendly delete confirmation template

2022-08-16 Thread Danilov Maxim
Hi Jacob.

On the one side - you can override this delete_confirmation.html and 
delete_selected_confirmation.html I do it since dj 1.4

 

On the other side I am agree with Jacob - it can be in Django by default. – We 
can add “collapsed” div to wrap  with every objects list, or we can add 
details/summary for that.

 

Mit freundlichen Grüßen,

DI Mag. Maxim Danilov

 

+43(681)207 447 76

  ma...@wpsoft.at

 

From: django-developers@googlegroups.com 
[mailto:django-developers@googlegroups.com] On Behalf Of Jacob Rief
Sent: Tuesday, August 16, 2022 1:57 PM
To: Django developers (Contributions to Django itself) 

Subject: More user friendly delete confirmation template

 

Whenever a user attempts to delete an object inside the Django admin,

a delete confirmation page is shown. If the object to be deleted contains

many relations, the user is overwhelmed with a list of other objects to be

deleted together with the current object. Often those objects are just

internal relations the user never heard of, and this may be unsettling.

 

I therefore propose to hide those related objects behind a link named

"Show related object to delete"

If the user clicks on that link, the complete list of objects to be deleted is

expanded into the confirmation page. This also prevents having to scroll

down to the end of a potentially very long page in order to confirm the

deletion by clicking on "Yes I'm sure".

 



 

– Jacob

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com 
 .
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/e59f0771-cb65-4564-ace4-50a7ffd96cf6n%40googlegroups.com
 

 .

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/01d8b16a%24d5c5f640%248151e2c0%24%40wpsoft.at.


More user friendly delete confirmation template

2022-08-16 Thread Jacob Rief
Whenever a user attempts to delete an object inside the Django admin,
a delete confirmation page is shown. If the object to be deleted contains
many relations, the user is overwhelmed with a list of other objects to be
deleted together with the current object. Often those objects are just
internal relations the user never heard of, and this may be unsettling.

I therefore propose to hide those related objects behind a link named
"Show related object to delete"
If the user clicks on that link, the complete list of objects to be deleted 
is
expanded into the confirmation page. This also prevents having to scroll
down to the end of a potentially very long page in order to confirm the
deletion by clicking on "Yes I'm sure".

[image: Screenshot 2022-08-16 at 13.34.46.png]

– Jacob

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/e59f0771-cb65-4564-ace4-50a7ffd96cf6n%40googlegroups.com.


Re: UI/UX - FilteredSelectMultiple - Filtering the selected options

2022-08-16 Thread Gav O'Connor
Thanks Jacob. 

We have the functionality of the selects working fine, it's just finding a 
way to make it clear to the user that the selected options that are 
filtered out are still in fact selected and will be sent as such in the 
POST. 

Thanks for the info though, I'll take  look. 

On Monday, 15 August 2022 at 22:38:36 UTC+1 jacob...@gmail.com wrote:

> I'have implemented such a widget in django-formset 
> . It just hides (removes) the selected 
> options which have been filtered out.
> Otherwise, filtering by muting options, wouldn't have the desired visual 
> effect.
>
> Please note that in order to implement this feature, I used three  multiple> elements, two of them visible (the left
> and right one) and one hidden, which contains the currently selected 
> options, even if filtered. A nice side-effect of this
> architecture is, that it allows autocompletion for long source lists, and 
> in addition, undoing and redoing a selection.
>
> Please check in the link from above the example:
>  *> Default *(or any other CSS framework) *> Opinion*.
>
> – Jacob
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/de7bc647-a408-426e-8572-97f2b1c00873n%40googlegroups.com.