Verified Commit 8f2a33d0 authored by dockx thibault's avatar dockx thibault
Browse files

:sparkles: Feat(tasks) - Repeatable tasks

Allows the creation of repeatable tasks as well as defining scope of new or old members
Showing with 49 additions and 2 deletions
+49 -2
......@@ -372,6 +372,26 @@ attributetype ( 1.3.6.1.4.1.38414.62.1.50 NAME 'fdPluginManagerSupportContractUr
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )
##### Tasks Granular Part 2 #####
attributetype ( 1.3.6.1.4.1.38414.62.1.52 NAME 'fdTasksRepeatable'
DESC 'Allow a given task to be repeatable'
EQUALITY booleanMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX '1.3.6.1.4.1.1466.115.121.1.7')
attributetype ( 1.3.6.1.4.1.38414.62.1.53 NAME 'fdTasksUpdatable'
DESC 'Allow a given task to be updatable'
EQUALITY booleanMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX '1.3.6.1.4.1.1466.115.121.1.7')
attributetype ( 1.3.6.1.4.1.38414.62.1.54 NAME 'fdTasksRepeatableSchedule'
DESC 'Set the repetition of the tasks via a set attribute'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX '1.3.6.1.4.1.1466.115.121.1.15')
##### Classes #####
### old gosa ObjectClass ###
......@@ -441,7 +461,7 @@ objectclass ( 1.3.6.1.4.1.38414.62.2.5 NAME 'fdMailTemplateConf'
objectclass (1.3.6.1.4.1.38414.62.2.6 NAME 'fdTasks'
DESC 'FusionDirectory - Tasks objects'
MUST ( cn $ fdTasksStatus $ fdTasksCreationDate )
MAY ( fdTasksScheduleDate $ fdTasksEndDate) )
MAY ( fdTasksScheduleDate $ fdTasksEndDate $ fdTasksRepeatableSchedule $ fdTasksUpdatable $ fdTasksRepeatable ) )
objectclass (1.3.6.1.4.1.38414.62.2.7 NAME 'fdTasksMail'
DESC 'FusionDirectory - Tasks objects Mail'
......
......@@ -45,7 +45,7 @@ class tasks extends simplePlugin
return [
// Attributes are grouped by section
'tasks' => [
'name' => _('Tasks Generic | Saving will create un-modifiable subtasks'),
'name' => _('Tasks Generic'),
'attrs' => [
new StringAttribute(
_('Task Name'), _('Name for this task'),
......@@ -69,6 +69,23 @@ class tasks extends simplePlugin
),
]
],
'taskSetting' => [
'name' => _('Advanced settings'),
'attrs' => [
new BooleanAttribute(
_('Only with new members'), _('Allows creation of sub-tasks for "NEW MEMBERS" only. (Case of Dynamic Group)'),
'fdTasksUpdatable', FALSE, TRUE
),
new BooleanAttribute(
_('Repeatable Task'), _('Set the task to be repeatable.'),
'fdTasksRepeatable', FALSE
),
new SelectAttribute(
_('Repeatable Schedule'), _('Select the desired schedule.'),
'fdTasksRepeatableSchedule', FALSE, ['Yearly', 'Monthly', 'Daily', 'Hourly'], 'Daily'
),
]
],
];
}
......@@ -78,6 +95,16 @@ class tasks extends simplePlugin
global $config;
parent::__construct($dn, $object, $parent, $mainTab);
$this->attributesAccess['fdTasksRepeatable']->setManagedAttributes(
[
'disable' => [
FALSE => [
'fdTasksRepeatableSchedule',
]
]
]
);
$this->attributesAccess['fdSubTasksActivation']->setInLdap(FALSE);
}
......
Supports Markdown
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