Commit Graph

321 Commits

Author SHA1 Message Date
Ryan Wyllie d3d95d5dc2 MDL-63303 message: fix bugs in message drawer part 4
* Add clarification to delete messages lang strings
* Stop message polling when sending a message to fix UI bug
* Publish update last message event when polling finds more messages
* Remove logged in user from group conversation participants list
* Use user object to fetch user preferences to reduce DB calls
* Remove animated slide transitions because the browser breaks when
  showing some conversations
2018-11-16 14:10:10 +08:00
Ryan Wyllie c75559cfff MDL-63303 message: move message drawer to end of <body>
Fix some of the behat tests that are looking for generic button
names that match some of the buttons in the message drawer which
happen to appear earlier in the DOM.
2018-11-15 14:43:22 +08:00
Ryan Wyllie a111ab44af MDL-63303 message: fix bugs in message drawer part 2
* Added missing icon mappings for font-awesome
* Fixed focus on dialogue button when it opens
* Fixed UI updates on user block / unblock
* Fix jQuery syntax error when sending message with quotes
* Fix message/index.php opening drawer when no conversation found
* Fix placeholders rendered for new requests
2018-11-15 14:43:21 +08:00
Ryan Wyllie 1d3535f95c MDL-63303 message: fix bugs in message drawer
* Fix navigation from view_contact to view_conversation on an action
  such as blocking
* Fix default open message section on overview page depending on which
  section has conversations
* Fix message/index.php for users who haven't yet started a
  conversation
2018-11-15 14:43:21 +08:00
Ryan Wyllie 8c8939c1ae MDL-63303 message: add enter to send user preference 2018-11-15 14:43:21 +08:00
Ryan Wyllie 1e3453b7c7 MDL-63303 message: change nav popover to toggle message drawer 2018-11-15 14:43:21 +08:00
Ryan Wyllie 5005d8cfb4 MDL-63303 message: add message drawer (boost only) 2018-11-15 14:43:21 +08:00
Sara Arjona f7dfa9ba3e MDL-63214 message: Add privacy preferences to filter who can message
Add new messaging profile preferences to allow users to choose who
can message them:
- By default, users can select between 'My contacts only' and 'My
contacts and anyone in my courses'
- When $CFG->messagingallusers is enabled, a new option is displayed
also: 'Anyone on the site'. For users who have selected this option,
if $CFG->messagingallusers is disabled, the behaviour will be changed
to 'My contacts and anyone in my courses'
2018-10-17 11:52:57 +02:00
Mark Nelson f219eac7b4 MDL-63211 core: update core to use new APIs 2018-10-03 11:51:29 +08:00
Mark Nelson 0b3eadcd96 MDL-63211 core_message: deprecated functions and added new API 2018-10-03 11:35:26 +08:00
Pavel Sokolov f88cc4ccae MDL-63130 message: message_count_unread_message counts sent messages 2018-09-06 18:16:06 +08:00
Adrian Greeve 5454e72c21 MDL-55188 events: First deprecation of eventslib.php 2018-07-30 09:23:54 +08:00
Mark Nelson c57fadcc64 MDL-62808 core_message: fixed 'useridto' being incorrectly set to 0 2018-07-09 12:00:06 +08:00
Mark Nelson 883ce42127 MDL-36941 core: convert existing api to use new table structure
Also deprecated the following functions -

1. message_move_userfrom_unread2read - It is not necessary
   for us to mark a message as read on user deletion.
2. message_get_blocked_users - Horrible logic used to
   determine if a user is blocked via reference on some
   randomly chosen 'isblocked' variable.
3. message_get_contacts - The same as above. This can be
   done in a much nicer way.
4. message_mark_message_read - We want two functions to do
   this to avoid confusing messages and notifications.
5. message_can_delete_message - This assumed the variable
   $message contained the 'useridto' property, which
   was present in the old table structure. We do not want
   future usages where a query is done on the new table
   and is simply passed as this won't contain this property.
6. message_delete_message - Same as above.
2018-03-23 12:30:27 +08:00
Marina Glancy 6e65554ea1 MDL-58010 user: allow to update only whitelisted user preferences 2017-03-10 18:04:47 +00:00
Mark Nelson 29c3b0b4d2 MDL-58014 core_message: fixed unread message count 2017-02-20 13:29:13 +08:00
Ryan Wyllie b1e6f1a8fb MDL-57370 message: deprecate message_get_recent_conversations 2017-02-07 01:40:47 +00:00
Mark Nelson af5765b3fb MDL-56139 core_message: removed unused constants 2016-11-16 10:22:52 +08:00
Mark Nelson ffd7798c96 MDL-56139 core: changes after peer review
- No longer use the Fibonacci sequence for delaying the timeout.
  It is too aggressive.
- The backoff_timer AMD module now expects the callback AND the
  backoff function to be passed to the constructor.
- Added ability to specify polling frequency in config.php.
- Added helper function to return the cache key.
- Reworded the parameters for clarity.
2016-11-16 10:22:52 +08:00
Ankit Agarwal 20ab51fdbc MDL-56409 messages: Save one db query per page load 2016-11-08 12:50:30 +05:30
Amanda Doughty cc350fd9c8 MDL-47162 core_message: Add course id to message eventdata 2016-10-27 18:11:27 +02:00
Ryan Wyllie 0d602fdd37 MDL-56292 message: fix message_get_recent_conversations
Renamed the $user param to a more common pattern and removed the
readtable flags from the SQL, which are no longer required.
2016-10-10 12:48:52 +08:00
Mark Nelson 5b0769db68 MDL-54744 core_message: deprecated functions in message/lib.php
Also -

1) Made note of the deprecation as well as the functions and
   files that were removed earlier in upgrade.txt.
2) Added new functions to api.php to replace the deprecated ones
   that were being used in unit tests.
3) Removed files that are no longer being used.
2016-10-07 16:35:25 +08:00
Mark Nelson 7b55aaa12e MDL-55942 core: obey the mighty CiBoT 2016-10-07 16:26:40 +08:00
Mark Nelson 79f6c36c12 MDL-55942 core_message: moved added functionality from message/lib.php 2016-10-07 16:26:40 +08:00
Ryan Wyllie 0b19d04836 MDL-55812 message: simplify notification popover items 2016-10-07 16:26:40 +08:00
Mark Nelson 658d0b2fd7 MDL-55770 core_message: remove the send message pop-up
Revert "MDL-48933 core_message: New dialog to send a message to a user"
Revert "MDL-48933 core_message: Behat tests to cover messenger dialogs"
2016-10-07 16:26:40 +08:00
Mark Nelson d7d7ca2ea1 MDL-55754 core_message: fixed unread message count 2016-10-07 16:26:40 +08:00
Ryan Wyllie c33b7d8913 MDL-54701 message: add unread message count to messages 2016-10-07 16:26:40 +08:00
Ryan Wyllie 8c55bd6c34 MDL-54701 message: add message popover count and mark as read 2016-10-07 16:26:40 +08:00
Ryan Wyllie a4a804b8f9 MDL-54698 message: add save/cancel button to processor popup 2016-10-07 16:26:40 +08:00
Ryan Wyllie ada7695d7c MDL-54708 message: notification popover respects message preferences 2016-10-07 16:26:40 +08:00
Ryan Wyllie 643b015db2 MDL-54698 message: make processor settings dialogue 2016-10-07 16:26:40 +08:00
Ryan Wyllie eda6bc19e6 MDL-54701 message: added isread to data_for_messagearea_conversations 2016-10-07 16:26:40 +08:00
Ryan Wyllie 9e8a29c95d MDL-54708 message: fix js module naming 2016-10-07 16:26:40 +08:00
Ryan Wyllie 3274d5ca66 MDL-54708 message: add backend APIs for notifications popover 2016-10-07 16:26:40 +08:00
Ryan Wyllie 12d8c7b222 MDL-54700 message: added toggle contact button to user profile 2016-10-07 16:20:51 +08:00
Mark Nelson 34c2f34762 MDL-54687 core_message: added userid parameter for altering contacts 2016-10-07 16:20:51 +08:00
Mark Nelson 879e2bef23 MDL-54687 core_message: created page for new messaging interface
This commit introduces the templates, renderer and initial API
that will be used for further development.
2016-10-07 16:20:51 +08:00
Mark Nelson f3c0e69232 MDL-54687 core_message: removed 'message_print_*' functions 2016-10-07 16:20:51 +08:00
Cameron Ball 64e8311939 MDL-37138 message: Use blanktarget option for message text 2016-05-30 13:18:01 +08:00
dg711 c55494fef7 MDL-53207 message: display stock pic for msg from\to unreal user 2016-03-19 23:36:41 +05:30
Dan Poltawski c116a115d9 Merge branch 'MDL-52928-master' of git://github.com/andrewnicols/moodle 2016-03-01 11:34:04 +08:00
dg711 88e1d0ed26 MDL-52892 message: users' pic overrides others
While listing the messages , the logged in users' profile pic used to
override over other users' pics .
2016-02-19 00:58:44 +05:30
Andrew Nicols a0bc890ec5 MDL-52928 message: Correct contact fetching in recent conversations 2016-02-09 13:38:59 +08:00
Juan Leyva ea21d6370f MDL-52570 message: Do not return deleted messages in WS 2016-01-07 12:10:32 +01:00
Mark Nielsen e61a9638f1 MDL-52060 phpunit: Improve get_message_processors reset 2015-12-22 13:40:39 +08:00
Ryan Wyllie cd0c9ac87d MDL-50426 message: optional permission check on message
Changed the messaging API to allow you to provide a parameter
that will cause the code to check if the sender of the message
has the correct permissions before the message is sent.

The ajax messaging (message button on profile page) has been
updated to perform these permission checks. This brings it
inline with the existing private message page.
2015-11-05 08:20:39 +00:00
Ben Kelada 42c0b0473c MDL-51673 messages: remove strict type check of int vs string 2015-10-16 12:33:18 -05:00
Mark Nelson b5e617e245 MDL-51312 core: added message_deleted event 2015-09-24 15:13:42 -07:00