forked from ZwiiCMS-Team/ZwiiCampus
News 5.3 voir CMS
This commit is contained in:
parent
d64ffa02c7
commit
caf00c0d41
@ -1,3 +1,5 @@
|
|||||||
|
# Version 5.3
|
||||||
|
- Option d'un lien de retour dans la signature
|
||||||
# Version 5.2
|
# Version 5.2
|
||||||
- Termes des commandes de profils
|
- Termes des commandes de profils
|
||||||
# Version 5.1
|
# Version 5.1
|
||||||
@ -24,5 +26,3 @@
|
|||||||
- Ecran layout réservé à la configuration et au thème
|
- Ecran layout réservé à la configuration et au thème
|
||||||
- Bug avec l'initialisation, fichier css déclaré mais absent
|
- Bug avec l'initialisation, fichier css déclaré mais absent
|
||||||
- Appel de la feuille style si présente
|
- Appel de la feuille style si présente
|
||||||
|
|
||||||
A faire partie CSS à amléiorer au niveau des options
|
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
class news extends common
|
class news extends common
|
||||||
{
|
{
|
||||||
|
|
||||||
const VERSION = '5.2';
|
const VERSION = '5.3';
|
||||||
const REALNAME = 'News';
|
const REALNAME = 'News';
|
||||||
const DATADIRECTORY = self::DATA_DIR . 'news/';
|
const DATADIRECTORY = self::DATA_DIR . 'news/';
|
||||||
|
|
||||||
@ -308,7 +308,8 @@ class news extends common
|
|||||||
'height' => $this->getInput('newsOptionHeight', helper::FILTER_INT, true),
|
'height' => $this->getInput('newsOptionHeight', helper::FILTER_INT, true),
|
||||||
'dateFormat' => $this->getInput('newsOptionDateFormat'),
|
'dateFormat' => $this->getInput('newsOptionDateFormat'),
|
||||||
'timeFormat' => $this->getInput('newsOptionTimeFormat'),
|
'timeFormat' => $this->getInput('newsOptionTimeFormat'),
|
||||||
'versionData' => $this->getData(['module', $this->getUrl(0), 'config', 'versionData'])
|
'buttonBack' => $this->getInput('newsOptionButtonBack'),
|
||||||
|
'versionData' => $this->getData(['module', $this->getUrl(0), 'config', 'versionData']),
|
||||||
]
|
]
|
||||||
]);
|
]);
|
||||||
|
|
||||||
@ -593,13 +594,19 @@ class news extends common
|
|||||||
// Mettre à jour la version
|
// Mettre à jour la version
|
||||||
$this->setData(['module', $this->getUrl(0), 'config', 'versionData', '3.4']);
|
$this->setData(['module', $this->getUrl(0), 'config', 'versionData', '3.4']);
|
||||||
}
|
}
|
||||||
// Mise à jour 3.4
|
// Mise à jour 4.4
|
||||||
if (version_compare($versionData, '4.4', '<')) {
|
if (version_compare($versionData, '4.4', '<')) {
|
||||||
$this->setData(['module', $this->getUrl(0), 'config', 'dateFormat', '%d %B %Y']);
|
$this->setData(['module', $this->getUrl(0), 'config', 'dateFormat', '%d %B %Y']);
|
||||||
$this->setData(['module', $this->getUrl(0), 'config', 'timeFormat', '%H:%M']);
|
$this->setData(['module', $this->getUrl(0), 'config', 'timeFormat', '%H:%M']);
|
||||||
// Mettre à jour la version
|
// Mettre à jour la version
|
||||||
$this->setData(['module', $this->getUrl(0), 'config', 'versionData', '4.4']);
|
$this->setData(['module', $this->getUrl(0), 'config', 'versionData', '4.4']);
|
||||||
}
|
}
|
||||||
|
// Mise à jour 5.3
|
||||||
|
if (version_compare($versionData, '5.3', '<')) {
|
||||||
|
$this->setData(['module', $this->getUrl(0), 'config', 'buttonBack', true]);
|
||||||
|
// Mettre à jour la version
|
||||||
|
$this->setData(['module', $this->getUrl(0), 'config', 'versionData', '5.3']);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
<?php
|
<?php
|
||||||
class init extends news {
|
class init extends news {
|
||||||
public static $defaultData = [
|
public static $defaultData = [
|
||||||
'feeds' => false,
|
'feeds' => true,
|
||||||
'feedsLabel' => '',
|
'feedsLabel' => 'RSS',
|
||||||
'itemsperPage' => 8,
|
'itemsperPage' => 8,
|
||||||
'itemsperCol' => 12,
|
'itemsperCol' => 12,
|
||||||
'height' => -1,
|
'height' => -1,
|
||||||
'versionData' => '3.5',
|
'versionData' => '5.3',
|
||||||
'dateFormat' => '%d %B %Y',
|
'dateFormat' => '%d %B %Y',
|
||||||
'timeFormat' =>'%H:%M',
|
'timeFormat' =>'%H:%M',
|
||||||
|
'buttonBack' => true
|
||||||
];
|
];
|
||||||
|
|
||||||
public static $defaultTheme = [
|
public static $defaultTheme = [
|
||||||
@ -16,7 +17,8 @@ class init extends news {
|
|||||||
'borderStyle' => 'none',
|
'borderStyle' => 'none',
|
||||||
'borderColor' => 'rgba(33, 34, 35, 1)',
|
'borderColor' => 'rgba(33, 34, 35, 1)',
|
||||||
'backgroundColor' => 'rgba(255, 255, 255, 1)',
|
'backgroundColor' => 'rgba(255, 255, 255, 1)',
|
||||||
'borderWidth' => '0'
|
'borderWidth' => '0',
|
||||||
|
'itemsBlur' => '0%'
|
||||||
];
|
];
|
||||||
|
|
||||||
}
|
}
|
0
module/news/ressource/feed-icon-16.gif
Normal file → Executable file
0
module/news/ressource/feed-icon-16.gif
Normal file → Executable file
Before Width: | Height: | Size: 652 B After Width: | Height: | Size: 652 B |
0
module/news/vendor/FeedWriter/README.md
vendored
Normal file → Executable file
0
module/news/vendor/FeedWriter/README.md
vendored
Normal file → Executable file
0
module/news/view/add/add.css
Normal file → Executable file
0
module/news/view/add/add.css
Normal file → Executable file
@ -4,7 +4,14 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row verticalAlignMiddle">
|
<div class="row verticalAlignMiddle">
|
||||||
<div class="col12 newsDate">
|
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'buttonBack'])): ?>
|
||||||
|
<div class="col6 textAlignLeft">
|
||||||
|
<a href="<?php echo helper::baseUrl() . $this->getUrl(0); ?>">
|
||||||
|
<?php echo template::ico('left') . helper::translate('Retour'); ?>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
|
<div class="col6 newsDate textAlignRight">
|
||||||
<!-- bloc signature et date -->
|
<!-- bloc signature et date -->
|
||||||
<?php echo template::ico('user'); ?>
|
<?php echo template::ico('user'); ?>
|
||||||
<?php echo $module::$articleSignature . ' - '; ?>
|
<?php echo $module::$articleSignature . ' - '; ?>
|
||||||
@ -13,7 +20,7 @@
|
|||||||
<!-- Bloc edition -->
|
<!-- Bloc edition -->
|
||||||
<?php if (
|
<?php if (
|
||||||
$this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')
|
$this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')
|
||||||
AND
|
and
|
||||||
( // Propriétaire
|
( // Propriétaire
|
||||||
($this->getUser('group') === self::GROUP_ADMIN)
|
($this->getUser('group') === self::GROUP_ADMIN)
|
||||||
)
|
)
|
||||||
@ -25,7 +32,8 @@
|
|||||||
<!-- Bloc RSS-->
|
<!-- Bloc RSS-->
|
||||||
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'feeds'])): ?>
|
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'feeds'])): ?>
|
||||||
<div id="rssFeed">
|
<div id="rssFeed">
|
||||||
<a type="application/rss+xml" href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/rss'; ?>" target="_blank">
|
<a type="application/rss+xml" href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/rss'; ?>"
|
||||||
|
target="_blank">
|
||||||
<img src='module/news/ressource/feed-icon-16.gif' />
|
<img src='module/news/ressource/feed-icon-16.gif' />
|
||||||
<?php
|
<?php
|
||||||
echo '<p>' . $this->getData(['module', $this->getUrl(0), 'config', 'feedsLabel']) . '</p>';
|
echo '<p>' . $this->getData(['module', $this->getUrl(0), 'config', 'feedsLabel']) . '</p>';
|
||||||
|
0
module/news/view/config/config.css
Normal file → Executable file
0
module/news/view/config/config.css
Normal file → Executable file
0
module/news/view/index/index.css
Normal file → Executable file
0
module/news/view/index/index.css
Normal file → Executable file
@ -46,7 +46,6 @@
|
|||||||
&& strlen($this->getData(['module', $this->getUrl(0), 'posts', $newsId, 'content'])) >= $this->getData(['module', $this->getUrl(0), 'config', 'height'])
|
&& strlen($this->getData(['module', $this->getUrl(0), 'posts', $newsId, 'content'])) >= $this->getData(['module', $this->getUrl(0), 'config', 'height'])
|
||||||
): ?>
|
): ?>
|
||||||
<?php echo ' ... <a href="' . helper::baseUrl(true) . $this->getUrl(0) . '/' . $newsId . '"><span class="newsSuite">lire la suite</span></a>'; ?>
|
<?php echo ' ... <a href="' . helper::baseUrl(true) . $this->getUrl(0) . '/' . $newsId . '"><span class="newsSuite">lire la suite</span></a>'; ?>
|
||||||
|
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -48,12 +48,17 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col6">
|
<div class="col3">
|
||||||
<?php echo template::checkbox('newsOptionShowFeeds', true, 'Lien du flux RSS', [
|
<?php echo template::checkbox('newsOptionShowFeeds', true, 'Lien du flux RSS', [
|
||||||
'checked' => $this->getData(['module', $this->getUrl(0), 'config', 'feeds']),
|
'checked' => $this->getData(['module', $this->getUrl(0), 'config', 'feeds']),
|
||||||
'help' => 'Flux limité aux articles de la première page.'
|
'help' => 'Flux limité aux articles de la première page.'
|
||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="col3">
|
||||||
|
<?php echo template::checkbox('newsOptionButtonBack', true, 'Bouton de retour', [
|
||||||
|
'checked' => $this->getData(['module', $this->getUrl(0), 'config', 'buttonBack'])
|
||||||
|
]); ?>
|
||||||
|
</div>
|
||||||
<div class="col6">
|
<div class="col6">
|
||||||
<?php echo template::text('newsOptionFeedslabel', [
|
<?php echo template::text('newsOptionFeedslabel', [
|
||||||
'label' => 'Etiquette RSS',
|
'label' => 'Etiquette RSS',
|
||||||
|
Loading…
Reference in New Issue
Block a user