View organisations.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension GitKit { | |
public class func getMyOrganisations() -> Observable<[Organisation]> { | |
guard let organisationsURL = GitKit.currentUser.value?.organizationsUrl else { return Observable.just([]) } | |
return Alamofire.request(.GET, (organisationsURL)) | |
.rx_responseJSON() | |
.map { response, json in | |
guard let array = json as? [[String:AnyObject]] else { return [] } |
View gist:eaf5a4698ee985a814cc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<label ng-repeat="material in materials" class="materials col-lg-8 col-lg-offset-2 debug" style="border-right: 1px solid black;"> | |
<div class="inner"> | |
<input type="checkbox" ng-model="materials" ng-click="select(item)" checklist-model="choices.materials" checklist-value="material"> | |
<i class="icon-{{material | lowercase}}" ng-class="{class: materials}"></i> {{material | capitalize}} | |
</div> | |
</label> |
View gist:5a8dc8bb00e99688c0ec
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(angular) { | |
'use strict'; | |
angular.module('store', ['ngRoute']) | |
.controller('MainController', ['$scope','$route','$routeParams','$location', function($scope, $route, $routeParams, $location) { | |
$scope.$route = $route; | |
$scope.$location = $location; | |
$scope.$routeParams = $routeParams; | |
}]) |