• B
    Balistar

    Hi Jared,
    Since the new UI Module, the vendor CSS files, that are suppose to be loaded automatically, are blocked from loading in my Custom Dashboard.

    mangoUi~ngMango~ngMangoServices.js:39 Refused to load the stylesheet 'http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css' because it violates the following Content Security Policy directive: "style-src 'self' 'unsafe-inline'".
    

    I believe I changed everything in my dashboard and is following your admin template.
    Other than styling my dashboard works fine.

    mangoUI 3.4.5
    on Chrome 67

    posted in Dashboard Designer & Custom AngularJS Pages read more
  • B
    Balistar

    The best would be if your customer's network has its own IP address. Simply do a port forward on the network's router.

    Bar that, install teamviewer.com on the computer running Mango, or a bit more secure on another PC attached to the customer's LAN.

    posted in User help read more
  • B
    Balistar

    OK. In any case the current JSON retriever works fine in 3.2.

    I find this tool to be very helpful to quickly get the correct slashes for the pointers:

    www.jsonpointer.com

    posted in Mango feedback read more
  • B
    Balistar

    Missing again.

    Document file not found: .../mango/web/WEB-INF/dox/httpJsonRetrieverDS.htm

    core 3.2.2+20171009170034

    posted in Mango feedback read more
  • B
    Balistar

    @jared-wiltshire said in maEventAudio issues:

    @balistar
    I came checked into this and if you use acknowledged="false" instead of acknowledged="'false'" you should get the correct result.

    Thanks, that worked. "Acknowledge Box" shows all filtered events.

    posted in User help read more
  • B
    Balistar

    The standard event handler action to send an Alarm to the outside world is an Email. We run many processes unattended overnight and needed something more "Urgent" to get staff attention. Perhaps there is a better way, but what works for us is that a Notification gets send to one or a group mobile phones. On the phone the Notification pops up with a sound (even on a locked phone) and action can be taken.

    You can run your own server or use something like OneSignal. All use API.

    Enter HTTP Builder. Very powerful.

    In Mango a global script has been created with all the authorization, etc variables and gets called in other scripts.

    Global Script:

    function OneSignalNotice(notice){
    
    var url = "https://onesignal.com/api/v1/notifications";
    
    var headers = {
        "Content-Type": "application/json",
        "Authorization": "Basic ZWY5NmUxZjctYjAyNC00MTg0LWxxxxxxxxx",
    };
    
    
    var parameters = {
      "app_id" : "9b42d346-dd6f-4462-85a5-xxxxxxx",
      "contents" : {"en": notice},
      "included_segments" : "All"
    };
    
    
    HttpBuilder.post(url, headers, parameters).err(function(status, headers, parameters) {
      throw "Script failed with HTTP status : " + status;
    }).resp(function(status, headers, parameters) {
      "Hallo" 
    }).execute();
    
    }
    

    I don't think Event Handler / Set Point / Set to scripted value is meant to be used this way, but it works:

    // Send OneSignal Alarm Notice
    OneSignalNotice("ALARM Harvest 1 Temperature is too HIGH at: " + JSON.stringify(p226.value));
    
    

    .

    0_1514177188394_Image mango 1.jpg

    I hope it will help someone.

    posted in How-To read more
  • B
    Balistar

    When I added

    date-filter="true"
    

    events started to get listed without having to refresh the page. Thanks.

    My table now is:

    <ma-events-table  limit="5" alarm-level="'URGENT'" acknowledged = "'false'" date-filter="true" from="from" to="to"></ma-events-table>
    

    The "Acknowledge Box" still only shows 0 events.

    Another issue with maEventAudio is that on an Android there is no sound. I (nor you guys I suspect) have much experience with mobile. Perhaps it is related to the longstanding HTLM5 audio issues that mobile apps have. Permissions etc...

    PS what is the deal with "'xxx'" vs "xxx"? Your documentation and examples sometimes conflict.

    posted in User help read more
  • B
    Balistar

    Thanks Jared,

    Your work around works perfectly.

    Alarms goes off on Events. This makes it even more clear to me that I must be missing something in my event table configuration.

    <ma-events-table  limit="5" alarm-level="'URGENT'" acknowledged = "'false'" from="from" to="to"></ma-events-table>
    

    The now working ma-event-audio is sounding on events, but those events are not updated on the Event Table list. Only on a page refresh. I have a 20 datapoints on the same page that are updated every minute.

    For that matter. The Acknowledge "box" is not showing any events, even though there are "not-acknowledged" events in the table (after page page refresh).

    0_1513729664410_Image 2.jpg

    core 3.2.2

    posted in User help read more
  • B
    Balistar

    Hi,

    I am trying to get ma-event-audio to work in a custom web app (in overrides).

    The ONLY reference I could find anywhere is on the API Documents:

    <ma-event-audio audio-files="{CRITICAL: '/audio/critical.mp3'"></ma-event-audio>
    

    does not work. Nor does:

    <ma-event-audio audio-files="{CRITICAL: '/audio/critical.mp3'}"></ma-event-audio>
    

    Note the added closing "}"

    Nor:

    <ma-event-audio audio-files="./audio/critical.mp3" event-level="'URGENT'"></ma-event-audio>
    

    I have have a working event table on the same page:

    <md-card flex="100" flex-xs="100" style="padding: 0px;">
      <ma-events-table  limit="5" alarm-level="'URGENT'" acknowledged = "'false'" from="from" to="to"></ma-events-table>
    </md-card>
    

    posted in User help read more
  • B
    Balistar

    Thanks Phil,

    HTTP Publisher actually works perfectly for Firebase. Took some playing with Postman, but it turns out to be easy..

    0_1513469357051_Image 1.jpg

    But using HttpBuilder in a script is a lot more flexible.

    posted in How-To read more