← Back to team overview

mahara-contributors team mailing list archive

[Bug 1514299] [NEW] MNet method "get_views_for_user()" returns full urls for collections when it should return partial

 

Public bug reported:

See also https://github.com/MaharaProject/moodle-
assignsubmission_mahara/issues/15

When a student is picking a collection in the Mahara assignment
submission plugin for Moodle, the URLs for collections (both the preview
URL and the navigation URL) are incorrect. This is because the
get_views_for_user() method on the Mahara side returns an absolute URL
for the collection['url'] field, while it returns a relative-to-wwwroot
URL for the view['url'] field.

I'm tackling this by putting workaround code in the submission plugin,
and by patching Mahara to return the same ['url'] values for views &
collections.

And then eventually (when there are no more of the old, bad Mahara
instances around) we can drop the workaround code from the Moodle
plugin. Although I guess hopefully by then we won't be using MNet for
the plugin anymore, anyway. :)

** Affects: mahara
     Importance: Medium
     Assignee: Aaron Wells (u-aaronw)
         Status: In Progress

** Affects: mahara/1.10
     Importance: Medium
     Assignee: Aaron Wells (u-aaronw)
         Status: In Progress

** Affects: mahara/15.04
     Importance: Medium
     Assignee: Aaron Wells (u-aaronw)
         Status: In Progress

** Affects: mahara/15.10
     Importance: Medium
     Assignee: Aaron Wells (u-aaronw)
         Status: In Progress

** Affects: mahara/16.04
     Importance: Medium
     Assignee: Aaron Wells (u-aaronw)
         Status: In Progress


** Tags: mnet no-behat-needed

** Also affects: mahara/15.04
   Importance: Undecided
       Status: New

** Also affects: mahara/1.10
   Importance: Undecided
       Status: New

** Also affects: mahara/16.04
   Importance: Undecided
       Status: New

** Also affects: mahara/15.10
   Importance: Undecided
       Status: New

** Changed in: mahara/1.10
       Status: New => In Progress

** Changed in: mahara/15.04
       Status: New => In Progress

** Changed in: mahara/15.10
       Status: New => In Progress

** Changed in: mahara/16.04
       Status: New => In Progress

** Changed in: mahara/1.10
   Importance: Undecided => Medium

** Changed in: mahara/15.04
   Importance: Undecided => Medium

** Changed in: mahara/15.10
   Importance: Undecided => Medium

** Changed in: mahara/16.04
   Importance: Undecided => Medium

** Changed in: mahara/16.04
     Assignee: (unassigned) => Aaron Wells (u-aaronw)

** Changed in: mahara/15.10
     Assignee: (unassigned) => Aaron Wells (u-aaronw)

** Changed in: mahara/15.04
     Assignee: (unassigned) => Aaron Wells (u-aaronw)

** Changed in: mahara/1.10
     Assignee: (unassigned) => Aaron Wells (u-aaronw)

** Changed in: mahara/1.10
    Milestone: None => 1.10.8

** Changed in: mahara/15.04
    Milestone: None => 15.04.5

** Changed in: mahara/15.10
    Milestone: None => 15.10.1

** Changed in: mahara/16.04
    Milestone: None => 16.04.0

** Tags added: mnet no-behat-needed

** Description changed:

  See also https://github.com/MaharaProject/moodle-
  assignsubmission_mahara/issues/15
  
  When a student is picking a collection in the Mahara assignment
  submission plugin for Moodle, the URLs for collections (both the preview
  URL and the navigation URL) are incorrect. This is because the
  get_views_for_user() method on the Mahara side returns an absolute URL
  for the collection['url'] field, while it returns a relative-to-wwwroot
  URL for the view['url'] field.
  
  I'm tackling this by putting workaround code in the submission plugin,
  and by patching Mahara to return the same ['url'] values for views &
  collections.
+ 
+ And then eventually (when there are no more of the old, bad Mahara
+ instances around) we can drop the workaround code from the Moodle
+ plugin. Although I guess hopefully by then we won't be using MNet for
+ the plugin anymore, anyway. :)

-- 
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1514299

Title:
  MNet method "get_views_for_user()" returns full urls for collections
  when it should return partial

Status in Mahara:
  In Progress
Status in Mahara 1.10 series:
  In Progress
Status in Mahara 15.04 series:
  In Progress
Status in Mahara 15.10 series:
  In Progress
Status in Mahara 16.04 series:
  In Progress

Bug description:
  See also https://github.com/MaharaProject/moodle-
  assignsubmission_mahara/issues/15

  When a student is picking a collection in the Mahara assignment
  submission plugin for Moodle, the URLs for collections (both the
  preview URL and the navigation URL) are incorrect. This is because the
  get_views_for_user() method on the Mahara side returns an absolute URL
  for the collection['url'] field, while it returns a relative-to-
  wwwroot URL for the view['url'] field.

  I'm tackling this by putting workaround code in the submission plugin,
  and by patching Mahara to return the same ['url'] values for views &
  collections.

  And then eventually (when there are no more of the old, bad Mahara
  instances around) we can drop the workaround code from the Moodle
  plugin. Although I guess hopefully by then we won't be using MNet for
  the plugin anymore, anyway. :)

To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1514299/+subscriptions


Follow ups