Skip to content

Instantly share code, notes, and snippets.

Avatar

Leor Brenman lbrenman

View GitHub Profile
@lbrenman
lbrenman / MOCK_DATA.js
Created Aug 13, 2016
Arrow - How to Populate Your Arrow Builder Project With Data
View MOCK_DATA.js
module.exports = {
data: [
{"Name":"Demivee","Type":"Prospect","Phone":"1-(818)173-8443"},
{"Name":"Shufflester","Type":"Prospect","Phone":"93-(232)869-5557"},
{"Name":"Voonte","Type":"Customer","Phone":"62-(269)473-1186"},
{"Name":"Thoughtsphere","Type":"Prospect","Phone":"86-(902)994-3017"},
{"Name":"Zoonder","Type":"Customer","Phone":"1-(202)358-2758"},
{"Name":"Flashspan","Type":"Customer","Phone":"57-(126)114-4912"},
{"Name":"Yoveo","Type":"Customer","Phone":"593-(320)380-5127"},
@lbrenman
lbrenman / app.tss
Created Aug 12, 2016
Titanium Master Detail Pass Data from TableView Row Example
View app.tss
/*
This is your global styles file. Selectors and rules you define
here will be applied throughout your app. However, these rules
have the lowest priority of any style settings.
For more information, see the "Style Priorities" section of
http://docs.appcelerator.com/platform/latest/#!/guide/Alloy_Styles_and_Themes
For example, the following would apply to all labels, windows,
@lbrenman
lbrenman / app.tss
Created Aug 12, 2016
Titanium Master Detail Basic Example
View app.tss
/*
This is your global styles file. Selectors and rules you define
here will be applied throughout your app. However, these rules
have the lowest priority of any style settings.
For more information, see the "Style Priorities" section of
http://docs.appcelerator.com/platform/latest/#!/guide/Alloy_Styles_and_Themes
For example, the following would apply to all labels, windows,
@lbrenman
lbrenman / places.js
Created Aug 12, 2016
Arrow Builder Custom API for Google Places
View places.js
var Arrow = require('arrow');
var request = require('request');
var apikey = '<YOUR GOOGLE PLACES API KEY>';
var baseurl = 'https://maps.googleapis.com/maps/api/place/nearbysearch/json?radius=500&type=restaurant&key='+apikey+'&location=';
var location = '-33.8670522,151.1957362'
var Places = Arrow.API.extend({
group: 'places',
path: '/api/places',
method: 'GET',
@lbrenman
lbrenman / Lbsfdemoapi.js
Last active Jul 28, 2016
Appcelerator Arrow Client SDK Example
View Lbsfdemoapi.js
var config = {
headers: {},
timeout: 30000,
domain: 'http://localhost',
port: 0
};
var NoCache = 1,
CacheElseNetwork = 2,
NetworkElseCache = 4,
View Android Soft Keyboard Tip.md

Developer Tip for Managing the Android Soft Keyboard

The Android soft keyboard will display when an input field, such as textField, is in focus (e.g. a finger touch in the textField is sensed by the device). Normally, this is the behavior we want.

However, what if the first screen of your app is a login screen? Then we may not want the keyboard to launch as it may obscure information on the screen that we want the user to see before logging in.

In this case, the reason the keyboard launches immediately is because in the screen above, the textField is the first focusable field on the screen and that is where the focus will be.

@lbrenman
lbrenman / README.md
Last active Jul 22, 2016
Appcelerator Titanium Simple Rest Call to Populate a TableView
View README.md

#Simple Appcelerator Titanium app to make a REST web service call and populate a TableViewRow

Â

@lbrenman
lbrenman / Account.js
Last active Jul 8, 2016
Arrow API Swagger Interface
View Account.js
var Arrow = require('arrow');
var Model = Arrow.Model.reduce('appc.salesforce/Account', 'Account', {
fields: {
Name: {
type: String,
description: 'Account Name',
maxlength: 255,
required: true,
optional: false
@lbrenman
lbrenman / MyArrowApp.js
Last active Jun 3, 2016
Arrow Client Side SDK Example
View MyArrowApp.js
var config = {
headers: {},
timeout: 30000,
domain: 'http://localhost',
port: 0
};
var NoCache = 1,
CacheElseNetwork = 2,
NetworkElseCache = 4,
@lbrenman
lbrenman / README.md
Last active Jun 3, 2016
Appcelerator Arrow Titanium Client Side SDK Example (SOAP)
View README.md

Appcelerator Arrow Client Side SDK example

In a prior post, I described how to use the Appcelerator Arrow SOAP connector to expose a SOAP Weather service as a mobile optimized REST API. The Arrow Admin console enables you to test the APIs and also provides sample code to consume the API as shown below:

The Titanium code sample provided in the admin console shows how to manually make an HTTPClient web service call.

Generate the SDK

You can’t perform that action at this time.