v44 format de l'historique
This commit is contained in:
parent
44856c03c6
commit
b88e99e31d
@ -50,7 +50,7 @@ class common
|
||||
const ACCESS_TIMER = 1800;
|
||||
|
||||
// Numéro de version
|
||||
const ZWII_VERSION = '1.0.43';
|
||||
const ZWII_VERSION = '1.0.44';
|
||||
|
||||
// URL autoupdate
|
||||
const ZWII_UPDATE_URL = 'https://forge.chapril.org/ZwiiCMS-Team/update/raw/branch/master/lms/';
|
||||
|
@ -672,10 +672,11 @@ class course extends common
|
||||
$courseId = $this->getUrl(2);
|
||||
$userId = $this->getUrl(3);
|
||||
$history = $this->getData(['enrolment', $courseId, $userId]);
|
||||
$pages = json_decode(file_get_contents(self::DATA_DIR . $courseId . '/page.json'), true);
|
||||
foreach ($history['history'] as $pageId => $time) {
|
||||
self::$userHistory[$pageId] = [
|
||||
helper::dateUTF8('%d %B %Y - %H:%M:%S', $time),
|
||||
$this->getData(['page', $pageId, 'shortTitle']),
|
||||
$pages['page'][$pageId]['shortTitle'],
|
||||
];
|
||||
}
|
||||
|
||||
|
@ -15,6 +15,10 @@ $(document).ready((function () {
|
||||
$('#dataTables').DataTable({
|
||||
language: {
|
||||
url: "core/vendor/datatables/french.json"
|
||||
}
|
||||
},
|
||||
searching: false,
|
||||
pageLength: 100,
|
||||
lengthChange: false,
|
||||
paging: false
|
||||
});
|
||||
}));
|
@ -8,7 +8,11 @@
|
||||
</div>
|
||||
</div>
|
||||
<?php if ($module::$userHistory): ?>
|
||||
<?php echo template::table([6, 6], $module::$userHistory, ['Page', 'Dernière consultation de cette page'], ['id' => 'dataTables']); ?>
|
||||
<div class="row textAlignCenter">
|
||||
<div class="col8">
|
||||
<?php echo template::table([6, 6], $module::$userHistory, ['Dernière consultation de cette page', 'Titre de la page'], ['id' => 'dataTables']); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php else: ?>
|
||||
<?php echo template::speech('Aucun historique'); ?>
|
||||
<?php endif; ?>
|
Loading…
Reference in New Issue
Block a user