Opened 7 years ago

Closed 7 years ago

Last modified 5 years ago

#11617 closed (duplicate)

Enhance User Message System

Reported by: Christian Karrié Owned by: nobody
Component: contrib.auth Version: 1.0
Severity: Keywords: user message enhancement
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

Hi,

I would like to see a enhanced user message system that allows to specify some base types of the message.

For example:

  • message_type = 'Error'
  • message_type = 'Success'
  • message_type = 'Notice'

That would be very practicable if you do an custom action and want to display as a user message, if it has failed or not.

An example for validating a Model using a Admin Action for further calculations could look like this:

# admin.py (fictional code)

def validate(modeladmin, request, queryset):
    for q in queryset.all():
        message = u"%s: %s" %(q.name, q.validate())
        if q.is_valid:
            message_type = 'Success'
        else:
            message_type = 'Error'
        request.user.message_set.create(message=message, message_type=message_type)
validate.short_description = "Validate for Agl"

Change History (5)

comment:1 Changed 7 years ago by Ramiro Morales

I'm tempted to close this as a d uplicate of #4606 where the addition of a type to the message is one of the proposed/asked for features of a new messaging system.

comment:2 Changed 7 years ago by Ramiro Morales

oops, I meant #4604

comment:3 Changed 7 years ago by Karen Tracey

Resolution: duplicate
Status: newclosed

It's a more direct duplicate of #3995.

comment:4 Changed 7 years ago by Christian Karrié

You're right, is a duplicate of 4604 and 3995, I'm sorry

comment:5 Changed 5 years ago by Jacob

milestone: 1.2

Milestone 1.2 deleted

Note: See TracTickets for help on using tickets.
Back to Top