From 255ec7b80335a0d90324eaca26823f611a0e1890 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?William=20Tis=C3=A4ter?= Date: Mon, 5 May 2014 01:03:47 +0200 Subject: [PATCH] Add cancel button to key edit --- ui/index.html | 1 + ui/javascripts/app/controllers.js | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/ui/index.html b/ui/index.html index b9db4de0f9..f0cd715175 100644 --- a/ui/index.html +++ b/ui/index.html @@ -210,6 +210,7 @@ {{ textarea value=model.valueDecoded class="form-control"}} + diff --git a/ui/javascripts/app/controllers.js b/ui/javascripts/app/controllers.js index 1fd78ba853..29b4910e2c 100644 --- a/ui/javascripts/app/controllers.js +++ b/ui/javascripts/app/controllers.js @@ -143,6 +143,12 @@ App.KvEditController = Ember.Controller.extend({ }) }, + cancelEdit: function() { + this.set('isLoading', true); + this.transitionToRoute('kv.show', this.get("model").get('parentKey')); + this.set('isLoading', false); + }, + deleteKey: function() { this.set('isLoading', true); var key = this.get("model");