• Jared Wiltshire

    So I guess the relevant documentation for the $save methods etc are listed here, notice the link to the AngularJS $resource documentation.


    And yeah one definite advantage of logging something to the console like you did is that Chrome debugger will show you the methods/functions on the prototype of an object.

    push() is a JavaScript built in Array method which has been around since the start of time, you will notice I previously linked to the MDN documentation for this function. MDN is an extremely useful resource for JavaScript. We have no intentions on trying to replicate it in our documentation :)

    posted in User help read more
  • Jared Wiltshire

    @psysak said in Implementing project tracking sheet:

    You know what I find very useful, and maybe someone else would too, just seeing somewhere all the objects which are available to me from the dashboard designer.

    The dashboard designer does have a pretty complete list of available components on the left, some of them do not have very good descriptions though I know.

    I don't know if you have seen this also, you can also browse the component API docs through the menu if you enable the menu item.

    The "Element specific" attributes should also give you some idea of what attributes are available for each element/component.


    @psysak said in Implementing project tracking sheet:

    figured out how I could console log from the ng-click and printed the myItem object which allowed me to see what I can do to it

    Another good way of doing this is adding a <pre> tag to inspect a variable on your page.

    <pre ng-bind="$ctrl.varName | json"></pre>

    posted in User help read more
  • Jared Wiltshire

    @sstuhlmann check your Chrome dev tools betwork tab to see what REST API requests for data points are actually issued.

    If it is like you say you can stop the query running until you retrieve your device name by using a ng-if e.g.

    <ma-point-query ng-if="$ctrl.devName">

    Alternatively do something like this, so that if devName is undefined it queries for the deviceName being null instead (which should return 0 results)

    <ma-point-query query="{deviceName:$ctrl.devName || null}">

    Although what I suspect is actually happening is that the query is not exact, I think that type of query is actually a fuzzy query, it will search for deviceName LIKE %devName% in the SQL database.

    Try this -

    <ma-point-query query="{deviceName:$ctrl.devName, $exact: true}">

    posted in Development general discussion read more
  • Jared Wiltshire

    @Pikey4 You are probably just missing the * at the end, documentation may not cover this :(


    posted in How-To read more
  • Jared Wiltshire

    @psysak The help pages are the best resource - https://help.infiniteautomation.com/introduction-to-html5-web-apps/

    The videos should be helpful too. Also look at the examples built into Mango, it looks like you already found these however.

    @psysak said in Implementing project tracking sheet:

    Also, is there a resource available from you guys which maybe maps out the structure of mango and how things interact?

    Basic infrastructure:
    Mango backend -> REST API / WebSockets -> HTMl5 / AngularJS frontend

    For developing a dashboard you don't really need to know much about the backend, REST API or WebSockets. That is abstracted through the use of AngularJS services and components.

    The big picture things you need to know about the backend are

    • Data sources connect to devices and read individual pieces of data into data points
    • Data points generally store long term time series data (i.e. trends)
    • The JSON data store can be used to store tabular data and configuration information for your dashboards
    • If you need to store user inputted data from your dashboard into a time series you can use a virtual data source / data points

    The front end -

    • <ma-point-value> retrieves and displays the current data point value using WebSockets to get live updates
    • <ma-point-values> retrieves historical point values for a given time range for use on charts/tables (via REST)
    • <ma-json-store> retrieves the contents of a JSON store via REST and keeps it up to date via WebSockets

    And then obviously the plethora of components used to display this information on the dashboards. Check the examples / dashboard designer / API documentation for more information on these.

    @psysak said in Implementing project tracking sheet:

    it would be really really useful for you guys to have something which can nudge people in the right direction without having to bug you all the time :)

    Hopefully the help site and examples satisfies this somewhat. We are happy to answer specific questions in the forum.

    posted in User help read more
  • Jared Wiltshire

    @BG we are still looking into it. Could you also send your env.properties file from overrides (reply to the same support email where you sent the thread dump). I want to check a couple of setttings. Also include the type of processor you are using and how many CPU cores.

    posted in Dashboard Designer & Custom AngularJS Pages read more
  • Jared Wiltshire


    <md-button ng-click="jsonStoreData.rows.push({myProperty: 'someValue'})">Add row</md-button>


    posted in User help read more
  • Jared Wiltshire

    @psysak said in Implementing project tracking sheet:

    So would the idea be to create a single JSON Store XID for a particular site, for example, and then start storing multiple items?

    You can store any arbitrary JSON data in each JSON store item. e.g. an array of rows. The permissions however can only be set per item so it would make sense to partition your into different JSON store items depending on your access requirements.

    posted in User help read more
  • Jared Wiltshire

    OK thanks for the additional details, that makes sense. The old watchlist page does not use websockets, the chart on the new watchlist page also does not. The table does.

    posted in Dashboard Designer & Custom AngularJS Pages read more
  • Jared Wiltshire

    OK that's interesting, can you download the thread dump and post it for me when you see the blocked thread again (I'm assuming you might have restarted Mango to clear it).

    @bg said in Dashboard refresh speed?:

    Do I need to upgrade my java version?
    Your Linux installation page says JDK 1.8 is required but not the build number.

    Its unlikely that this is related to your Java version. We do no recommend any particular build number, the latest is usually advisable.

    posted in Dashboard Designer & Custom AngularJS Pages read more