1.0.4 • Published 6 years ago
fpm-plugin-jpush v1.0.4
FPM-PLUGIN-JPUSH
用于极光推送的插件
Install
yarn add fpm-plugin-jpush
Basic Info
- Run Action Hook Name:
INIT
init the jpush clientBEFORE_SERVER_START
extend the biz module
- ExtendModule Name:
jpush
- Exception
E.JPush.PUSH_ERROR
{ errno: -10021, code: 'PUSH_ERROR', message: '' } ```
getDependencies()
[]
- The Reference Of The
Bind()
Method An BizModule Object Contains Functionspush
getRecords
Useage
- Add Config Set
$ vim config.json
addjpush
entry{ //... "jpush": { "appkey": "", "secretkey": "", } }
Use Functions
method:
jpush.push
args:{ title: 'foo', content: 'foo2', extras: {'url': 'http://blog.yunplus.io'}}
jpush.getRecords()
var func = new YF.Func('jpush.getRecords'); func.invoke({ limit: 10, skip: 0}) .then(function(data){ console.log(data) }).catch(function(err){ })