CC-5948 - Fixed bug where user couldn't edit repeating instances of a show while another instance was playing

This commit is contained in:
Duncan Sommerville 2014-11-04 18:38:31 -05:00
parent 7bc07a91f2
commit 0f3c1914e1
1 changed files with 3 additions and 4 deletions

View File

@ -412,11 +412,9 @@ class Application_Service_ShowFormService
$ccShowInstance = CcShowInstancesQuery::create()
->filterByDbShowId($this->ccShow->getDbId())
->filterByDbModifiedInstance(false)
->filterByDbEnds(gmdate("Y-m-d H:i:s"), Criteria::GREATER_THAN)
->orderByDbStarts()
->limit(1)
->filterByDbStarts(gmdate("Y-m-d H:i:s"), Criteria::GREATER_THAN)
->findOne();
$starts = new DateTime($ccShowInstance->getDbStarts(), new DateTimeZone("UTC"));
$ends = new DateTime($ccShowInstance->getDbEnds(), new DateTimeZone("UTC"));
$showTimezone = $this->ccShow->getFirstCcShowDay()->getDbTimezone();
@ -427,6 +425,7 @@ class Application_Service_ShowFormService
return array($starts, $ends);
}
/**
*
* Validates show forms