protected function getPath($prePath, $id, $fileName, $format) { $segment = $this->getSegment($id) . '/'; $prePath = rtrim($prePath, '/'); return $prePath . '/' . $format . '/' . $segment . $id . '-' . $fileName; }