Add additional_acl column to edit_access table
To be able to have special ACL (json) for edit edit access table too
This commit is contained in:
@@ -14,5 +14,6 @@ CREATE TABLE edit_access (
|
|||||||
uid VARCHAR,
|
uid VARCHAR,
|
||||||
enabled SMALLINT NOT NULL DEFAULT 0,
|
enabled SMALLINT NOT NULL DEFAULT 0,
|
||||||
protected INT,
|
protected INT,
|
||||||
deleted SMALLINT DEFAULT 0
|
deleted SMALLINT DEFAULT 0,
|
||||||
|
additional_acl JSONB
|
||||||
) INHERITS (edit_generic) WITHOUT OIDS;
|
) INHERITS (edit_generic) WITHOUT OIDS;
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ CREATE TABLE edit_group (
|
|||||||
deleted SMALLINT DEFAULT 0,
|
deleted SMALLINT DEFAULT 0,
|
||||||
edit_scheme_id INT,
|
edit_scheme_id INT,
|
||||||
edit_access_right_id INT NOT NULL,
|
edit_access_right_id INT NOT NULL,
|
||||||
alternative_acl JSONB,
|
additional_acl JSONB,
|
||||||
FOREIGN KEY (edit_scheme_id) REFERENCES edit_scheme (edit_scheme_id) MATCH FULL ON DELETE CASCADE ON UPDATE CASCADE,
|
FOREIGN KEY (edit_scheme_id) REFERENCES edit_scheme (edit_scheme_id) MATCH FULL ON DELETE CASCADE ON UPDATE CASCADE,
|
||||||
FOREIGN KEY (edit_access_right_id) REFERENCES edit_access_right (edit_access_right_id) MATCH FULL ON DELETE CASCADE ON UPDATE CASCADE
|
FOREIGN KEY (edit_access_right_id) REFERENCES edit_access_right (edit_access_right_id) MATCH FULL ON DELETE CASCADE ON UPDATE CASCADE
|
||||||
) INHERITS (edit_generic) WITHOUT OIDS;
|
) INHERITS (edit_generic) WITHOUT OIDS;
|
||||||
|
|||||||
@@ -411,6 +411,7 @@ if ($form->my_page_name == 'edit_order') {
|
|||||||
$elements[] = $form->formCreateElement("description");
|
$elements[] = $form->formCreateElement("description");
|
||||||
// add name/value list here
|
// add name/value list here
|
||||||
$elements[] = $form->formCreateElementListTable("edit_access_data");
|
$elements[] = $form->formCreateElementListTable("edit_access_data");
|
||||||
|
$elements[] = $form->formCreateElement("additional_acl");
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
print "[No valid page definition given]";
|
print "[No valid page definition given]";
|
||||||
|
|||||||
@@ -49,7 +49,15 @@ $edit_access = array (
|
|||||||
"1" => "Yes",
|
"1" => "Yes",
|
||||||
"0" => "No"
|
"0" => "No"
|
||||||
)
|
)
|
||||||
)
|
),
|
||||||
|
"additional_acl" => array (
|
||||||
|
"value" => $GLOBALS["additional_acl"],
|
||||||
|
"output_name" => "Additional ACL (as JSON)",
|
||||||
|
"type" => "textarea",
|
||||||
|
"error_check" => "json",
|
||||||
|
"rows" => 10,
|
||||||
|
"cols" => 60
|
||||||
|
),
|
||||||
),
|
),
|
||||||
"table_name" => "edit_access",
|
"table_name" => "edit_access",
|
||||||
"load_query" => "SELECT edit_access_id, name FROM edit_access ORDER BY name",
|
"load_query" => "SELECT edit_access_id, name FROM edit_access ORDER BY name",
|
||||||
|
|||||||
@@ -442,7 +442,7 @@ class Basic
|
|||||||
// on second call it sends the end time and then also prints the running time
|
// on second call it sends the end time and then also prints the running time
|
||||||
public function runningTime($simple = false)
|
public function runningTime($simple = false)
|
||||||
{
|
{
|
||||||
list($micro, $timestamp) = explode(" ", microtime());
|
list($micro, $timestamp) = explode(' ', microtime());
|
||||||
$string = '';
|
$string = '';
|
||||||
$running_time = '';
|
$running_time = '';
|
||||||
if (!$this->starttime) {
|
if (!$this->starttime) {
|
||||||
|
|||||||
Reference in New Issue
Block a user