Also remove the app info dialog code from apps grid

This commit is contained in:
Johannes Zellner
2019-09-13 16:07:55 +02:00
parent 7c9654a541
commit a1fe79c876
2 changed files with 1 additions and 58 deletions
-39
View File
@@ -120,44 +120,6 @@
</div>
</div>
<!-- Modal information of app -->
<div class="modal fade" id="appInfoModal" tabindex="-1" role="dialog">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<img ng-src="{{appInfo.app.iconUrl}}" onerror="this.onerror=null;this.src='img/appicon_fallback.png'" class="app-info-icon"/>
<h5 class="app-info-title">
{{ appInfo.app.manifest.title }}
<span class="app-info-meta text-small">{{ appInfo.app.upstreamVersion }} (Package <a ng-href="/#/appstore/{{appInfo.app.manifest.id}}?version={{appInfo.app.manifest.version}}">v{{ appInfo.app.manifest.version }}</a>) </span>
<br/>
App ID <span class="app-info-meta text-small">{{ appInfo.app.id }}</a> </span>
<br/>
Last updated <span class="app-info-meta text-small">{{ appInfo.app.updateTime | prettyDate }}</span>
</h5>
</div>
<div class="modal-body">
<div class="app-postinstall-message" ng-hide="appInfo.app.manifest && appInfo.app.manifest.postInstallMessage">
This package has no special usage information.
</div>
<div class="app-postinstall-message" ng-show="appInfo.app.manifest && appInfo.app.manifest.postInstallMessage">
<div ng-bind-html="appInfo.message | postInstallMessage:appInfo.app | markdown2html"></div>
</div>
<div ng-show="appInfo.app.manifest.addons.localstorage.ftp">
<br/>
<b>SFTP</b> <sup><a ng-href="{{ config.webServerOrigin }}/documentation/apps/#ftp-access" class="help" target="_blank"><i class="fa fa-question-circle"></i></a></sup><br/>
Server: {{ config.adminFqdn }}<br/>
Port: 222<br/>
Username: {{ user.username }}@{{ appInfo.app.fqdn }}<br/>
</div>
</div>
<div class="modal-footer">
<a ng-show="appInfo.app.manifest.documentationUrl" target="_blank" ng-href="{{appInfo.app.manifest.documentationUrl}}" class="btn btn-info pull-left">Documentation</a>
<button type="button" class="btn btn-default" data-dismiss="modal" autofocus>Close</button>
</div>
</div>
</div>
</div>
<!-- Modal postinstall confirm -->
<div class="modal fade" id="appPostInstallConfirmModal" tabindex="-1" role="dialog">
<div class="modal-dialog">
@@ -301,7 +263,6 @@
<div class="grid-item-actions" ng-show="user.admin">
<a href="" ng-hide="!backupsEnabled || (app | activeTask)" ng-click="appRestore.show(app)" uib-tooltip="Backups" tooltip-placement="right" tooltip-class="app-tooltip"><i class="fa fa-archive scale"></i></a>
<a ng-href="#/app/{{ app.id}}" uib-tooltip="Configure" tooltip-placement="right" tooltip-class="app-tooltip"><i class="fa fa-wrench scale"></i></a>
<a href="" ng-click="showInformation(app)" uib-tooltip="Information" tooltip-placement="right" tooltip-class="app-tooltip"><i class="fa fa-info-circle scale"></i></a>
</div>
<!-- we check the version here because the box updater does not know when an app gets updated -->
+1 -19
View File
@@ -179,11 +179,6 @@ angular.module('Application').controller('AppsController', ['$scope', '$location
}
};
$scope.appInfo = {
app: {},
message: ''
};
$scope.appPostInstallConfirm = {
app: {},
message: '',
@@ -263,7 +258,6 @@ angular.module('Application').controller('AppsController', ['$scope', '$location
$('#appErrorModal').modal('hide');
$('#appRestoreModal').modal('hide');
$('#appUpdateModal').modal('hide');
$('#appInfoModal').modal('hide');
$('#appPostInstallConfirmModal').modal('hide');
// reset update dialog
@@ -288,18 +282,6 @@ angular.module('Application').controller('AppsController', ['$scope', '$location
$scope.appPostInstallConfirm.confirmed = false;
};
$scope.showInformation = function (app) {
$scope.reset();
$scope.appInfo.app = app;
$scope.appInfo.message = app.manifest.postInstallMessage;
$('#appInfoModal').modal('show');
return false; // prevent propagation and default
};
$scope.renderAccessRestrictionUser = function (userId) {
var user = $scope.users.filter(function (u) { return u.id === userId; })[0];
@@ -376,7 +358,7 @@ angular.module('Application').controller('AppsController', ['$scope', '$location
});
// setup all the dialog focus handling
['appUpdateModal', 'appRestoreModal', 'appInfoModal', 'appErrorModal'].forEach(function (id) {
['appUpdateModal', 'appRestoreModal', 'appErrorModal'].forEach(function (id) {
$('#' + id).on('shown.bs.modal', function () {
$(this).find("[autofocus]:first").focus();
});