IBM / secret-map-dashboard

**work in progress**
4 stars 12 forks source link

Add in triggers from beacons #133

Closed AnthonyAmanse closed 6 years ago

AnthonyAmanse commented 6 years ago

POST from iOShttp://169.48.110.218/triggers/add

{
    "zone":8,
    "event":"enter",
    "timestamp":"test"
}

GET http://169.48.110.218/triggers/total that will be used by the dashboard

{
    "zone_one_enter": 5,
    "zone_one_exit": 7,
    "zone_two_enter": 5,
    "zone_two_exit": 4,
    "zone_three_enter": 0,
    "zone_three_exit": 0,
    "zone_four_enter": 0,
    "zone_four_exit": 0,
    "zone_five_enter": 0,
    "zone_five_exit": 0,
    "zone_six_enter": 0,
    "zone_six_exit": 0,
    "zone_seven_enter": 0,
    "zone_seven_exit": 0,
    "zone_eight_enter": 6,
    "zone_eight_exit": 0,
    "zone_nine_enter": 8,
    "zone_nine_exit": 0,
    "zone_ten_enter": 0,
    "zone_ten_exit": 0,
    "zone_eleven_enter": 0,
    "zone_eleven_exit": 0,
    "zone_twelve_enter": 0,
    "zone_twelve_exit": 0,
    "zone_thirteen_enter": 0,
    "zone_thirteen_exit": 0,
    "zone_fourteen_enter": 0,
    "zone_fourteen_exit": 0,
    "zone_fifteen_enter": 0,
    "zone_fifteen_exit": 0
}

Tweaked svg to pdf. Generated pdf should now have the same size as SVG. This is used by the iOS app. Added real-data.js which is the current data from the floorplan

darrylbalderas commented 6 years ago

https://github.com/IBM/secret-map-dashboard/pull/132

Do I no longer need the footprint schema, since this will be replacing that?

AnthonyAmanse commented 6 years ago

@db118 ThisTrigger schema is only for the enter/exit events from the beacon. We haven't integrated this one on the iOS app yet. The Footprint schema can still be useful for storing the steps outside of the blockchain network.