Skip to content

Instantly share code, notes, and snippets.

View liorkesos's full-sized avatar
😎
chillin

Lior Kesos liorkesos

😎
chillin
View GitHub Profile
//
// Badge.h
//
// Created by Simon Madine on 29/04/2010.
// Copyright 2010 The Angry Robot Zombie Factory.
// MIT licensed
//
// Converted to Cordova by Joseph Stuhr.
//
//
// BackTrack.m
//
#import "BackTrack.h"
@implementation BackTrack
- (void)startTrack:(NSMutableArray*)badgeNumber withDict:(NSMutableDictionary*)options {
@liorkesos
liorkesos / gist:2342595
Created April 9, 2012 09:49
BackTrack.js
/*
* This code is adapted from the work of Michael Nachbaur
* by Simon Madine of The Angry Robot Zombie Factory
* 2010-05-04
* MIT licensed
*
* Converted to Cordova by Joseph Stuhr.
*/
/**
function similarDate() {
var now = new Date();
var sec=now.getSeconds();
if( sec < 10 )
sec='0'+sec;
var min=now.getMinutes();
if( min < 10 )
min='0'+min;
var hour=now.getHours();
if( hour < 10 )
@liorkesos
liorkesos / dashboard.js
Last active December 16, 2015 18:49
The wierd issue here is that stuff that I put on the scope within the success - doesn't work. - actually nothing in the update function persists in scope. I see that the request is fine because I see the console.log at line 36. The controller is defined in index.html that ng-includes profile.html For instance the $scope.authenticated is not set …
function DashboardController($scope, $http, $location) {
$scope.list = ['ש.עבודה','משימות','הודעות','מערכת','מבחנים'];
$scope.test = ['1','2','3','4'];
$scope.dis='none';
$scope.start=function () {
console.log("hello");
}
$scope.show=function (item) {
if (item=='מערכת') {
@liorkesos
liorkesos / File Stucture
Last active December 17, 2015 01:28
A sequence of files which get called and enable an angular.js app The app structure looks like this
app
index.html
app.js
css/
js/
controllers/
youtubeSearch.js
services/
views/
main.html
@liorkesos
liorkesos / info.html
Created July 25, 2013 13:27
internal object links
<section data-ng-controller="TripController">
<h1>Trip Information</h1>
<accordion close-others="oneAtATime">
<accordion-group heading="{{group.title}}" ng-repeat="group in groups">
{{group.content}}
<ul ng-repeat="link in {{group.links}}">
<li>{{link}}</li>li>
</ul>
</accordion-group>
</accordion>
@liorkesos
liorkesos / 1 - server.js
Last active November 22, 2016 16:54
MEAN.io code walkthrough
/*!
* nodejs-express-mongoose-demo
* Copyright(c) 2013 Madhusudhan Srinivasa <madhums8@gmail.com>
* MIT Licensed
*/
/**
* Module dependencies.
*/
@liorkesos
liorkesos / gist:6211471
Created August 12, 2013 14:49
Question about filter in angular
<section id="admin" data-ng-controller="AdminController">
Routes are
<h1>
foobar</h1>
<ul>
<li ng-repeat="route in routes | filter:templateUrl ">
r is - {{route.templateUrl}}
</li>
</ul>
</section>
@liorkesos
liorkesos / angular cms.js service
Last active December 21, 2015 06:29
editable shit
window.app.factory("CMS", function(Global, $resource) {
var _this = this;
_this.content = {};
_this.content["index"] = {
en: {
signupbutton: "sign up now",
signuptext: "for more info",
picsign: "Your free 10 days trip to Israel starts here",
whatstitle: "What's it all about?",