The upgrade in https://reviews.mahara.org/#/c/7128/5 will have made them
all lowercase as group_generate_shortname() returns a lowercase value

** Changed in: mahara
    Milestone: 17.10.0 => None

** Changed in: mahara
       Status: Confirmed => Won't Fix

-- 
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/1603302

Title:
  Convert mixed-case group shortnames

Status in Mahara:
  Won't Fix

Bug description:
  Mahara: master

  With the new functionality added to allow admins to update the group
  shortname, an interesting paradigm now exists.

  Currently, we allow mixed case alphanumeric characters for the
  shortname.

  A variable was introduced 'retainshortname' to make sure the shortname
  entered (via the webservice and / or CSV upload ) is valid and follows
  the shortname naming conventions.

  
  In the group_create() function (htdocs/lib/group.php), we then validate to 
make sure the shortname they've used (i.e. for newly created groups), matches 
what we would have generated automatically.

  1. If the user specifies a mixed case shortname in the CSV upload, the
  generated shortname will not match as it always converts everything to
  lowercase.

  2. If the user specifies a shortname completely unrelated to the
  display name, the shortname will also not match. i.e. shortname =
  'abc' displayname = 'My Group'. The generated shortname will be
  'mygroup'.

  I'm of the opinion that the following needs to be modified:

  1. The shortname should be alphanumeric lower case characters.

  2. A common validation function needs to be created so the edit group,
  upload csv, and webservice group creation are using the same rules.
  Therefore, we won't have multiple validation functions for the same
  thing throughout the code.

  3. We can eliminate the 'retainshortname' flag as we would have
  already validated the shortname if it got to the group_create()
  function.

  4. An upgrade script to convert mixed case shortnames to lower case.

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

_______________________________________________
Mailing list: https://launchpad.net/~mahara-contributors
Post to     : mahara-contributors@lists.launchpad.net
Unsubscribe : https://launchpad.net/~mahara-contributors
More help   : https://help.launchpad.net/ListHelp

Reply via email to