Skip to content

Instantly share code, notes, and snippets.

$ sudo nano /private/etc/hosts
@ashleycoker
ashleycoker / organisations.js
Created August 12, 2013 12:27
Updates organisation
/**
* Update organisation
*/
exports.update = function (req, res, next) {
var org = req.organisation;
org = _.extend(org, req.body);
org.save(function (err, org){
if ( err ) return next(err);
res.json({
@ashleycoker
ashleycoker / gist.js
Created August 9, 2013 12:23
Lazy data associations in ExtJS 4
Ext.require([
'Ext.data.*',
'Ext.panel.Panel',
'Ext.layout.container.Card',
'Ext.tip.QuickTipManager'
]);
Ext.define('Customer', {
extend: 'Ext.data.Model',
fields: [{