mirror of https://github.com/status-im/consul.git
ui: [BUGFIX] Role/Policy selector default sort (#9434)
* Sort the options when they aren't being searched
This commit is contained in:
parent
85205a63e8
commit
dc940cbf61
|
@ -23,7 +23,7 @@
|
|||
<PowerSelect
|
||||
@searchEnabled={{true}}
|
||||
@search={{action collection.search}}
|
||||
@options={{options}}
|
||||
@options={{sort-by 'Name:asc' options}}
|
||||
@loadingMessage="Loading..."
|
||||
@searchMessage="No possible options"
|
||||
@searchPlaceholder={{placeholder}}
|
||||
|
|
|
@ -10,10 +10,10 @@ Feature: dc / acls / policies / as many / add existing: Add existing policy
|
|||
---
|
||||
And 2 policy models from yaml
|
||||
---
|
||||
- ID: policy-1
|
||||
Name: Policy 1
|
||||
- ID: policy-2
|
||||
Name: Policy 2
|
||||
- ID: policy-1
|
||||
Name: Policy 1
|
||||
---
|
||||
When I visit the [Model] page for yaml
|
||||
---
|
||||
|
@ -22,6 +22,7 @@ Feature: dc / acls / policies / as many / add existing: Add existing policy
|
|||
---
|
||||
Then the url should be /datacenter/acls/[Model]s/key
|
||||
And I click "form > #policies .ember-power-select-trigger"
|
||||
And I see the text "Policy 1" in ".ember-power-select-option:first-child"
|
||||
And I type "Policy 1" into ".ember-power-select-search-input"
|
||||
And I click ".ember-power-select-option:first-child"
|
||||
And I see 1 policy model on the policies component
|
||||
|
|
|
@ -10,10 +10,10 @@ Feature: dc / acls / roles / as many / add existing: Add existing
|
|||
---
|
||||
And 2 role models from yaml
|
||||
---
|
||||
- ID: role-1
|
||||
Name: Role 1
|
||||
- ID: role-2
|
||||
Name: Role 2
|
||||
- ID: role-1
|
||||
Name: Role 1
|
||||
---
|
||||
When I visit the token page for yaml
|
||||
---
|
||||
|
@ -22,6 +22,7 @@ Feature: dc / acls / roles / as many / add existing: Add existing
|
|||
---
|
||||
Then the url should be /datacenter/acls/tokens/key
|
||||
And I click "form > #roles .ember-power-select-trigger"
|
||||
And I see the text "Role 1" in ".ember-power-select-option:first-child"
|
||||
And I type "Role 1" into ".ember-power-select-search-input"
|
||||
And I click ".ember-power-select-option:first-child"
|
||||
And I see 1 role model on the roles component
|
||||
|
|
Loading…
Reference in New Issue