美文网首页
再来一次友盟推送

再来一次友盟推送

作者: 我是小胡胡123 | 来源:发表于2017-09-19 18:16 被阅读27次

未运行,点通知中心启动APP
didFinishLaunchingWithOptions(参数有内容,可以不管。因为会进入didReceiveNotificationResponse)-》didReceiveNotificationResponse
点app图标,啥也不会有。

运行在后台,点通知中心启动APP
didReceiveNotificationResponse
点app图标,啥也不会有。

运行在前台,
收到通知--马上进入到willPresentNotification
点击通知中心,-》didReceiveNotificationResponse

调试记录:

// 普通消息
2017-09-19 17:18:19.146527+0800 XXX[2085:447214] -[AppDelegate userNotificationCenter:willPresentNotification:withCompletionHandler:] ----------> {
    UNNotificationRequest =     {
        UNNotificationContent =         {
            UNNotificationAttachment =             (
            );
            badge = 0;
            body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d2";
            categoryIdentifier = "";
            launchImageName = "";
            subtitle = "";
            threadIdentifier = "";
            title = "";
            userInfo =             {
                aps =                 {
                    alert =                     {
                        body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d2";
                        subtitle = "";
                        title = "";
                    };
                    sound = default;
                };
                d = us96166150581269377811;
                p = 0;
            };
        };
        identifier = us96166150581269377811;
    };
    date = "2017-09-19  17:18:18";
}




2017-09-19 17:19:48.571306+0800 XXX[2085:447214] -[AppDelegate userNotificationCenter:didReceiveNotificationResponse:withCompletionHandler:] ----------> {
    UNNotificationResponse =     {
        UNNotificationRequest =         {
            UNNotificationContent =             {
                UNNotificationAttachment =                 (
                );
                badge = 0;
                body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d2";
                categoryIdentifier = "";
                launchImageName = "";
                subtitle = "";
                threadIdentifier = "";
                title = "";
                userInfo =                 {
                    aps =                     {
                        alert =                         {
                            body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d2";
                            subtitle = "";
                            title = "";
                        };
                        sound = default;
                    };
                    d = us96166150581269377811;
                    p = 0;
                };
            };
            identifier = us96166150581269377811;
        };
        date = "2017-09-19  17:18:18";
    };
    actionIdentifier = "com.apple.UNNotificationDefaultActionIdentifier";
}

// 自定义字段


2017-09-19 17:23:51.013074+0800 XXX[2085:447214] -[AppDelegate userNotificationCenter:willPresentNotification:withCompletionHandler:] ----------> {
    UNNotificationRequest =     {
        UNNotificationContent =         {
            UNNotificationAttachment =             (
            );
            badge = 0;
            body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d3";
            categoryIdentifier = "";
            launchImageName = "";
            subtitle = "";
            threadIdentifier = "";
            title = "";
            userInfo =             {
                aps =                 {
                    alert =                     {
                        body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d3";
                        subtitle = "";
                        title = "";
                    };
                    sound = default;
                };
                bussinessLine = common;
                d = us66157150581302741311;
                p = 0;
            };
        };
        identifier = us66157150581302741311;
    };
    date = "2017-09-19  17:23:49";
}


2017-09-19 17:23:54.104388+0800 XXX[2085:447214] -[AppDelegate userNotificationCenter:didReceiveNotificationResponse:withCompletionHandler:] ----------> {
    UNNotificationResponse =     {
        UNNotificationRequest =         {
            UNNotificationContent =             {
                UNNotificationAttachment =                 (
                );
                badge = 0;
                body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d3";
                categoryIdentifier = "";
                launchImageName = "";
                subtitle = "";
                threadIdentifier = "";
                title = "";
                userInfo =                 {
                    aps =                     {
                        alert =                         {
                            body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d3";
                            subtitle = "";
                            title = "";
                        };
                        sound = default;
                    };
                    bussinessLine = common;
                    d = us66157150581302741311;
                    p = 0;
                };
            };
            identifier = us66157150581302741311;
        };
        date = "2017-09-19  17:23:49";
    };
    actionIdentifier = "com.apple.UNNotificationDefaultActionIdentifier";
}



