Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Add list with highlights of the day/week/month/ever on home.page #186

Open
pki0 opened this issue Feb 11, 2017 · 1 comment
Assignees

Comments

@pki0
Copy link
Collaborator

pki0 commented Feb 11, 2017

  • Add a fancy list with Pokemon of the day (Mythic and pokemon-raking order by IV [Snorlax, Lapras, Dragonite, Rhydorn and their prevolutions ?])
  • Choose if you want to see day/week/month/ever
  • Maybe replace it with the Lure counter on homepage

Progress:

  • Queries done
  • Including "xdays" to show spawntime very short (e.g. 1 Day ago, 3 Days ago)

Queries:
Today:
SELECT pokemon_id, disappear_time, individual_attack, individual_defense, individual_stamina, ROUND(SUM(100*(individual_attack+individual_defense+individual_stamina)/45),1) as IV, DATEDIFF(now(), disappear_time) AS xdays FROM pokemon WHERE (pokemon_id = '149' or pokemon_id = '148' or pokemon_id = '147' or pokemon_id = '131' or pokemon_id = '143' or pokemon_id = '111' or pokemon_id = '112') AND disappear_time > (UTC_TIMESTAMP() - INTERVAL 1 DAY) GROUP BY encounter_id ORDER BY IV DESC

Last week:
SELECT pokemon_id, disappear_time, individual_attack, individual_defense, individual_stamina, ROUND(SUM(100*(individual_attack+individual_defense+individual_stamina)/45),1) as IV, DATEDIFF(now(), disappear_time) AS xdays FROM pokemon WHERE (pokemon_id = '149' or pokemon_id = '148' or pokemon_id = '147' or pokemon_id = '131' or pokemon_id = '143' or pokemon_id = '111' or pokemon_id = '112') AND disappear_time > (UTC_TIMESTAMP() - INTERVAL 7 DAY) GROUP BY encounter_id ORDER BY IV DESC

Last month:
SELECT pokemon_id, disappear_time, individual_attack, individual_defense, individual_stamina, ROUND(SUM(100*(individual_attack+individual_defense+individual_stamina)/45),1) as IV, DATEDIFF(now(), disappear_time) AS xdays FROM pokemon WHERE (pokemon_id = '149' or pokemon_id = '148' or pokemon_id = '147' or pokemon_id = '131' or pokemon_id = '143' or pokemon_id = '111' or pokemon_id = '112') AND disappear_time > (UTC_TIMESTAMP() - INTERVAL 1 MONTH) GROUP BY encounter_id ORDER BY IV DESC

E.g. ever:
SELECT pokemon_id, disappear_time, individual_attack, individual_defense, individual_stamina, ROUND(SUM(100*(individual_attack+individual_defense+individual_stamina)/45),1) as IV, DATEDIFF(now(), disappear_time) AS xdays FROM pokemon WHERE pokemon_id = '149' or pokemon_id = '148' or pokemon_id = '147' or pokemon_id = '131' or pokemon_id = '143' or pokemon_id = '111' or pokemon_id = '112' GROUP BY encounter_id ORDER BY IV DESC

@tokar86a
Copy link

sure sounds nice :)

@pki0 pki0 changed the title [Feature Request] Add ranking with highlights of the day/week/month/ever [Feature Request] Add list with highlights of the day/week/month/ever on home.page Feb 11, 2017
@Obihoernchen Obihoernchen removed the WIP label Apr 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants