Allow the user to setup a subscription when enabling email

This commit is contained in:
Johannes Zellner
2018-05-29 17:17:53 +02:00
parent 3251dc3d73
commit 11ae5d4832
2 changed files with 34 additions and 11 deletions

View File

@@ -6,18 +6,26 @@
<div class="modal-header">
<h4 class="modal-title">Cloudron Email Server</h4>
</div>
<div class="modal-body" ng-show="selectedDomain.provider === 'noop' || selectedDomain.provider === 'manual'">
No DNS provider is setup. The DNS records listed below have to be setup manually.<br/>
</div>
<div class="modal-body" ng-hide="selectedDomain.provider === 'noop' || selectedDomain.provider === 'manual'">
Cloudron will setup Email related DNS records automatically for {{selectedDomain.domain}}. Status of DNS Records below
may show an error while DNS is propagating (~5 minutes).
<br/><br/>
If this domain is already configured to handle email with some other provider, it will overwrite those records.
<div class="modal-body">
<div ng-show="selectedDomain.provider === 'noop' || selectedDomain.provider === 'manual'">
No DNS provider is setup. The DNS records listed below have to be setup manually.<br/>
</div>
<div ng-hide="selectedDomain.provider === 'noop' || selectedDomain.provider === 'manual'">
Cloudron will setup Email related DNS records automatically for {{selectedDomain.domain}}. Status of DNS Records below
may show an error while DNS is propagating (~5 minutes).
<br/><br/>
If this domain is already configured to handle email with some other provider, it will overwrite those records.
</div>
<div ng-hide="hasSubscription">
<h4 class="text-danger">
The Cloudron Email Server is only part of the paid subscription.
</h4>
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
<button type="button" class="btn btn-success" ng-click="enableEmail()">I understand, enable</button>
<button type="button" class="btn btn-success" ng-show="hasSubscription" ng-click="enableEmail()">I understand, enable</button>
<a class="btn btn-success" ng-hide="hasSubscription" ng-click="closeEnableEmailDialog()" ng-href="{{ config.webServerOrigin + '/console.html#/userprofile?view=subscriptions&email=' + appstoreConfig.profile.emailEncoded + '&cloudronId=' + appstoreConfig.cloudronId }}" target="_blank">Setup Subscription</a>
</div>
</div>
</div>