mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-03 09:49:28 +02:00
Can change the status from the privacy tab
add colors in the social icons
This commit is contained in:
parent
14b6aac5cc
commit
d3a787dd59
6 changed files with 72 additions and 30 deletions
|
@ -216,6 +216,21 @@ if (Permissions::canAdminVideos()) {
|
|||
TimeLogEnd(__FILE__, __LINE__);
|
||||
$resp = $obj->save(true);
|
||||
|
||||
if(!empty($resp)){
|
||||
if(!empty($_POST['videoStatus'])){
|
||||
$found = false;
|
||||
foreach ($statusThatTheUserCanUpdate as $key => $value) {
|
||||
if($_POST['videoStatus'] == $value[0]){
|
||||
$found = true;
|
||||
}
|
||||
}
|
||||
if($found){
|
||||
$obj = new Video('', '', @$_POST['id'], true);
|
||||
$obj->setStatus(@$_POST['videoStatus']);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($_REQUEST['playlists_id'])) {
|
||||
if (!PlayLists::canAddVideoOnPlaylist($resp)) {
|
||||
Playlists::addVideo($resp, $_REQUEST['playlists_id']);
|
||||
|
|
|
@ -1223,8 +1223,8 @@ class API extends PluginAbstract
|
|||
* @param array $parameters
|
||||
* 'videos_id' the video id that will be deleted
|
||||
* ['APISecret' if passed will not require user and pass]
|
||||
* ['user' username of the user that will like the video]
|
||||
* ['pass' password of the user that will like the video]
|
||||
* ['user' username of the user that will login]
|
||||
* ['pass' password of the user that will login]
|
||||
* @example {webSiteRootURL}plugin/API/{getOrSet}.json.php?APIName={APIName}&videos_id=1&user=admin&pass=123&APISecret={APISecret}
|
||||
* @return \ApiObject
|
||||
*/
|
||||
|
@ -1257,8 +1257,8 @@ class API extends PluginAbstract
|
|||
* 'videos_id' the video that will receive the comment
|
||||
* ['id' the comment id if you will edit some]
|
||||
* ['APISecret' if passed will not require user and pass]
|
||||
* ['user' username of the user that will like the video]
|
||||
* ['pass' password of the user that will like the video]
|
||||
* ['user' username of the user that will login]
|
||||
* ['pass' password of the user that will login]
|
||||
* @example {webSiteRootURL}plugin/API/{getOrSet}.json.php?APIName={APIName}&videos_id=1&user=admin&pass=123&APISecret={APISecret}
|
||||
* @return \ApiObject
|
||||
*/
|
||||
|
@ -1298,8 +1298,8 @@ class API extends PluginAbstract
|
|||
* 'comment' String with the comment
|
||||
* 'videos_id' the video that will retreive the comments
|
||||
* ['APISecret' if passed will not require user and pass]
|
||||
* ['user' username of the user that will like the video]
|
||||
* ['pass' password of the user that will like the video]
|
||||
* ['user' username of the user that will login]
|
||||
* ['pass' password of the user that will login]
|
||||
* ['rowCount' max numbers of rows]
|
||||
* ['current' current page]
|
||||
* @example {webSiteRootURL}plugin/API/{getOrSet}.json.php?APIName={APIName}&videos_id=1&user=admin&pass=123&APISecret={APISecret}
|
||||
|
@ -1335,8 +1335,8 @@ class API extends PluginAbstract
|
|||
* @param array $parameters
|
||||
* @example {webSiteRootURL}plugin/API/{getOrSet}.json.php?APIName={APIName}
|
||||
* ['live_schedule_id' if you pass it will return a specific live_schedule record]
|
||||
* 'user' username of the user that will like the video
|
||||
* 'pass' password of the user that will like the video
|
||||
* 'user' username of the user that will login
|
||||
* 'pass' password of the user that will login
|
||||
* @return \ApiObject
|
||||
*/
|
||||
public function get_api_live_schedule($parameters)
|
||||
|
@ -1364,8 +1364,8 @@ class API extends PluginAbstract
|
|||
* @param array $parameters
|
||||
* @example {webSiteRootURL}plugin/API/{getOrSet}.json.php?APIName={APIName}
|
||||
* ['live_schedule_id' if you pass it will return a specific live_schedule record]
|
||||
* 'user' username of the user that will like the video
|
||||
* 'pass' password of the user that will like the video
|
||||
* 'user' username of the user that will login
|
||||
* 'pass' password of the user that will login
|
||||
* @return \ApiObject
|
||||
*/
|
||||
public function set_api_live_schedule_delete($parameters)
|
||||
|
@ -1401,8 +1401,8 @@ class API extends PluginAbstract
|
|||
* 'scheduled_time' pass it in the YYYY-mm-dd HH:ii:ss format
|
||||
* 'status' a for active or i for inactive
|
||||
* 'scheduled_password'
|
||||
* 'user' username of the user that will like the video
|
||||
* 'pass' password of the user that will like the video
|
||||
* 'user' username of the user that will login
|
||||
* 'pass' password of the user that will login
|
||||
* @return \ApiObject
|
||||
*/
|
||||
public function set_api_live_schedule($parameters)
|
||||
|
@ -2026,8 +2026,8 @@ class API extends PluginAbstract
|
|||
/**
|
||||
* @param array $parameters (all parameters are mandatories)
|
||||
* 'videos_id' the video ID what you want to send the like
|
||||
* 'user' username of the user that will like the video
|
||||
* 'pass' password of the user that will like the video
|
||||
* 'user' username of the user that will login
|
||||
* 'pass' password of the user that will login
|
||||
* @example {webSiteRootURL}plugin/API/{getOrSet}.json.php?APIName={APIName}&videos_id=1&user=admin&pass=123
|
||||
* @return \ApiObject
|
||||
*/
|
||||
|
@ -2039,8 +2039,8 @@ class API extends PluginAbstract
|
|||
/**
|
||||
* @param array $parameters (all parameters are mandatories)
|
||||
* 'videos_id' the video ID what you want to send the like
|
||||
* 'user' username of the user that will like the video
|
||||
* 'pass' password of the user that will like the video
|
||||
* 'user' username of the user that will login
|
||||
* 'pass' password of the user that will login
|
||||
* @example {webSiteRootURL}plugin/API/{getOrSet}.json.php?APIName={APIName}&videos_id=1&user=admin&pass=123
|
||||
* @return \ApiObject
|
||||
*/
|
||||
|
@ -2052,8 +2052,8 @@ class API extends PluginAbstract
|
|||
/**
|
||||
* @param array $parameters (all parameters are mandatories)
|
||||
* 'videos_id' the video ID what you want to send the like
|
||||
* 'user' username of the user that will like the video
|
||||
* 'pass' password of the user that will like the video
|
||||
* 'user' username of the user that will login
|
||||
* 'pass' password of the user that will login
|
||||
* @example {webSiteRootURL}plugin/API/{getOrSet}.json.php?APIName={APIName}&videos_id=1&user=admin&pass=123
|
||||
* @return \ApiObject
|
||||
*/
|
||||
|
|
|
@ -6,13 +6,13 @@ foreach (CustomizeUser::getSocialMedia() as $platform => $details) {
|
|||
continue;
|
||||
}
|
||||
?>
|
||||
<div class="form-group">
|
||||
<div class="form-group social-network">
|
||||
<label class="col-md-4 control-label">
|
||||
<?php echo $details['label']; ?>
|
||||
</label>
|
||||
<div class="col-md-8 inputGroupContainer">
|
||||
<div class="input-group largeSocialIcon">
|
||||
<span class="input-group-addon"><i class="<?php echo $details['icon']; ?>"></i></span>
|
||||
<span class="input-group-addon"><i class="<?php echo $details['icon']; ?> <?php echo $details['class']; ?> socialColor"></i></span>
|
||||
<input id="user<?php echo ucfirst($platform); ?>" platform="<?php echo $platform; ?>"
|
||||
placeholder="<?php echo $details['placeholder']; ?>"
|
||||
class="form-control CustomizeUserSocialMedia"
|
||||
|
|
|
@ -111,13 +111,17 @@ ul.social-network li {
|
|||
}
|
||||
|
||||
/* Define a base class for common styles */
|
||||
.social-network a, .social-network button {
|
||||
.social-network a, .social-network button{
|
||||
border-color: var(--hover-color) !important;
|
||||
color: var(--hover-color); /* Change text color on hover */
|
||||
box-shadow: 0 0 1px 1px var(--hover-color); /* Outer glow effect */
|
||||
transition: box-shadow 0.3s ease; /* Smooth transition for the glow effect */
|
||||
}
|
||||
|
||||
.social-network i.socialColor {
|
||||
color: var(--hover-color); /* Change text color on hover */
|
||||
}
|
||||
|
||||
.social-network a:hover, .social-network button:hover {
|
||||
background-color: var(--hover-color);
|
||||
box-shadow: 0 0 6px 4px var(--hover-color); /* Outer glow effect */
|
||||
|
|
|
@ -922,6 +922,7 @@ if (empty($advancedCustom->disableHTMLDescription)) {
|
|||
$('#inputVideoId').val(row.id);
|
||||
$('#inputTitle').val(row.title);
|
||||
$('#inputVideoPassword').val(row.video_password);
|
||||
$('#videoStatus').val(row.status);
|
||||
$('#inputTrailer').val(row.trailer1);
|
||||
$('#inputCleanTitle').val(row.clean_title);
|
||||
$('#created').val(row.created);
|
||||
|
@ -1150,6 +1151,7 @@ if (empty($advancedCustom->disableHTMLDescription)) {
|
|||
"title": $('#inputTitle').val(),
|
||||
"trailer1": $('#inputTrailer').val(),
|
||||
"video_password": $('#inputVideoPassword').val(),
|
||||
"videoStatus": $('#videoStatus').val(),
|
||||
"videoLink": $('#videoLink').val(),
|
||||
"epg_link": $('#epg_link').val(),
|
||||
"videoLinkType": $('#videoLinkType').val(),
|
||||
|
@ -1232,6 +1234,7 @@ if (empty($advancedCustom->disableHTMLDescription)) {
|
|||
$('#videoStartSeconds').val('00:00:00');
|
||||
$('#videoSkipIntroSecond').val('00:00:00');
|
||||
$('#inputVideoPassword').val("");
|
||||
$('#videoStatus').val('a');
|
||||
$('#inputCleanTitle').val("");
|
||||
$('#created').val("");
|
||||
$('#inputDescription').val("");
|
||||
|
|
|
@ -191,14 +191,34 @@
|
|||
</li>
|
||||
<?php
|
||||
}
|
||||
if (!empty($advancedCustomUser->userCanProtectVideosWithPassword) || Permissions::canAdminVideos()) {
|
||||
?>
|
||||
<li class="list-group-item">
|
||||
<div class="row">
|
||||
<?php
|
||||
$col = 12;
|
||||
if (!empty($advancedCustomUser->userCanProtectVideosWithPassword) || Permissions::canAdminVideos()) {
|
||||
$col = 6;
|
||||
?>
|
||||
<div class="col-sm-6">
|
||||
<label class="control-label" for="inputVideoPassword"><?php echo __("Password Protected"); ?></label>
|
||||
<input type="text" id="inputVideoPassword" class="form-control" placeholder="<?php echo __("Password"); ?>">
|
||||
</li>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
<div class="col-sm-<?php echo $col; ?>">
|
||||
<label for="videoStatus"><?php echo __('Video Status'); ?></label>
|
||||
<select class="form-control last" id="videoStatus">
|
||||
<?php
|
||||
foreach ($statusThatTheUserCanUpdate as $value) {
|
||||
echo "<option value=\"{$value[0]}\">" . __(Video::$statusDesc[$value[0]]) . "</option>";
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
<?php
|
||||
if (empty($advancedCustomUser->userCanNotChangeUserGroup) || Permissions::canAdminVideos()) {
|
||||
if ($advancedCustom->paidOnlyUsersTellWhatVideoIs || Permissions::canAdminVideos()) {
|
||||
?>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue