SAAS-1063: REST API for podcasts

Hierarchy routing is working
Basic implentation of podcast INDEX and POST actions done
This commit is contained in:
drigato 2015-09-16 14:22:13 -04:00
parent a444751397
commit 67db2c1d25
9 changed files with 391 additions and 9 deletions

View file

@ -0,0 +1,34 @@
<?php
class Application_Service_PodcastService
{
/**
* There is maximum of 50 podcasts allowed in the library - to limit
* resource consumption. This function returns true if the podcast
* limit has been reached.
*
* @return bool
*/
public static function podcastLimitReached()
{
if (PodcastQuery::create()->count() >= 50) {
return true;
} else {
return false;
}
}
/**
* Returns true if the given podcast URL is valid.
*
* @param $podcastUrl String containing the podcast feed URL
*
* @return bool
*/
public static function validatePodcastUrl($podcastUrl)
{
//TODO
return true;
}
}