Merge branch 'master' of https://github.com/TelescopeJS/Telescope into devel

Conflicts:
	.meteor/versions
This commit is contained in:
Sacha Greif 2014-12-27 12:01:19 +09:00
commit 87548b4903
5 changed files with 29 additions and 28 deletions

View file

@ -13,10 +13,10 @@ artwells:queue@0.0.3
autoupdate@1.1.4
backbone@1.0.0
base64@1.0.2
bengott:avatar@0.7.2
bengott:avatar@0.7.3
binary-heap@1.0.2
blaze@2.0.4
blaze-tools@1.0.2
blaze@2.0.4
boilerplate-generator@1.0.2
callback-hook@1.0.2
ccan:cssreset@1.0.0

View file

@ -172,27 +172,27 @@
"start_posting": "开始发布.",
// Translation needed (found during migration to tap:i18n)
"please_fill_in_a_title": "Please fill in a title",
"seconds_before_posting_again": " seconds before posting again",
"upvoted": "Upvoted",
"posted_date": "Posted Date",
"posted_time": "Posted Time",
"posted_date": "Posted Date",
"posted_time": "Posted Time",
"profile": "Profile",
"sign_out": "Sign Out",
"invitedcount": "InvitedCount",
"invites": "Invites",
"invited": "Invited?",
"admin": "Admin",
"actions": "Actions",
"please_fill_in_a_title": "请填写标题",
"seconds_before_posting_again": "秒前发布",
"upvoted": "最多投票",
"posted_date": "发布日期",
"posted_time": "发布时间",
"posted_date": "发布日期",
"posted_time": "发布时间",
"profile": "个人中心",
"sign_out": "登出",
"invitedcount": "邀请总数",
"invites": "邀请",
"invited": "邀请?",
"admin": "管理",
"actions": "操作",
"invites_left": "invites left",
"id": "ID",
"name": "Name:",
"name": "名字:",
"bio": "Bio:",
"github": "GitHub",
"site": "Site",
"upvoted_posts": "Upvoted Posts",
"site": "网址",
"upvoted_posts": "最多踩",
"downvoted_posts": "Downvoted Posts",
"mark_as_read": "Mark as read",

View file

@ -6,7 +6,7 @@ Meteor.startup(function () {
action: function() {
var campaign = buildCampaign(getCampaignPosts(getSetting('postsPerNewsletter', 5)));
var campaignSubject = '<div class="campaign-subject"><strong>Subject:</strong> '+campaign.subject+' (note: contents might change)</div>';
var campaignSchedule = '<div class="campaign-schedule"><strong>Scheduled for:</strong> '+getNextCampaignSchedule()+'</div>';
var campaignSchedule = '<div class="campaign-schedule"><strong>Scheduled for:</strong> '+ Meteor.call('getNextJob') +'</div>';
this.response.write(campaignSubject+campaignSchedule+campaign.html);
this.response.end();

View file

@ -17,7 +17,7 @@
<span class="post-submitted">Submitted by <a href="{{profileUrl}}" class="comment-link" target="_blank">{{authorName}}</a></span>
<span class="post-date">on {{date}}</span>
|
<a href="{{postPageLink}}" class="comment-link" target="_blank">{{comments}} Comments</a>
<a href="{{postPageLink}}" class="comment-link" target="_blank">{{commentCount}} Comments</a>
</div>

View file

@ -58,11 +58,12 @@ var migrationsList = {
Posts.update(post._id, {$set: {status: 2}});
console.log("---------------------");
console.log("Post: "+post.title);
console.log("Updating status to approved");
console.log("Updating status to approved");
});
return i;
},
updateCategories: function () {
if (typeof Categories === "undefined" || Categories === null) return;
var i = 0;
Categories.find({slug: {$exists : false}}).forEach(function (category) {
i++;
@ -71,11 +72,11 @@ var migrationsList = {
console.log("---------------------");
console.log("Category: "+category.name);
console.log("Updating category with new slug: "+slug);
});
return i;
},
updatePostCategories: function () {
if (typeof Categories === "undefined" || Categories === null) return;
var i = 0;
Posts.find().forEach(function (post) {
i++;
@ -140,7 +141,7 @@ var migrationsList = {
// update postCount
var postsByUser = Posts.find({userId: user._id});
properties.postCount = postsByUser.count();
// update commentCount
var commentsByUser = Comments.find({userId: user._id});
properties.commentCount = commentsByUser.count();
@ -282,7 +283,7 @@ var migrationsList = {
addLastCommentedAt: function () {
var i = 0;
Posts.find({$and: [
{comments: {$gt: 0}},
{comments: {$gt: 0}},
{lastCommentedAt: {$exists : false}}
]}).forEach(function (post) {
i++;
@ -416,7 +417,7 @@ var migrationsList = {
var result = Posts.update(post._id, {$set: {categories: justCategoryIds, oldCategories: post.categories}}, {multi: true, validate: false});
console.log("---------------------");
});
return i;
return i;
},
cleanUpStickyProperty: function () {
var i = 0;
@ -426,8 +427,8 @@ var migrationsList = {
var result = Posts.update(post._id, {$set: {sticky: false}}, {multi: true, validate: false});
console.log("---------------------");
});
return i;
return i;
}
};
// TODO: normalize categories?
// TODO: normalize categories?