Skip to content

Instantly share code, notes, and snippets.

View vinsonizer's full-sized avatar

Jason Vinson vinsonizer

  • Charlotte Metro, USA
View GitHub Profile
@vinsonizer
vinsonizer / groupCtrlSpec.js
Created December 30, 2015 22:10
Additional Methods on Group Controller for edit/save behavior
'use strict';
describe('Groups Controller', function() {
var scope, ctrl, groups, user, guild, $rootScope;
beforeEach(function() {
module(function($provide) {
$provide.value('User', {});
});
@vinsonizer
vinsonizer / Pivot.scala
Created October 19, 2012 19:18
Sample Pivot Table starter implementation
package pivot
class Pivot(val rows: List[List[String]]) {
val headers = rows.head.zipWithIndex.map(_.swap)
val body = rows.tail
def addCalcCol(f: List[String] => String)(newColName: String) : Pivot = {
val newRows = (headers.map(_._2) :+ newColName) +:
body.map(row => { row :+ f(row)})