Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/SegmentEditor/Model.php')
-rw-r--r--plugins/SegmentEditor/Model.php10
1 files changed, 9 insertions, 1 deletions
diff --git a/plugins/SegmentEditor/Model.php b/plugins/SegmentEditor/Model.php
index 7e73b6a1ab..3aec99eb23 100644
--- a/plugins/SegmentEditor/Model.php
+++ b/plugins/SegmentEditor/Model.php
@@ -119,6 +119,15 @@ class Model
return $segments;
}
+ public function getSegmentByDefinition($definition)
+ {
+ $sql = $this->buildQuerySortedByName("definition = ?");
+ $bind = [$definition];
+
+ $segment = $this->getDb()->fetchRow($sql, $bind);
+ return $segment;
+ }
+
public function deleteSegment($idSegment)
{
$db = $this->getDb();
@@ -178,5 +187,4 @@ class Model
DbHelper::createTable(self::$rawPrefix, $segmentTable);
}
-
}