diff --git a/app/lib/world/names.coffee b/app/lib/world/names.coffee index fc0a6aff9..d52471998 100644 --- a/app/lib/world/names.coffee +++ b/app/lib/world/names.coffee @@ -69,25 +69,18 @@ module.exports.thangNames = thangNames = "Buffy" "Allankrita" ] - "Peasant": [ + "Peasant M": [ "Yorik" "Hector" "Thad" "Victor" "Lyle" "Charles" - "Mary" - "Brandy" - "Gwendolin" - "Tabitha" - "Regan" "Yusef" "Hingle" "Azgot" "Piers" "Carlton" - "Giselle" - "Bernadette" "Hershell" "Gawain" "Durfkor" @@ -99,6 +92,13 @@ module.exports.thangNames = thangNames = "Icey" "Matilda" "Mertia" + "Mary" + "Brandy" + "Gwendolin" + "Tabitha" + "Regan" + "Giselle" + "Bernadette" ] "Archer F": [ "Phoebe" diff --git a/app/lib/world/vector.coffee b/app/lib/world/vector.coffee index 72f761775..ed5112f2c 100644 --- a/app/lib/world/vector.coffee +++ b/app/lib/world/vector.coffee @@ -8,7 +8,7 @@ class Vector a.copy()[name](b, useZ) isVector: true - apiProperties: ['x', 'y', 'magnitude', 'heading', 'distance', 'dot', 'equals', 'copy'] + apiProperties: ['x', 'y', 'magnitude', 'heading', 'distance', 'dot', 'equals', 'copy', 'distanceSquared'] constructor: (@x=0, @y=0, @z=0) -> diff --git a/app/templates/employers.jade b/app/templates/employers.jade index efeb59429..bfb2ca051 100644 --- a/app/templates/employers.jade +++ b/app/templates/employers.jade @@ -28,6 +28,7 @@ block content th(data-i18n="employers.candidate_last_updated") Last Updated if me.isAdmin() th ✓? + th ಥ_ಥ tbody for candidate, index in candidates @@ -57,4 +58,8 @@ block content if candidate.get('jobProfileApproved') td ✓ else - td ✗ \ No newline at end of file + td ✗ + if profile.active + td ᶘ ᵒᴥᵒᶅ + else + td ⨂_⨂ \ No newline at end of file diff --git a/scripts/mail.coffee b/scripts/mail.coffee index 7d51fee76..b9983b619 100644 --- a/scripts/mail.coffee +++ b/scripts/mail.coffee @@ -77,7 +77,8 @@ grabUser = (session, callback) -> totalEmailsSent = 0 emailUser = (user, callback) -> - return callback null, false if user.emails?.recruiting?.enabled is false # TODO: later, obey also "announcements" when that's untangled + #return callback null, false if user.emails?.anyNotes?.enabled is false # TODO: later, uncomment to obey also "anyNotes" when that's untangled + return callback null, false if user.emails?.recruitNotes?.enabled is false return callback null, false if user.email in alreadyEmailed return callback null, false if DEBUGGING and (totalEmailsSent > 1 or Math.random() > 0.1) ++totalEmailsSent diff --git a/server/users/user_handler.coffee b/server/users/user_handler.coffee index 212ed7685..cc6f279d3 100644 --- a/server/users/user_handler.coffee +++ b/server/users/user_handler.coffee @@ -235,9 +235,10 @@ UserHandler = class UserHandler extends Handler getCandidates: (req, res) -> authorized = req.user.isAdmin() or ('employer' in req.user.get('permissions')) since = (new Date((new Date()) - 2 * 30.4 * 86400 * 1000)).toISOString() - query = {'jobProfile.active': true, 'jobProfile.updated': {$gt: since}} - #query = {'jobProfile.updated': {$gt: since}} + #query = {'jobProfile.active': true, 'jobProfile.updated': {$gt: since}} + query = {'jobProfile.updated': {$gt: since}} query.jobProfileApproved = true unless req.user.isAdmin() + query['jobProfile.active'] = true unless req.user.isAdmin() selection = 'jobProfile' selection += ' email' if authorized selection += ' jobProfileApproved' if req.user.isAdmin() @@ -251,7 +252,7 @@ UserHandler = class UserHandler extends Handler fields = if authorized then ['jobProfile', 'jobProfileApproved', 'photoURL', '_id'] else ['jobProfile'] obj = _.pick document.toObject(), fields obj.photoURL ||= obj.jobProfile.photoURL if authorized - subfields = ['country', 'city', 'lookingFor', 'jobTitle', 'skills', 'experience', 'updated'] + subfields = ['country', 'city', 'lookingFor', 'jobTitle', 'skills', 'experience', 'updated', 'active'] if authorized subfields = subfields.concat ['name'] obj.jobProfile = _.pick obj.jobProfile, subfields