You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
consul/ui/packages/consul-ui/app/controllers/_peered-resource.js

17 lines
438 B

import Controller from '@ember/controller';
import { inject as service } from '@ember/service';
export default class PeeredResourceController extends Controller {
@service abilities;
get _searchProperties() {
const { searchProperties } = this;
if (!this.abilities.can('use peers')) {
return searchProperties.filter(propertyName => propertyName !== 'PeerName');
} else {
return searchProperties;
}
}
}