Graph help on Homepage

Eric Whalen ewhalen at xtremeinternet.biz
Tue Nov 28 05:22:30 EST 2017


Fair enough, thank you.

From: Users [mailto:users-bounces at lists.genieacs.com] On Behalf Of Sergio Fernández
Sent: Tuesday, November 28, 2017 5:19 AM
To: Community support for GenieACS users <users at lists.genieacs.com>
Subject: Re: Graph help on Homepage

That's true. Let's wait for Zaid or another guru to enlighten us... :)


Sergio Fernández Rubio - https://www.linkedin.com/in/sergiofdz/
(+34) 687 016 994
CEO @ ACSdesk
https://acsdesk.com

2017-11-28 11:04 GMT+01:00 <eric at aisling-technologies.com<mailto:eric at aisling-technologies.com>>:
I am confused, how is what I am doing any different than what is being done in the “Connected Devices” graph?

The only real difference is that I am not declaring the validation rules correct?

From: Users [mailto:users-bounces at lists.genieacs.com<mailto:users-bounces at lists.genieacs.com>] On Behalf Of Sergio Fernández
Sent: Tuesday, November 28, 2017 4:41 AM
To: Community support for GenieACS users <users at lists.genieacs.com<mailto:users at lists.genieacs.com>>
Subject: Fwd: Graph help on Homepage

In the release of v1.1.0 we can find this explanation from Zaid:


  *   Presets precondition queries no longer support "$or" or other MongoDB logical operators.

Source: https://github.com/zaidka/genieacs/releases/tag/v1.1.0

Zaid has given priority to Provisions and I think he removed this functionality in order to evade security problems.
But when it comes to graphs on Homepage, now I don't exactly know how would I do what you want to perform in v1.1.

Sergio Fernández Rubio - https://www.linkedin.com/in/sergiofdz/
(+34) 687 016 994<tel:+34%20687%2001%2069%2094>
CEO @ ACSdesk
https://acsdesk.com

---------- Forwarded message ----------
From: <eric at aisling-technologies.com<mailto:eric at aisling-technologies.com>>
Date: 2017-11-28 10:33 GMT+01:00
Subject: Graph help on Homepage
To: Community support for GenieACS users <users at lists.genieacs.com<mailto:users at lists.genieacs.com>>
Ok, so I want to create a couple of graphs on the home tab.  My first is to show SINR levels at a glance for the connected CPEs.  For ease of troubleshooting, I removed the “Connected Devices” graph and just used the following code in graphs.json.erb,

{
  "SINR" : [
      {
        "label" : "Excellent",
        "color" : "#5e5",
"query" : {"InternetGatewayDevice.SystemConfig.Status.ModemStatus.RSRP" : {"$gt" : "<%= 24 %>"}}
      },
      {
        "label" : "Good",
        "color" : "#ee5",
"query" : {"InternetGatewayDevice.SystemConfig.Status.ModemStatus.RSRP" : {"$lt" : "<%= 25 %>", "$gt" : "<%= 19 %>"}}
      },
      {
        "label" : "Poor",
        "color" : "#e55",
"query" : {"InternetGatewayDevice.SystemConfig.Status.ModemStatus.RSRP" : {"$lt" : "<%= 20 %>"}}
      }
   ]
}
When I apply the code and attempt to access the Home tab, I get the following error,
undefined method `each' for nil:NilClass

What am I missing?  Is there another file that I need to edit?

Thank you.

_______________________________________________
Users mailing list
Users at lists.genieacs.com<mailto:Users at lists.genieacs.com>
http://lists.genieacs.com/mailman/listinfo/users


_______________________________________________
Users mailing list
Users at lists.genieacs.com<mailto:Users at lists.genieacs.com>
http://lists.genieacs.com/mailman/listinfo/users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.genieacs.com/pipermail/users/attachments/20171128/abb8d056/attachment-0001.html>


More information about the Users mailing list