Compare commits
8 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
12da117cab | ||
|
|
ef48f4b48e | ||
|
|
aae6db52b5 | ||
|
|
fb7d65d645 | ||
|
|
3b9c60e985 | ||
|
|
452df60866 | ||
|
|
7ce7123756 | ||
|
|
d42072e3ad |
@@ -67,6 +67,11 @@ if (!empty($errid)) {
|
||||
$mail_body .= "User-Area: " . AREA . "\n";
|
||||
$mail_body .= "Froxlor-version: " . Froxlor::VERSION . "\n";
|
||||
$mail_body .= "DB-version: " . Froxlor::DBVERSION . "\n\n";
|
||||
try {
|
||||
$mail_body .= "Database: " . Database::getAttribute(PDO::ATTR_SERVER_VERSION);
|
||||
} catch (\Exception $e) {
|
||||
/* ignore */
|
||||
}
|
||||
$mail_body .= "End of report";
|
||||
$mail_html = nl2br($mail_body);
|
||||
|
||||
|
||||
@@ -696,7 +696,7 @@ opcache.validate_timestamps'),
|
||||
('system', 'distribution', ''),
|
||||
('system', 'update_channel', 'stable'),
|
||||
('system', 'updatecheck_data', ''),
|
||||
('system', 'update_notify_last', '2.0.1'),
|
||||
('system', 'update_notify_last', '2.0.4'),
|
||||
('system', 'traffictool', 'goaccess'),
|
||||
('api', 'enabled', '0'),
|
||||
('2fa', 'enabled', '1'),
|
||||
@@ -740,7 +740,7 @@ opcache.validate_timestamps'),
|
||||
('panel', 'logo_overridetheme', '0'),
|
||||
('panel', 'logo_overridecustom', '0'),
|
||||
('panel', 'settings_mode', '0'),
|
||||
('panel', 'version', '2.0.1'),
|
||||
('panel', 'version', '2.0.4'),
|
||||
('panel', 'db_version', '202212060');
|
||||
|
||||
|
||||
|
||||
@@ -66,10 +66,11 @@ if (Froxlor::isFroxlorVersion('0.10.38.3')) {
|
||||
KEY customerid (customerid)
|
||||
) ENGINE=InnoDB CHARSET=utf8 COLLATE=utf8_general_ci;";
|
||||
Database::query($sql);
|
||||
Database::query("SET SESSION innodb_strict_mode=OFF;");
|
||||
// new customer allowed_mysqlserver field
|
||||
Database::query("ALTER TABLE `" . TABLE_PANEL_CUSTOMERS . "` ADD `allowed_mysqlserver` text NOT NULL default '[0]';");
|
||||
Database::query("ALTER TABLE `" . TABLE_PANEL_CUSTOMERS . "` CHANGE COLUMN `allowed_phpconfigs` `allowed_phpconfigs` text NOT NULL default '';");
|
||||
Database::query("ALTER TABLE `" . TABLE_PANEL_CUSTOMERS . "` CHANGE COLUMN `customernumber` `customernumber` varchar(100) NOT NULL default '';");
|
||||
Database::query("ALTER TABLE `" . TABLE_PANEL_CUSTOMERS . "` CHANGE COLUMN `allowed_phpconfigs` `allowed_phpconfigs` text NOT NULL;");
|
||||
Database::query("ALTER TABLE `" . TABLE_PANEL_CUSTOMERS . "` ADD `allowed_mysqlserver` text NOT NULL;");
|
||||
$has_customer_table_update_200 = true;
|
||||
// ftp_users adjustments
|
||||
Database::query("ALTER TABLE `" . TABLE_FTP_USERS . "` CHANGE COLUMN `password` `password` varchar(255) NOT NULL default '';");
|
||||
@@ -210,7 +211,7 @@ if (Froxlor::isDatabaseVersion('202211030')) {
|
||||
$newCronBin = Froxlor::getInstallDir().'/bin/froxlor-cli';
|
||||
$compCron = <<<EOF
|
||||
<?php
|
||||
chmod($newCronBin, 0755);
|
||||
chmod('$newCronBin', 0755);
|
||||
// re-create cron.d configuration file
|
||||
exec('$newCronBin froxlor:cron -r 99');
|
||||
exit;
|
||||
@@ -240,3 +241,35 @@ if (Froxlor::isFroxlorVersion('2.0.0')) {
|
||||
|
||||
Froxlor::updateToVersion('2.0.1');
|
||||
}
|
||||
|
||||
if (Froxlor::isFroxlorVersion('2.0.1')) {
|
||||
Update::showUpdateStep("Updating from 2.0.1 to 2.0.2", false);
|
||||
Froxlor::updateToVersion('2.0.2');
|
||||
}
|
||||
|
||||
if (Froxlor::isFroxlorVersion('2.0.2')) {
|
||||
Update::showUpdateStep("Updating from 2.0.2 to 2.0.3", false);
|
||||
Froxlor::updateToVersion('2.0.3');
|
||||
}
|
||||
|
||||
if (Froxlor::isFroxlorVersion('2.0.3')) {
|
||||
Update::showUpdateStep("Updating from 2.0.3 to 2.0.4", false);
|
||||
|
||||
$complete_filedir = Froxlor::getInstallDir() . '/scripts';
|
||||
// check if compat. cronjob still exists (most likely didn't run successfully b/c of error from former 2.0 release)
|
||||
if (@file_exists($complete_filedir.'/froxlor_master_cronjob.php')) {
|
||||
Update::showUpdateStep("Adjusting backward compatibility for cronjob");
|
||||
$newCronBin = Froxlor::getInstallDir() . '/bin/froxlor-cli';
|
||||
$compCron = <<<EOF
|
||||
<?php
|
||||
chmod('$newCronBin', 0755);
|
||||
// re-create cron.d configuration file
|
||||
exec('$newCronBin froxlor:cron -r 99');
|
||||
exit;
|
||||
EOF;
|
||||
file_put_contents($complete_filedir . '/froxlor_master_cronjob.php', $compCron);
|
||||
Update::lastStepStatus(0);
|
||||
}
|
||||
|
||||
Froxlor::updateToVersion('2.0.4');
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ final class Froxlor
|
||||
{
|
||||
|
||||
// Main version variable
|
||||
const VERSION = '2.0.1';
|
||||
const VERSION = '2.0.4';
|
||||
|
||||
// Database version (YYYYMMDDC where C is a daily counter)
|
||||
const DBVERSION = '202212060';
|
||||
|
||||
@@ -113,17 +113,15 @@ class Collection
|
||||
public function withPagination(array $columns, array $default_sorting = []): Collection
|
||||
{
|
||||
// Get only searchable columns
|
||||
/*
|
||||
$sortableColumns = [];
|
||||
foreach ($columns as $key => $column) {
|
||||
if (isset($column['sortable']) && $column['sortable']) {
|
||||
if (!isset($column['sortable']) || (isset($column['sortable']) && $column['sortable'])) {
|
||||
$sortableColumns[$key] = $column;
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
// Prepare pagination
|
||||
$this->pagination = new Pagination($columns, $this->count(), (int)Settings::Get('panel.paging'), $default_sorting);
|
||||
$this->pagination = new Pagination($sortableColumns, $this->count(), (int)Settings::Get('panel.paging'), $default_sorting);
|
||||
$this->params = array_merge($this->params, $this->pagination->getApiCommandParams());
|
||||
|
||||
return $this;
|
||||
|
||||
@@ -63,7 +63,9 @@ class Pagination
|
||||
$this->perPage = $perPage;
|
||||
$this->pageno = 1;
|
||||
// add default limitation by settings
|
||||
if (Settings::Get('panel.paging') > 0) {
|
||||
$this->addLimit(Settings::Get('panel.paging'));
|
||||
}
|
||||
// check search request
|
||||
$this->searchtext = '';
|
||||
if (count($fields) > 0) {
|
||||
@@ -205,7 +207,7 @@ class Pagination
|
||||
"total" => $this->entries,
|
||||
"per_page" => $this->perPage,
|
||||
"current_page" => $this->pageno,
|
||||
"last_page" => ceil($this->entries / $this->perPage),
|
||||
"last_page" => (Settings::Get('panel.paging') > 0) ? ceil($this->entries / $this->perPage) : -1,
|
||||
"from" => $this->data['sql_offset'] ?? null,
|
||||
"to" => min($this->data['sql_offset'] + $this->perPage, $this->entries),
|
||||
'sortfields' => array_keys($this->fields),
|
||||
|
||||
@@ -54,11 +54,13 @@ return [
|
||||
'label' => lng('ssl_certificates.valid_from'),
|
||||
'field' => 'validfromdate',
|
||||
'searchable' => false,
|
||||
'sortable' => false,
|
||||
],
|
||||
'c.validtodate' => [
|
||||
'label' => lng('ssl_certificates.valid_until'),
|
||||
'field' => 'validtodate',
|
||||
'searchable' => false,
|
||||
'sortable' => false,
|
||||
],
|
||||
],
|
||||
'visible_columns' => Listing::getVisibleColumnsForListing('sslcertificates_list', [
|
||||
|
||||
Reference in New Issue
Block a user