MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    How to send notification with MMM-EasyPix

    Scheduled Pinned Locked Moved Unsolved Troubleshooting
    4 Posts 2 Posters 440 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S Offline
      Sven1894
      last edited by

      How can I send notifications with the MMM-EasyPix module?
      I tried

      image.onerror = this.sendNotification('Pic is not exisiting');
      

      but nothing happened.
      If I do

      image.onerror = console.log('Pic is not exisiting');
      

      it logs ‘Pic is not existing’ in the console.

      Any Ideas?

      S 1 Reply Last reply Reply Quote 0
      • S Offline
        sdetweil @Sven1894
        last edited by

        @Sven1894 where are u trying to send the notification?

        this only works in the modulename.js
        not in the node_helper

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        S 1 Reply Last reply Reply Quote 0
        • S Offline
          Sven1894 @sdetweil
          last edited by

          @sdetweil In the MMM-EasyPix.js

          S 1 Reply Last reply Reply Quote 0
          • S Offline
            sdetweil @Sven1894
            last edited by sdetweil

            @Sven1894 what module are u sending it to?

            and you know what ‘this.’ means.
            sometimes you have to take special care.

            have you debugged w the developer window ?

            ctrl-shift-i, select the sources tab, find the module source, click
            put a stop on the line where it is about to send and examine the ‘this.’ pointer

            if it’s in a callback it might be pointing to somewhere unexpected

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            1 Reply Last reply Reply Quote 0
            • 1 / 1
            • First post
              Last post
            Enjoying MagicMirror? Please consider a donation!
            MagicMirror created by Michael Teeuw.
            Forum managed by Sam, technical setup by Karsten.
            This forum is using NodeBB as its core | Contributors
            Contact | Privacy Policy