diff --git a/admin/inc/class.admin_egw_acl_record.inc.php b/admin/inc/class.admin_egw_acl_record.inc.php
index 3e2d9eaca4..3af30a5309 100644
--- a/admin/inc/class.admin_egw_acl_record.inc.php
+++ b/admin/inc/class.admin_egw_acl_record.inc.php
@@ -26,7 +26,7 @@ class admin_egw_acl_record implements importexport_iface_egw_record
static $types = array(
'select' => array('acl_appname'),
'select-account' => array('acl_account', 'acl_location'),
- 'select-bool' => array('acl1', 'acl2','acl4','acl8','acl16','acl64','acl128','acl256'),
+ 'select-bool' => array('acl_run', 'acl1', 'acl2','acl4','acl8','acl16','acl64','acl128','acl256'),
);
/**
diff --git a/admin/inc/class.admin_export_acl_csv.inc.php b/admin/inc/class.admin_export_acl_csv.inc.php
index 9cc36f76e0..0454c30e5f 100644
--- a/admin/inc/class.admin_export_acl_csv.inc.php
+++ b/admin/inc/class.admin_export_acl_csv.inc.php
@@ -56,10 +56,7 @@ class admin_export_acl_csv implements importexport_iface_export_plugin
}
foreach($accounts as $account_id => $account_data)
{
- $query['account_id'] = $account_id;
- $account_acl = array();
- admin_acl::get_rows($query, $account_acl);
- $selection = array_merge($selection, $account_acl);
+ $this->get_account_acl($account_id, $options['mapping']['acl_run'], $query, $selection);
}
$options['begin_with_fieldnames'] = true;
@@ -110,6 +107,38 @@ class admin_export_acl_csv implements importexport_iface_export_plugin
return $export_object;
}
+ /**
+ * Get the acl data for one account & format it as needed
+ *
+ * @param int $account_id
+ * @param boolean $run_rights Include run rights
+ * @param array $query
+ * @param array $selection
+ */
+ protected function get_account_acl($account_id, $run_rights, $query, &$selection)
+ {
+ $query['account_id'] = $account_id;
+ $query['filter'] = 'other';
+ $account_acl = array();
+ admin_acl::get_rows($query, $account_acl);
+ $selection = array_merge($selection, $account_acl);
+
+ $run = array();
+ if($run_rights)
+ {
+ $query['filter'] = 'run';
+ admin_acl::get_rows($query, $run);
+ foreach($run as &$run_row)
+ {
+ $run_row['acl_run'] = true;
+ unset($run_row['acl_location']);
+ unset($run_row['acl1']);
+ }
+ $selection = array_merge($selection, $run);
+ }
+
+ }
+
/**
* returns translated name of plugin
*
diff --git a/admin/inc/class.admin_wizard_export_acl_csv.inc.php b/admin/inc/class.admin_wizard_export_acl_csv.inc.php
index 5b963e74cb..585558137e 100644
--- a/admin/inc/class.admin_wizard_export_acl_csv.inc.php
+++ b/admin/inc/class.admin_wizard_export_acl_csv.inc.php
@@ -23,6 +23,7 @@ class admin_wizard_export_acl_csv extends importexport_wizard_basic_export_csv
'acl_appname' => lang('Application'),
'acl_location' => lang('Data from'),
'all_acls' => lang('All ACLs'),
+ 'acl_run' => lang('Run'),
'acl1' => lang('Read'),
'acl2' => lang('Add'),
'acl4' => lang('Edit'),
diff --git a/admin/setup/importexport_default.xml b/admin/setup/importexport_default.xml
index c3b7558bc3..3ce4acff85 100644
--- a/admin/setup/importexport_default.xml
+++ b/admin/setup/importexport_default.xml
@@ -17,6 +17,7 @@
acl_account
acl_appname
acl_location
+ acl_run
acl1
acl2
acl4