Merge branch 'feature-rules' of https://github.com/Angtrim/wekan into Angtrim-feature-rules

This commit is contained in:
Lauri Ojansivu 2018-09-16 00:10:40 +03:00
commit 6673b79738
60 changed files with 3074 additions and 259 deletions

View file

@ -56,6 +56,17 @@ Activities.before.insert((userId, doc) => {
doc.createdAt = new Date();
});
Activities.after.insert((userId, doc) => {
const activity = Activities._transform(doc);
RulesHelper.executeRules(activity);
});
if (Meteor.isServer) {
// For efficiency create indexes on the date of creation, and on the date of
// creation in conjunction with the card or board id, as corresponding views