Use new subscription setup flow for app install dialog

This commit is contained in:
Johannes Zellner
2020-02-21 14:07:46 +01:00
parent 81fb4ab435
commit 52d454276d
2 changed files with 11 additions and 12 deletions

View File

@@ -149,11 +149,12 @@
<p>Please upgrade to a server instance with more memory. Alternately, free up resources by uninstalling unused applications.</p>
</div>
<div class="collapse" id="collapseSubscriptionRequired" data-toggle="false">
<iframe ng-src="{{ config.webServerOrigin + '/helper/' + appInstall.subscriptionHelperPage + '?appstoreId=' + appInstall.app.manifest.appstoreId + '&email=' + subscription.emailEncoded + '&cloudronId=' + subscription.cloudronId }}" style="width: 100%; height: 150px; border: none;"></iframe>
<p class="text-bold">A subscription for this Cloudron is required to install more apps.</p>
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default"data-dismiss="modal">Close</button>
<button type="button" class="btn btn-success pull-left" ng-click="openSubscriptionSetup()" ng-show="appInstall.state === 'subscriptionRequired'">Setup Subscription</button>
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-danger" ng-show="user.admin && appInstall.state === 'resourceConstraint'" ng-click="appInstall.showForm(true)">Install anyway</button>
<button type="button" class="btn btn-success" ng-show="appInstall.state === 'appInfo'" ng-click="appInstall.showForm()">Install</button>
<button type="button" class="btn btn-success" ng-show="appInstall.state === 'installForm'" ng-click="appInstall.submit()" ng-disabled="appInstallForm.$invalid || appInstall.busy"><i class="fa fa-circle-notch fa-spin" ng-show="appInstall.busy"></i> Install {{ appInstall.needsOverwrite ? 'and overwrite DNS' : '' }}</button>