GithubHelp home page GithubHelp logo

fe-trex's People

Contributors

bld010 avatar emilylalonde avatar lundgrea avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

fe-trex's Issues

BE - A user can delete a destination

Request

mutation {
  removeDestination(input: {id: 6}) {
    destination {
      name
    }
  }

Response

{
  "data": {
    "destination": {
      "name": "Colliermouth"
    }
  }
}

BE - A user see all of their transportation (associated with a leg of their trip)

Leg and Leg Transportations

  • Returns single leg based on the ID passed in, and associated transportations

Request:

{
  leg(id: 1) {
    startDate
    startLocation
    endDate
    endLocation
    tripId
  }
  transportations {
    id
    mode
    departureCity
    departureTime
    arrivalTime
    arrivalCity
  }
}

Response:

{
  "data": {
    "leg": {
      "startDate": "2019-05-19",
      "startLocation": "Purdytown",
      "endDate": "2020-04-16",
      "endLocation": "Purdytown",
      "tripId": 1
    },
    "transportations": [
      {
        "id": "1",
        "mode": "flight",
        "departureCity": "Haland",
        "departureTime": "2020-08-02 08:24:19 -0600",
        "arrivalTime": "2019-07-13 02:53:29 -0600",
        "arrivalCity": "North Jules"
      },
      {
        "id": "2",
        "mode": "flight",
        "departureCity": "Taniastad",
        "departureTime": "2020-06-28 14:14:46 -0600",
        "arrivalTime": "2019-07-12 17:52:08 -0600",
        "arrivalCity": "West Ned"
      },
      {
        "id": "3",
        "mode": "flight",
        "departureCity": "East Fatima",
        "departureTime": "2020-04-21 13:47:41 -0600",
        "arrivalTime": "2019-05-07 06:13:31 -0600",
        "arrivalCity": "Faheyborough"
      },
      {
        "id": "4",
        "mode": "flight",
        "departureCity": "Alberttown",
        "departureTime": "2020-02-18 10:31:50 -0700",
        "arrivalTime": "2019-05-21 07:05:17 -0600",
        "arrivalCity": "Camimouth"
      },
      {
        "id": "5",
        "mode": "flight",
        "departureCity": "Gilberteland",
        "departureTime": "2020-10-21 16:29:24 -0600",
        "arrivalTime": "2019-01-30 05:00:12 -0700",
        "arrivalCity": "Bernieborough"
      }
    ]
  }
}

FE - Follower - Trip View

As a Follower user I want to be able to view the trip of the Wanderer I following so I can be aware of their travel plans.

BE - A user can edit a notification

Update Notification

Required Fields

  • id
  • active
  • userId

Request:

mutation {
  updateNotification(
    input: {
      id: 8
      active: false,
      userId: 4
    })
  {
    notification {
      id
      active
      userId
    }
  }
}

Response:

{
  "data": {
    "updateNotification": {
      "notification": {
        "id": "8",
        "active": false,
        "userId": 4
      }
    }
  }
}

FE - Wanderer's MyTrips Page

As a Wanderer, I want to see my upcoming Trips so I can edit/review trip details.

  • User can click on "MyTrips" from Home to be taken to MyTrips page
  • User can see a list of their trips on MyTrips page
  • User can click "Add a New Trip" on MyTrips page
  • Clicking on "Add a New Trip" button takes user to TripForm

BE - Create Users & Friendships model / table

Users model / table:
Attributes:

  • name
  • email (unique)
  • role
  • phone_number
  • latitude (optional)
  • longitude (optional)

Relationships:

  • has_many :friendships
  • has_many :friends, through: :friendships
  • has_many :trips

Friendship model / table:
Relationships:

  • belongs_to :user
  • belongs_to :friend

BE - A user can edit a lodging

Update Lodging

Required Fields

  • id
  • name
  • arrivalDate
  • departureDate
  • city
  • legId

Request:

mutation {
  updateLodging(
    input: {
      id: 9,
      name: "La Quinta",
      arrivalDate: "2019-10-11",
      departureDate:"2019-10-20",
      city: "Los Angeles",
      legId: 2
    })
  {
    lodging {
      name
      arrivalDate
      departureDate
      city
      legId
    }
  }
}

Response:

{
  "data": {
    "updateLodging": {
      "lodging": {
        "name": "La Quinta",
        "arrivalDate": "2019-10-11",
        "departureDate": "2019-10-20",
        "city": "Los Angeles",
        "legId": 2
      }
    }
  }
}

FE - Wanderer Map Page

As a Wanderer based on my itinerary I want see my current location on a map so I can orient myself on my trip.

  • Display map on dashboard

FE - Follower - Contact Wanderer

As a Follower I want to be able to send a ping to a Wanderer from a template of messages so I can send a greeting or request a check-in.

  • Fire new message API call on button click
  • Display verification that message was sent

FE - Wanderer - Message Follower

As a Wanderer I want to be able to ping the Follower from a template of pre-formatted message with my location (if possible) so that I can let my loved ones know I am safe.

  • Create component(s) (Message)
  • Integrate GET API Network Request
  • Display notification in footer
  • Render message within Message Component

BE- Google Geocoder Connection

Establish Connection with Google Geocoder API
*** Add to config application.yml***
GOOGLE_KEY: AIzaSyCmFzPokmvGKpiVJV-zFqqoK74Clzifbwg

BE - A user can create a transportion

Create Transportation

Required Fields

  • mode
  • arrivalTime
  • departureTime
  • arrivalCity
  • departureCity
  • legId

Request:

mutation {
  createTransportation(
    input: {
      mode: "bus",
      departureCity: "Hollywood",
      departureTime: "2020-01-13 16:01:26 -0700",
      arrivalCity: "San Juan",
      arrivalTime: "2019-04-02 04:08:33 -0600",
      legId: 1
    })
  {
    transportation {
      id
      mode
      departureCity
      departureTime
      arrivalCity
      arrivalTime
      legId
    }
  }
}

Response:

{
  "data": {
    "createTransportation": {
      "transportation": {
        "id": "6",
        "mode": "bus",
        "departureCity": "Hollywood",
        "departureTime": "2020-01-13 16:01:26 -0700",
        "arrivalCity": "San Juan",
        "arrivalTime": "2019-04-02 04:08:33 -0600",
        "legId": 1
      }
    }
  }
}

FE - Wanderer - Delete Followers

As a Wanderer I want to be able to delete Followers so that people I no longer want to follow me have access to my trips.

  • Grab follower to delete's ID
  • DELETE Follower from API

BE - A user can see all of their notifications

User and User's Notifications

  • Returns all the notifications for a single user by passing in the user's ID

Request:

{
  user(id: 1) {
    id
    name
    email
  }
  notifications {
    id
    active
    userId
  }
}

Response:

{
  "data": {
    "user": {
      "id": "1",
      "name": "Trudie Deckow",
      "email": "[email protected]"
    },
    "notifications": [
      {
        "id": "1",
        "active": true,
        "userId": 1
      },
      {
        "id": "2",
        "active": true,
        "userId": 1
      },
      {
        "id": "3",
        "active": true,
        "userId": 1
      },
      {
        "id": "4",
        "active": true,
        "userId": 2
      },
      {
        "id": "5",
        "active": true,
        "userId": 2
      },
      {
        "id": "6",
        "active": false,
        "userId": 3
      },
      {
        "id": "7",
        "active": false,
        "userId": 3
      }
    ]
  }
}

BE - A user can create a notification

Create Notification

Required Fields

  • active
  • userId

Request:

mutation {
  createNotification(
    input: {
      active: true,
      userId: 4
    })
  {
    notification {
      id
      active
      userId
    }
  }
}

Response:**

{
  "data": {
    "createNotification": {
      "notification": {
        "id": "8",
        "active": true,
        "userId": 4
      }
    }
  }
}

BE - A user can create a trip

Request

mutation {
  createTrip(input: {name: "Spain", startDate: "10-10-10", endDate: "10-19-10", userId: 1}) {
    trip {
      name
    }
  }
}

Response

{
  "data": {
    "createTrip": {
      "trip": {
        "name": "Spain"
      }
    }
  }
}

BE - A user can see all of their trips

Request

{
  user(id: 1) {
    name
    email
    trips {
      name
      startDate
      endDate
    }
  }
}

Response

{
  "data": {
    "user": {
      "name": "Lucienne Herman",
      "email": "[email protected]",
      "trips": [
        {
          "name": "Senegal",
          "startDate": "2019-10-06",
          "endDate": "2020-02-27"
        },
        {
          "name": "Albania",
          "startDate": "2019-05-10",
          "endDate": "2020-08-24"
        },
        {
          "name": "South Georgia and the South Sandwich Islands",
          "startDate": "2018-11-01",
          "endDate": "2019-10-27"
        }
      ]
    }
  }
}

BE - A user can create a lodging

Create Lodging

Required Fields

  • name
  • arrivalDate
  • departureDate
  • city
  • legId

Request:

mutation {
  createLodging(
    input: {
      name: "Queen Anne Hotel",
      arrivalDate: "2019-10-11",
      departureDate:"2019-10-20",
      city: "San Francisco",
      legId: 2
    })
  {
    lodging {
      name
      arrivalDate
      departureDate
      city
      legId
    }
  }
}

Response:

{
  "data": {
    "createLodging": {
      "lodging": {
        "id": "9",
        "name": "Queen Anne Hotel",
        "arrivalDate": "2019-10-11",
        "departureDate": "2019-10-20",
        "city": "San Francisco",
        "legId": 2
      }
    }
  }
}

BE - A user can delete a trip

Request

mutation {
  removeTrip(input: {id: 5}) {
    trip {
      name
    }
  }
}

Response

{
  "data": {
    "removeTrip": {
      "trip": {
        "name": "Spain"
      }
    }
  }
}

FE - Wanderer - SafetyInfo Page

As a Wanderer based on my itinerary I want to receive emergency related information in the Emergency Tab about:

  • General Safety Information
  • 'Food/Water'
  • Embassy Location
  • Vaccination Info
  • Warnings - crime

BE - A user can edit a transportation

Update Transportation

Required Fields

  • id
  • mode
  • arrivalTime
  • departureTime
  • arrivalCity
  • departureCity
  • legId

Request:

mutation {
  updateTransportation(
    input: {
      id: 6,
      mode: "bus",
      departureCity: "Las Vegas",
      departureTime: "2020-01-13 16:01:26 -0700",
      arrivalCity: "Santa Fe",
      arrivalTime: "2019-04-02 04:08:33 -0600",
      legId: 1
    })
  {
    transportation {
      id
      mode
      departureCity
      departureTime
      arrivalCity
      arrivalTime
      legId
    }
  }
}

Response:

{
  "data": {
    "updateTransportation": {
      "transportation": {
        "id": "6",
        "mode": "bus",
        "departureCity": "Las Vegas",
        "departureTime": "2020-01-13 16:01:26 -0700",
        "arrivalCity": "Santa Fe",
        "arrivalTime": "2019-04-02 04:08:33 -0600",
        "legId": 1
      }
    }
  }
}

BE - A user can delete a notification

Remove Notification

  • Deletes a notification from the DB.

Required Fields

  • id

Request:

mutation {
  removeNotification(
    input: {
      id: 8
    })
  {
    notification {
      id
      active
      userId
    }
  }
}

Response:

{
  "data": {
    "removeNotification": {
      "notification": {
        "id": "8",
        "active": false,
        "userId": 4
      }
    }
  }
}

BE - A user can delete a transportion

Remove Transportation

  • Deletes a transportation from the DB.

Required Fields

  • id

Request:

mutation {
  removeTransportation(
    input: {
      id: 6
    })
  {
    transportation {
      id
      mode
      departureCity
      departureTime
      arrivalCity
      arrivalTime
      legId
    }
  }
}

Response:

{
  "data": {
    "removeTransportation": {
      "transportation": {
        "id": "6",
        "mode": "bus",
        "departureCity": "Las Vegas",
        "departureTime": "2020-01-13 16:01:26 -0700",
        "arrivalCity": "Santa Fe",
        "arrivalTime": "2019-04-02 04:08:33 -0600",
        "legId": 1
      }
    }
  }
}

BE - A user can delete their lodging

Remove Lodging

  • Deletes a lodging from the database.

Required Fields

  • id

Request:

mutation {
  removeLodging(
    input: {
      id: 9
    })
  {
    lodging {
      name
      arrivalDate
      departureDate
      city
      legId
    }
  }
}

Response:

{
  "data": {
    "removeLodging": {
      "lodging": {
        "name": "La Quinta",
        "arrivalDate": "2019-10-11",
        "departureDate": "2019-10-20",
        "city": "Los Angeles",
        "legId": 2
      }
    }
  }
}

BE - A user can see all of their lodgings

Leg and Leg Lodgings

  • Returns single leg based on the ID passed in, and the associated lodgings

Request:

{
  leg(id: 1) {
    lodgings {
      name
      arrivalDate
      departureDate
      city
      legId
    }
  }
}

Response:

{
  "data": {
    "leg": {
      "lodgings": [
        {
          "name": "Klein-Mante",
          "arrivalDate": "2019-03-14",
          "departureDate": "2020-07-13",
          "city": "Bartellmouth",
          "legId": 1
        },
        {
          "name": "Schneider-Mayert",
          "arrivalDate": "2019-09-16",
          "departureDate": "2020-03-24",
          "city": "Lake Darrylside",
          "legId": 1
        }
      ]
    }
  }
}

FE - Wanderer - Emergency Number

As a Wanderer I want to see the emergency number of my current location so that I am able to contact the local emergency if necessary.

  • Fetch from API
  • Display on dashboard

FE - Wanderers - Add Followers

As a Wanderer I want to be able to invite Followers to follow my travels so that they can view my itinerary and location.

  • Input Follower Info
  • Post new Follower to API
  • Pass new information to MyFollowers to update list upon re-focus (wrap in withNavigationFocus and check props in componentDidUpdate)

FE - Wanderer - Trip Edit

As a Wanderer I want to be able to edit each upcoming Trip so that I can keep it up to date with my latest travel plans.

  • Auto populate trip information within TripForm
  • PATCH API Network Request with new trip details
  • Test API call

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.