CC-4961: Show linking
Refactoring all services thus far
This commit is contained in:
parent
5735baf237
commit
896e03d76b
7 changed files with 612 additions and 417 deletions
|
@ -10,9 +10,9 @@ class Application_Service_ShowService
|
|||
* @param $ccShow
|
||||
* @param $showData
|
||||
*/
|
||||
public function setShow($showData, $isNewShow)
|
||||
public function setShow($showData, $isUpdate)
|
||||
{
|
||||
if ($isNewShow) {
|
||||
if (!$isUpdate) {
|
||||
$ccShow = new CcShow();
|
||||
} else {
|
||||
$ccShow = CcShowQuery::create()->findPk($showData["add_show_id"]);
|
||||
|
@ -33,6 +33,17 @@ class Application_Service_ShowService
|
|||
return $ccShow;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* Deletes all the cc_show_rebroadcast entries for a specific show
|
||||
* that is currently being edited. They will get recreated with
|
||||
* the new show specs
|
||||
*/
|
||||
public function deleteShowRebroadcasts($showId)
|
||||
{
|
||||
CcShowRebroadcastQuery::create()->filterByDbShowId($showId)>delete();
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* Sets the fields for a cc_show_rebroadcast table row
|
||||
|
@ -70,6 +81,17 @@ class Application_Service_ShowService
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* Deletes all the cc_show_hosts entries for a specific show
|
||||
* that is currently being edited. They will get recreated with
|
||||
* the new show specs
|
||||
*/
|
||||
public function deleteShowHosts($showId)
|
||||
{
|
||||
CcShowHostsQuery::create()->filterByDbShow($showId)->delete();
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* Sets the fields for a cc_show_hosts table row
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue