Fix display of alt domains

This commit is contained in:
Girish Ramakrishnan
2019-09-27 12:58:26 -07:00
parent c068deb47e
commit b90550d6ba

View File

@@ -160,7 +160,7 @@ angular.module('Application').controller('ActivityController', ['$scope', '$loca
} else {
return name + ' was taken out of repair mode';
}
} else if ('mailboxName' in data) {
} else if (('mailboxName' in data) && data.mailboxName !== data.app.mailboxName) {
if (data.mailboxName) {
return 'Mailbox of ' + name + ' was set to ' + q(data.mailboxName);
} else {
@@ -183,10 +183,11 @@ angular.module('Application').controller('ActivityController', ['$scope', '$loca
return 'Certificate of ' + name + ' was reset';
}
} else if (data.location) {
if (data.location !== data.app.location || data.domain !== data.app.domain) {
return 'Location of ' + name + ' was changed to ' + data.location + '.' + data.domain;
if (data.fqdn !== data.app.fqdn) {
return 'Location of ' + name + ' was changed to ' + data.fqdn;
} else if (!angular.equals(data.alternateDomains, data.app.alternateDomains)) {
return 'Alternate domains of ' + name + ' was set to ' + q(data.alternateDomains.join(','));
var altFqdns = data.alternateDomains.map(function (a) { return a.fqdn; });
return 'Alternate domains of ' + name + ' was ' + (altFqdns.length ? 'set to ' + altFqdns.join(', ') : 'reset');
} else if (!angular.equals(data.portBindings, data.app.portBindings)) {
return 'Port bindings of ' + name + ' was changed';
}