From 5f449ab111c1472de40654101d747d5fc3a60aab Mon Sep 17 00:00:00 2001 From: Diego Najar Date: Tue, 26 Dec 2017 17:45:02 +0100 Subject: [PATCH] Fixes on Language dictionaries --- bl-kernel/abstract/dblist.class.php | 5 +- bl-kernel/admin/controllers/content.php | 9 +- bl-kernel/admin/views/content.php | 2 +- bl-kernel/admin/views/dashboard.php | 10 +- bl-kernel/admin/views/edit-content.php | 3 +- bl-kernel/dbcategories.class.php | 10 +- bl-kernel/dbpages.class.php | 26 +- bl-kernel/dbtags.class.php | 2 +- bl-kernel/functions.php | 24 +- bl-kernel/helpers/filesystem.class.php | 6 +- bl-languages/ru_RU.json | 13 +- bl-languages/tr_TR.json | 2 +- bl-plugins/api/plugin.php | 3 +- bl-plugins/latest-content/plugin.php | 3 +- bl-plugins/rss/plugin.php | 3 +- bl-plugins/sitemap/plugin.php | 5 +- bl-plugins/static-pages/plugin.php | 3 +- bl-themes/alternative/.gitignore | 1 + bl-themes/alternative/.travis.yml | 11 + bl-themes/alternative/css/scrolling-nav.css | 19 + bl-themes/alternative/index.php | 62 + bl-themes/alternative/js/scrolling-nav.js | 29 + bl-themes/alternative/languages/en.json | 7 + bl-themes/alternative/metadata.json | 10 + bl-themes/alternative/php/head.php | 16 + bl-themes/alternative/php/home.php | 25 + bl-themes/alternative/php/page.php | 20 + bl-themes/alternative/php/sidebar.php | 1 + .../vendor/bootstrap/css/bootstrap-grid.css | 1567 +++ .../bootstrap/css/bootstrap-grid.min.css | 7 + .../vendor/bootstrap/css/bootstrap-reboot.css | 342 + .../bootstrap/css/bootstrap-reboot.min.css | 8 + .../vendor/bootstrap/css/bootstrap.css | 8374 +++++++++++++ .../vendor/bootstrap/css/bootstrap.min.css | 7 + .../vendor/bootstrap/js/bootstrap.bundle.js | 6287 ++++++++++ .../bootstrap/js/bootstrap.bundle.min.js | 7 + .../vendor/bootstrap/js/bootstrap.js | 3850 ++++++ .../vendor/bootstrap/js/bootstrap.min.js | 7 + .../jquery.easing.compatibility.js | 59 + .../vendor/jquery-easing/jquery.easing.js | 166 + .../vendor/jquery-easing/jquery.easing.min.js | 1 + bl-themes/alternative/vendor/jquery/jquery.js | 10253 ++++++++++++++++ .../alternative/vendor/jquery/jquery.min.js | 4 + 43 files changed, 31208 insertions(+), 61 deletions(-) create mode 100755 bl-themes/alternative/.gitignore create mode 100755 bl-themes/alternative/.travis.yml create mode 100755 bl-themes/alternative/css/scrolling-nav.css create mode 100755 bl-themes/alternative/index.php create mode 100755 bl-themes/alternative/js/scrolling-nav.js create mode 100644 bl-themes/alternative/languages/en.json create mode 100644 bl-themes/alternative/metadata.json create mode 100644 bl-themes/alternative/php/head.php create mode 100644 bl-themes/alternative/php/home.php create mode 100644 bl-themes/alternative/php/page.php create mode 100644 bl-themes/alternative/php/sidebar.php create mode 100755 bl-themes/alternative/vendor/bootstrap/css/bootstrap-grid.css create mode 100755 bl-themes/alternative/vendor/bootstrap/css/bootstrap-grid.min.css create mode 100755 bl-themes/alternative/vendor/bootstrap/css/bootstrap-reboot.css create mode 100755 bl-themes/alternative/vendor/bootstrap/css/bootstrap-reboot.min.css create mode 100755 bl-themes/alternative/vendor/bootstrap/css/bootstrap.css create mode 100755 bl-themes/alternative/vendor/bootstrap/css/bootstrap.min.css create mode 100755 bl-themes/alternative/vendor/bootstrap/js/bootstrap.bundle.js create mode 100755 bl-themes/alternative/vendor/bootstrap/js/bootstrap.bundle.min.js create mode 100755 bl-themes/alternative/vendor/bootstrap/js/bootstrap.js create mode 100755 bl-themes/alternative/vendor/bootstrap/js/bootstrap.min.js create mode 100755 bl-themes/alternative/vendor/jquery-easing/jquery.easing.compatibility.js create mode 100755 bl-themes/alternative/vendor/jquery-easing/jquery.easing.js create mode 100755 bl-themes/alternative/vendor/jquery-easing/jquery.easing.min.js create mode 100755 bl-themes/alternative/vendor/jquery/jquery.js create mode 100755 bl-themes/alternative/vendor/jquery/jquery.min.js diff --git a/bl-kernel/abstract/dblist.class.php b/bl-kernel/abstract/dblist.class.php index a1b2ae1f..26e9f3d5 100644 --- a/bl-kernel/abstract/dblist.class.php +++ b/bl-kernel/abstract/dblist.class.php @@ -24,6 +24,7 @@ class dbList extends dbJSON parent::__construct($file); } + // Returns an array with a list of key of pages, FALSE if out of range public function getList($key, $pageNumber, $amountOfItems) { if (empty($key)) { @@ -39,7 +40,7 @@ class dbList extends dbJSON if ($amountOfItems==-1) { // Invert keys to values, is necesary returns as key the key pages - $list = array_flip($list); + //$list = array_flip($list); return $list; } @@ -56,7 +57,7 @@ class dbList extends dbJSON return false; } - $list = array_flip($list); + //$list = array_flip($list); return array_slice($list, $init, $amountOfItems, true); } diff --git a/bl-kernel/admin/controllers/content.php b/bl-kernel/admin/controllers/content.php index 56237b91..425199bb 100644 --- a/bl-kernel/admin/controllers/content.php +++ b/bl-kernel/admin/controllers/content.php @@ -31,12 +31,9 @@ if (empty($published) && $Url->pageNumber()>1) { Redirect::page('content'); } -// List of drafts pages -$drafts = $dbPages->getDraftDB(); - -$scheduled = $dbPages->getScheduledDB(); - -$static = $dbPages->getStaticDB(); +$drafts = $dbPages->getDraftDB(true); +$scheduled = $dbPages->getScheduledDB(true); +$static = $dbPages->getStaticDB(true); // Title of the page $layout['title'] .= ' - '.$Language->g('Manage content'); \ No newline at end of file diff --git a/bl-kernel/admin/views/content.php b/bl-kernel/admin/views/content.php index f5bf8f23..2249bf98 100644 --- a/bl-kernel/admin/views/content.php +++ b/bl-kernel/admin/views/content.php @@ -46,7 +46,7 @@ function table($status, $icon='arrow-circle-o-down') { '; } - foreach($list as $pageKey=>$fields) { + foreach($list as $pageKey) { $page = buildPage($pageKey); if ($page) { echo ''; diff --git a/bl-kernel/admin/views/dashboard.php b/bl-kernel/admin/views/dashboard.php index ec53cc4c..bc4e2ba6 100644 --- a/bl-kernel/admin/views/dashboard.php +++ b/bl-kernel/admin/views/dashboard.php @@ -114,11 +114,11 @@ p('Published') ?> - getPublishedDB()) ?> + getPublishedDB(false)) ?> p('Static') ?> - getStaticDB()) ?> + getStaticDB(false)) ?> p('Users') ?> count() ?> @@ -135,12 +135,11 @@

p('Scheduled content') ?>