From fbb875f5d1b81ef573c0f05a6f46f354e7ef5a13 Mon Sep 17 00:00:00 2001 From: Hannah Wolfe Date: Wed, 4 Sep 2013 21:05:36 +0100 Subject: [PATCH] Removing api calls from server side closes #603, issue #395 - Changed hard-coded 'JOE BLOGGS' to use author data - We still had api calls loading data server side before rendering pages.. which is unnecessary. - Only thing using this was editor title, which is now populated client side - May improve content screen load time. --- ghost/admin/tpl/preview.hbs | 2 +- ghost/admin/views/editor.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/ghost/admin/tpl/preview.hbs b/ghost/admin/tpl/preview.hbs index 7ff02722df..16480506f4 100644 --- a/ghost/admin/tpl/preview.hbs +++ b/ghost/admin/tpl/preview.hbs @@ -5,7 +5,7 @@ {{! TODO: JavaScript toggle featured/unfeatured}} {{#if published}}Published{{else}}Written{{/if}} by - Joe Bloggs + {{#if author.name}}{{author.name}}{{else}}{{author.email_address}}{{/if}}
diff --git a/ghost/admin/views/editor.js b/ghost/admin/views/editor.js index 367eebe91b..7cf916ffb1 100644 --- a/ghost/admin/views/editor.js +++ b/ghost/admin/views/editor.js @@ -239,6 +239,7 @@ // Add the container view for the Publish Bar this.addSubview(new PublishBar({el: "#publish-bar", model: this.model})).render(); + this.$('#entry-title').val(this.model.get('title')); this.$('#entry-markdown').html(this.model.get('content_raw')); this.initMarkdown();