Compare commits

...

2 Commits

Author SHA1 Message Date
Jean-Christian Paul Denis a4111065bb
release 1.1 2023-08-13 18:17:44 +02:00
Jean-Christian Paul Denis 7b12fb3087
upgrade to Dotclear 2.27 2023-08-13 18:17:07 +02:00
7 changed files with 106 additions and 70 deletions

View File

@ -1,41 +1,60 @@
1.0 - 2023.04.23
- require dotclear 2.26
- use latest dotclear namespace
- remove all the magic
postInfoWidget 1.1 - 2023.08.13
===========================================================
* Require Dotclear 2.27
* Require PHP 7.4
* Upgrade to Dotclear 2.27
* Move third party repository
* Use Dotclear style for CHANGELOG
0.9 - 2023.03.21
- require Dotclear 2.25
- use namespace
postInfoWidget 1.0 - 2023.04.23
===========================================================
* require dotclear 2.26
* use latest dotclear namespace
* remove all the magic
0.8 - 2022.11.20
- fix compatibility with Dotclear 2.24 (required)
postInfoWidget 0.9 - 2023.03.21
===========================================================
* require Dotclear 2.25
* use namespace
0.7 - 2021.09.17
- clean up and cosmetics
postInfoWidget 0.8 - 2022.11.20
===========================================================
* fix compatibility with Dotclear 2.24 (required)
0.6 - 2021.08.27
- cleanup (PSR2, short array, ...)
- update license
postInfoWidget 0.7 - 2021.09.17
===========================================================
* clean up and cosmetics
0.5.1 - 2015.04.23 - Pierre Van Glabeke
- modif url support
postInfoWidget 0.6 - 2021.08.27
===========================================================
* cleanup (PSR2, short array, ...)
* update license
0.5 - 2015-01-29 - Pierre Van Glabeke
- ajout case hors ligne
- modif localisation
- fin de ligne unix (LF)
postInfoWidget 0.5.1 - 2015.04.23 - Pierre Van Glabeke
===========================================================
* modif url support
0.4 - 2013.11.12
- Switch to Dotclear 2.6
- Clean up code
- Add widget options
postInfoWidget 0.5 - 2015-01-29 - Pierre Van Glabeke
===========================================================
* ajout case hors ligne
* modif localisation
* fin de ligne unix (LF)
0.3 - 2010.06.21
- Fixed tags list
- Fixed nav links
postInfoWidget 0.4 - 2013.11.12
===========================================================
* Switch to Dotclear 2.6
* Clean up code
* Add widget options
0.2 - 2010.06.05
- Switched to DC 2.2
postInfoWidget 0.3 - 2010.06.21
===========================================================
* Fixed tags list
* Fixed nav links
0.1 - 2010.05.24
- First lab release
postInfoWidget 0.2 - 2010.06.05
===========================================================
* Switched to DC 2.2
postInfoWidget 0.1 - 2010.05.24
===========================================================
* First lab release

View File

