Skip to content
Extraits de code Groupes Projets
Valider 5447bd01 rédigé par mattab's avatar mattab
Parcourir les fichiers

Rename creation_time -> segment_creation_time

parent d9217598
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -222,10 +222,10 @@ allow_adding_segments_for_all_websites = 1 ...@@ -222,10 +222,10 @@ allow_adding_segments_for_all_websites = 1
; When archiving segments for the first time, this determines the oldest date that will be archived. ; When archiving segments for the first time, this determines the oldest date that will be archived.
; This option can be used to avoid archiving (for isntance) the lastN years for every new segment. ; This option can be used to avoid archiving (for isntance) the lastN years for every new segment.
; Valid option values include: beginning_of_time (start date of archiving will not be changed) ; Valid option values include: "beginning_of_time" (start date of archiving will not be changed)
; creation_time (start date of archiving will be the creation date of the segment) ; "segment_creation_time" (start date of archiving will be the creation date of the segment)
; lastN where N is an integer (start date of archiving will be N days before the creation date) ; lastN where N is an integer (eg "last10" to archive for 10 days before the segment creation date)
process_new_segments_from = beginning_of_time process_new_segments_from = "beginning_of_time"
; this action name is used when the URL ends with a slash / ; this action name is used when the URL ends with a slash /
; it is useful to have an actual string to write in the UI ; it is useful to have an actual string to write in the UI
......
...@@ -22,7 +22,7 @@ use Piwik\Plugins\SegmentEditor\Model; ...@@ -22,7 +22,7 @@ use Piwik\Plugins\SegmentEditor\Model;
class SegmentArchivingRequestUrlProvider class SegmentArchivingRequestUrlProvider
{ {
const BEGINNING_OF_TIME = 'beginning_of_time'; const BEGINNING_OF_TIME = 'beginning_of_time';
const CREATION_TIME = 'creation_time'; const CREATION_TIME = 'segment_creation_time';
/** /**
* @var Model * @var Model
......
...@@ -98,7 +98,7 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase ...@@ -98,7 +98,7 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase
), ),
array( // test creation_time uses creation time of segment array( // test creation_time uses creation time of segment
'creation_time', 'segment_creation_time',
1, 1,
$dateRange, $dateRange,
'week', 'week',
...@@ -106,8 +106,8 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase ...@@ -106,8 +106,8 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase
"2014-01-01,2015-03-01" "2014-01-01,2015-03-01"
), ),
array( // test creation_time uses earliest time of segment if multiple match (multiple for site) array( // test segment_creation_time uses earliest time of segment if multiple match (multiple for site)
'creation_time', 'segment_creation_time',
1, 1,
$dateRange, $dateRange,
'week', 'week',
...@@ -115,8 +115,8 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase ...@@ -115,8 +115,8 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase
'2012-01-01,2015-03-01' '2012-01-01,2015-03-01'
), ),
array( // test creation_time uses earliest time of segment if multiple match (multiple for site + one for all) array( // test segment_creation_time uses earliest time of segment if multiple match (multiple for site + one for all)
'creation_time', 'segment_creation_time',
2, 2,
$dateRange, $dateRange,
'week', 'week',
...@@ -125,7 +125,7 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase ...@@ -125,7 +125,7 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase
), ),
array( // test 'now' is used if no site matches (testing w/o any segments) array( // test 'now' is used if no site matches (testing w/o any segments)
'creation_time', 'segment_creation_time',
1, 1,
$dateRange, $dateRange,
'week', 'week',
...@@ -134,7 +134,7 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase ...@@ -134,7 +134,7 @@ class SegmentArchivingRequestUrlProviderTest extends \PHPUnit_Framework_TestCase
), ),
array( // test 'now' is used if no site matches (testing w/ segment for another site) array( // test 'now' is used if no site matches (testing w/ segment for another site)
'creation_time', 'segment_creation_time',
3, 3,
$dateRange, $dateRange,
'week', 'week',
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter