-3

whatsAppでユーザーのステータス(オンライン/オフライン)と入力状態をStore.Presence.find( phonenumber+ '@c.us').then(function(r){ console.log(r)})取得するために、結果のオブジェクトを取得した後に関数を使用しましたが、電話番号でそれを証明しているため、常に間違っているオフラインステータスを取得します。

プレゼンス (オンライン/オフライン) ステータスと WhatsAPI の入力機能の最近の機能は何ですか?

4

1 に答える 1

0
    var check = window.setInterval( function() {
        Store.Presence.find( phonenumber + '@c.us' ).then(  function(d) {
            if (d.isOnline) {
                console.log( phonenumber + " is ONLINE" );
                // do something with it
            }
        });
    } , 2000);

まだ働いている。

于 2017-12-31T21:37:52.203 に答える