-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Ability to set timeframe for /tag/____ pages #2439
Comments
@jywarren Can I try this? |
Please do! This would be great and @ebarry would like it too.
…On Wed, Mar 7, 2018 at 10:47 AM, Rishabh Singh ***@***.***> wrote:
@jywarren <https://github.com/jywarren> Can I try this?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2439 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AABfJzxzDtNLRE8pZ86DIQWcXGdRSq1Wks5tcAEagaJpZM4Sgqyl>
.
|
This will assist with metrics and evaluation, thank you! |
Hi @rishabhptr how is this coming? Thanks! |
Hey, I will make a pr with initial implementation for time ranges in a day or two for you to review. Thanks! |
Hey, as mentioned in the issue we need to create a new action for this instead of using optional parameters for dates in the original show action for tag. So what would be the response for the example request, the show page which resources filtered within the range or any new page with more descriptive information just like the stats page. Thanks 😄 |
I think we can re-use the |
And I wonder if we can add an optional filter to the ActiveRecord queries in the same action, rather than making a new action? We could add it after this line, and the matching one from the wildcard section above it: plots2/app/controllers/tag_controller.rb Line 96 in 2f35d87
We'd want to limit range based on, i guess, node creation date? |
Yes, that was exactly my thought, instead of new action we can use the same action with optional start and end parameters. Already the show method is quite detailed and good in finding different nodes for a tag and so it would avoid redundancy of the code and layout. |
super, that sounds great!
…On Thu, Apr 12, 2018 at 10:08 AM, Rishabh Singh ***@***.***> wrote:
Yes, that was exactly my thought, instead of new action we can use the
same action with optional start and end parameters. Already the show method
is quite detailed and good in finding different nodes for a tag and so it
would avoid redundancy of the code and layout.
So I think I can go ahead with changes in the controller and then we can
add the interface from which user can select and view data for a specific
date range. Thanks for the help clarifying the issue! 😄
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2439 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AABfJy-zgug_xCuSRQoU6caM9O7UISHAks5tn23_gaJpZM4Sgqyl>
.
|
We should also plan ahead to make the graph reflect the period of time shown. Looking good!! |
Yes, it makes sense to update the chart also maybe we can have the graph update while choosing a range from the interface much like we are doing nodes through start and end values. 😄 |
I've updated this with a checklist of sub-parts that could be broken out and solved individually. Thanks!!! |
This one seems interesting, @rishabhptr are you working on it? |
#2618 added this nicely -- see:
But we need a few more things here --
@ViditChitkara what do you think? |
@jywarren Great checklist!! Would be happy to implement this step by step!! Thanks! |
That'd be amazing, Vidit. Thanks! |
Adding a new FTO for the range buttons! #3298 And the others here could make good FTOs as well 👍 |
@jywarren I'm not able to produce this page locally. How do I go about this? |
Hi @Manasa2850 do you mean you can't access for example: http://localhost:3000/tag/spectrometry?start=07-01-2018&end=08-01-2018 ? |
We may be able to look at #9256 for a quick and standard way to insert dates. |
We have these great pages to show activity on a topic:
https://publiclab.org/tag/data-logging
However, sometimes we want to be able to see this for a given time period, to understand community growth in that timeframe, kind of like on GitHub Pulse:
https://github.com/publiclab/plots2/pulse/monthly vs.
https://github.com/publiclab/plots2/pulse/weekly
That looks like this (so we may need to set an interface, but for now let's just focus on the pages)
We have these great stats pages where you can set a range: https://publiclab.org/stats/range/10-05-2015/10-05-2016/
The code for that (for example) is:
plots2/app/controllers/stats_controller.rb
Lines 11 to 32 in efc315d
Next steps
This could be solved in a few steps, and the first might be to create a new Tag controller action like:
weekly
andmonthly
buttons like on GitHub Pulse to show the past week or monthThe text was updated successfully, but these errors were encountered: