Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-65135

Add year to messaging conversation date headings, if not the current year

    XMLWordPrintable

Details

    • MOODLE_37_STABLE
    • MOODLE_311_STABLE
    • Easy
    • Hide

      Note: testing required database access to update message dates

      1. Login as any user
      2. Open messaging drawer
      3. Click on your self conversation under Starred
      4. Send two messages: "Message one" and then "Message two"
      5. Confirm short date is shown, e.g. 18 December
      6. In your database editor, you should now have two records with the following query:

        SELECT * FROM moodle.m_messages;

      7. Backdate the time of the first message using the following query:

        UPDATE m_messages SET timecreated = 1559913000 WHERE id = 1;

      8. Reload Moodle in your browser
      9. Open messaging drawer
      10. Click on your self conversation under Starred
      11. Confirm the date portion of the first message is "7 June 2019" (e.g. full date)
      12. Confirm the date portion of the second message is "18 December" (e.g. short date)
      Show
      Note: testing required database access to update message dates Login as any user Open messaging drawer Click on your self conversation under Starred Send two messages: "Message one" and then "Message two" Confirm short date is shown, e.g. 18 December In your database editor, you should now have two records with the following query: SELECT * FROM moodle.m_messages; Backdate the time of the first message using the following query: UPDATE m_messages SET timecreated = 1559913000 WHERE id = 1; Reload Moodle in your browser Open messaging drawer Click on your self conversation under Starred Confirm the date portion of the first message is "7 June 2019" (e.g. full date) Confirm the date portion of the second message is "18 December" (e.g. short date)

    Description

      See the attached screenshot. If the message listed under the heading "21 March" was sent last year, how would we know? 

      We should see if it's possible to format these timestamps conditionally, as we did for the recent message dates in MDL-65114

      So (for headings only!):

      • Timestamps for a date which is NOT inside the current calendar year will be of the format "21 March, 2018".
      • Timestamps which are inside the current calendar year remain as they are now.

      Attachments

        1. date_headings_conversation_view.png
          date_headings_conversation_view.png
          13 kB
        2. MDL-65135.jpg
          MDL-65135.jpg
          28 kB
        3. MDL-65135 before after.png
          MDL-65135 before after.png
          54 kB
        4. screenshot-1.png
          screenshot-1.png
          32 kB

        Issue Links

          Activity

            People

              pholden Paul Holden
              jaked Jake Dallimore
              David Mudrák (@mudrd8mz) David Mudrák (@mudrd8mz)
              Victor Déniz Falcón Victor Déniz Falcón
              Anna Carissa Sadia Anna Carissa Sadia
              Votes:
              4 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 0 minutes
                  0m
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 2 hours, 45 minutes
                  2h 45m

                  Clockify

                    Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.