Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View mwawrusch's full-sized avatar

Martin Wawrusch mwawrusch

View GitHub Profile
//
// ViewController.swift
// TestLive
//
// Created by Martin Wawrusch on 6/9/17.
//
import UIKit
import lf
import AVFoundation
/**
* import {checkIfSessionActive} from '.../session.service';
* @CanActivate(checkIfSessionActive)
*/
export function checkIfSessionActive(next: ComponentInstruction, prev) : Promise<boolean> {
let injector = Injector.resolveAndCreate([SessionService,
ApiClientService,
TokenService,
LoggerService,
LocalStorageService,
_ = require 'underscore'
Hoek = require 'hoek'
Boom = require 'boom'
async = require 'async'
helperProductFeeds = require './helper-product-feeds'
arnConstants = require './arn-constants'
stateConstants = require './state-constants'
helperProductFeedIdFromMessage = require './helper-product-feed-id-from-message'
helperInvokeTransloadit = require './helper-invoke-transloadit'
_ = require 'underscore'
Hoek = require 'hoek'
transloadit = require 'transloadit'
###
Sends a post request to transloadit to start image processing.
###
module.exports = (testMode,authKey,authSecret,templateId,notifyUrl,sourceUrl,productFeedId,cb) ->
Hoek.assert _.isString(authKey),"The required parameter authKey is missing or not a string."
/Users/mwawrusch/.rvm/gems/ruby-1.9.3-p362/gems/iron_core-1.0.1/lib/iron_core/iron_logger.rb:50:in `raise_exception': Error while remote building worker (IronCore::Error)
Successfully installed net-http-persistent-2.9.4
Successfully installed netrc-0.10.3
Successfully installed rest-3.0.6
Successfully installed iron_core-1.0.7
Successfully installed bundler-1.8.5
Successfully installed rubyzip-0.9.9
Successfully installed iron_worker_ng-1.3.0
7 gems installed
I, [2015-03-17T22:27:12.759629 #18] INFO -- IronWorkerNG: Found workerfile with path='send-event-reminder.worker'
helper-build-query
{"wildcard":{"displayName":"*"}}
✓ an empty query
{"filtered":{"query":{"bool":{"must":[{"match":{"displayName":"ama"}}]}}}}
✓ a query text query
{"filtered":{"query":{"bool":{"must":[{"match":{"displayName":"ama"}},{"match":{"displayName":"bank"}}]}}}}
✓ a query text with multiple strings query
{"filtered":{"query":{"bool":{"must":[{"match":{"displayName":"ama"}},{"match":{"displayName":"bank"}}]}}}}
✓ a query text with multiple strings query and excessive white space
{"filtered":{"query":{"bool":{"must":[{"match":{"displayName":"côte"}},{"match":{"displayName":"d’ivoire"}}]}}}}
1 Images 1 / Sizes: 15 - Lory - Wht Blk Zebra Snk
2 Images 1 / Sizes: 15 - Lory - Lipstick Trop Stmpd Snk P
3 Images 1 / Sizes: 15 - Lory - Gold Dusty Metallic
4 Images 1 / Sizes: 15 - Lory - Black KidSuede
5 Images 1 / Sizes: 15 - Brielle - Blk Snk Stella
6 Images 1 / Sizes: 15 - Brielle - Dk Gye Gold Snk
7 Images 1 / Sizes: 15 - Czarnecki - Bone
8 Images 1 / Sizes: 15 - Yvone - Brownie
9 Images 1 / Sizes: 15 - Brasiliana - Atndo Soft Black
10 Images 1 / Sizes: 15 - Cyby - Atanado Real Dawn
#
# This is the main Apache HTTP server configuration file. It contains the
# configuration directives that give the server its instructions.
# See <URL:http://httpd.apache.org/docs/2.4/> for detailed information.
# In particular, see
# <URL:http://httpd.apache.org/docs/2.4/mod/directives.html>
# for a discussion of each configuration directive.
#
# Do NOT simply read the instructions in here without understanding
# what they do. They're here only as hints or reminders. If you are unsure
#
# Virtual Hosts
#
# If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <URL:http://httpd.apache.org/docs/2.2/vhosts/>
"data": {
"report": {
"rtmDaily": [{
"adgroup": "13980786660",
"type": "1",
"datetime": "2014-06-28 00:00:00",
"demo_data": "[{\"s\":\"100366\", \"uc\":\"1477\", \"ec\":\"1784\"}, {\"s\":\"100367\", \"uc\":\"290\", \"ec\":\"336\"}, {\"s\":\"100364\", \"uc\":\"718\", \"ec\":\"851\"}, {\"s\":\"100365\", \"uc\":\"410\", \"ec\":\"486\"}, {\"s\":\"100368\", \"uc\":\"240\", \"ec\":\"276\"}, {\"s\":\"100369\", \"uc\":\"932\", \"ec\":\"1105\"}, {\"s\":\"100370\", \"uc\":\"155\", \"ec\":\"191\"}, {\"s\":\"100649\", \"uc\":\"41\", \"ec\":\"44\"}, {\"s\":\"100648\", \"uc\":\"27\", \"ec\":\"30\"}, {\"s\":\"100906\", \"uc\":\"191\", \"ec\":\"220\"}, {\"s\":\"100647\", \"uc\":\"34\", \"ec\":\"46\"}, {\"s\":\"100907\", \"uc\":\"149\", \"ec\":\"165\"}, {\"s\":\"100374\", \"uc\":\"1428\", \"ec\":\"1649\"}, {\"s\":\"100373\", \"uc\":\"1565\", \"ec\":\"1819\"}, {\"s\":\"100372\", \"uc\":\"2490\", \"ec\":\"2925\"}, {\"s\":\"100371\", \"uc\":\