OpenCATS icon indicating copy to clipboard operation
OpenCATS copied to clipboard

To remove DEMO access level

Open skrchnavy opened this issue 9 years ago • 4 comments

Currently DEMO access level is used to create demo sites to present different functions.

Benefit of removing DEMO access level is simplification of code where are used exceptions for this level, for example:

  • https://github.com/opencats/OpenCATS/blob/master/modules/candidates/CandidatesUI.php#L995
  • https://github.com/opencats/OpenCATS/blob/master/modules/candidates/CandidatesUI.php#L2972
  • https://github.com/opencats/OpenCATS/blob/master/modules/joborders/JobOrdersUI.php#L800
  • etc.

Using features implemented in #91 it would be possible to remove DEMO access level when demo role is created with same access levels as has DEMO user.

skrchnavy avatar Aug 17 '16 14:08 skrchnavy

Agreed - whilst it's nice to demo the project at demo.opencats.org, I agree it's not sensible to leave this in the production codebase.

RussH avatar Aug 17 '16 14:08 RussH

I agree, we should nevertheless, remove the DEMO access level and create the DEMO role, which can be renamed to some other Role name that better reflects it's purpose or capabilities.

mlespiau avatar Aug 18 '16 03:08 mlespiau

I didn't use the front-end 'demo' functionality in the updated demo at http://demo.opencats.org. Even less reason to retain it. Lots of cruft in there from the original devs.

RussH avatar Aug 24 '16 08:08 RussH

In PR #125 there are added tests for different access levels, so we can update those tests to reduce default access level for DEMO to be on same level as ReadOnly or Disabled and then the code can be updated accordingly to pass those tests.

skrchnavy avatar Oct 12 '16 07:10 skrchnavy