@ -1,11 +1,10 @@
# README
[![Release](https://img.shields.io/github/v/release/JcDenis/postInfoWidget)](https://github.com/JcDenis/postInfoWidget/releases)
[![Date](https://img.shields.io/github/release-date/JcDenis/postInfoWidget)](https://github.com/JcDenis/postInfoWidget/releases)
[![Issues](https://img.shields.io/github/issues/JcDenis/postInfoWidget)](https://github.com/JcDenis/postInfoWidget/issues)
[![Dotclear](https://img.shields.io/badge/dotclear-v2.26-blue.svg)](https://fr.dotclear.org/download)
[![Dotaddict](https://img.shields.io/badge/dotaddict-official-green.svg)](https://plugins.dotaddict.org/dc2/details/postInfoWidget)
[![License](https://img.shields.io/github/license/JcDenis/postInfoWidget)](https://github.com/JcDenis/postInfoWidget/blob/master/LICENSE)
[![Release](https://img.shields.io/badge/release-1.1-a2cbe9.svg)](https://git.dotclear.watch/JcDenis/postInfoWidget/releases)
[![Date](https://img.shields.io/badge/date-2023.08.13-c44d58.svg)](https://git.dotclear.watch/JcDenis/postInfoWidget/releases)
[![Dotclear](https://img.shields.io/badge/dotclear-v2.27-137bbb.svg)](https://fr.dotclear.org/download)
[![Dotaddict](https://img.shields.io/badge/dotaddict-official-9ac123.svg)](https://plugins.dotaddict.org/dc2/details/postInfoWidget)
[![License](https://img.shields.io/github/license/JcDenis/postInfoWidget)](https://git.dotclear.watch/JcDenis/postInfoWidget/blob/master/LICENSE)
## WHAT IS POSTINFOWIDGET ?
@ -16,10 +15,11 @@ Show entry details in a widget.
## REQUIREMENTS
_postInfoWidget_ requires:
_postInfoWidget_ requires:
* permissions to manage widgets
* Dotclear 2.26
* permissions to manage widgets
* Dotclear 2.26
* PHP 7.4
## USAGE
@ -30,14 +30,14 @@ Add and configure "Entry information list" from widgets manager.
## LINKS
* License : [GNU GPL v2](https://www.gnu.org/licenses/old-licenses/lgpl-2.0.html)
* Source & contribution : [GitHub Page](https://github.com/JcDenis/postInfoWidget)
* Packages & details : [Dotaddict Page](https://plugins.dotaddict.org/dc2/details/postInfoWidget)
* Discuss and help : [Dotclear Forum](http://forum.dotclear.org/viewtopic.php?pid=332974#p332974)
* License : [GNU GPL v2](https://www.gnu.org/licenses/old-licenses/lgpl-2.0.html)
* Source & contribution : [Gitea Page](https://git.dotclear.watch/JcDenis/postInfoWidget) or [GitHub Page](https://github.com/JcDenis/postInfoWidget)
* Packages & details: [Gitea Page](https://git.dotclear.watch/JcDenis/postInfoWidget/releases) or [Dotaddict Page](https://plugins.dotaddict.org/dc2/details/postInfoWidget)
* Discuss and help : [Dotclear Forum](http://forum.dotclear.org/viewtopic.php?pid=332974#p332974)
## CONTRIBUTORS
* Jean-Christian Denis
* Pierre Van Glabeke
* Jean-Christian Denis
* Pierre Van Glabeke
You are welcome to contribute to this code.
You are welcome to contribute to this code.

View File

@ -10,7 +10,7 @@
* @copyright Jean-Christian Denis
* @copyright GPL-2.0 https://www.gnu.org/licenses/gpl-2.0.html
*/
if (!defined('DC_RC_PATH') || is_null(dcCore::app()->auth)) {
if (!defined('DC_RC_PATH')) {
return null;
}
@ -18,16 +18,16 @@ $this->registerModule(
'Entry information list',
'Show Entry informations on a widget',
'Jean-Christian Denis, Pierre Van Glabeke',
'1.0',
'1.1',
[
'requires' => [['core', '2.26']],
'requires' => [['core', '2.27']],
'permissions' => dcCore::app()->auth->makePermissions([
dcAuth::PERMISSION_USAGE,
dcAuth::PERMISSION_CONTENT_ADMIN,
]),
'type' => 'plugin',
'support' => 'http://forum.dotclear.org/viewtopic.php?pid=332974#p332974',
'details' => 'http://plugins.dotaddict.org/dc2/details/postInfoWidget',
'repository' => 'https://raw.githubusercontent.com/JcDenis/postInfoWidget/master/dcstore.xml',
'support' => 'https://git.dotclear.watch/JcDenis/' . basename(__DIR__) . '/issues',
'details' => 'https://git.dotclear.watch/JcDenis/' . basename(__DIR__) . '/src/branch/master/README.md',
'repository' => 'https://git.dotclear.watch/JcDenis/' . basename(__DIR__) . '/raw/branch/master/dcstore.xml',
]
);

View File

@ -2,12 +2,12 @@
<modules xmlns:da="http://dotaddict.org/da/">
<module id="postInfoWidget">
<name>Entry information list</name>
<version>1.0</version>
<version>1.1</version>
<author>Jean-Christian Denis, Pierre Van Glabeke</author>
<desc>Show Entry informations on a widget</desc>
<file>https://github.com/JcDenis/postInfoWidget/releases/download/v1.0/plugin-postInfoWidget.zip</file>
<da:dcmin>2.26</da:dcmin>
<da:details>http://plugins.dotaddict.org/dc2/details/postInfoWidget</da:details>
<da:support>http://forum.dotclear.org/viewtopic.php?pid=332974#p332974</da:support>
<file>https://git.dotclear.watch/JcDenis/postInfoWidget/releases/download/v1.1/plugin-postInfoWidget.zip</file>
<da:dcmin>2.27</da:dcmin>
<da:details>https://git.dotclear.watch/JcDenis/postInfoWidget/src/branch/master/README.md</da:details>
<da:support>https://git.dotclear.watch/JcDenis/postInfoWidget/issues</da:support>
</module>
</modules>

View File

@ -15,20 +15,18 @@ declare(strict_types=1);
namespace Dotclear\Plugin\postInfoWidget;
use dcCore;
use dcNsProcess;
use Dotclear\Core\Process;
class Backend extends dcNsProcess
class Backend extends Process
{
public static function init(): bool
{
static::$init = defined('DC_CONTEXT_ADMIN');
return static::$init;
return self::status(My::checkContext(My::BACKEND));
}
public static function process(): bool
{
if (!static::$init) {
if (!self::status()) {
return false;
}

View File

@ -15,20 +15,18 @@ declare(strict_types=1);
namespace Dotclear\Plugin\postInfoWidget;
use dcCore;
use dcNsProcess;
use Dotclear\Core\Process;
class Frontend extends dcNsProcess
class Frontend extends Process
{
public static function init(): bool
{
static::$init = true;
return static::$init;
return self::status(My::checkContext(My::FRONTEND));
}
public static function process(): bool
{
if (!static::$init) {
if (!self::status()) {
return false;
}

21
src/My.php 100644
View File

@ -0,0 +1,21 @@
<?php
/**
* @brief postInfoWidget, a plugin for Dotclear 2
*
* @package Dotclear
* @subpackage Plugin
*
* @author Jean-Christian Denis, Pierre Van Glabeke
*
* @copyright Jean-Christian Denis
* @copyright GPL-2.0 https://www.gnu.org/licenses/gpl-2.0.html
*/
declare(strict_types=1);
namespace Dotclear\Plugin\postInfoWidget;
use Dotclear\Module\MyPlugin;
class My extends MyPlugin
{
}