Skip to content

Commit

Permalink
closes #481 (#673)
Browse files Browse the repository at this point in the history
  • Loading branch information
nadar authored Oct 6, 2021
1 parent 93cef29 commit 3d7116e
Show file tree
Hide file tree
Showing 5 changed files with 48 additions and 34 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ In order to read more about upgrading and BC breaks have a look at the [UPGRADE
+ [#666](https://github.com/luyadev/luya-module-admin/pull/666) Fixed injection issue with zaaDecimal within zaaMultipleInputs.
+ [#665](https://github.com/luyadev/luya-module-admin/pull/665) Replaced `<span>` tags with `<a>` tags in main admin menu and submenus.
+ [#663](https://github.com/luyadev/luya-module-admin/issues/663) A new `TagRelation::cleanup(ActiveRecord $model)` method to remove all tag relations for a certain model.
+ [#481](https://github.com/luyadev/luya-module-admin/issues/481) Fixed issue where file manager files count is not updated accordingly after uploading new files.

## 4.1.0 (21. September 2021)

Expand Down
56 changes: 32 additions & 24 deletions src/resources/dist/bower.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/resources/dist/login.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/resources/dist/main.js

Large diffs are not rendered by default.

21 changes: 13 additions & 8 deletions src/resources/js/directives.js
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,8 @@ zaa.directive("tooltip", ['$document', '$http', function ($document, $http) {
link: function (scope, element, attr) {
var defaultPosition = 'right';

var lastValue = null

var positions = {
top: function () {
var bcr = element[0].getBoundingClientRect();
Expand Down Expand Up @@ -238,11 +240,14 @@ zaa.directive("tooltip", ['$document', '$http', function ($document, $http) {

element.on('mouseenter', function () {

if (scope.tooltipExpression) {
scope.tooltipText = scope.tooltipExpression;
}

// Generate tooltip HTML for the first time
if (!scope.pop && (typeof scope.tooltipDisabled === 'undefined' || scope.tooltipDisabled === false)) {
if (scope.tooltipExpression) {
scope.tooltipText = scope.tooltipExpression;
}
if ((!scope.pop || lastValue != scope.tooltipText) && (typeof scope.tooltipDisabled === 'undefined' || scope.tooltipDisabled === false)) {

lastValue = scope.tooltipText

var html = '<div class="tooltip tooltip-' + (scope.tooltipPosition || defaultPosition) + (scope.tooltipImageUrl ? ' tooltip-image' : '') + '" role="tooltip">' +
'<div class="tooltip-arrow"></div>' +
Expand Down Expand Up @@ -1240,6 +1245,7 @@ zaa.directive("storageFileManager", function () {
ServiceQueueWaiting.waitFor(response.data.queueIds).then(waitForResposne => {
$scope.getFilesForCurrentPage().then(function () {
AdminToastService.success(i18n['js_dir_manager_upload_image_ok']);
$scope.foldersDataReload()
LuyaLoading.stop();
});
});
Expand All @@ -1264,8 +1270,7 @@ zaa.directive("storageFileManager", function () {

file.upload.then(function (response) {
$timeout(function () {

ServiceQueueWaiting.waitFor(response.data.queueIds).then(waitForResposne => {
ServiceQueueWaiting.waitFor(response.data.queueIds).then(waitForResponse => {
$scope.uploadResults++;
file.processed = true;
file.result = response.data;
Expand All @@ -1274,9 +1279,8 @@ zaa.directive("storageFileManager", function () {
LuyaLoading.stop();
$scope.errorMsg = true
}
$scope.foldersDataReload()
})


});
}, function (response) {
file = response.data;
Expand Down Expand Up @@ -1448,6 +1452,7 @@ zaa.directive("storageFileManager", function () {
AdminToastService.success(i18n['js_dir_manager_rm_file_ok']);
$scope.selectedFiles = [];
$scope.closeFileDetail();
$scope.foldersDataReload();
});
});
}]);
Expand Down

0 comments on commit 3d7116e

Please sign in to comment.