mirror of
https://github.com/getredash/redash.git
synced 2026-05-09 21:02:27 -04:00
37 lines
1.2 KiB
HTML
37 lines
1.2 KiB
HTML
<settings-screen>
|
|
<!--<h2 class="p-l-5">{{snippet.trigger}}</h2>-->
|
|
|
|
<div class="">
|
|
<!--<pre>-->
|
|
<!--{{snippet | json}}-->
|
|
<!--</pre>-->
|
|
|
|
<form name="snippetForm" class="form">
|
|
<div class="form-group">
|
|
<label>Trigger</label>
|
|
<input type="string" class="form-control" ng-model="snippet.trigger" ng-disabled="!canEdit" required>
|
|
</div>
|
|
|
|
<div class="form-group">
|
|
<label>Description</label>
|
|
<input type="string" class="form-control" ng-model="snippet.description" ng-disabled="!canEdit">
|
|
</div>
|
|
|
|
<div class="form-group">
|
|
<label>Snippet</label>
|
|
<pre ng-if="!canEdit">{{snippet.snippet}}</pre>
|
|
<div ui-ace="editorOptions" ng-model="snippet.snippet" style="height:300px" ng-if="canEdit"></div>
|
|
</div>
|
|
|
|
<div class="form-group" ng-if="canEdit">
|
|
<button class="btn btn-primary" ng-disabled="!snippetForm.$valid" ng-click="saveChanges()">Save</button>
|
|
<button class="btn btn-danger" ng-if="snippet.id" ng-click="delete()">Delete</button>
|
|
</div>
|
|
<small ng-if="snippet.user">
|
|
Created by: {{snippet.user.name}}
|
|
</small>
|
|
</form>
|
|
|
|
</div>
|
|
</settings-screen>
|