Html5+ offline packaging to create local messages

Recently, I want to talk about a body art photo site packaged into an Android app, using html5 is not bad

Package the Html5+ Runtime offline yourself, usually import the Hello instance of the SDK, and then modify it. When doing the message notification function, using push.createMessage does not work.

First refer to the Android platform offline package push plug-in configuration

It is necessary to pay special attention to the configuration of AndroidManifest, you need to replace the package name with your own package name

1
2
3
4
5
6
7
8
9
< receiver  android:exported="true" android:name="io.dcloud.feature.apsXm.XMNotificationReceiver">
< intent-filter >
< action  android:name="android.intent.action.BOOT_COMPLETED"/>
< action  android:name="%填写APK的包名%.__CREATE_NOTIFICATION"/>
< action  android:name="%填写APK的包名%.__REMOVE_NOTIFICATION"/>
< action  android:name="%填写APK的包名%.__CLEAR_NOTIFICATION"/>
< action  android:name="%填写APK的包名%.__CLILK_NOTIFICATION"/>
</ intent-filter >
</ receiver >

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326414312&siteId=291194637