diff --git a/ghost/admin/models/post.js b/ghost/admin/models/post.js
index 91fd1d3009..0d37c4538f 100644
--- a/ghost/admin/models/post.js
+++ b/ghost/admin/models/post.js
@@ -50,7 +50,7 @@
nextPage: 0,
prevPage: 0,
- url: Ghost.settings.apiRoot + '/posts',
+ url: Ghost.settings.apiRoot + '/posts/',
model: Ghost.Models.Post,
parse: function (resp) {
diff --git a/ghost/admin/models/settings.js b/ghost/admin/models/settings.js
index e2447b4da1..f6b926ae0a 100644
--- a/ghost/admin/models/settings.js
+++ b/ghost/admin/models/settings.js
@@ -3,7 +3,7 @@
"use strict";
//id:0 is used to issue PUT requests
Ghost.Models.Settings = Backbone.Model.extend({
- url: Ghost.settings.apiRoot + '/settings?type=blog,theme',
+ url: Ghost.settings.apiRoot + '/settings/?type=blog,theme',
id: "0"
});
diff --git a/ghost/admin/models/tag.js b/ghost/admin/models/tag.js
index 9ab0f9098e..b3be4b6d23 100644
--- a/ghost/admin/models/tag.js
+++ b/ghost/admin/models/tag.js
@@ -3,6 +3,6 @@
"use strict";
Ghost.Collections.Tags = Backbone.Collection.extend({
- url: Ghost.settings.apiRoot + '/tags'
+ url: Ghost.settings.apiRoot + '/tags/'
});
}());
diff --git a/ghost/admin/models/themes.js b/ghost/admin/models/themes.js
new file mode 100644
index 0000000000..47549b758d
--- /dev/null
+++ b/ghost/admin/models/themes.js
@@ -0,0 +1,9 @@
+/*global window, document, Ghost, $, _, Backbone */
+(function () {
+ "use strict";
+
+ Ghost.Models.Themes = Backbone.Model.extend({
+ url: Ghost.settings.apiRoot + '/themes'
+ });
+
+}());
\ No newline at end of file
diff --git a/ghost/admin/models/user.js b/ghost/admin/models/user.js
index 42933487e0..d4317e1516 100644
--- a/ghost/admin/models/user.js
+++ b/ghost/admin/models/user.js
@@ -3,11 +3,11 @@
"use strict";
Ghost.Models.User = Backbone.Model.extend({
- url: Ghost.settings.apiRoot + '/users/me'
+ url: Ghost.settings.apiRoot + '/users/me/'
});
// Ghost.Collections.Users = Backbone.Collection.extend({
-// url: Ghost.settings.apiRoot + '/users'
+// url: Ghost.settings.apiRoot + '/users/'
// });
}());
diff --git a/ghost/admin/models/widget.js b/ghost/admin/models/widget.js
index ec0c47b3d1..e2f7ae5350 100644
--- a/ghost/admin/models/widget.js
+++ b/ghost/admin/models/widget.js
@@ -36,7 +36,7 @@
});
Ghost.Collections.Widgets = Backbone.Collection.extend({
- // url: Ghost.settings.apiRoot + '/widgets', // What will this be?
+ // url: Ghost.settings.apiRoot + '/widgets/', // What will this be?
model: Ghost.Models.Widget
});
diff --git a/ghost/admin/router.js b/ghost/admin/router.js
index 88b6f8a5ee..b9dbe34255 100644
--- a/ghost/admin/router.js
+++ b/ghost/admin/router.js
@@ -7,10 +7,8 @@
routes: {
'' : 'blog',
'content/' : 'blog',
- 'settings/' : 'settings',
- 'settings(/:pane)' : 'settings',
- 'editor/' : 'editor',
- 'editor(/:id)' : 'editor',
+ 'settings(/:pane)/' : 'settings',
+ 'editor(/:id)/' : 'editor',
'debug/' : 'debug',
'register/' : 'register',
'signup/' : 'signup',
@@ -40,7 +38,7 @@
settings: function (pane) {
if (!pane) {
// Redirect to settings/general if no pane supplied
- this.navigate('/settings/general', {
+ this.navigate('/settings/general/', {
trigger: true,
replace: true
});
diff --git a/ghost/admin/tpl/settings/general.hbs b/ghost/admin/tpl/settings/general.hbs
index a9eded36df..a6f81cb771 100644
--- a/ghost/admin/tpl/settings/general.hbs
+++ b/ghost/admin/tpl/settings/general.hbs
@@ -26,7 +26,7 @@
{{#if logo}}
{{else}}
- Upload Image
+ Upload Image
{{/if}}
Display a sexy logo for your publication
@@ -36,7 +36,7 @@ {{#if cover}}Display a cover image on your site
diff --git a/ghost/admin/views/blog.js b/ghost/admin/views/blog.js index 158a3d37fe..6d4bb754e2 100644 --- a/ghost/admin/views/blog.js +++ b/ghost/admin/views/blog.js @@ -186,7 +186,7 @@ e.preventDefault(); // for now this will disable "open in new tab", but when we have a Router implemented // it can go back to being a normal link to '#/ghost/editor/X' - window.location = '/ghost/editor/' + this.model.get('id'); + window.location = '/ghost/editor/' + this.model.get('id') + '/'; }, templateName: "preview", diff --git a/ghost/admin/views/editor.js b/ghost/admin/views/editor.js index 18938065bb..d9aa0346aa 100644 --- a/ghost/admin/views/editor.js +++ b/ghost/admin/views/editor.js @@ -94,7 +94,7 @@ }); this.listenTo(this.model, 'change:status', this.render); this.model.on('change:id', function (m) { - Backbone.history.navigate('/editor/' + m.id); + Backbone.history.navigate('/editor/' + m.id + '/'); }); }, @@ -660,4 +660,4 @@ }); }; -}()); \ No newline at end of file +}()); diff --git a/ghost/admin/views/settings.js b/ghost/admin/views/settings.js index 44ec30c989..7710ddb79b 100644 --- a/ghost/admin/views/settings.js +++ b/ghost/admin/views/settings.js @@ -59,7 +59,7 @@ var self = this, model; - Ghost.router.navigate('/settings/' + id); + Ghost.router.navigate('/settings/' + id + '/'); Ghost.trigger('urlchange'); if (this.pane && id === this.pane.el.id) { return;