open-nomad/ui/app/components/variable-form.hbs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

160 lines
5.1 KiB
Handlebars
Raw Normal View History

{{did-update this.onViewChange @view}}
{{did-insert this.establishKeyValues}}
2022-08-29 18:35:43 +00:00
<form class="new-variables" autocomplete="off" {{on "submit" this.save}}>
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
{{#if @model.isNew}}
<div class="related-entities related-entities-hint">
2022-08-29 18:35:43 +00:00
<p>Prefix your path with <code>nomad/jobs/</code> to automatically make your variable accessible to a specified job, task group, or task.<br />
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
Format: <code>nomad/jobs/&lt;jobname&gt;</code>, <code>nomad/jobs/&lt;jobname&gt;/&lt;groupname&gt;</code>, <code>nomad/jobs/&lt;jobname&gt;/&lt;groupname&gt;/&lt;taskname&gt;</code></p>
</div>
{{/if}}
{{#if this.hasConflict}}
<div class="notification conflict is-danger">
2022-08-29 18:35:43 +00:00
<h3 class="title is-4">Heads up! Your variable has a conflict.</h3>
<p>This might be because someone else tried saving in the time since you've had it open.</p>
{{#if this.conflictingVariable.modifyTime}}
<span class="tooltip" aria-label="{{format-ts this.conflictingVariable.modifyTime}}">
{{moment-from-now this.conflictingVariable.modifyTime}}
</span>
{{/if}}
{{#if this.conflictingVariable.items}}
<pre><code>{{stringify-object this.conflictingVariable.items whitespace=2}}</code></pre>
{{else}}
<p>Your ACL token limits your ability to see further details about the conflicting variable.</p>
{{/if}}
<div class="options">
<button data-test-refresh-button type="button" class="button" {{on "click" this.refresh}}>Refresh your browser</button>
<button data-test-overwrite-button type="button" class="button is-danger" {{on "click" this.saveWithOverwrite}}>Overwrite anyway</button>
</div>
</div>
{{/if}}
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
<div class={{if this.namespaceOptions "path-namespace"}}>
<label>
<span>
Path
</span>
<Input
@type="text"
@value={{this.path}}
placeholder="nomad/jobs/my-job/my-group/my-task"
class="input path-input {{if this.duplicatePathWarning "error"}}"
disabled={{not @model.isNew}}
{{autofocus}}
ui: create variable permission logic (#13447) * ui: inject router service into Variable ability to compute path * ui: test create secure variable ability * refact: update templates to properly check create ability * chore: update token factory to enable 1 path to have create ability * refact: remove router service injection for path variable * refact: update mirage factory for edit and delete perms on path for testing * ui: handle path matching (#13474) * test: write specifications for nearestPath computation * ui: write logic for getting all paths * ui: nearestPathMatching algorithm * test: nearestPathMatching algorithm test * ui: handle namespace filtering for capabilities check (#13475) * ui: add namespace handling * refact: add logical OR operator to handle unstructured object. * ui: acceptance test for create flow in secure variables (#13500) * test: write happy path test for creating variable * refact: add missing data-test attributes * test: sad path for disabled button * fix: move comment in file * test: acceptance test for editing a variable (#13529) * refact: add data-test variable * test: happy path and sad path for edit flow * refact: update test language to say disabled * ui: glob matching algorithm (#13533) * ui: compute length difference (#13542) * ui: compute length difference * refact: use glob matching and sorting algos in `nearestMatchingPath` (#13544) * refact: use const in compute * ui: smallest difference logic * refact: use glob matching and sorting algo in _nearestPathPath helper * ui: add can edit to variable capabilities (#13545) * ui: create edit capabilities getter * ui: add ember-can check for edit button * refact: update test to mock edit capabilities in policy * fix: remove unused var * Edit capabilities for variables depend on Create Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com> * refact: update token factory (#13596) * refact: update rulesJSON in token factory to reflect schema update * refact: update capability names (#13597) * refact: update rules to match rulesJSON * refact: update create to write * ui: add `canDestroy` permissions (#13598) * refact: update rulesJSON in token factory to reflect schema update * refact: update rules to match rulesJSON * refact: update create to write * ui: add canDestroy capability * test: unit test for canDestroy * ui: add permission check to template * test: acceptance test for delete flow * refact: update test to use correct capability name * refact: update tests to reflect rulesJSON schema change * ui: update path matching logic to account for schema change (#13605) * refact: update path matching logic * refact: update tests to reflect rulesJSON change Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-06 14:48:22 +00:00
data-test-path-input
/>
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
{{#if this.duplicatePathWarning}}
<p class="duplicate-path-error help is-danger">
2022-08-29 18:35:43 +00:00
There is already a variable located at
{{this.path}}
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
.
<br />
Please choose a different path, or
<LinkTo
@route="variables.variable.edit"
@model={{this.duplicatePathWarning.path}}
>
2022-08-29 18:35:43 +00:00
edit the existing variable
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
</LinkTo>
.
</p>
{{/if}}
</label>
2022-08-29 18:35:43 +00:00
<VariableForm::NamespaceFilter
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
@data={{hash
disabled=(not @model.isNew)
selection=this.variableNamespace
namespaceOptions=this.namespaceOptions
}}
@fns={{hash
onSelect=this.setNamespace
setNamespaceOptions=this.setNamespaceOptions
}}
/>
</div>
{{#if (eq this.view "json")}}
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
<div
class="editor-wrapper boxed-section-body is-full-bleed
{{if this.JSONError 'error'}}"
>
<div
data-test-json-editor
{{code-mirror
content=this.JSONItems
onUpdate=this.updateCode
extraKeys=(hash Cmd-Enter=(action "save"))
}}
ui: add namespace filter to `variables.index` (#13618) * ui: add namespace filter feature ui: add namespace filtering to variables.index test: namespace filter refact: fix action in template ui: move data fetching and query param logic to ui: controller query parameter logic ui: prevent from forwarding query param ui: create variables controller refact: use dependency injection for controlling parent qp chore: clean-up reset in route chore: clean-up reset in route * ui: add namespace filter to secure var form (#13629) ui: update variable factory to accept namespaces refact: update api to accept disabled ui: add namespace setting logic to form refact: remove debugger refact: get correct selectors for ui: move data loading to namespace-filter component chore: prettify template ui: update factory to handle namespace setting refact: remove inline styling for grid class * ui: fix placement of filter in `SecureVariablesForm` (#13762) * refact: conditionally render css class * chore: remove unused CSS property * refact: edit path-input class to prevent textarea override * refact: inject missing store service (#13763) * chore: patch fixes for when no default namespace is available (#13782) * test: add tests for namespace filtering conditions (#13816) * test: add tests for namespace filtering and namespaces appearing in form * patch namespace related issue to saving and querying (#13825) * refact: use namespace id, not entity * refact: update adapter to edit request to include qp * ui: early exit if no snapshot * refact: test passes wrong interface to method * chore: add missing url update URL builder * refact: model in doesn't have absolutePath * Align error message * chore: update tests (#13905) * chore: patch brittle tests with better selectors * chore: update assertion count Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-22 20:05:35 +00:00
></div>
{{#if this.JSONError}}
<p class="help is-danger">
{{this.JSONError}}
</p>
{{/if}}
</div>
{{else}}
{{#each this.keyValues as |entry iter|}}
<div class="key-value">
<label>
<span>
Key
</span>
<Input
ui: create variable permission logic (#13447) * ui: inject router service into Variable ability to compute path * ui: test create secure variable ability * refact: update templates to properly check create ability * chore: update token factory to enable 1 path to have create ability * refact: remove router service injection for path variable * refact: update mirage factory for edit and delete perms on path for testing * ui: handle path matching (#13474) * test: write specifications for nearestPath computation * ui: write logic for getting all paths * ui: nearestPathMatching algorithm * test: nearestPathMatching algorithm test * ui: handle namespace filtering for capabilities check (#13475) * ui: add namespace handling * refact: add logical OR operator to handle unstructured object. * ui: acceptance test for create flow in secure variables (#13500) * test: write happy path test for creating variable * refact: add missing data-test attributes * test: sad path for disabled button * fix: move comment in file * test: acceptance test for editing a variable (#13529) * refact: add data-test variable * test: happy path and sad path for edit flow * refact: update test language to say disabled * ui: glob matching algorithm (#13533) * ui: compute length difference (#13542) * ui: compute length difference * refact: use glob matching and sorting algos in `nearestMatchingPath` (#13544) * refact: use const in compute * ui: smallest difference logic * refact: use glob matching and sorting algo in _nearestPathPath helper * ui: add can edit to variable capabilities (#13545) * ui: create edit capabilities getter * ui: add ember-can check for edit button * refact: update test to mock edit capabilities in policy * fix: remove unused var * Edit capabilities for variables depend on Create Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com> * refact: update token factory (#13596) * refact: update rulesJSON in token factory to reflect schema update * refact: update capability names (#13597) * refact: update rules to match rulesJSON * refact: update create to write * ui: add `canDestroy` permissions (#13598) * refact: update rulesJSON in token factory to reflect schema update * refact: update rules to match rulesJSON * refact: update create to write * ui: add canDestroy capability * test: unit test for canDestroy * ui: add permission check to template * test: acceptance test for delete flow * refact: update test to use correct capability name * refact: update tests to reflect rulesJSON schema change * ui: update path matching logic to account for schema change (#13605) * refact: update path matching logic * refact: update tests to reflect rulesJSON change Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-06 14:48:22 +00:00
data-test-var-key
@type="text"
@value={{entry.key}}
class="input"
{{autofocus ignore=(eq iter 0)}}
{{on "input" (fn this.validateKey entry)}}
/>
</label>
2022-08-29 18:35:43 +00:00
<VariableForm::InputGroup @entry={{entry}} />
{{#if (eq entry this.keyValues.lastObject)}}
<button
class="add-more button is-info is-inverted"
type="button"
disabled={{not (and entry.key entry.value)}}
{{on "click" this.appendRow}}
>
Add More
</button>
{{else}}
<button
class="delete-row button is-danger is-inverted"
type="button"
{{on "click" (action this.deleteRow entry)}}
>
Delete
</button>
{{/if}}
{{#each-in entry.warnings as |k v|}}
<span class="key-value-error help is-danger">
{{v}}
</span>
{{/each-in}}
</div>
{{/each}}
{{/if}}
{{#if (and this.shouldShowLinkedEntities @model.isNew)}}
2022-08-29 18:35:43 +00:00
<VariableForm::RelatedEntities
@new={{true}}
@job={{@model.pathLinkedEntities.job}}
@group={{@model.pathLinkedEntities.group}}
@task={{@model.pathLinkedEntities.task}}
2022-08-03 15:58:11 +00:00
@namespace={{this.variableNamespace}}
/>
{{/if}}
<footer>
<button
disabled={{this.shouldDisableSave}}
class="button is-primary"
type="submit"
ui: create variable permission logic (#13447) * ui: inject router service into Variable ability to compute path * ui: test create secure variable ability * refact: update templates to properly check create ability * chore: update token factory to enable 1 path to have create ability * refact: remove router service injection for path variable * refact: update mirage factory for edit and delete perms on path for testing * ui: handle path matching (#13474) * test: write specifications for nearestPath computation * ui: write logic for getting all paths * ui: nearestPathMatching algorithm * test: nearestPathMatching algorithm test * ui: handle namespace filtering for capabilities check (#13475) * ui: add namespace handling * refact: add logical OR operator to handle unstructured object. * ui: acceptance test for create flow in secure variables (#13500) * test: write happy path test for creating variable * refact: add missing data-test attributes * test: sad path for disabled button * fix: move comment in file * test: acceptance test for editing a variable (#13529) * refact: add data-test variable * test: happy path and sad path for edit flow * refact: update test language to say disabled * ui: glob matching algorithm (#13533) * ui: compute length difference (#13542) * ui: compute length difference * refact: use glob matching and sorting algos in `nearestMatchingPath` (#13544) * refact: use const in compute * ui: smallest difference logic * refact: use glob matching and sorting algo in _nearestPathPath helper * ui: add can edit to variable capabilities (#13545) * ui: create edit capabilities getter * ui: add ember-can check for edit button * refact: update test to mock edit capabilities in policy * fix: remove unused var * Edit capabilities for variables depend on Create Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com> * refact: update token factory (#13596) * refact: update rulesJSON in token factory to reflect schema update * refact: update capability names (#13597) * refact: update rules to match rulesJSON * refact: update create to write * ui: add `canDestroy` permissions (#13598) * refact: update rulesJSON in token factory to reflect schema update * refact: update rules to match rulesJSON * refact: update create to write * ui: add canDestroy capability * test: unit test for canDestroy * ui: add permission check to template * test: acceptance test for delete flow * refact: update test to use correct capability name * refact: update tests to reflect rulesJSON schema change * ui: update path matching logic to account for schema change (#13605) * refact: update path matching logic * refact: update tests to reflect rulesJSON change Co-authored-by: Phil Renaud <phil@riotindustries.com> Co-authored-by: Phil Renaud <phil@riotindustries.com>
2022-07-06 14:48:22 +00:00
data-test-submit-var
>
Save
{{pluralize "Variable" @this.keyValues.length}}
</button>
</footer>
</form>