Commit b88e420f authored by Sebastian Kummer's avatar Sebastian Kummer

Merge pull request #43 in ZP/z-push from...

Merge pull request #43 in ZP/z-push from bugfix/ZP-692-diffstate.php-use-different-cutoff to develop

* commit '9106da1f':
  ZP-692 Add notes and set to false when we don't care about filtertime. Released under the Affero GNU General Public License (AGPL) version 3.
  ZP-692 Different cutoff dates. Released under the Affero GNU General Public License (AGPL) version 3.

(cherry picked from commit 0dbd04af)
parent 15bad8bb
......@@ -88,7 +88,20 @@ class DiffState implements IChanges {
*/
public function ConfigContentParameters($contentparameters) {
$this->contentparameters = $contentparameters;
$this->cutoffdate = Utils::GetCutOffDate($contentparameters->GetFilterType());
$filtertype = $contentparameters->GetFilterType();
switch($contentparameters->GetContentClass()) {
case "Email":
case "Calendar":
$this->cutoffdate = ($filtertype === false) ? 0 : Utils::GetCutOffDate($filtertype);
break;
case "Contacts":
case "Tasks":
case "Notes":
default:
$this->cutoffdate = false;
break;
}
}
/**
......@@ -256,4 +269,4 @@ class DiffState implements IChanges {
}
?>
\ No newline at end of file
?>
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