-
Контакт с автором
+
@tsymbalmitia (telegram)
|
quantum@hika.su (email)
diff --git a/administrator/components/com_quantummanager/views/quantummanager/tmpl/default.php b/administrator/components/com_quantummanager/views/quantummanager/tmpl/default.php
index ca37bbb..555c0aa 100644
--- a/administrator/components/com_quantummanager/views/quantummanager/tmpl/default.php
+++ b/administrator/components/com_quantummanager/views/quantummanager/tmpl/default.php
@@ -30,8 +30,8 @@
'cssClass' => 'quantumtreecatalogs-module-muted'
],
'quantumupload' => [
- 'maxsize' => QuantummanagerHelper::getParamsComponentValue('maxsize'),
- 'dropAreaHidden' => 1,
+ 'maxsize' => QuantummanagerHelper::getParamsComponentValue('maxsize', '10'),
+ 'dropAreaHidden' => QuantummanagerHelper::getParamsComponentValue('dropareahidden', '0'),
'directory' => $folderRoot
],
'quantumtoolbar' => [
@@ -44,7 +44,7 @@
'directory' => $folderRoot,
'view' => 'list-grid',
'onlyfiles' => '0',
- 'metafile' => QuantummanagerHelper::getParamsComponentValue('metafile'),
+ 'metafile' => QuantummanagerHelper::getParamsComponentValue('metafile' , '1'),
],
'quantumcropperjs' => [
'position' => 'bottom'
diff --git a/administrator/components/com_quantummanager/views/quantummanager/tmpl/modal.php b/administrator/components/com_quantummanager/views/quantummanager/tmpl/modal.php
index 1680fa6..85bf52d 100644
--- a/administrator/components/com_quantummanager/views/quantummanager/tmpl/modal.php
+++ b/administrator/components/com_quantummanager/views/quantummanager/tmpl/modal.php
@@ -70,8 +70,8 @@
'cssClass' => 'quantumtreecatalogs-module-muted'
],
'quantumupload' => [
- 'maxsize' => QuantummanagerHelper::getParamsComponentValue('maxsize'),
- 'dropAreaHidden' => 1,
+ 'maxsize' => QuantummanagerHelper::getParamsComponentValue('maxsize', '10'),
+ 'dropAreaHidden' => QuantummanagerHelper::getParamsComponentValue('dropareahidden', '0'),
'directory' => $folderRoot
],
'quantumtoolbar' => [
@@ -84,7 +84,7 @@
'directory' => $folderRoot,
'view' => 'list-grid',
'onlyfiles' => '0',
- 'metafile' => QuantummanagerHelper::getParamsComponentValue('metafile'),
+ 'metafile' => QuantummanagerHelper::getParamsComponentValue('metafile', 1),
],
'quantumcropperjs' => [
'position' => 'bottom'
diff --git a/administrator/components/com_quantummanager/views/quantummanager/tmpl/window.php b/administrator/components/com_quantummanager/views/quantummanager/tmpl/window.php
index 529404f..7c37d57 100644
--- a/administrator/components/com_quantummanager/views/quantummanager/tmpl/window.php
+++ b/administrator/components/com_quantummanager/views/quantummanager/tmpl/window.php
@@ -41,8 +41,8 @@
'cssClass' => 'quantumtreecatalogs-module-muted'
],
'quantumupload' => [
- 'maxsize' => QuantummanagerHelper::getParamsComponentValue('maxsize'),
- 'dropAreaHidden' => 1,
+ 'maxsize' => QuantummanagerHelper::getParamsComponentValue('maxsize', '10'),
+ 'dropAreaHidden' => QuantummanagerHelper::getParamsComponentValue('dropareahidden', '0'),
'directory' => $folderRoot
],
'quantumtoolbar' => [
@@ -55,7 +55,7 @@
'directory' => $folderRoot,
'view' => 'list-grid',
'onlyfiles' => '0',
- 'metafile' => QuantummanagerHelper::getParamsComponentValue('metafile'),
+ 'metafile' => QuantummanagerHelper::getParamsComponentValue('metafile', '1'),
],
'quantumcropperjs' => [
'position' => 'bottom'
diff --git a/changelog.md b/changelog.md
index 182eebb..2f4c417 100644
--- a/changelog.md
+++ b/changelog.md
@@ -1,3 +1,11 @@
+1.1.4
+- исправление ошибки загрузки класса
+- теперь показывается метаинформация папок
+- исправление краха метаинфомрации
+- не был установлен по умолчанию параметр максимального размера загружаемых файлов
+- не показывались ошибки при загрузке файлов
+- добавлен параметр показа области загрузки
+
1.1.3
- метаинформация по умолчанию включена
- если картинка больше не выделена, то переключается метаинформация на следующую выбранную
diff --git a/media/com_quantummanager/css/main.css b/media/com_quantummanager/css/main.css
index fba04f7..e9725b4 100644
--- a/media/com_quantummanager/css/main.css
+++ b/media/com_quantummanager/css/main.css
@@ -89,7 +89,7 @@
flex-direction: column;
}
.quantummanager .quantummanager-container .quantummanager-center > div {
- width: 100%;
+ width: calc(100% - 15px);
}
.quantummanager .quantummanager-container .quantummanager-right {
width: 25%;
@@ -528,6 +528,9 @@
background: #fff;
z-index: 5;
}
+ .quantummanager .quantummanager-left ~ .quantummanager-center {
+ padding-left: 20px;
+ }
.quantummanager-left.open {
left: 0;
}
diff --git a/media/com_quantummanager/css/quantumviewfiles.css b/media/com_quantummanager/css/quantumviewfiles.css
index 8f4377b..1c73f3c 100644
--- a/media/com_quantummanager/css/quantumviewfiles.css
+++ b/media/com_quantummanager/css/quantumviewfiles.css
@@ -197,7 +197,7 @@
}
.quantumviewfiles-module .view {
position: relative;
- height: 100%;
+ height: auto;
width: 100%;
}
.quantumviewfiles-module .meta-file ~ .view {
@@ -254,6 +254,10 @@
border: solid 5px #EFEFEF;
border-radius: 5px;
}
+.quantumviewfiles-module .meta-file .meta-preview.meta-preview-folder img {
+ background-color: transparent;
+ border: none;
+}
.quantumviewfiles-module .meta-file table {
border-collapse: collapse;
border-spacing: 0;
diff --git a/media/com_quantummanager/images/icons/folder.svg b/media/com_quantummanager/images/icons/folder.svg
new file mode 100644
index 0000000..208ee99
--- /dev/null
+++ b/media/com_quantummanager/images/icons/folder.svg
@@ -0,0 +1,2 @@
+
+
diff --git a/media/com_quantummanager/js/quantumupload.js b/media/com_quantummanager/js/quantumupload.js
index e3d670a..134e625 100644
--- a/media/com_quantummanager/js/quantumupload.js
+++ b/media/com_quantummanager/js/quantumupload.js
@@ -9,6 +9,7 @@
window.Qantumupload = function(Filemanager, UploadElement, options) {
+ this.options = options;
this.dropAreaAll = [];
this.dropAreaAll = [];
this.inputFileAll = [];
@@ -120,11 +121,7 @@ window.Qantumupload = function(Filemanager, UploadElement, options) {
let file = files[i];
if((file.size / 1024 / 1024) > this.maxsize) {
-
- /*vex.dialog.alert({
- unsafeMessage: '
Файл ' + file.name + ' не должен превышать ' + maxsize + ' мегабайта.'
- });*/
-
+ alert(QuantumuploadLang.file + file.name + QuantumuploadLang.maxsize + this.maxsize + QuantumuploadLang.megabyte);
this.countFiles--;
if(this.countFiles === 0) {
@@ -137,11 +134,7 @@ window.Qantumupload = function(Filemanager, UploadElement, options) {
let currExs = file.name.split('.');
if(currExs.length === 1) {
-
- /*vex.dialog.alert({
- unsafeMessage: '
Файл ' + file.name + ' должен иметь расширение.'
- });*/
-
+ alert(QuantumuploadLang.file + file.name + QuantumuploadLang.exs);
this.countFiles--;
return false;
}
diff --git a/media/com_quantummanager/js/quantumviewfiles.js b/media/com_quantummanager/js/quantumviewfiles.js
index f22d785..a390633 100644
--- a/media/com_quantummanager/js/quantumviewfiles.js
+++ b/media/com_quantummanager/js/quantumviewfiles.js
@@ -22,6 +22,8 @@ window.Quantumviewfiles = function(Filemanager, ViewfilesElement, options) {
this.breadcrumbsLists = [];
this.breadcrumbsWaitLoad = false;
this.searchNameValue = '';
+ this.cacheMetaPath = '';
+ this.cacheMeta = '';
this.init = function() {
let self = this;
@@ -56,6 +58,13 @@ window.Quantumviewfiles = function(Filemanager, ViewfilesElement, options) {
});
Filemanager.Quantumtoolbar.buttonAdd('viewfilesUp', 'left', 'navigations', 'btn-up hidden-label', QuantumviewfilesLang.buttonUp, 'quantummanager-icon-up', {}, function (ev) {
+
+ if(Filemanager.data.path === undefined)
+ {
+ ev.preventDefault();
+ return;
+ }
+
let currDirectories = Filemanager.data.path.split('/');
if (currDirectories.length > 1) {
currDirectories.pop();
@@ -125,10 +134,16 @@ window.Quantumviewfiles = function(Filemanager, ViewfilesElement, options) {
ev.preventDefault();
});
- Filemanager.Quantumtoolbar.buttonAdd('viewfilesUploadFile', 'center', 'file-other', 'btn-upload-file hidden-label', QuantumviewfilesLang.buttonUpload, 'quantummanager-icon-upload', {}, function (ev) {
- Filemanager.Qantumupload.selectFiles();
- ev.preventDefault();
- });
+ if(Filemanager.Qantumupload !== undefined)
+ {
+ if(Filemanager.Qantumupload.options.dropAreaHidden === '1') {
+ Filemanager.Quantumtoolbar.buttonAdd('viewfilesUploadFile', 'center', 'file-other', 'btn-upload-file hidden-label', QuantumviewfilesLang.buttonUpload, 'quantummanager-icon-upload', {}, function (ev) {
+ Filemanager.Qantumupload.selectFiles();
+ ev.preventDefault();
+ });
+ }
+ }
+
}
@@ -207,6 +222,11 @@ window.Quantumviewfiles = function(Filemanager, ViewfilesElement, options) {
let prevent = false;
for(let i=0;i
" + QuantumviewfilesLang.loading + " ";
};
- this.hideMetaFile = function () {
+ this.hideMeta = function () {
let self = this;
if(self.options.metafile === '1') {
@@ -369,6 +392,94 @@ window.Quantumviewfiles = function(Filemanager, ViewfilesElement, options) {
}
};
+ this.showMetaDirectory = function (cacheReset) {
+ let self = this;
+
+ if(self.options.metafile === '1') {
+
+ if(cacheReset === null || cacheReset === undefined || cacheReset === false) {
+ if(self.path === self.cacheMetaPath)
+ {
+ self.viewMeta.querySelector('.meta-file-list').innerHTML = self.cacheMeta;
+ let buttonToggleTags = self.viewMeta.querySelector('.show-all-tags');
+
+ if(buttonToggleTags !== null) {
+ let metaFind = self.viewMeta.querySelector('.meta-find');
+ buttonToggleTags.addEventListener('click', function () {
+ if(this.classList.contains('active')) {
+ this.classList.remove('active');
+ this.innerHTML = QuantumviewfilesLang.metaFileShow;
+ metaFind.classList.add('meta-hidden');
+ } else {
+ this.classList.add('active');
+ this.innerHTML = QuantumviewfilesLang.metaFileHide;
+ metaFind.classList.remove('meta-hidden');
+ }
+ });
+ }
+
+ return;
+ }
+ }
+
+ jQuery.get("/administrator/index.php?option=com_quantummanager&task=quantumviewfiles.getMetaFile&path=" + encodeURIComponent(self.path)).done(function (response) {
+ response = JSON.parse(response);
+ if(response.global !== undefined || response.find !== undefined) {
+ self.viewMeta.classList.remove('hidden');
+
+ let html = '