mirror of
https://github.com/ad-aures/castopod.git
synced 2026-04-15 20:47:46 +02:00
feat(public-ui): adapt public podcast and episode pages to wireframes
- adapt wireframes with responsive design - refactor models methods to cache requests for faster queries - update public controllers to cache pages while retaining analytics hits - add platform links to podcast page - add previous / next episodes in episode page - update npm packages to latest versions closes #30, #13
This commit is contained in:
parent
2517808cd4
commit
40a0535fc1
32 changed files with 2058 additions and 1474 deletions
|
|
@ -21,4 +21,24 @@ class LanguageModel extends Model
|
|||
protected $useSoftDeletes = false;
|
||||
|
||||
protected $useTimestamps = false;
|
||||
|
||||
public function getLanguageOptions()
|
||||
{
|
||||
if (!($options = cache('language_options'))) {
|
||||
$languages = $this->findAll();
|
||||
|
||||
$options = array_reduce(
|
||||
$languages,
|
||||
function ($result, $language) {
|
||||
$result[$language->code] = $language->native_name;
|
||||
return $result;
|
||||
},
|
||||
[]
|
||||
);
|
||||
|
||||
cache()->save('language_options', $options, DECADE);
|
||||
}
|
||||
|
||||
return $options;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue