Modify

Opened 15 years ago

Closed 15 years ago

#5682 closed enhancement (fixed)

Announcer should have a page listing all Watched items

Reported by: anonymous Owned by: Robert Corsaro
Priority: high Component: AnnouncerPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

Please see WatchlistPlugin.

If this functionality can't be duplicated/merged, please change the wording of "Watch This"/"Unwatch This" to something that doesn't closely match the wording used in the WatchlistPlugin. Perhaps "Add to Announcements" or "Remove from Announcements" or something similar.

See #4744 for this workaround.

Attachments (2)

announcer_ctxtnav_config.patch (1.3 KB) - added by Martin Scharrer 15 years ago.
Patch to make context navigation entries ('Watch this','Unwatch this') configurable
announcer_ctxtnav_config2.patch (1.5 KB) - added by Martin Scharrer 15 years ago.
Patch to fix wrong index order and rename notifications.

Download all attachments as: .zip

Change History (19)

comment:1 Changed 15 years ago by Ryan J Ollos

It would be nice put an entry in the metanav ('Watchlist') that links to the page with the table of all watched pages for a particular user.

comment:2 Changed 15 years ago by sincoder

I second this

comment:3 in reply to:  1 ; Changed 15 years ago by Martin Scharrer

Replying to rjollos:

It would be nice put an entry in the metanav ('Watchlist') that links to the page with the table of all watched pages for a particular user.

This is exactly what the WatchlistPlugin does.

comment:4 Changed 15 years ago by Martin Scharrer

Priority: normalhigh

The WatchlistPlugin rev.[6834] now actively supports the AnnouncerPlugin (see #4744) and allows to switch notification of wikis and tickets watched by the WatchlistPlugin on or off. This is not exactly the same as requested by this ticket but it comes close. Please note that wikis/tickets can be independently watched by both plugins.

I agree with the ticket creator that the navbar entries "Watch This"/"Unwatch This" would be changed to someting else not including 'watch', because this is to close to the WatchlistPlugin (uses "Watch"/"Unwatch"). Maybe having it configurable by the trac.ini config, so it can be changed by people which want to use both plugins?

comment:5 Changed 15 years ago by Robert Corsaro

I would accept that patch

Changed 15 years ago by Martin Scharrer

Patch to make context navigation entries ('Watch this','Unwatch this') configurable

comment:6 Changed 15 years ago by Martin Scharrer

Owner: changed from Robert Corsaro to Martin Scharrer
Status: newassigned

The attached patch allows the user (Trac admin) to rename or disable the context navigation entries.

Examples

Rename the cxtnav entries:

[announcer]
ctxtnav_names = Notify me, Do not notify me 

Disable the entries:

[announcer]
ctxtnav_names =

comment:7 in reply to:  3 Changed 15 years ago by Ryan J Ollos

Replying to martin_s:

This is exactly what the WatchlistPlugin does.

If these are two plugin are working nicely together now, that will be great! I will try installing the WatchListPlugin shortly. I have been using the AnnouncerPlugin for 6 months.

comment:8 Changed 15 years ago by Martin Scharrer

See also the related #6052.

comment:9 Changed 15 years ago by Robert Corsaro

Resolution: fixed
Status: assignedclosed

(In [6916]) Allow the ctxnav names for "watch/unwatch this" to be relabeled or shut off (by setting to blank). This patch was contributed by martin_s closes #5682

comment:10 Changed 15 years ago by anonymous

Thanks for the patch, I really appreciate it.

comment:11 Changed 15 years ago by Ryan J Ollos

I'm working on upgrading to install this patch and I added this change to the wiki page to document the configuration parameter. Please correct if this could be documented better.

Thanks!

comment:12 in reply to:  11 Changed 15 years ago by Martin Scharrer

Replying to rjollos:

I'm working on upgrading to install this patch and I added

this change to the wiki >page to document the configuration parameter. Please correct if this could be documented >better.

Thanks, I now added some more information and crosslinks in this change.

comment:13 Changed 15 years ago by Martin Scharrer

See also the related change of the WatchlistPlugin documentation.

comment:14 Changed 15 years ago by Martin Scharrer

Resolution: fixed
Status: closedreopened

Sorry, I got the indexes wrong therefore the ctxtnav item names are swapped at the moment.

Either change the order of the names in the documentation or fix the indexes in the source code. I would prefer the latter because it is more natural to specify the 'Watch' action name before the 'Unwatch' one.

Simply replaces index [0] with [1] and vice versa:

  • subscribers/watchers.py

     
    150150        realm, resource = resource.split('/', 1)
    151151        if self.is_watching(req.session.sid, not req.authname == 'anonymous',
    152152                realm, resource):
     153            action_name = self.ctxtnav_names[1]
     154        else:
    153155            action_name = self.ctxtnav_names[0]
    154         else:
    155             action_name = self.ctxtnav_names[1]
    156156        add_ctxtnav(req,
    157157            tag.a(
    158158                action_name, href=req.href.watch(realm, resource)

Changed 15 years ago by Martin Scharrer

Patch to fix wrong index order and rename notifications.

comment:15 Changed 15 years ago by Martin Scharrer

In my opinion the messages "You are now watching this resource for changes." and "You are no longer watching this resource for changes." should also be changed, so that the user is not confusing this with the addition and removal from the watchlist.

I made this changes in the attachment:announcer_ctxtnav_config2.patch .

comment:16 Changed 15 years ago by Martin Scharrer

Owner: changed from Martin Scharrer to Robert Corsaro
Status: reopenednew

comment:17 Changed 15 years ago by Robert Corsaro

Resolution: fixed
Status: newclosed

(In [7138]) reverse ctxtnames and check for exist fixes #5682

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Robert Corsaro.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.