| @@ 32-41 (lines=10) @@ | ||
| 29 | ); |
|
| 30 | } |
|
| 31 | ||
| 32 | public function allFormatted() |
|
| 33 | { |
|
| 34 | return $this->cache |
|
| 35 | ->tags($this->entityName, 'global') |
|
| 36 | ->rememberForever("{$this->locale}.{$this->entityName}.allFormatted", |
|
| 37 | function () { |
|
| 38 | return $this->repository->allFormatted(); |
|
| 39 | } |
|
| 40 | ); |
|
| 41 | } |
|
| 42 | ||
| 43 | public function saveTranslationForLocaleAndKey($locale, $key, $value) |
|
| 44 | { |
|
| @@ 50-59 (lines=10) @@ | ||
| 47 | return $this->repository->saveTranslationForLocaleAndKey($locale, $key, $value); |
|
| 48 | } |
|
| 49 | ||
| 50 | public function findTranslationByKey($key) |
|
| 51 | { |
|
| 52 | return $this->cache |
|
| 53 | ->tags($this->entityName, 'global') |
|
| 54 | ->rememberForever("{$this->locale}.{$this->entityName}.findTranslationByKey.{$key}", |
|
| 55 | function () use ($key) { |
|
| 56 | return $this->repository->findTranslationByKey($key); |
|
| 57 | } |
|
| 58 | ); |
|
| 59 | } |
|
| 60 | ||
| 61 | /** |
|
| 62 | * Update the given translation key with the given data |
|