Merge pull request #1 from Robbt/Robbt-fix/live-stream-source
Robbt fix/live stream source
This commit is contained in:
commit
ece85fe189
|
@ -9,8 +9,10 @@ Vagrant.configure("2") do |config|
|
|||
config.vm.network "forwarded_port", guest: 8000, host:8000
|
||||
# liquidsoap input harbors for instreaming (ie. /master)
|
||||
config.vm.network "forwarded_port", guest: 8001, host:8001
|
||||
# mkdics documentation
|
||||
config.vm.network "forwarded_port", guest: 8002, host:8002
|
||||
# mkdocs documentation
|
||||
config.vm.network "forwarded_port", guest: 8888, host:8888
|
||||
|
||||
|
||||
# make sure we are using nfs (doesn't work out of the box with debian)
|
||||
config.vm.synced_folder ".", "/vagrant", type: "nfs"
|
||||
|
|
|
@ -25,6 +25,7 @@ define('AIRTIME_TRANSIFEX_URL' , 'http://libretime.org/translating/');
|
|||
define('SUPPORT_TICKET_URL' , 'https://github.com/LibreTime/libretime/issues');
|
||||
define('UI_REVAMP_EMBED_URL' , 'https://www.youtube.com/embed/nqpNnCKGluY');
|
||||
define('LIBRETIME_WHATS_NEW_URL' , 'https://github.com/LibreTime/libretime/releases');
|
||||
define('LIBRETIME_EMAIL_FROM' , 'noreply@libretime.org');
|
||||
|
||||
define('LICENSE_VERSION' , 'GNU AGPL v.3');
|
||||
define('LICENSE_URL' , 'http://www.gnu.org/licenses/agpl-3.0-standalone.html');
|
||||
|
|
|
@ -156,7 +156,7 @@ class LoginController extends Zend_Controller_Action
|
|||
if ($request->isPost()) {
|
||||
if ($form->isValid($request->getPost())) {
|
||||
$query = CcSubjsQuery::create();
|
||||
$username = $form->userName->getValue();
|
||||
$username = $form->username->getValue();
|
||||
$email = $form->email->getValue();
|
||||
|
||||
if (empty($username)) {
|
||||
|
@ -179,7 +179,18 @@ class LoginController extends Zend_Controller_Action
|
|||
$form->email->addError($this->view->translate(_("Email could not be sent. Check your mail server settings and ensure it has been configured properly.")));
|
||||
}
|
||||
} else {
|
||||
$form->email->addError($this->view->translate(sprintf(_pro("That username or email address could not be found. If you are the station owner, you should <a href=\"%s\">reset your here</a>."), WHMCS_PASSWORD_RESET_URL)));
|
||||
if (!LIBRETIME_ENABLE_WHMCS) {
|
||||
$form->email->addError($this->view->translate(_("That username or email address could not be found.")));
|
||||
} else {
|
||||
$form->email->addError(
|
||||
$this->view->translate(
|
||||
sprintf(
|
||||
_pro("That username or email address could not be found. If you are the station owner, you should <a href=\"%s\">reset your here</a>."),
|
||||
WHMCS_PASSWORD_RESET_URL
|
||||
)
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
} else { //Form is not valid
|
||||
$form->email->addError($this->view->translate(_("There was a problem with the username or email address you entered.")));
|
||||
|
|
|
@ -41,7 +41,6 @@ class Application_Form_PasswordRestore extends Zend_Form
|
|||
)
|
||||
));
|
||||
|
||||
/*
|
||||
$cancel = new Zend_Form_Element_Button("cancel");
|
||||
$cancel->class = 'ui-button ui-widget ui-state-default ui-button-text-only center';
|
||||
$cancel->setLabel(_("Back"))
|
||||
|
@ -49,6 +48,5 @@ class Application_Form_PasswordRestore extends Zend_Form
|
|||
->setAttrib('onclick', 'window.location = ' . Zend_Controller_Front::getInstance()->getBaseUrl('login'))
|
||||
->setDecorators(array('ViewHelper'));
|
||||
$this->addElement($cancel);
|
||||
*/
|
||||
}
|
||||
}
|
||||
|
|
|
@ -32,8 +32,8 @@ class Application_Model_Auth
|
|||
|
||||
$message = sprintf(_("Hi %s, \n\nPlease click this link to reset your password: "), $user->getDbLogin());
|
||||
$message .= "{$e_link_protocol}://{$e_link_base}:{$e_link_port}{$e_link_path}";
|
||||
$message .= sprintf(_pro("\n\nIf you have any problems, please contact our support team: %s"), SUPPORT_ADDRESS);
|
||||
$message .= sprintf(_pro("\n\nThank you,\nThe %s Team"), SAAS_PRODUCT_BRANDING_NAME);
|
||||
$message .= sprintf(_("\n\nIf you have any problems, please contact our support team: %s"), SUPPORT_ADDRESS);
|
||||
$message .= sprintf(_("\n\nThank you,\nThe %s Team"), SAAS_PRODUCT_BRANDING_NAME);
|
||||
|
||||
$str = sprintf(_('%s Password Reset'), SAAS_PRODUCT_BRANDING_NAME);
|
||||
return Application_Model_Email::send($str, $message, $user->getDbEmail());
|
||||
|
|
|
@ -13,7 +13,7 @@ class Application_Model_Email
|
|||
*/
|
||||
public static function send($subject, $message, $to) {
|
||||
|
||||
$headers = sprintf('From: %s <noreply@account.sourcefabric.com>', SAAS_PRODUCT_BRANDING_NAME);
|
||||
$headers = sprintf('From: %s <%s>', SAAS_PRODUCT_BRANDING_NAME, LIBRETIME_EMAIL_FROM);
|
||||
return mail($to, $subject, $message, $headers);
|
||||
|
||||
}
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
<?php if (LIBRETIME_ENABLE_WHMCS): ?>
|
||||
<fieldset>
|
||||
<legend>Station Owners</legend>
|
||||
<p>
|
||||
|
@ -5,8 +6,11 @@
|
|||
</p>
|
||||
|
||||
</fieldset>
|
||||
<?php endif; ?>
|
||||
<fieldset>
|
||||
<?php if (LIBRETIME_ENABLE_WHMCS): ?>
|
||||
<legend>DJs, Program Managers, and Others</legend>
|
||||
<?php endif; ?>
|
||||
<form enctype="application/x-www-form-urlencoded" method="post" action="">
|
||||
<dl class="zend_form">
|
||||
|
||||
|
|
|
@ -15,8 +15,13 @@
|
|||
<?php echo $this->element->getElement('master_username')->render() ?>
|
||||
<span class="master_username_help_icon"></span>
|
||||
<?php echo $this->element->getElement('master_password')->render() ?>
|
||||
<?php echo $this->element->getElement("master_source_host")->render() ?>
|
||||
|
||||
<span id="stream_url"><?php echo $this->element->getElement("master_source_host")->render() ?>
|
||||
<a href=# id="connection_url_override" style="font-size: 12px;"><?php echo _("Override") ?></a>
|
||||
<span class="override_help_icon"></span></br>
|
||||
<div id="master_dj_connection_url_actions" style="display:none">
|
||||
<a href=# id="ok" style="font-size: 12px;"><?php echo _("OK") ?></a> <a href=# id="reset" style="font-size: 12px;"><?php echo _("RESET"); ?></a>
|
||||
</div>
|
||||
</span>
|
||||
<?php echo $this->element->getElement("master_source_port")->render() ?>
|
||||
<?php echo $this->element->getElement("master_source_mount")->render() ?>
|
||||
</fieldset>
|
||||
|
@ -26,8 +31,15 @@
|
|||
<p class="input-settings-inline-p">
|
||||
<?php echo _("DJs can use these settings in their broadcasting software to broadcast live only during shows assigned to them.") ?>
|
||||
</p>
|
||||
|
||||
<span id="stream_url">
|
||||
<?php echo $this->element->getElement("show_source_host")->render() ?>
|
||||
<a href=# id="connection_url_override" style="font-size: 12px;"><?php echo _("Override") ?></a>
|
||||
<span class="override_help_icon"></span>
|
||||
</br>
|
||||
<div id="live_dj_connection_url_actions" style="display:none">
|
||||
<a href=# id="ok" style="font-size: 12px;"><?php echo _("OK") ?></a> <a href=# id="reset" style="font-size: 12px;"><?php echo _("RESET"); ?></a>
|
||||
</div>
|
||||
</span>
|
||||
<?php echo $this->element->getElement("show_source_port")->render() ?>
|
||||
<?php echo $this->element->getElement("show_source_mount")->render() ?>
|
||||
</fieldset>
|
||||
|
|
|
@ -169,6 +169,17 @@ select {
|
|||
right:7px;
|
||||
line-height:16px !important;
|
||||
}
|
||||
#connection_url_override {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
float: left;
|
||||
margin-left: 5px;
|
||||
}
|
||||
|
||||
#master_dj_connection_url_actions {
|
||||
float:left;
|
||||
}
|
||||
|
||||
|
||||
#auto_switch_help, #auto_transition_help {
|
||||
right: 200px;
|
||||
|
|
|
@ -111,18 +111,17 @@ function checkLiquidsoapStatus(){
|
|||
|
||||
function setLiveSourceConnectionOverrideListener(){
|
||||
$("[id=connection_url_override]").click(function(event){
|
||||
var url_input = $(this).parent().find("#stream_url").children();
|
||||
var url_input = $(this).parent().find("dd[id$='_source_host-element']").children();
|
||||
url_input.removeAttr("readonly");
|
||||
|
||||
$(this).parent().find("div[id$='_dj_connection_url_actions']").show();
|
||||
event.preventDefault();
|
||||
});
|
||||
|
||||
// set action for "OK" and "X"
|
||||
var live_dj_actions = $("#live_dj_connection_url_actions");
|
||||
var live_dj_input = live_dj_actions.parent().find("#stream_url").children();
|
||||
var live_dj_input = live_dj_actions.parent().find("dd[id$='_source_host-element']").children();
|
||||
var master_dj_actions = $("#master_dj_connection_url_actions");
|
||||
var master_dj_input = master_dj_actions.parent().find("#stream_url").children();
|
||||
var master_dj_input = master_dj_actions.parent().find("dd[id$='_source_host-element']").children();
|
||||
|
||||
live_dj_actions.find("#ok").click(function(event){
|
||||
event.preventDefault();
|
||||
|
@ -136,8 +135,8 @@ function setLiveSourceConnectionOverrideListener(){
|
|||
|
||||
live_dj_actions.find("#reset").click(function(event){
|
||||
event.preventDefault();
|
||||
var port = $("#dj_harbor_input_port").val();
|
||||
var mount = $("#dj_harbor_input_mount_point").val();
|
||||
var port = $("#show_source_port").val();
|
||||
var mount = $("#show_source_mount").val();
|
||||
var url = "http://"+location.hostname+":"+port+"/"+mount;
|
||||
if (port == '' || mount == '') {
|
||||
url = 'N/A';
|
||||
|
@ -159,8 +158,8 @@ function setLiveSourceConnectionOverrideListener(){
|
|||
});
|
||||
|
||||
master_dj_actions.find("#reset").click(function(event){
|
||||
var port = $("#master_harbor_input_port").val();
|
||||
var mount = $("#master_harbor_input_mount_point").val();
|
||||
var port = $("#master_source_port").val();
|
||||
var mount = $("#master_source_mount").val();
|
||||
var url = "http://"+location.hostname+":"+port+"/"+mount;
|
||||
if (port == '' || mount == '') {
|
||||
url = 'N/A';
|
||||
|
|
|
@ -91,7 +91,8 @@ yum install -y \
|
|||
python-pip \
|
||||
selinux-policy \
|
||||
policycoreutils-python \
|
||||
python-celery
|
||||
python-celery \
|
||||
lsof
|
||||
|
||||
# for pip ssl install
|
||||
yum install -y \
|
||||
|
|
Loading…
Reference in New Issue