コード例 #1
0
var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');
WindowManager.include(

    '/windows/status/create',
    '/windows/status/update',
    '/windows/status/query',
    '/windows/status/remove',
    '/windows/status/search',
    '/windows/status/show'
);
exports['Status'] = function (evt) {
    var win = WindowManager.createWindow({
        backgroundColor: 'white'
    });
    var table = Ti.UI.createTableView({
        backgroundColor: '#fff',
        top: 0,
        data: Utils.createRows([
            'Create Status',
            'Query Status',
            'Search Statuses by User'
        ])
    });
    table.addEventListener('click', WindowManager.handleOpenWindow);
    win.add(table);
    return win;
};
コード例 #2
0
ファイル: table.js プロジェクト: chrishcollins/ti.cloud
var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');
WindowManager.include(

    '/windows/pushNotifications/query',
    '/windows/pushNotifications/notify',
    '/windows/pushNotifications/settings',
    '/windows/pushNotifications/subscribe',
    '/windows/pushNotifications/unsubscribe',
    '/windows/pushNotifications/notifyTokens',
    '/windows/pushNotifications/subscribeToken',
    '/windows/pushNotifications/unsubscribeToken',
    '/windows/pushNotifications/updateSubscription',
    '/windows/pushNotifications/showChannels',
    '/windows/pushNotifications/queryChannels',
    '/windows/pushNotifications/setBadge',
    '/windows/pushNotifications/resetBadge'
);
exports['Push Notifications'] = function () {
    var win = WindowManager.createWindow({
        backgroundColor: 'white'
    });

    var rows = [
        'Notify',
        'Notify Tokens',
        'Query Subscriptions',
        'Show Channels',
        'Query Channels',
        'Set Badge',
コード例 #3
0
var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');
WindowManager.include(

    '/windows/reviews/create',
    '/windows/reviews/show',
    '/windows/reviews/query',
    '/windows/reviews/update',
    '/windows/reviews/remove'
);

exports['Reviews'] = function (evt) {
    var win = WindowManager.createWindow({
        backgroundColor: 'white'
    });
    var table = Ti.UI.createTableView({
        backgroundColor: '#fff',
        top: 0,
        data: Utils.createRows([
            'Create Review',
            'Query Review'
        ])
    });
    table.addEventListener('click', WindowManager.handleOpenWindow);
    win.add(table);
    return win;
};
コード例 #4
0
var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');
WindowManager.include(

    '/windows/photoCollections/create',
    '/windows/photoCollections/update',
    '/windows/photoCollections/search',
    '/windows/photoCollections/remove',
    '/windows/photoCollections/show',
    '/windows/photoCollections/showSubcollections',
    '/windows/photoCollections/showPhotos'
);
exports['Photo Collections'] = function (evt) {
    var win = WindowManager.createWindow({
        backgroundColor: 'white'
    });
    var table = Ti.UI.createTableView({
        backgroundColor: '#fff',
        top: 0,
        data: Utils.createRows([
            'Create Photo Collection',
            'Search Photo Collections'
        ])
    });
    table.addEventListener('click', WindowManager.handleOpenWindow);
    win.add(table);
    return win;
};
コード例 #5
0
var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');
WindowManager.include(

	'/views/messages/create',
	'/views/messages/selectUsers',
	'/views/messages/showInbox',
	'/views/messages/showSent',
	'/views/messages/showThreads',
	'/views/messages/showThreadMessages',
	'/views/messages/show',
	'/views/messages/remove',
	'/views/messages/removeThread',
	'/views/messages/reply'
);
exports['Messages'] = function(evt) {
	var win = WindowManager.createWindow({
		backgroundColor: 'white'
	});
	var table = Ti.UI.createTableView({
		backgroundColor: '#fff',
		top: 0,
		color: 'black',
		data: Utils.createRows([
			'Create Message',
			'Show Inbox',
			'Show Sent',
			'Show Threads'
		])
	});
コード例 #6
0
var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');

WindowManager.include(
    '/windows/social/externalLink',
    '/windows/social/externalLogin',
    '/windows/social/externalUnlink',
    '/windows/social/searchFacebookFriends'
);

exports['Social'] = function (evt) {
    // Be sure to include the "facebook" module when running this app. It is now separate from the sdk.
    var Facebook = Ti.Facebook ? Ti.Facebook : require('facebook');
    var win = WindowManager.createWindow({
        backgroundColor: 'white'
    });
    var rows = [
        'Search Facebook Friends'
    ];
    if (Facebook.createLoginButton) {
        var available = true;
        try {
            Facebook.createLoginButton();
        }
        catch (err) {
            available = false;
        }
        if (available) {
            rows.push('External Link');
            rows.push('External Login');
コード例 #7
0
var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');
WindowManager.include(
    '/windows/checkins/create',
    '/windows/checkins/query',
    '/windows/checkins/remove',
    '/windows/checkins/show'
);

var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');
exports['Checkins'] = function (evt) {
    var win = WindowManager.createWindow({
        backgroundColor: 'white'
    });
    var table = Ti.UI.createTableView({
        backgroundColor: '#fff',
        top: 0,
        data: Utils.createRows([
            'Create Checkin',
            'Query Checkin'
        ])
    });
    table.addEventListener('click', WindowManager.handleOpenWindow);
    win.add(table);
    return win;
};
コード例 #8
0
var WindowManager = require('helper/WindowManager');
var Utils = require('helper/Utils');
var Cloud = require('ti.cloud');

WindowManager.include(
	'/views/chats/selectUsersForGroup',
	'/views/chats/showChatGroup',
	'/views/chats/query'
);

exports['Chats'] = function(evt) {
	var win = WindowManager.createWindow({
		backgroundColor: 'white',
		color: 'black'
	});

	var table = Ti.UI.createTableView({
		backgroundColor: '#fff',
		top: 0,
		bottom: 0,
		color : 'black'
	});
	table.addEventListener('click', function(evt) {
		if (evt.row.id) {
			WindowManager.handleOpenWindow({
				target: 'Show Chat Group',
				id: evt.row.id
			});
		} else if (evt.row.title === 'Query Chat Groups') {
			WindowManager.handleOpenWindow({
				target: 'Query Chat Groups'