diff --git a/module/download/download.php b/module/download/download.php
index 730607ca..63ee2d6a 100644
--- a/module/download/download.php
+++ b/module/download/download.php
@@ -14,7 +14,7 @@
class download extends common {
- const VERSION = '2.2';
+ const VERSION = '2.4';
const REALNAME = 'Téléchargement';
const DELETE = true;
const UPDATE = '0.0';
@@ -946,11 +946,6 @@ class download extends common {
$this->addOutput([
'display' => self::DISPLAY_RAW
]);
- // Valeurs en sortie
- $this->addOutput([
- 'title' => 'Configuration',
- 'view' => 'index'
- ]);
} else {
// Valeurs en sortie
$this->addOutput([
diff --git a/module/download/view/edit/edit.php b/module/download/view/edit/edit.php
index 9d048b0f..62315fdb 100644
--- a/module/download/view/edit/edit.php
+++ b/module/download/view/edit/edit.php
@@ -64,7 +64,8 @@
'Catégorie'
+ 'label' => 'Catégorie',
+ 'selected' => $this->getData(['module', $this->getUrl(0), 'items', $this->getUrl(2), 'category'])
]);
} else {
echo template::select('downloadEditCategorie', [''=>''], [
diff --git a/module/download/view/item/item.js.php b/module/download/view/item/item.js.php
index cb07dcd2..33bc0c81 100644
--- a/module/download/view/item/item.js.php
+++ b/module/download/view/item/item.js.php
@@ -10,6 +10,13 @@
* @link http://zwiicms.fr/
*/
+/**
+ * Incrément les stats
+ */
+ $('#downloadItemFile').click(function() {
+ $('#downloadStats').html(function(i, val) { return val*1+1 });
+});
+
/**
* Affiche le bloc pour rédiger un commentaire
*/
diff --git a/module/download/view/item/item.php b/module/download/view/item/item.php
index 97c06af5..acf7c575 100644
--- a/module/download/view/item/item.php
+++ b/module/download/view/item/item.php
@@ -20,19 +20,17 @@
switch ($this->getData(['module', $this->getUrl(0), 'items', $this->getUrl(1), 'ressourceType'])) {
case 'file':
$href = helper::baseUrl() . $this->getUrl(0) . '/downloadFile/' . $this->getUrl(1) . '/' . $_SESSION['csrf'];
- $value = 'Télécharger';
$target = '_self';
break;
case 'url' :
$href = $this->getData(['module', $this->getUrl(0), 'items', $this->getUrl(1), 'url']);
- $value = 'Visiter';
$target = '_blank';
break;
}
?>
$href,
- 'value' => $value,
+ 'value' => 'Télécharger',
'target'=> $target
]);
?>
@@ -74,9 +72,7 @@
getData(['module', $this->getUrl(0), 'items', $this->getUrl(1), 'file'])): ?>
- Téléchargements :
-
-
+ Téléchargements : '?>