Merge remote-tracking branch 'origin/saas-dev-publishing' into saas-dev-publishing
This commit is contained in:
commit
ef1a57459c
|
@ -237,7 +237,8 @@ class PodcastTask implements AirtimeTask {
|
|||
* @return bool true if the podcast polling interval has passed
|
||||
*/
|
||||
public function shouldBeRun() {
|
||||
return PodcastManager::hasPodcastPollIntervalPassed();
|
||||
$overQuota = Application_Model_Systemstatus::isDiskOverQuota();
|
||||
return !$overQuota && PodcastManager::hasPodcastPollIntervalPassed();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -10,8 +10,12 @@ class Application_Form_PodcastPreferences extends Zend_Form_SubForm {
|
|||
_("Public"),
|
||||
_("Private"),
|
||||
));
|
||||
$stationPodcastPrivacy->setSeparator(' ');
|
||||
$stationPodcastPrivacy->addDecorator('HtmlTag', array('tag' => 'dd',
|
||||
'id'=>"stationPodcastPrivacy-element",
|
||||
'class' => 'radio-inline-list',
|
||||
));
|
||||
$stationPodcastPrivacy->setValue($isPrivate);
|
||||
$stationPodcastPrivacy->setDecorators(array('ViewHelper', 'Label'));
|
||||
$this->addElement($stationPodcastPrivacy);
|
||||
|
||||
$stationPodcast = PodcastQuery::create()->findOneByDbId(Application_Model_Preference::getStationPodcastId());
|
||||
|
@ -22,7 +26,6 @@ class Application_Form_PodcastPreferences extends Zend_Form_SubForm {
|
|||
->setRequired(false)
|
||||
->setLabel(_("Feed URL"))
|
||||
->setValue($url);
|
||||
$feedUrl->setDecorators(array('ViewHelper', 'Label'));
|
||||
$this->addElement($feedUrl);
|
||||
}
|
||||
|
||||
|
|
|
@ -160,7 +160,7 @@ class Application_Service_PodcastService
|
|||
|
||||
$podcast->setDbDescription(Application_Model_Preference::GetStationDescription());
|
||||
$podcast->setDbLink(Application_Common_HTTPHelper::getStationUrl());
|
||||
$podcast->setDbLanguage(Application_Model_Preference::GetLocale());
|
||||
$podcast->setDbLanguage(explode('_', Application_Model_Preference::GetLocale())[0]);
|
||||
$podcast->setDbCreator(Application_Model_Preference::GetStationName());
|
||||
$podcast->setDbOwner(self::getOwnerId());
|
||||
$podcast->save();
|
||||
|
@ -387,9 +387,11 @@ class Application_Service_PodcastService
|
|||
// Need to split categories into separate tags
|
||||
$itunesCategories = explode(",", $podcast->getDbItunesCategory());
|
||||
foreach ($itunesCategories as $c) {
|
||||
if (!empty($c)) {
|
||||
$category = $channel->addChild("xmlns:itunes:category");
|
||||
$category->addAttribute("text", $c);
|
||||
}
|
||||
}
|
||||
|
||||
$episodes = PodcastEpisodesQuery::create()->filterByDbPodcastId($stationPodcastId)->find();
|
||||
foreach ($episodes as $episode) {
|
||||
|
@ -406,8 +408,10 @@ class Application_Service_PodcastService
|
|||
|
||||
//category
|
||||
foreach($itunesCategories as $c) {
|
||||
if (!empty($c)) {
|
||||
self::addEscapedChild($item, "category", $c);
|
||||
}
|
||||
}
|
||||
|
||||
//guid
|
||||
$guid = self::addEscapedChild($item, "guid", $episode->getDbEpisodeGuid());
|
||||
|
@ -437,7 +441,7 @@ class Application_Service_PodcastService
|
|||
//itunes:explicit - skip this?
|
||||
|
||||
//itunes:duration
|
||||
self::addEscapedChild($item, "xmlns:itunes:duration", $publishedFile->getDbLength());
|
||||
self::addEscapedChild($item, "xmlns:itunes:duration", explode('.', $publishedFile->getDbLength())[0]);
|
||||
}
|
||||
|
||||
//Format it nicely with newlines...
|
||||
|
|
|
@ -70,7 +70,7 @@
|
|||
<div id="jp_container_1" class="jp-audio">
|
||||
<div class="jp-type-playlist">
|
||||
|
||||
<div class="current-track">Now Playing: <span></span></div>
|
||||
<div class="current-track track-overflow">Now Playing: <span class="track-overflow"></span></div>
|
||||
<div class="jp-gui jp-interface">
|
||||
<div class="playbar playbar-buttons">
|
||||
<ul class="jp-controls rss-buttons">
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
<div class="publish-sources" ng-repeat="source in sources.toPublish">
|
||||
<input ng-disabled="{{source.status == 2}}" ng-model="publishData[source.source]" type="checkbox" name="publish_sources" id="{{source.source}}">
|
||||
<label class="source-name" for="{{source.source}}">{{source.label}}</label>
|
||||
<span ng-if="source.status == 2" style="margin: auto"><?php echo _("You aren't connected to this source.") ?></span>
|
||||
<span ng-if="source.status == 2" style="margin: auto"><a href="/preference#{{source.source}}-heading"><?php echo _("You aren't connected to this source.") ?></a></span>
|
||||
</div>
|
||||
<div ng-if="sources.toPublish.length == 0">
|
||||
<?php echo _("You have already published this track to all available sources!") . "<br/>"
|
||||
|
|
|
@ -74,7 +74,17 @@
|
|||
|
||||
<h3 class="collapsible-header" id="podcast-heading"><span class="arrow-icon"></span><?php echo _("Privacy Settings"); ?></h3>
|
||||
<div class="collapsible-content" id="podcast-settings">
|
||||
<?php echo $this->form->getSubform('preferences_podcast') ?>
|
||||
<fieldset class="padded">
|
||||
<dl>
|
||||
<?php echo $this->form->getSubform('preferences_podcast')->getElement("stationPodcastPrivacy")->renderLabel() ?>
|
||||
<div id="podcast-privacy-options">
|
||||
<?php echo $this->form->getSubform('preferences_podcast')->getElement("stationPodcastPrivacy")->renderViewHelper() ?>
|
||||
</div>
|
||||
<div style="clear:both"></div>
|
||||
<?php echo $this->form->getSubform('preferences_podcast')->getElement("stationPodcastFeedUrl") ?>
|
||||
|
||||
</dl>
|
||||
</fieldset>
|
||||
</div>
|
||||
|
||||
<p id="station_podcast_help_text">
|
||||
|
|
|
@ -67,6 +67,9 @@
|
|||
|
||||
#library_title {
|
||||
padding: 5px 5px 0;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
#library_content {
|
||||
|
|
|
@ -369,16 +369,27 @@ div.jp-title,
|
|||
display: block;
|
||||
text-transform: uppercase;
|
||||
clear: both;
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.current-track span {
|
||||
display: inline-block;
|
||||
display: inline;
|
||||
margin-left:10px;
|
||||
color: #FF6F01;
|
||||
width: 90%;
|
||||
}
|
||||
|
||||
.track-overflow {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.podcast ul li .podcast_info {
|
||||
display: inline-block;
|
||||
width: 99%;
|
||||
}
|
||||
|
||||
.podcast ul li span, .playlist-item-no-preview span {
|
||||
|
@ -570,6 +581,7 @@ div.jp-jplayer {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
@media (max-width: 590px) {
|
||||
.jp-time-block {
|
||||
display:block !important;
|
||||
|
|
|
@ -41,9 +41,14 @@
|
|||
text-align: left;
|
||||
}
|
||||
|
||||
#podcast-settings #podcast-privacy-options label {
|
||||
width: 12%;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
#podcast-settings label > input {
|
||||
width: auto;
|
||||
margin: 6px 6px 0 25%;
|
||||
margin: 6px 6px 0 0%;
|
||||
}
|
||||
|
||||
label {
|
||||
|
|
|
@ -1195,7 +1195,8 @@ input[type="checkbox"] {
|
|||
}
|
||||
|
||||
#pref_form dt, #pref_form dd,
|
||||
#pref_form textarea, #clientdetails_form dd {
|
||||
#pref_form textarea, #clientdetails_form dd,
|
||||
.podcast-metadata dt, .podcast-metadata dd {
|
||||
display:block;
|
||||
float:none;
|
||||
margin-left:0;
|
||||
|
|
|
@ -1427,6 +1427,7 @@ var AIRTIME = (function(AIRTIME) {
|
|||
// in the left-hand pane.
|
||||
mod.podcastTableWidget.assignDblClickHandler(function () {
|
||||
var podcast = mod.podcastDataTable.fnGetData(this);
|
||||
$("#library_filter").append(" - " + $(this).find(".library_title").text());
|
||||
openPodcastEpisodeTable(podcast);
|
||||
});
|
||||
|
||||
|
@ -1448,6 +1449,7 @@ var AIRTIME = (function(AIRTIME) {
|
|||
elementId : '',
|
||||
eventHandlers : {
|
||||
click: function () {
|
||||
$("#library_filter").text($.i18n._("Podcasts"));
|
||||
mod.setCurrentTable(mod.DataTableTypeEnum.PODCAST);
|
||||
}
|
||||
},
|
||||
|
|
|
@ -94,7 +94,7 @@ var AIRTIME = (function(AIRTIME) {
|
|||
"fnPreDrawCallback": function () {
|
||||
$("#draggingContainer").remove();
|
||||
},
|
||||
"fnServerData": self._fetchData,
|
||||
"fnServerData": self._fetchData.bind(self),
|
||||
//"fnInitComplete" : function() { self._setupEventHandlers(bItemSelection) }
|
||||
"fnDrawCallback": function () {
|
||||
self.clearSelection();
|
||||
|
@ -421,12 +421,14 @@ var AIRTIME = (function(AIRTIME) {
|
|||
|
||||
var sortColName = "";
|
||||
var sortDir = "";
|
||||
var search = self._$wrapperDOMNode.closest(".dataTables_wrapper").find(".dataTables_filter").find("input").val();
|
||||
if (oSettings.aaSorting.length > 0) {
|
||||
var sortColIdx = oSettings.aaSorting[0][0];
|
||||
sortColName = oSettings.aoColumns[sortColIdx].mDataProp;
|
||||
sortDir = oSettings.aaSorting[0][1].toUpperCase();
|
||||
}
|
||||
|
||||
// FIXME: We should probably just be sending aoData back here..?
|
||||
$.ajax({
|
||||
"dataType": 'json',
|
||||
"type": "GET",
|
||||
|
@ -435,7 +437,8 @@ var AIRTIME = (function(AIRTIME) {
|
|||
"limit": oSettings._iDisplayLength,
|
||||
"offset": oSettings._iDisplayStart,
|
||||
"sort": sortColName,
|
||||
'sort_dir': sortDir,
|
||||
"sort_dir": sortDir,
|
||||
"search": search
|
||||
},
|
||||
"success": function (json, textStatus, jqXHR) {
|
||||
var rawResponseJSON = json;
|
||||
|
|
Loading…
Reference in New Issue