2018-10-09 04:22:29 +00:00
<form onsubmit= {{ action "createOrUpdateKey" "update" }} >
2018-10-11 03:42:18 +00:00
<div class="box is-sideless is-fullwidth is-marginless is-paddingless">
2018-10-09 04:22:29 +00:00
<MessageError @model= {{ model }} @errorMessage= {{ error }} />
2018-08-16 17:48:24 +00:00
<NamespaceReminder @mode="edit" @noun="secret" />
2018-10-17 21:49:11 +00:00
{{ # if ( not-eq model .selectedVersion .version model .currentVersion ) }}
<div class="form-section">
<MessageInPage @type="warning" @class="is-marginless">
You are creating a new version based on data from Version {{ model .selectedVersion .version }} . The current version for <code> {{ model .id }} </code> is Version {{ model .currentVersion }} .
</MessageInPage>
</div>
{{ / if }}
<SecretEditDisplay
@showAdvancedMode= {{ showAdvancedMode }}
@codemirrorString= {{ codemirrorString }}
@secretData= {{ secretData }}
@isV2= {{ isV2 }}
@canEditV2Secret= {{ canEditV2Secret }}
@model= {{ model }}
@editActions= {{ hash
codemirrorUpdated=(action "codemirrorUpdated")
formatJSON=(action "formatJSON")
handleKeyDown=(action "handleKeyDown")
handleChange=(action "handleChange")
deleteRow=(action "deleteRow")
addRow=(action "addRow")
}}
/>
2018-10-15 14:40:54 +00:00
</div>
2018-04-03 14:16:57 +00:00
<div class="field is-grouped is-grouped-split is-fullwidth box is-bottomless">
<div class="field is-grouped">
2018-10-09 04:22:29 +00:00
<div class="control">
<button
type="submit"
disabled= {{ buttonDisabled }}
class="button is-primary"
>
Save
</button>
</div>
2018-04-03 14:16:57 +00:00
<div class="control">
{{ # secret-link
2018-10-09 04:22:29 +00:00
mode="show"
secret=model.id
2018-04-03 14:16:57 +00:00
class="button"
2018-10-17 21:49:11 +00:00
queryParams=(query-params version=this.modelForData.version)
2018-04-03 14:16:57 +00:00
}}
Cancel
{{ / secret-link }}
</div>
</div>
</div>
</form>