]> dev.renevier.net Git - syj.git/blobdiff - application/models/PathMapper.php
exported path: use title instead of idx for filename
[syj.git] / application / models / PathMapper.php
index 7f43e2239b64bae6d1187c9ea1c44f6571d77059..7d514e9f655a9ffac7c746f11cef451838468a52 100644 (file)
@@ -35,6 +35,12 @@ class Syj_Model_PathMapper
         return $this->_fetchItem($select, $path);
     }
 
+    public function findByTitle($title, Syj_Model_Path $path) {
+        $select = $this->_select();
+        $select->where('title = ?', (string)$title);
+        return $this->_fetchItem($select, $path);
+    }
+
     public function findByUrl($url, Syj_Model_Path $path) {
         $select = $this->_select();
         $select->where('id = ?', (int)$url)->orWhere('urlcomp = ?', (string)$url);