Commit 75bacd13 authored by Sylvi Low's avatar Sylvi Low Committed by Robert Lyon
Browse files

Rename "Logged-in users" on to "Registered users".(Fixed) Bug 1373095

Change-Id: Id9555f5c3fa2846a1f4458ab2667a73c11b9c275
parent 447a920e
......@@ -95,7 +95,7 @@ $string['listedinpages'] = 'Listed in pages';
// access levels
$string['public'] = 'Public';
$string['loggedin'] = 'Logged-in users';
$string['registeredusers'] = 'Registered users';
$string['friends'] = 'Friends';
$string['groups'] = 'Groups';
$string['users'] = 'Users';
......
......@@ -50,7 +50,6 @@ function pieform_element_viewacl(Pieform $form, $element) {
if ($form->get_property('userview')) {
$allowedpresets[] = 'friends';
}
$accesslist = array();
if ($value) {
foreach ($value as $item) {
......@@ -59,7 +58,7 @@ function pieform_element_viewacl(Pieform $form, $element) {
$item['publicallowed'] = (int)$public;
}
if (in_array($item['type'], $allpresets)) {
$item['name'] = get_string($item['type'], 'view');
$item['name'] = get_string(($item['type'] == 'loggedin' ? 'registeredusers' : $item['type']), 'view');
$item['preset'] = true;
}
else {
......@@ -95,7 +94,7 @@ function pieform_element_viewacl(Pieform $form, $element) {
'id' => $preset,
'start' => null,
'end' => null,
'name' => get_string($preset, 'view'),
'name' => get_string(($preset == 'loggedin' ? 'registeredusers' : $preset), 'view'),
'preset' => true
);
}
......@@ -186,7 +185,7 @@ function pieform_element_viewacl(Pieform $form, $element) {
function pieform_render_viewacl_getvaluebytype($type, $id) {
switch ($type) {
case 'loggedin':
return get_string('loggedin', 'view');
return get_string('registeredusers', 'view');
break;
case 'user':
$user = get_record('usr', 'id', $id);
......
......@@ -5,7 +5,7 @@
{if $item.accessgroups}
{foreach from=$item.accessgroups item=accessgroup name=ags}{strip}
{if $accessgroup.accesstype == 'loggedin'}
{str tag="loggedin" section="view"}
{str tag="registeredusers" section="view"}
{elseif $accessgroup.accesstype == 'public'}
{str tag="public" section="view"}
{elseif $accessgroup.accesstype == 'friends'}
......
......@@ -355,7 +355,7 @@ function editaccess_validate(Pieform $form, $values) {
$accesstypestrings = array(
'public' => get_string('public', 'view'),
'loggedin' => get_string('loggedin', 'view'),
'loggedin' => get_string('registeredusers', 'view'),
'friends' => get_string('friends', 'view'),
'user' => get_string('user', 'group'),
'group' => get_string('group', 'group'),
......
......@@ -67,7 +67,7 @@ $shareoptions = array(
if ($USER->get('institutions')) {
$shareoptions['institution'] = get_string('myinstitutions', 'group');
}
$shareoptions['loggedin'] = get_string('loggedin', 'view');
$shareoptions['loggedin'] = get_string('registeredusers', 'view');
if (get_config('allowpublicviews')) {
$shareoptions['public'] = get_string('public', 'view');
}
......
@javascript @core @core_portfolio @registered_users
Feature: Changing "Logged-in users" to "Registered users"
In order to see "Registered users"
As an admin
So I can know that it can only be accessed by registered users
Scenario: Changing "logged-in users" to "registered users" (Bug 1373095)
Given I log in as "admin" with password "Password1"
And I follow "Portfolio"
When I choose "Shared by me" in "Portfolio"
Then I should see "Registered users"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment