first commit

This commit is contained in:
2024-07-15 11:28:08 +02:00
commit f52d538ea5
21891 changed files with 6161164 additions and 0 deletions

View File

@@ -0,0 +1,47 @@
<?php
/**
* @package solo
* @copyright Copyright (c)2014-2022 Nicholas K. Dionysopoulos / Akeeba Ltd
* @license GNU General Public License version 3, or later
*/
use Awf\Text\Text;
defined('_AKEEBA') or die();
/** @var \Solo\View\Manage\Html $this */
$router = $this->container->router;
?>
<form name="adminForm" id="adminForm" action="@route('index.php?view=manage')" method="post"
class="akeeba-form--horizontal--with-hidden" role="form">
<div class="form-group">
<label class="control-label col-sm-3" for="description">
@lang('COM_AKEEBA_BUADMIN_LABEL_DESCRIPTION')
</label>
<div class="col-sm-9">
<input type="text" name="description" maxlength="255" size="50"
value="{{ $this->record['description'] }}"
class="form-control" />
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-3" for="comment">
@lang('COM_AKEEBA_BUADMIN_LABEL_COMMENT')
</label>
<div class="col-sm-9">
<textarea id="comment" name="comment" rows="5" cols="73"
autocomplete="off">{{ $this->record['comment'] }}</textarea>
</div>
</div>
<div class="akeeba-hidden-fields-container">
<input type="hidden" name="task" value="" />
<input type="hidden" name="id" value="{{ $this->record['id'] }}" />
<input type="hidden" name="token" value="@token()">
</div>
</form>

View File

@@ -0,0 +1,220 @@
<?php
/**
* @package solo
* @copyright Copyright (c)2014-2022 Nicholas K. Dionysopoulos / Akeeba Ltd
* @license GNU General Public License version 3, or later
*/
use Awf\Text\Text;
defined('_AKEEBA') or die();
// Used for type hinting
/** @var Solo\View\Manage\Html $this */
$router = $this->container->router;
$token = $this->container->session->getCsrfToken()->getValue();
$proKey = (defined('AKEEBABACKUP_PRO') && AKEEBABACKUP_PRO) ? 'PRO' : 'CORE';
?>
@if ($this->promptForBackupRestoration)
@include('Manage/howtorestore_modal')
@endif
<div class="akeeba-block--info">
<h4>@lang('COM_AKEEBA_BUADMIN_LABEL_HOWDOIRESTORE_LEGEND')</h4>
<p>
@sprintf('COM_AKEEBA_BUADMIN_LABEL_HOWDOIRESTORE_TEXT_' . $proKey,
'https://www.akeeba.com/videos/1214-akeeba-solo/1637-abts05-restoring-site-new-server.html',
$router->route('index.php?view=Transfer'),
'https://www.akeeba.com/latest-kickstart-core.zip'
)
</p>
@if (!AKEEBABACKUP_PRO)
<p>
@if ($this->getContainer()->segment->get('insideCMS', false))
@sprintf('COM_AKEEBA_BUADMIN_LABEL_HOWDOIRESTORE_TEXT_CORE_INFO_ABOUT_PRO',
'https://www.akeeba.com/products/akeeba-backup-wordpress.html')
@else
@sprintf('COM_AKEEBA_BUADMIN_LABEL_HOWDOIRESTORE_TEXT_CORE_INFO_ABOUT_PRO',
'https://www.akeeba.com/products/akeeba-solo.html')
@endif
</p>
@endif
</div>
<form action="@route('index.php?view=manage')" method="post" name="adminForm" id="adminForm"
role="form" class="akeeba-form">
<table class="akeeba-table--striped" id="itemsList">
<thead>
<tr>
<th width="20">
<input type="checkbox" name="toggle" value="" onclick="akeeba.System.checkAll(this);" />
</th>
<th width="20" class="akeeba-hidden-phone">
@html('grid.sort', 'COM_AKEEBA_BUADMIN_LABEL_ID', 'id', $this->lists->order_Dir, $this->lists->order,
'default')
</th>
<th width="80" class="akeeba-hidden-phone">
@html('grid.sort', 'COM_AKEEBA_BUADMIN_LABEL_FROZEN', 'frozen', $this->lists->order_Dir, $this->lists->order,
'default')
</th>
<th width="25%">
@html('grid.sort', 'COM_AKEEBA_BUADMIN_LABEL_DESCRIPTION', 'description', $this->lists->order_Dir,
$this->lists->order, 'default')
</th>
<th width="25%" class="akeeba-hidden-phone">
@html('grid.sort', 'COM_AKEEBA_BUADMIN_LABEL_PROFILEID', 'profile_id', $this->lists->order_Dir,
$this->lists->order, 'default')
</th>
<th width="80">
@html('grid.sort', 'COM_AKEEBA_BUADMIN_LABEL_DURATION', 'backupstart', $this->lists->order_Dir,
$this->lists->order, 'default')
</th>
<th width="80">
@lang('COM_AKEEBA_BUADMIN_LABEL_STATUS')
</th>
<th width="110" class="akeeba-hidden-phone">
@lang('COM_AKEEBA_BUADMIN_LABEL_SIZE')
</th>
<th class="akeeba-hidden-phone">
@lang('COM_AKEEBA_BUADMIN_LABEL_MANAGEANDDL')
</th>
</tr>
<tr>
<td></td>
<td class="akeeba-hidden-phone"></td>
<td>
@html('select.genericlist', $this->frozenList, 'filter_frozen', ['list.attr' => ['class' => 'akeebaGridViewAutoSubmitOnChange'], 'list.select' => $this->lists->fltFrozen])
</td>
<td>
<input type="text" name="filter_description" id="description"
class="akeebaGridViewAutoSubmitOnChange" style="width: 100%;"
value="{{ $this->lists->fltDescription }}"
placeholder="@lang('SOLO_MANAGE_FIELD_DESCRIPTION')">
</td>
<td class="akeeba-hidden-phone">
@html('select.genericlist', $this->profilesList, 'filter_profile', ['list.attr' => ['class' => 'akeebaGridViewAutoSubmitOnChange', 'style' => 'max-width: 12vw'], 'list.select' => $this->lists->fltProfile])
</td>
<td></td>
<td></td>
<td colspan="2" class="akeeba-hidden-phone"></td>
</tr>
</thead>
<tfoot>
<tr>
<td colspan="11" class="center">
{{ $this->pagination->getListFooter() }}
</td>
</tr>
</tfoot>
<tbody>
@if(empty($this->items))
<tr>
<td colspan="11">
@lang('SOLO_LBL_NO_RECORDS')
</td>
</tr>
@endif
@if (!empty($this->items))
<?php $i = 0; ?>
@foreach ($this->items as $record)
<?php
list($originDescription, $originIcon) = $this->getOriginInformation($record);
list($startTime, $duration, $timeZoneText) = $this->getTimeInformation($record);
list($statusClass, $statusIcon) = $this->getStatusInformation($record);
$profileName = $this->getProfileName($record);
$frozenIcon = 'akion-waterdrop';
$frozenTask = 'freeze';
$frozenTitle = Text::_('COM_AKEEBA_BUADMIN_LABEL_ACTION_FREEZE');
if ($record['frozen'])
{
$frozenIcon = 'akion-ios-snowy';
$frozenTask = 'unfreeze';
$frozenTitle = Text::_('COM_AKEEBA_BUADMIN_LABEL_ACTION_UNFREEZE');
}
?>
<tr>
<td>@html('grid.id', ++$i, $record['id'])</td>
<td class="akeeba-hidden-phone">
{{{ $record['id'] }}}
</td>
<td style="text-align: center">
<a href="@route('index.php?view=Manage&id=' . $record['id'] . '&task=' . $frozenTask . '&token=' . $token)" title="{{$frozenTitle}}">
<span class="{{ $frozenIcon }}"></span>
</a>
</td>
<td>
<span class="{{ $originIcon }} akeebaCommentPopover" rel="popover"
title="@lang('COM_AKEEBA_BUADMIN_LABEL_ORIGIN')"
data-content="{{{ $originDescription }}}"></span>
@if( ! (empty($record['comment'])))
<span class="akion-help-circled akeebaCommentPopover" rel="popover"
data-content="{{{ $record['comment'] }}}"></span>
@endif
<a href="@route('index.php?view=manage&task=showComment&id=' . $record['id'] . '&token=' . $token)">
{{{ empty($record['description']) ? Text::_('COM_AKEEBA_BUADMIN_LABEL_NODESCRIPTION') : $record['description'] }}}
</a>
<br />
<div class="akeeba-buadmin-startdate" title="@lang('COM_AKEEBA_BUADMIN_LABEL_START')">
<small>
<span class="akion-calendar"></span>
{{{ $startTime }}} {{{ $timeZoneText }}}
</small>
</div>
</td>
<td class="akeeba-hidden-phone">
#{{{ (int)$record['profile_id'] }}}. {{{ $profileName }}}
<br />
<small>
<em>{{{ $this->translateBackupType($record['type']) }}}</em>
</small>
</td>
<td>
{{{ $duration }}}
</td>
<td>
<span class="{{ $statusClass }} akeebaCommentPopover" rel="popover"
data-original-title="@lang('COM_AKEEBA_BUADMIN_LABEL_STATUS')"
data-content="@lang('COM_AKEEBA_BUADMIN_LABEL_STATUS_' . $record['meta'])"
style="padding: 0.4em 0.6em;"
>
<span class="{{ $statusIcon }}"></span>
</span>
</td>
<td class="akeeba-hidden-phone">
@if($record['meta'] == 'ok')
{{{ \Solo\Helper\Format::fileSize($record['size']) }}}
@elseif($record['total_size'] > 0)
<i>{{ \Solo\Helper\Format::fileSize($record['total_size']) }}</i>
@else
&mdash;
@endif
</td>
<td class="akeeba-hidden-phone">
@include('Manage/manage_column', ['record' => &$record])
</td>
</tr>
@endforeach
@endif
</tbody>
</table>
<div class="akeeba-hidden-fields-container">
<input type="hidden" name="boxchecked" id="boxchecked" value="0">
<input type="hidden" name="task" id="task" value="default">
<input type="hidden" name="filter_order" id="filter_order" value="{{ $this->lists->order }}">
<input type="hidden" name="filter_order_Dir" id="filter_order_Dir" value="{{ $this->lists->order_Dir }}">
<input type="hidden" name="token" value="@token()">
</div>
</form>

