Mark Notification Download 6.1.2.0

5.0
us Michieal ~ Coder ~ 2 years ago

This component adds in the ability to mark a notification as read, or to delete a notification without leaving the page that you are on. No more having to click the various notifications to mark them as read. This utility grants the user the ability to delete their own notifications (and thus help keep your database clean). Modeled off of how Facebook allows you to just mark a notification as read, or to delete those annoying "this person liked your comment" notifications.

Suggestions for improvement, or bug fixes (or simply finding one and letting me know) are always welcome!

This is the initial release of the component, and I have tested it on a live site.

Comments
German Dominik L Replied 7 months ago

Can someone help?

I get this error:

[23-Apr-2023 11:46:02 UTC] PHP WARNING: 2023-04-23 11:46:02 (UTC): "Undefined array key "guid"" in file
/home/queermeet/public_html/components/MarkNotification/actions/delnotif.php
(line 12)

gb ALBERT DICK Replied 9 months ago

DO YOU KNOW IF THERE IS A FIX FOR THIS YET AS WOULD LIKE TO GET RID OF THEM ALL
enter image description here

us Pariter Retirap Replied 2 years ago

This is an example of notifications that don't get deleted "out of the box" with this component. Have not attempted to bug fix this yet, I imagine it's just because Videos/group/event haven't been tagged as an item to receive the action button. Thanks for your hard work!

enter image description here

German Michael Zülsdorff Replied 2 years ago

Just tried 6.1.2.0, and the logic appears still strange to me. This screenshot shows two groupies of mine:

  • Honey, who liked a photo some days ago. This notification has been marked already as read and because of that it is no longer part of popup on the right
  • Botox, who just added a fresh comment. And this noticfiation is in fact still unread.

Nevertheless, I get the same 'Mark Read' link in both cases - I would expect to get it with Botox, only.


enter image description here

us Michieal ~ Coder ~ Replied 2 years ago

As seen in the image below, only the first notification goes through the templating process, as defined in view.php. (I copied over the original into my component so that I could modify it.)

Notification Template Issue

us Michieal ~ Coder ~ Replied 2 years ago

@Hugo -- Thank you! I added it in.

@Michael -- thank you for the direction! This task, is proving to be difficult. Mainly, because I realized that I had to put the controls into the block to be removed. I surrounded it by a <div id="notif-$guid"> so that I can remove all of it (rather than having the notification gone, and the controls to delete / mark read sitting there pointing at nothing). <-- that mostly works, because some notifications don't get templated?! (don't get it).

German Michael Zülsdorff Replied 2 years ago

and it doesn't on the fly refresh the all notifications page content.

jquery will be your friend ... you would use something like

$('.anchor-to-be-deleted').remove();

Study OssnComment's delete action + accompanying script and you'll get an idea. :)

cl Erassus ︎ ︎ Replied 2 years ago

Hi Michieal, nice update, all working great.

I added the spanish locale file in the github.

Regards.

us Michieal ~ Coder ~ Replied 2 years ago

V6.1.2.0 ~ Added happy javascript to perform the calls so that the page doesn't have to refresh each time you mark or delete a notification.

Added the Delete All Reactions as a button on the bottom of the Notifications dropdown, next to the See All link.

It's not 100% exactly what I want it to be, but it's very, very close. Ie., it doesn't (yet) have the ability to on the fly refresh just the notifications drop down, and it doesn't on the fly refresh the all notifications page content.
If anyone is willing to help with this, I would be extremely happy!

us Michieal ~ Coder ~ Replied 2 years ago

I would do a pull request, as I can merge it right in.

Because I haven't figured out how to make use of the "friends" on here.

Component

Developer: Michieal
License GPL v2
Type: Tools
Requires Ossn Version : 6.1
Latest Version: 6.1.2.0
Last Updated 2 years ago
Repository Url View Repository

Versions