// 内容链接
2017-09-19 17:26:05.435575+0800 XXX[2085:447214] -[AppDelegate userNotificationCenter:willPresentNotification:withCompletionHandler:] ----------> {
    UNNotificationRequest =     {
        UNNotificationContent =         {
            UNNotificationAttachment =             (
            );
            badge = 0;
            body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d3";
            categoryIdentifier = "";
            launchImageName = "";
            subtitle = "";
            threadIdentifier = "";
            title = "";
            userInfo =             {
                aps =                 {
                    alert =                     {
                        body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d3";
                        subtitle = "";
                        title = "";
                    };
                    bussinessLine = common;
                    "mutable-content" = 1;
                    sound = default;
                };
                bussinessLine = common;
                d = us61490150581316196211;
                p = 0;
            };
        };
        identifier = us61490150581316196211;
    };
    date = "2017-09-19  17:26:03";
}


2017-09-19 17:26:32.002471+0800 XXX[2085:447214] -[AppDelegate userNotificationCenter:didReceiveNotificationResponse:withCompletionHandler:] ----------> {
    UNNotificationResponse =     {
        UNNotificationRequest =         {
            UNNotificationContent =             {
                UNNotificationAttachment =                 (
                );
                badge = 0;
                body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d3";
                categoryIdentifier = "";
                launchImageName = "";
                subtitle = "";
                threadIdentifier = "";
                title = "";
                userInfo =                 {
                    aps =                     {
                        alert =                         {
                            body = "\U662f\U7684\U963f\U65af\U987f\U53d1\U8212\U670d3";
                            subtitle = "";
                            title = "";
                        };
                        bussinessLine = common;
                        "mutable-content" = 1;
                        sound = default;
                    };
                    bussinessLine = common;
                    d = us61490150581316196211;
                    p = 0;
                };
            };
            identifier = us61490150581316196211;
        };
        date = "2017-09-19  17:26:03";
    };
    actionIdentifier = "com.apple.UNNotificationDefaultActionIdentifier";
}


 2017/09/19 17:41:06:210  -[AppDelegate application:didFinishLaunchingWithOptions:]----> {
  "UIApplicationLaunchOptionsRemoteNotificationKey" : {
    "d" : "us94553150581405739511",
    "p" : 0,
    "custom_bussinessLine" : "custom_common",
    "aps" : {
      "mutable-content" : 1,
      "alert" : {
        "title" : "",
        "subtitle" : "",
        "body" : "是的阿斯顿发舒服1001"
      },
      "bussinessLine" : "common",
      "sound" : "default"
    }
  }
}






相关文章

  • 再来一次友盟推送

    未运行,点通知中心启动APPdidFinishLaunchingWithOptions(参数有内容,可以不管。因为...

  • iOS 友盟推送--关键点/核心点

    |:-| totem iOS集成友盟推送 1.iOS集成“友盟推送”后,友盟服务响应的deviceToken = ...

  • iOS 推送以及小红点

    思路: 1.设置友盟推送相关内容 // 友盟推送相关内容设置 - (void)setUMengPushMessag...

  • 友盟推送

    最近公司项目集成推送功能,相互比较之后选择了友盟推送。由于之前一直没有接触过推送,这次集成也算是踩了不少坑,写下来...

  • 友盟推送

    iOS收到推送后,跳转到某一页面 最近刚好有个项目,向指定用户推送订购信息、物品状态等等。 给大家讲一点常识,友盟...

  • 友盟推送

    友盟推送 推送不好用解决办法: 检查device_token。同一部测试机跑bundle id不同的程序所产生的d...

  • 2018-12-04工作日志-友盟推送别名

    注册了友盟推送别名,没有删除推送别名,直接卸载App,再次安装App,友盟推送服务进程运行起来后会收到之前的推送通...

  • React Native 的友盟推送

    前言 友盟推送集成失败? 本文带你3分钟快速集成友盟推送~想详细了解友盟集成小伙伴, 可以参考我的往期文章:Rea...

  • Cocos Unity安卓接入友盟推送

    项目原来使用百度云推送,推送到达率比较低,了解一下友盟推送。 友盟入口:https://www.umeng.com...

  • flutter项目集成友盟推送安卓端的心得

    1.问题 项目是纯flutter的,集成友盟推送,一开始,看到友盟有flutter推送的库,以为安卓的推送会很简单...

网友评论

      本文标题:再来一次友盟推送

      本文链接:https://www.haomeiwen.com/subject/ukrgsxtx.html