Merge branch '12300' into 12400
This commit is contained in:
commit
b2c25db925
@ -3162,12 +3162,6 @@ class core extends common
|
|||||||
'style' => file_get_contents($stylePath)
|
'style' => file_get_contents($stylePath)
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
if ($output['style']) {
|
|
||||||
$this->addOutput([
|
|
||||||
//'style' => $this->output['style'] . file_get_contents($output['style'])
|
|
||||||
'style' => file_get_contents($output['style'])
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
|
|
||||||
// JS
|
// JS
|
||||||
$scriptPath = $modulePath . self::MODULE_DIR . $moduleId . '/view/' . $output['view'] . '/' . $output['view'] . '.js.php';
|
$scriptPath = $modulePath . self::MODULE_DIR . $moduleId . '/view/' . $output['view'] . '/' . $output['view'] . '.js.php';
|
||||||
|
@ -1,4 +1,14 @@
|
|||||||
<?php if ($module::$articles) : ?>
|
<?php if ($module::$articles) : ?>
|
||||||
|
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'feeds'])) : ?>
|
||||||
|
<div id="rssFeed">
|
||||||
|
<a type="application/rss+xml" href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/rss'; ?>" target="_blank">
|
||||||
|
<img src='module/blog/ressource/feed-icon-16.gif' />
|
||||||
|
<?php
|
||||||
|
echo $this->getData(['module', $this->getUrl(0), 'config', 'feedsLabel']) ? '<p>' . $this->getData(['module', $this->getUrl(0), 'config', 'feedsLabel']) . '</p>' : '';
|
||||||
|
?>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
<article>
|
<article>
|
||||||
<?php foreach ($module::$articles as $articleId => $article) : ?>
|
<?php foreach ($module::$articles as $articleId => $article) : ?>
|
||||||
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'articlesLenght']) === 0) : ?>
|
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'articlesLenght']) === 0) : ?>
|
||||||
@ -143,16 +153,6 @@
|
|||||||
<?php endforeach; ?>
|
<?php endforeach; ?>
|
||||||
</article>
|
</article>
|
||||||
<?php echo $module::$pages; ?>
|
<?php echo $module::$pages; ?>
|
||||||
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'feeds'])) : ?>
|
|
||||||
<div id="rssFeed">
|
|
||||||
<a type="application/rss+xml" href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/rss'; ?>" target="_blank">
|
|
||||||
<img src='module/blog/ressource/feed-icon-16.gif' />
|
|
||||||
<?php
|
|
||||||
echo '<p>' . $this->getData(['module', $this->getUrl(0), 'config', 'feedsLabel']) . '</p>';
|
|
||||||
?>
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
<?php endif; ?>
|
|
||||||
<?php else : ?>
|
<?php else : ?>
|
||||||
<?php echo template::speech('Aucun article'); ?>
|
<?php echo template::speech('Aucun article'); ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
@ -1,6 +1,7 @@
|
|||||||
# Version 4.4
|
# Version 4.4
|
||||||
- Intl date Formats
|
- Intl date Formats
|
||||||
- Modification liées à la suppression de flatpickr
|
- Bug un conflit avec le style de la page
|
||||||
|
- Modifications liées à la suppression de flatpickr
|
||||||
# Version 4.3
|
# Version 4.3
|
||||||
- Multilinguisme
|
- Multilinguisme
|
||||||
# Version 4.23
|
# Version 4.23
|
||||||
|
@ -266,8 +266,7 @@ class news extends common
|
|||||||
|
|
||||||
// Générer la feuille de CSS
|
// Générer la feuille de CSS
|
||||||
$style = '.newsFrame {';
|
$style = '.newsFrame {';
|
||||||
$style .= 'border-right:' . $this->getInput('newsThemeBorderStyle', helper::FILTER_STRING_SHORT) . ' ' . $this->getInput('newsThemeBorderColor') . ' ' . $this->getInput('newsThemeBorderWidth', helper::FILTER_STRING_SHORT) . ';';
|
$style .= 'border:' . $this->getInput('newsThemeBorderStyle', helper::FILTER_STRING_SHORT) . ' ' . $this->getInput('newsThemeBorderColor') . ' ' . $this->getInput('newsThemeBorderWidth', helper::FILTER_STRING_SHORT) . ';';
|
||||||
$style .= 'border-left:' . $this->getInput('newsThemeBorderStyle', helper::FILTER_STRING_SHORT) . ' ' . $this->getInput('newsThemeBorderColor') . ' ' . $this->getInput('newsThemeBorderWidth', helper::FILTER_STRING_SHORT) . ';';
|
|
||||||
$style .= 'background-color:' . $this->getInput('newsThemeBackgroundColor') . ';';
|
$style .= 'background-color:' . $this->getInput('newsThemeBackgroundColor') . ';';
|
||||||
$style .= '}';
|
$style .= '}';
|
||||||
|
|
||||||
@ -546,9 +545,6 @@ class news extends common
|
|||||||
'showBarEditButton' => true,
|
'showBarEditButton' => true,
|
||||||
'showPageContent' => true,
|
'showPageContent' => true,
|
||||||
'view' => 'index',
|
'view' => 'index',
|
||||||
'style' => file_exists($this->getData(['module', $this->getUrl(0), 'theme', 'style']))
|
|
||||||
? $this->getData(['module', $this->getUrl(0), 'theme', 'style'])
|
|
||||||
: ''
|
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,14 +13,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Module news
|
* Module news TRUC
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
|
||||||
.newsTitle {
|
|
||||||
background-color: #ECEFF1;
|
|
||||||
padding:5px;
|
|
||||||
}*/
|
|
||||||
.newsContent {
|
.newsContent {
|
||||||
overflow: hidden; /* les dépassements seront masqués */
|
overflow: hidden; /* les dépassements seront masqués */
|
||||||
position: relative;
|
position: relative;
|
||||||
@ -51,5 +46,3 @@
|
|||||||
display: inline;
|
display: inline;
|
||||||
vertical-align: top;
|
vertical-align: top;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,54 +1,60 @@
|
|||||||
<?php if ($module::$news) : ?>
|
<?php if ($module::$news): ?>
|
||||||
<article>
|
<link rel="stylesheet" type="text/css" href="<?php echo helper::baseUrl(false) . $this->getData(['module', $this->getUrl(0), 'theme', 'style']);?> "/>
|
||||||
<div class="row">
|
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'feeds'])): ?>
|
||||||
<?php foreach ($module::$news as $newsId => $news) : ?>
|
|
||||||
<div class="newsFrame col<?php echo $module::$nbrCol; ?>">
|
|
||||||
<h2 class="newsTitle" id="<?php echo $newsId; ?>">
|
|
||||||
<?php echo '<a href="' . helper::baseUrl(true) . $this->getUrl(0) . '/' . $newsId . '">' . $news['title'] . '</a>'; ?>
|
|
||||||
</h2>
|
|
||||||
<div class="newsSignature">
|
|
||||||
<?php echo template::ico('user'); ?>
|
|
||||||
<?php echo $news['userId']; ?>
|
|
||||||
<?php echo template::ico('calendar-empty'); ?>
|
|
||||||
<?php echo helper::dateUTF8($module::$dateFormat, $news['publishedOn']) . ' - ' . helper::dateUTF8($module::$timeFormat, $news['publishedOn']); ?>
|
|
||||||
<!-- Bloc edition -->
|
|
||||||
<?php if (
|
|
||||||
|
|
||||||
$this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')
|
|
||||||
and
|
|
||||||
( // Propriétaire
|
|
||||||
($this->getUser('group') === self::GROUP_ADMIN)
|
|
||||||
)
|
|
||||||
) : ?>
|
|
||||||
<a href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/edit/' . $newsId . '/' . $_SESSION['csrf']; ?>">
|
|
||||||
<?php echo template::ico('pencil'); ?> Éditer
|
|
||||||
</a>
|
|
||||||
<?php endif; ?>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="newsContent">
|
|
||||||
<?php echo $news['content']; ?>
|
|
||||||
<?php if (
|
|
||||||
$this->getData(['module', $this->getUrl(0), 'config', 'height']) !== -1
|
|
||||||
&& 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 endif; ?>
|
|
||||||
</div>
|
|
||||||
<?php endforeach; ?>
|
|
||||||
</div>
|
|
||||||
</article>
|
|
||||||
<?php echo $module::$pages; ?>
|
|
||||||
<?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 $this->getData(['module', $this->getUrl(0), 'config', 'feedsLabel']) ? '<p>' . $this->getData(['module', $this->getUrl(0), 'config', 'feedsLabel']) . '</p>' : '';
|
||||||
?>
|
?>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php else : ?>
|
<article>
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
<?php foreach ($module::$news as $newsId => $news): ?>
|
||||||
|
<div class="col<?php echo $module::$nbrCol; ?>">
|
||||||
|
<div class="newsFrame">
|
||||||
|
<h2 class="newsTitle" id="<?php echo $newsId; ?>">
|
||||||
|
<?php echo '<a href="' . helper::baseUrl(true) . $this->getUrl(0) . '/' . $newsId . '">' . $news['title'] . '</a>'; ?>
|
||||||
|
</h2>
|
||||||
|
<div class="newsSignature">
|
||||||
|
<?php echo template::ico('user'); ?>
|
||||||
|
<?php echo $news['userId']; ?>
|
||||||
|
<?php echo template::ico('calendar-empty'); ?>
|
||||||
|
<?php echo helper::dateUTF8($module::$dateFormat, $news['publishedOn']) . ' - ' . helper::dateUTF8($module::$timeFormat, $news['publishedOn']); ?>
|
||||||
|
<!-- Bloc edition -->
|
||||||
|
<?php if (
|
||||||
|
|
||||||
|
$this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')
|
||||||
|
and
|
||||||
|
( // Propriétaire
|
||||||
|
($this->getUser('group') === self::GROUP_ADMIN)
|
||||||
|
)
|
||||||
|
): ?>
|
||||||
|
<a
|
||||||
|
href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/edit/' . $newsId . '/' . $_SESSION['csrf']; ?>">
|
||||||
|
<?php echo template::ico('pencil'); ?> Éditer
|
||||||
|
</a>
|
||||||
|
<?php endif; ?>
|
||||||
|
</div>
|
||||||
|
<div class="newsContent">
|
||||||
|
<?php echo $news['content']; ?>
|
||||||
|
<?php if (
|
||||||
|
$this->getData(['module', $this->getUrl(0), 'config', 'height']) !== -1
|
||||||
|
&& 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 endif; ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<?php endforeach; ?>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
<?php echo $module::$pages; ?>
|
||||||
|
<?php else: ?>
|
||||||
<?php echo template::speech('Aucune news'); ?>
|
<?php echo template::speech('Aucune news'); ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
Loading…
Reference in New Issue
Block a user