Move subscription setup outlink button inside iframe for better label control
This commit is contained in:
@@ -43,10 +43,8 @@ angular.module('Application').controller('MainController', ['$scope', '$route',
|
||||
});
|
||||
});
|
||||
|
||||
$scope.waitForPlanSelection = function () {
|
||||
if ($scope.waitingForPlanSelection) return;
|
||||
|
||||
$scope.waitingForPlanSelection = true;
|
||||
$scope.showSubscriptionModal = function () {
|
||||
$('#setupSubscriptionModal').modal('show');
|
||||
|
||||
function checkPlan() {
|
||||
if (!$scope.waitingForPlanSelection) return;
|
||||
@@ -55,7 +53,7 @@ angular.module('Application').controller('MainController', ['$scope', '$route',
|
||||
if (error) return console.error(error);
|
||||
|
||||
// check again to give more immediate feedback once a subscription was setup
|
||||
if (subscription.plan.id === 'free') {
|
||||
if (subscription.plan.id === 'free' || subscription.plan.id === 'expired') {
|
||||
$timeout(checkPlan, 5000);
|
||||
} else {
|
||||
$scope.waitingForPlanSelection = false;
|
||||
@@ -65,11 +63,9 @@ angular.module('Application').controller('MainController', ['$scope', '$route',
|
||||
});
|
||||
}
|
||||
|
||||
checkPlan();
|
||||
};
|
||||
$scope.waitingForPlanSelection = true;
|
||||
|
||||
$scope.showSubscriptionModal = function () {
|
||||
$('#setupSubscriptionModal').modal('show');
|
||||
checkPlan();
|
||||
};
|
||||
|
||||
function refreshNotifications() {
|
||||
|
||||
Reference in New Issue
Block a user