View File

@@ -0,0 +1,69 @@
<?php
/**
* @package solo
* @copyright Copyright (c)2014-2022 Nicholas K. Dionysopoulos / Akeeba Ltd
* @license GNU General Public License version 3, or later
*/
use Awf\Text\Text;
defined('_AKEEBA') or die();
/** @var $this \Solo\View\Configuration\Html */
$router = $this->container->router;
$proKey = (defined('AKEEBABACKUP_PRO') && AKEEBABACKUP_PRO) ? 'PRO' : 'CORE';
$js = <<< JS
akeeba.System.documentReady(function(){
setTimeout(function() {
akeeba.System.howToRestoreModal = akeeba.Modal.open({
inherit: '#akeeba-config-howtorestore-bubble',
width: '80%'
});
}, 500);
});
JS;
?>
@inlineJs($js)
<div id="akeeba-config-howtorestore-bubble" style="display: none;">
<div class="akeeba-renderer-fef {{ ($this->getContainer()->appConfig->get('darkmode', -1) == 1) ? 'akeeba-renderer-fef--dark' : '' }}">
<h4>
@lang('COM_AKEEBA_BUADMIN_LABEL_HOWDOIRESTORE_LEGEND')
</h4>
<p>
@sprintf('COM_AKEEBA_BUADMIN_LABEL_HOWDOIRESTORE_TEXT_' . $proKey,
'https://www.akeeba.com/videos/1214-akeeba-solo/1637-abts05-restoring-site-new-server.html',
$router->route('index.php?view=Transfer'),
'https://www.akeeba.com/latest-kickstart-core.zip'
)
</p>
@if (!AKEEBABACKUP_PRO)
<p>
@if ($this->getContainer()->segment->get('insideCMS', false))
@sprintf('COM_AKEEBA_BUADMIN_LABEL_HOWDOIRESTORE_TEXT_CORE_INFO_ABOUT_PRO',
'https://www.akeeba.com/products/akeeba-backup-wordpress.html')
@else
@sprintf('COM_AKEEBA_BUADMIN_LABEL_HOWDOIRESTORE_TEXT_CORE_INFO_ABOUT_PRO',
'https://www.akeeba.com/products/akeeba-solo.html')
@endif
</p>
@endif
<div>
<a href="#" onclick="akeeba.System.howToRestoreModal.close(); document.getElementById('akeeba-config-howtorestore-bubble').style.display = 'none'" class="akeeba-btn--primary">
<span class="akion-close"></span>
@lang('COM_AKEEBA_BUADMIN_BTN_REMINDME')
</a>
<a href="@route('index.php?view=Manage&task=hideModal')" class="akeeba-btn--green">
<span class="akion-checkmark-circled"></span>
@lang('COM_AKEEBA_BUADMIN_BTN_DONTSHOWTHISAGAIN')
</a>
</div>
</div>
</div>

View File

