show ldap login into in all the post install dialogs

This commit is contained in:
Girish Ramakrishnan
2020-08-28 17:08:18 -07:00
parent 566f0f7783
commit b420d054ae
2 changed files with 12 additions and 0 deletions

View File

@@ -22,6 +22,10 @@
</h5>
</div>
<div class="modal-body">
<p ng-show="postInstallConfirm.customAuth && !app.manifest.addons.email"></p>
<p ng-show="app.manifest.addons.email">This app is set up to allow all users with a mailbox on this Cloudron. Login with the email and Cloudron password to access the mailbox.</p>
<p ng-show="!postInstallConfirm.customAuth && !app.manifest.addons.email"> This app is set up to authenticate with the Cloudron User Directory. Cloudron users can login and use {{ appPostInstallConfirm.app.manifest.title }}.</p>
<div ng-bind-html="app.manifest.postInstallMessage | markdown2html"></div>
<div ng-show="app.manifest.documentationUrl">
Please see the <a target="_blank" ng-href="{{ app.manifest.documentationUrl }}">documentation</a> for more information.
@@ -281,6 +285,10 @@
<h4>First Time Setup</h4>
</div>
<div class="modal-body">
<p ng-show="postInstallMessage.customAuth && !app.manifest.addons.email"></p>
<p ng-show="app.manifest.addons.email">This app is set up to allow all users with a mailbox on this Cloudron. Login with the email and Cloudron password to access the mailbox.</p>
<p ng-show="!postInstallMessage.customAuth && !app.manifest.addons.email"> This app is set up to authenticate with the Cloudron User Directory. Cloudron users can login and use {{ appPostInstallConfirm.app.manifest.title }}.</p>
<div ng-bind-html="app.manifest.postInstallMessage | markdown2html"></div>
</div>
<div class="modal-footer">

View File

@@ -142,10 +142,12 @@ angular.module('Application').controller('AppController', ['$scope', '$location'
$scope.postInstallMessage = {
confirmed: false,
openApp: false,
customAuth: false,
show: function (openApp) {
$scope.postInstallMessage.confirmed = false;
$scope.postInstallMessage.openApp = !!openApp;
$scope.postInstallMessage.customAuth = !($scope.app.manifest.addons['ldap'] || $scope.manifest.addons['oauth']);
if (!$scope.app.manifest.postInstallMessage) return;
$('#postInstallModal').modal('show');
@@ -1404,10 +1406,12 @@ angular.module('Application').controller('AppController', ['$scope', '$location'
$scope.postInstallConfirm = {
message: '',
confirmed: false,
customAuth: false,
show: function () {
$scope.postInstallConfirm.message = $scope.app.manifest.postInstallMessage;
$scope.postInstallConfirm.confirmed = false;
$scope.postInstallConfirm.customAuth = !($scope.app.manifest.addons['ldap'] || $scope.app.manifest.addons['oauth']);
$('#postInstallConfirmModal').modal('show');