flightplan-tool / flightplan

Search for award inventory using Node.js and Headless Chrome!
Apache License 2.0
140 stars 41 forks source link

Website version Vs GitHub version #33

Closed johneakin closed 5 years ago

johneakin commented 5 years ago

Is there a different version on your website than in GitHub?

I don't see the GetRoutes functionality on GitHub Also I tried passing a sample JSON from the Search API from the website as input to the GitHub version but get a map() error.

jd20 commented 5 years ago

It is different, the front-end and API server have diverged significantly over the last couple months, which is why they're not compatible (as you've found). The Searcher and Parser's are same between both (so any scraper fixes get checked in here first).

johneakin commented 5 years ago

Thanks Using the Master, When a search is made, should the extra filters for airline/flight etc show on the left panel? The code seems to be there, but they arent showing for me. (Although I havent scraped too much data)

jd20 commented 5 years ago

The data flows from server to what is actually rendered like this:

1. Cities / Dates Selected => 2. Other Filters => 3. Airline / Flight Filters

The first part comes from the server API response, the second part happens in searchStore.results, and the final part happens in searchStore.awards. So, what is scraped and what filters are selected will affect the list of airlines / flights shown. The UI gets the list of airlines and flights to display from searchStore.flights and searchStore.airlines. Hope that helps!

brianfife commented 4 years ago

It is different, the front-end and API server have diverged significantly over the last couple months

Is there any reason you are not open sourcing those components as well? Searching in CLI for a visualization of the data via client/server is cumbersome vs. being able to search from the client/server implementation. It'd almost be better off for the CLI search tool to just dump the results to console.