@@ -0,0 +1,233 @@
<?php
/**
* @package solo
* @copyright Copyright (c)2014-2022 Nicholas K. Dionysopoulos / Akeeba Ltd
* @license GNU General Public License version 3, or later
*/
use Awf\Text\Text;
use Solo\Helper\Utils as AkeebaHelperUtils;
defined('_AKEEBA') or die();
/** @var array $record */
/** @var Solo\View\Manage\Html $this */
$router = $this->container->router;
if (!isset($record['remote_filename']))
{
$record['remote_filename'] = '';
}
$archiveExists = $record['meta'] == 'ok';
$showManageRemote = in_array($record['meta'], array(
'ok', 'remote'
)) && !empty($record['remote_filename']) && (AKEEBABACKUP_PRO == 1);
$engineForProfile = array_key_exists($record['profile_id'], $this->enginesPerProfile) ? $this->enginesPerProfile[$record['profile_id']] : 'none';
$showUploadRemote = $this->privileges['backup'] && $archiveExists && empty($record['remote_filename']) && ($engineForProfile != 'none') && ($record['meta'] != 'obsolete') && (AKEEBABACKUP_PRO == 1);
$showDownload = $this->privileges['download'] && $archiveExists;
$showViewLog = $this->privileges['backup'] && isset($record['backupid']) && !empty($record['backupid']);
$postProcEngine = '';
$thisPart = '';
$thisID = urlencode($record['id']);
if ($showUploadRemote)
{
$postProcEngine = $engineForProfile ?: 'none';
$showUploadRemote = !empty($postProcEngine);
}
?>
<div style="display: none">
<div id="akeeba-buadmin-{{ (int)$record['id'] }}" tabindex="-1" role="dialog">
<div class="akeeba-renderer-fef {{ ($this->getContainer()->appConfig->get('darkmode', -1) == 1) ? 'akeeba-renderer-fef--dark' : '' }}">
<h4>@lang('COM_AKEEBA_BUADMIN_LBL_BACKUPINFO')</h4>
<p>
<strong>@lang('COM_AKEEBA_BUADMIN_LBL_ARCHIVEEXISTS')</strong><br />
@if ($record['meta'] == 'ok')
<span class="akeeba-label--success">
@lang('SOLO_YES')
</span>
@else
<span class="akeeba-label--failure">
@lang('SOLO_NO')
</span>
@endif
</p>
<p>
<strong>@lang('COM_AKEEBA_BUADMIN_LBL_ARCHIVEPATH' . ($archiveExists ? '' : '_PAST'))</strong>
<br />
<span class="akeeba-label--information">
{{{ AkeebaHelperUtils::getRelativePath(APATH_BASE, dirname($record['absolute_path'])) }}}
</span>
</p>
<p>
<strong>@lang('COM_AKEEBA_BUADMIN_LBL_ARCHIVENAME' . ($archiveExists ? '' : '_PAST'))</strong>
<br />
<code>
{{{ $record['archivename'] }}}
</code>
</p>
</div>
</div>
@if ($showDownload)
<div id="akeeba-buadmin-download-{{ (int) $record['id'] }}" tabindex="-2" role="dialog">
<div class="akeeba-renderer-fef {{ ($this->getContainer()->appConfig->get('darkmode', -1) == 1) ? 'akeeba-renderer-fef--dark' : '' }}">
<div class="akeeba-block--warning">
@if(defined('WPINC') && !$this->showBrowserDownload)
<h4>
@lang('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_TITLE_NODOWNLOAD')
</h4>
<p>
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD')
</p>
<p>
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_REENABLE')
</p>
<p>
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_ALTERNATIVE')
</p>
@elseif($this->phpErrorDisplay === -1)
<h4>
@lang('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_TITLE_NODOWNLOAD_PHPERRORDISPLAY')
</h4>
<p>
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_PHPERRORDISPLAY_UNKNOWN')
</p>
@elseif($this->phpErrorDisplay === 1)
<h4>
@lang('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_TITLE_NODOWNLOAD_PHPERRORDISPLAY')
</h4>
<p>
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_PHPERRORDISPLAY_ENABLED')
</p>
@if (defined('WP_DEBUG') && WP_DEBUG)
<p>@lang('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_PHPERRORDISPLAY_WPDEBUG')</p>
@elseif(defined('AKEEBADEBUG'))
@if (defined('WPINC'))
<p>
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_PHPERRORDISPLAY_AKEEBADEBUG', str_replace(WP_CONTENT_URL . '/', '', plugins_url('helpers', AkeebaBackupWP::$absoluteFileName)))
</p>
@else
<p>
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_PHPERRORDISPLAY_AKEEBADEBUG', 'app')
</p>
@endif
@endif
@else
<h4>
@lang('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_TITLE')
</h4>
@if (defined('WPINC'))
<p>
@lang('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_WORDPRESS')
</p>
@endif
<p>
@lang('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING')
</p>
@endif
</div>
@if((defined('WPINC') && !$this->showBrowserDownload) || $this->phpErrorDisplay != 0)
<div class="akeeba-block--info">
<?php
$archiveName = $record['archivename'];
$extension = substr($archiveName, -4);
$firstPart = substr($extension, 0, 2) . '01';
$lastPart = substr($extension, 0, 2) . sprintf('%02u', min($record['multipart'] - 1, 1));
?>
@if ($record['multipart'] < 2)
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_MULTIPART_1', $archiveName)
@elseif($record['multipart'] < 3)
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_MULTIPART_2', substr($archiveName, 0, -4), $extension, $firstPart)
@else
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_WARNING_NODOWNLOAD_MULTIPART', $record['multipart'], substr($archiveName, 0, -4), $extension, $firstPart, $lastPart)
@endif
</div>
@else
@if ($record['multipart'] < 2)
<a class="akeeba-btn--primary--small comAkeebaManageDownloadButton"
data-id="{{{ $record['id'] }}}">
<span class="akion-ios-download"></span>
@lang('COM_AKEEBA_BUADMIN_LOG_DOWNLOAD')
</a>
@endif
@if ($record['multipart'] >= 2)
<div>
@sprintf('COM_AKEEBA_BUADMIN_LBL_DOWNLOAD_PARTS', $record['multipart'])
</div>
@for ($count = 0; $count < $record['multipart']; $count++)
@if ($count > 0)
&bull;
@endif
<a class="akeeba-btn--small--dark comAkeebaManageDownloadButton"
data-id="{{{ $record['id'] }}}"
data-part="{{{ $count }}}">
<span class="akion-android-download"></span>
@sprintf('COM_AKEEBA_BUADMIN_LABEL_PART', $count)
</a>
@endfor
@endif
@endif
</div>
</div>
@endif
</div>
@if ($showManageRemote)
<div style="padding-bottom: 3pt;">
<a class="akeeba-btn--primary akeeba_remote_management_link"
data-management="{{{ $router->route('index.php?view=Remotefiles&tmpl=component&task=listActions&id=' . (int)$record['id']) }}}"
data-reload="{{{ $router->route('index.php?view=Manage') }}}"
>
<span class="akion-cloud"></span>
@lang('COM_AKEEBA_BUADMIN_LABEL_REMOTEFILEMGMT')
</a>
</div>
@elseif ($showUploadRemote)
<a class="akeeba-btn--primary akeeba_upload"
data-upload="{{{ $router->route('index.php?view=Upload&tmpl=component&task=start&id=' . $record['id']) }}}"
data-reload="{{{ $router->route('index.php?view=Manage') }}}"
title="<?php echo Text::sprintf('COM_AKEEBA_TRANSFER_DESC', Text::_("ENGINE_POSTPROC_{$postProcEngine}_TITLE")) ?>"
>
<span class="akion-android-upload"></span>
@lang('COM_AKEEBA_TRANSFER_TITLE')
(<em>{{ $postProcEngine }}</em>)
</a>
@endif
<div style="padding-bottom: 3pt">
@if ($showDownload)
<a class="akeeba-btn--{{ $showManageRemote || $showUploadRemote ? 'small--grey' : 'green' }} akeeba_download_button"
data-dltarget="#akeeba-buadmin-download-{{ (int)$record['id'] }}"
>
<span class="akion-android-download"></span>
@lang('COM_AKEEBA_BUADMIN_LOG_DOWNLOAD')
</a>
@endif
@if ($showViewLog)
<a class="akeeba-btn--grey akeebaCommentPopover"
{{ ($record['meta'] != 'obsolete') ? '' : 'disabled="disabled"' }}
href="@route('index.php?view=Log&tag=' . $this->escape($record['tag']) . '.' . $this->escape($record['backupid']) . '&task=start&profileid=' . $record['profile_id'])"
data-original-title="@lang('COM_AKEEBA_BUADMIN_LBL_LOGFILEID')"
data-content="{{{ $record['backupid'] }}}"
>
<span class="akion-ios-search-strong"></span>
@lang('COM_AKEEBA_LOG')
</a>
@endif
<a class="akeeba-btn--grey--small akeebaCommentPopover akeeba_showinfo_link"
data-infotarget="#akeeba-buadmin-{{ (int)$record['id'] }}"
data-content="@lang('COM_AKEEBA_BUADMIN_LBL_BACKUPINFO')"
>
<span class="akion-information-circled"></span>
</a>
</div>