ui: Filter global intentions list by selected partition (#11475)

* ui: Filter global intentions list by namespace and partition

Filters global intention listing by the current partition rather than trying to use a wildcard.
This commit is contained in:
John Cowen 2021-11-09 17:38:24 +00:00 committed by GitHub
parent 14591de8d2
commit 71d8ac4605
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 5 deletions

4
.changelog/11475.txt Normal file
View File

@ -0,0 +1,4 @@
```release-note:bug
ui: Filter the global intentions list by the currently selected parition rather
than a wildcard
```

View File

@ -6,9 +6,9 @@ import { get } from '@ember/object';
// Listing of intentions still requires the `ns` query string parameter which // Listing of intentions still requires the `ns` query string parameter which
// will give us all the intentions that have the `ns` as either the SourceNS or // will give us all the intentions that have the `ns` as either the SourceNS or
// the DestinationNS. // the DestinationNS.
// We currently list intentions by the * wildcard namespace for back compat reasons
// TODO: Change the above so that we only list intentions with // TODO: Investigate the above to see if we should only list intentions with
// Source/Destination in the currently selected nspace // Source/Destination in the currently selected nspace or leave as is.
export default class IntentionAdapter extends Adapter { export default class IntentionAdapter extends Adapter {
requestForQuery(request, { dc, ns, partition, filter, index, uri }) { requestForQuery(request, { dc, ns, partition, filter, index, uri }) {
return request` return request`
@ -21,7 +21,7 @@ export default class IntentionAdapter extends Adapter {
} }
${{ ${{
partition: '*', partition,
ns: '*', ns: '*',
index, index,
filter, filter,

View File

@ -25,7 +25,7 @@ module('Integration | Adapter | intention', function(hooks) {
filter: '*', filter: '*',
index: 1, index: 1,
ns: '*', ns: '*',
partition: '*', partition: 'partition-1',
}, },
{ {
filter: '*', filter: '*',