Merge pull request #15 from discourse/fix_back_button
FIX: Ensure that back button always redirects to the index page
This commit is contained in:
commit
915657b8cd
|
@ -96,8 +96,9 @@ export default Ember.Controller.extend({
|
||||||
this.set('everEditing', false);
|
this.set('everEditing', false);
|
||||||
},
|
},
|
||||||
|
|
||||||
goBack() {
|
goHome() {
|
||||||
history.back();
|
this.set('selectedQueryId', null);
|
||||||
|
this.transitionToRoute('adminPlugins.explorer');
|
||||||
},
|
},
|
||||||
|
|
||||||
resetParams() {
|
resetParams() {
|
||||||
|
|
|
@ -34,7 +34,7 @@
|
||||||
{{#if editing}}
|
{{#if editing}}
|
||||||
<div class="name">
|
<div class="name">
|
||||||
<div class="previous">
|
<div class="previous">
|
||||||
{{d-button action="goBack" icon="chevron-left" class="no-text btn-med"}}
|
{{d-button action="goHome" icon="chevron-left" class="no-text btn-med"}}
|
||||||
</div>
|
</div>
|
||||||
{{text-field value=selectedItem.name}}
|
{{text-field value=selectedItem.name}}
|
||||||
</div>
|
</div>
|
||||||
|
@ -44,7 +44,7 @@
|
||||||
{{else}}
|
{{else}}
|
||||||
<div class="name">
|
<div class="name">
|
||||||
<div class="previous">
|
<div class="previous">
|
||||||
{{d-button action="goBack" icon="chevron-left" class="no-text btn-med"}}
|
{{d-button action="goHome" icon="chevron-left" class="no-text btn-med"}}
|
||||||
</div>
|
</div>
|
||||||
<h2>{{selectedItem.name}}</h2>
|
<h2>{{selectedItem.name}}</h2>
|
||||||
{{d-button action="editName" icon="pencil" class="no-text btn-small"}}
|
{{d-button action="editName" icon="pencil" class="no-text btn-small"}}
|
||||||
|
|
Loading…
Reference in New Issue