Skip to content

Commit

Permalink
Merge pull request #130 from hckrs/development
Browse files Browse the repository at this point in the history
Release v3.3 bugfixes + speedup
  • Loading branch information
JarnoLeConte committed Nov 19, 2015
2 parents 6fa8d64 + 02641ba commit 704c0d7
Show file tree
Hide file tree
Showing 443 changed files with 459 additions and 403 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
hckrs.io ![hckrs icon](https://s3.amazonaws.com/hckrs.io/static/logo/logo-icon-vector-mini.png)
=========

[**hckrs.io**](http://hckrs.io) is an invite only platform for hackers; for basicly anyone who has to make stuff, somehow related to technology. ***#web #design #growth #hardware #life...***
[**hckrs.io**](http://hckrs.io) is an invite only platform for hackers; for basicly anyone who has to make stuff, somehow related to technology. ***#web #design #growth #hardware #life...***
[**Join your local city**](http://hckrs.io) to see it in action. *(Europe only for now)*

<a href="http://hckrs.io"><img src="https://s3.amazonaws.com/hckrs.io/static/preview/preview1.jpg" alt="Screenshot hckrs.io" ></a>
Expand All @@ -18,16 +18,16 @@ Get you hacking
######1. [Download](https://github.com/Jarnoleconte/hckrs.io/archive/development.zip) / clone this repo.
######2. Go to the ***hckrs*** folder in your terminal.
######3. Install dependencies: `source ./tools/install.sh`
######4. Move to the project `cd web` and startup a local server `hckrs run`
######5. Open [http://localhost:3000](http://localhost:3000) in your browser and login with ***Twitter*** ([why?](https://github.com/Jarnoleconte/hckrs.io/wiki/Run-Project#login-at-the-site))
######4. Start up a local server `hckrs run`
######5. Open [http://localhost:3000](http://localhost:3000) in your browser and login with ***Twitter*** ([why?](https://github.com/Jarnoleconte/hckrs.io/wiki/Run-Project#login-at-the-site))

*Support for* ***OS X*** *and* ***Linux*** *right now.*
*Meteor has no solid support for windows yet.*




Roadmap
Roadmap
--------

* Subcultures with meetups
Expand All @@ -49,10 +49,10 @@ Roadmap
Documentation
--------------

Read the [wiki](https://github.com/Jarnoleconte/hckrs.io/wiki) to get understanding of the project structure.
Read the [wiki](https://github.com/Jarnoleconte/hckrs.io/wiki) to get understanding of the project structure.

Techniqual documentation is available during development.
Start up a local server and navigate in your browser to:
Techniqual documentation is available during development.
Start up a local server and navigate in your browser to:
[http://localhost:3000/docs](http://localhost:3000/docs)


Expand All @@ -67,19 +67,19 @@ Partners in crime
The [hckrs.io](http://hckrs.io) core team is open.

Toon | Jarno | Daan | Daniël | Steven
:---:|:-----:|:----:|:------:|:------:
:---:|:-----:|:----:|:------:|:------:
<a href="https://github.com/ramshorst"><img src="https://avatars0.githubusercontent.com/u/5200239?v=3&s=80" width="80" alt="Toon van Ramshorst" style="width:80px;height:80px;border-radius: 40px;"></a> | <a href="https://github.com/Jarnoleconte"><img src="https://avatars0.githubusercontent.com/u/279767?v=3&s=80" alt="Jarno Le Conté" width="80" style="width:80px;height:80px;border-radius: 40px;"></a> | <a href="https://github.com/daanvr"><img src="https://avatars0.githubusercontent.com/u/4609765?v=3&s=80" alt="Daan van Ramshorst" width="80" style="width:80px;height:80px;border-radius: 40px;"></a> | <a href="https://github.com/Dandandan"><img src="https://avatars0.githubusercontent.com/u/163737?v=3&s=80" alt="Daniël Heres" width="80" style="width:80px;height:80px;border-radius: 40px;"></a> | <a href="https://github.com/Mellowlicious"><img src="https://avatars0.githubusercontent.com/u/8102336?v=3&s=80" alt="Steven den Hartog" width="80" style="width:80px;height:80px;border-radius: 40px;"></a>
co-founder | lead-dev | growth | core-dev | core-dev


Getting involved?
------------------

No need to be a developer to contribute. We have ambitous plans that require all kinds of skills, you may be good in ***video, story telling, copywriting, blogging, interviewing/podcasting, mobile apps, events, curation, hackatons, recruitment***.
No need to be a developer to contribute. We have ambitous plans that require all kinds of skills, you may be good in ***video, story telling, copywriting, blogging, interviewing/podcasting, mobile apps, events, curation, hackatons, recruitment***.

We are looking for people that make things happen. (**BAM!**)

It's also okay to just start developing (making changes to this repo). Feel free to work on issues or add your own. Do a pull request when you are done.
It's also okay to just start developing (making changes to this repo). Feel free to work on issues or add your own. Do a pull request when you are done.

**GO!**

Expand Down
88 changes: 37 additions & 51 deletions web/Routes.js → Routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ FrontpageController = DefaultController.extend({
template: 'frontpage',
waitOn: function() {
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('staff'),
Meteor.subscribe('ambassadors')
];
Expand All @@ -131,51 +130,42 @@ FrontpageController = DefaultController.extend({
AgendaController = DefaultController.extend({
template: 'agenda',
waitOn: function () {
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('users') // XXX be more precise
];
return [];
}
});

BooksController = DefaultController.extend({
template: 'books',
waitOn: function () {
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('users') // XXX be more precise
];
return [];
}
});

DealsController = DefaultController.extend({
template: 'deals',
waitOn: function () {
var city = Url.city();
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('users') // XXX be more precise
].concat(!city ? [] : [
Meteor.subscribe('deals', city),
Meteor.subscribe('dealsSort', city)
]);
];
}
});

HackerController = DefaultController.extend({
template: 'hacker',
waitOn: function () {
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('users') // XXX be more precise
Meteor.subscribe('userByBitHash', this.params.bitHash)
];
},
onBeforeAction: function() {
if (this.ready() && !this.initialized) {
if (this.ready()) {
var userId = (Users.userForBitHash(this.params.bitHash) || {})._id;
Session.set('hackerId', userId);
Session.set('hackerEditMode', Users.myProp('isAccessDenied'));
this.initialized = true;
if (Users.myProp('isAccessDenied'))
Session.set('hackerEditMode', true);
}
this.next();
}
Expand All @@ -184,10 +174,12 @@ HackerController = DefaultController.extend({
HackersController = DefaultController.extend({
template: 'hackers',
waitOn: function () {
var city = Url.city();
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('invitations'),
Meteor.subscribe('users') // XXX be more precise
Meteor.subscribe('usersOfCity', city),
Meteor.subscribe('usersInvitedByUser', Meteor.userId())
];
}
});
Expand All @@ -197,13 +189,12 @@ HighlightsController = DefaultController.extend({
template: 'highlights',
waitOn: function() {
var city = Url.city();
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('users') // XXX be more precise
].concat(!city ? [] : [
Meteor.subscribe('usersOfHighlightsOfCity', city),
Meteor.subscribe('highlights', city),
Meteor.subscribe('highlightsSort', city)
]);
];
},
onBeforeAction: function() {
var city = Session.get('currentCity');
Expand All @@ -224,10 +215,11 @@ HighlightsController = DefaultController.extend({
InvitationsController = DefaultController.extend({
template: 'invitations',
waitOn: function () {
var city = Url.city();
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('invitations'),
Meteor.subscribe('users') // XXX be more precise
Meteor.subscribe('usersInvitedByUser', Meteor.userId())
];
}
});
Expand All @@ -236,13 +228,12 @@ MapController = DefaultController.extend({
template: 'map',
waitOn: function () {
var city = Url.city();
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('users') // XXX be more precise
].concat(!city ? [] : [
Meteor.subscribe('usersOfCity', city),
Meteor.subscribe('places', city),
Meteor.subscribe('mapHackersLocations', {excludeCity: city}) // load anonym location data of all users world wide (XXX TODO: async)
]);
];
},
onAfterAction: function() {
Interface.setHeaderStyle('fixed');
Expand Down Expand Up @@ -308,7 +299,7 @@ AdminController = DefaultAdminController.extend({
return [];
},
onBeforeAction: function() {
this.redirect('admin_hackers');
this.redirect('admin_highlights');
}
});

Expand All @@ -322,12 +313,11 @@ AdminDashboardController = DefaultAdminController.extend({
AdminDealsController = DefaultAdminController.extend({
template: 'admin_deals',
waitOn: function () {
var city = Session.get('currentCity');
var isAdmin = Users.hasAdminPermission();
var city = Session.get('currentCity');
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('deals', isAdmin ? 'all' : city),
Meteor.subscribe('users') // XXX be more precise
Meteor.subscribe('deals', isAdmin ? 'all' : city)
];
}
});
Expand All @@ -336,9 +326,7 @@ AdminEmailTemplatesController = DefaultAdminController.extend({
template: 'admin_emailTemplates',
waitOn: function () {
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('emailTemplates'),
Meteor.subscribe('users') // XXX be more precise
Meteor.subscribe('emailTemplates')
];
}
});
Expand All @@ -350,34 +338,33 @@ AdminGrowthController = DefaultAdminController.extend({
},
waitOn: function () {
return [
Meteor.subscribe('currentUser'),
// load all github users from the selected city
Meteor.subscribe('growthGithub', AdminGrowth.getCity()),
Meteor.subscribe('emailTemplates'),
Meteor.subscribe('users') // XXX be more precise
Meteor.subscribe('emailTemplates')
];
}
});

AdminHackersController = DefaultAdminController.extend({
template: 'admin_hackers',
waitOn: function () {
var isAdmin = Users.hasAdminPermission();
var city = Session.get('currentCity');
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('users') // XXX be more precise
isAdmin ? Meteor.subscribe('usersAll') : Meteor.subscribe('usersOfCity', city)
];
}
});

AdminHighlightsController = DefaultAdminController.extend({
template: 'admin_highlights',
waitOn: function () {
var city = Session.get('currentCity');
var isAdmin = Users.hasAdminPermission();
var city = Session.get('currentCity');
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('highlights', isAdmin ? 'all' : city),
Meteor.subscribe('users') // XXX be more precise
Meteor.subscribe('highlights', isAdmin ? 'all' : city)
];
}
});
Expand All @@ -386,12 +373,11 @@ AdminHighlightsController = DefaultAdminController.extend({
AdminPlacesController = DefaultAdminController.extend({
template: 'admin_places',
waitOn: function () {
var city = Session.get('currentCity');
var isAdmin = Users.hasAdminPermission();
var city = Session.get('currentCity');
if (!city) return [];
return [
Meteor.subscribe('currentUser'),
Meteor.subscribe('places', isAdmin ? 'all' : city),
Meteor.subscribe('users') // XXX be more precise
Meteor.subscribe('places', isAdmin ? 'all' : city)
];
}
});
Expand Down
File renamed without changes.
5 changes: 5 additions & 0 deletions web/client/admin/admin.js → client/admin/admin.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,14 @@ Field.fn.avatar = function(val) {
/* DATA FIELD templates */

Field.edit = {
fieldId: 'id',
key: 'id',
label: 'edit',
tmpl: Template.reactiveTable_editButton
}

Field.date = {
fieldId: 'createdAt',
key: 'createdAt',
label: 'date',
sortByValue: true,
Expand All @@ -56,6 +58,7 @@ Field.date = {
}

Field.city = {
fieldId: 'city',
key: 'city',
label: 'city',
fn: function(val, obj) {
Expand All @@ -65,6 +68,7 @@ Field.city = {
}

Field.private = {
fieldId: 'private',
key: 'private',
label: 'private',
fn: function(val, obj) {
Expand All @@ -74,6 +78,7 @@ Field.private = {
}

Field.url = {
fieldId: 'url',
key: 'url',
label: 'url',
fn: function(val, obj) {
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ Template.admin_deals.helpers({
Field.date,
Field.city,
Field.private,
'title',
'description',
{ fieldId: 'title', key: 'title', label: 'title'},
{ fieldId: 'description', key: 'description', label: 'description'},
Field.url,
'code'
{ fieldId: 'code', key: 'code', label: 'code'},
],
}
}
Expand Down
Loading

0 comments on commit 704c0d7

Please sign in to comment.