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

Add "Clients (over time)" graph #583

Merged
merged 7 commits into from
Oct 10, 2017
Merged

Add "Clients (over time)" graph #583

merged 7 commits into from
Oct 10, 2017

Conversation

DL6ER
Copy link
Member

@DL6ER DL6ER commented Sep 22, 2017

By submitting this pull request, I confirm the following (please check boxes, eg [X] - no spaces) Failure to fill the template will close your PR:

Please submit all pull requests against the development branch. Failure to do so will delay or deny your request

  • I have read and understood the contributors guide.
  • I have checked that another pull request for this purpose does not exist.
  • I have considered, and confirmed that this submission will be valuable to others.
  • I accept that this submission may not be used, and the pull request closed at the will of the maintainer.
  • I give this submission freely, and claim no ownership to its content.

How familiar are you with the codebase?:

10


This adds an over time graph for the individual clients that used the Pi-hole as their DNS server.
The "design" of the new graph has still to be improved - this is only a proof-of-concept screenshot:
untitled

Important: Needs up-to-date version of FTL on custom branch new/clientsovertime

This template was created based on the work of udemy-dl.

@DL6ER
Copy link
Member Author

DL6ER commented Sep 23, 2017

Using absolute instead of relative numbers seems to give a more useful graph.

screenshot at 2017-09-23 13-02-31

@@ -642,7 +728,7 @@ $(document).ready(function() {
var m = parseInt(time[2], 10) || 0;
var from = padNumber(h)+":"+padNumber(m-5)+":00";
var to = padNumber(h)+":"+padNumber(m+4)+":59";
return "Forward destinations from "+from+" to "+to;
return "Client activity from "+from+" to "+to;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You flipped the forward destinations and client activity hover text

@@ -680,6 +766,64 @@ $(document).ready(function() {
});

// Pull in data via AJAX
updateClientsOverTime();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be switched with the forward destinations call on line 827.

var m = parseInt(time[2], 10) || 0;
var from = padNumber(h)+":"+padNumber(m-5)+":00";
var to = padNumber(h)+":"+padNumber(m+4)+":59";
return "Forward destinations from "+from+" to "+to;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Client activity

@pi-hole pi-hole deleted a comment Sep 23, 2017
Signed-off-by: DL6ER <dl6er@dl6er.de>
Signed-off-by: DL6ER <dl6er@dl6er.de>
AzureMarker
AzureMarker previously approved these changes Sep 23, 2017
@AzureMarker
Copy link
Contributor

With the change in excluding clients from the client graph in the corresponding FTL PR, this PR should change the settings page info for the excluded domains section.

@pi-hole pi-hole deleted a comment Sep 30, 2017
…like we do it already for the main graph)

Signed-off-by: DL6ER <dl6er@dl6er.de>
@DL6ER DL6ER changed the title [WIP] Add "Clients (over time)" graph Add "Clients (over time)" graph Oct 10, 2017
@DL6ER DL6ER merged commit 89af988 into devel Oct 10, 2017
@DL6ER DL6ER deleted the new/clientsovertime branch October 10, 2017 17:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants