Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed issue: auth_webserver_autocreate_user option not properly setti…

…ng template permission
  • Loading branch information...
commit 66b0565d9bd0b36fca9247ff8c10a2301435d7b5 1 parent 4ac107a
@c-schmitz c-schmitz authored
View
11 application/core/UserIdentity.php
@@ -130,11 +130,12 @@ public function authenticate($sOneTimePassword='')
$aTemplates=explode(",",$aUserProfile['templatelist']);
foreach ($aTemplates as $sTemplateName)
{
- $oRecord=new Templates_rights;
- $oRecord->uid = $oUser->uid;
- $oRecord->folder = trim($sTemplateName);
- $oRecord->use = 1;
- $oRecord->save();
+ $oPermission=new Permission;
+ $oPermission->uid = $oUser->uid;
+ $oPermission->entity = 'template';
+ $oPermission->permission = trim($sTemplateName);
+ $oPermission->read_p = 1;
+ $oPermission->save();
}
// read again user from newly created entry
View
2  application/tests/staticCalls.php
@@ -94,7 +94,6 @@ function checkStatic($line)
'SettingGlobal::',
'Zend_Http_Client::',
'Zend_XmlRpc_Value::',
-'Templates_rights_model::',
'Zend_XmlRpc_Server_Fault::',
'Zend_XmlRpc_Value::',
'Zend_Server_Cache::',
@@ -129,7 +128,6 @@ function checkStatic($line)
'surveypermission::',
'Template::',
'templates::',
-'Templates_rights::',
'register::',
'::first',
'::before',
View
11 installer/sql/create-mssql.sql
@@ -536,17 +536,6 @@ CREATE TABLE [prefix_users] (
--
--- Table structure for table templates_rights
---
-CREATE TABLE [prefix_templates_rights] (
-[uid] int NOT NULL,
-[folder] varchar(255) NOT NULL,
-[use] int NOT NULL,
-PRIMARY KEY ([uid],[folder])
-);
-
-
---
-- Table structure for table templates
--
CREATE TABLE [prefix_templates] (
View
11 installer/sql/create-mysql.sql
@@ -540,17 +540,6 @@ CREATE TABLE `prefix_users` (
--
--- Table structure for table templates_rights
---
-CREATE TABLE `prefix_templates_rights` (
- `uid` int(11) NOT NULL,
- `folder` varchar(255) NOT NULL,
- `use` int(11) NOT NULL,
- PRIMARY KEY (`uid`,`folder`)
-) ENGINE=MYISAM CHARACTER SET utf8 COLLATE utf8_unicode_ci;
-
-
---
-- Table structure for table templates
--
CREATE TABLE `prefix_templates` (
View
12 installer/sql/create-pgsql.sql
@@ -542,18 +542,6 @@ CREATE TABLE prefix_users (
"modified" timestamp
);
-
---
--- Table structure for table templates_rights
---
-CREATE TABLE prefix_templates_rights (
- "uid" integer NOT NULL,
- "folder" character varying(255) NOT NULL,
- "use" integer NOT NULL,
- CONSTRAINT prefix_templates_rights_pkey PRIMARY KEY ("uid","folder")
-);
-
-
--
-- Table structure for table templates
--

0 comments on commit 66b0565

Please sign in to comment.
Something went wrong with that request. Please try again.