seamug / Who-s-At-Glue

iBeacon-enabled conference meet-up app for Gluecon

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Who-s-At-Glue

iBeacon-enabled conference meet-up app for Gluecon

What the App Does

This is a Kinvey iOS app that illustrates how to make it easy to create an application for a different kind of events, that give possibility to manage interests with help of iBeacon. Application use iBeacon to tracing User's location and post him notifications.

Backend Setup

  1. Create a new app on Kinvey
  2. Create the following collections:
    • events - This collection should have one row to describe the event including the following columns:
      • Name - common name, for your use only
      • interests - an array of topics covered by the conference
      • startDate - the KinveyKit-formatted date & time for the conference to start. e.g. "ISODate(\"2014-05-01T17:54:00.000Z\")" .
      • endDate the KinveyKit-formatted date & time that the conference ends
      • boothPopupDistance - max distance in meters for the "Welcome to Kinvey" popup - tweak to configure the user experience between useful and annoying
      • portalURL - the web portal for the app. This is configurable because the URL wasn't known at ship time
    • roomBeacons - This collection has a row for each beacon at the conference
      • event - the _id of the corresponding event in the events collection
      • name - a short, user-visible string to identify the beacon in the UI
      • uuid - the beacon uuid
      • major - the beacon major identifier
      • minor - the beacon minor identifier
      • beaconId - this field is autogenerated by business logic to create a unique identifier based on the uuid, major, and minor numbers

Business Logic Setup

Upload the business logic scripts to the new app.

  1. Download the BL Command Line Interface

  2. Navigate to the root of the project directory http://devcenter.kinvey.com/ios/bl-cli-downloads

  3. Temporarily rename the business-logic directory

     mv business-logic/ business-logic-temp/
    
  4. Run and select the newly created backend.

     kinvey init
    
  5. Delete the new directory

     rm -rf business-logic
    
  6. Move the temp directory back

     mv business-logic-temp/ business-logic/
    
  7. Upload the code

LinkedIn Setup

The app is set up to use LinkedIn login, since there is also an option for creating a new app account with just email and password, it's optional. Then update following code in AppDelegate.m

@{KCS_LINKEDIN_SECRET_KEY:@"<#LinkedIn Secret Key#>",
KCS_LINKEDIN_API_KEY:@"<#LinkedIn API Key#>",
KCS_LINKEDIN_ACCEPT_REDIRECT:@"<#LinkedIn Accept URL#>",
KCS_LINKEDIN_CANCEL_REDIRECT:@"<#LinkedIn Cancel URL#>"}

App Setup

  1. Download the source

     `git clone`
    
  2. Before the app can be used, the dependencies have to be pulled through CocoaPods. If you've never used CocoaPods before, first follow the instalation steps here http://cocoapods.org/.

  3. Since the Podfile is in the repo, just install it:

     `pod install`
    
  4. Open WhosAtGlue.xcworkspace

  5. In Appdelegate.m add the Kinvey app credentials, and the LinkedIn credentials in -application:didFinishLaunchingWithOptions:.

  6. In EventModel.m set the kEventId macro to be the _id of the particular event row in the events collection.

  7. In MainViewController.m also insert that event id in the kEventId macro, and optionally specify a kKinveyBoothId if you want a particular beacon to trigger the Kinvey popup.

  8. Export the events and roomBeacons collections from the Kinvey web console. Copy the generated .json files into the project. These are used to pre-seed the data in case the app started in offline mode.

Customizing the App

You can use Mock data for easy use this tutorial.

Beacon of Interest Popup

Application use AJNotificationView for notification user when he appears near something in his interests. User can change his interests in SettingsTableViewController.

License

Copyright (c) 2014 Kinvey, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

About

iBeacon-enabled conference meet-up app for Gluecon

License:Apache License 2.0


Languages

Language:Objective-C 94.5%Language:JavaScript 4.6%Language:C 0.4%Language:C++ 0.3%Language:Ruby 0.1%