MOBILE-2831 core: Update push plugin and add new files

main
Dani Palou 2019-01-31 15:45:45 +01:00
parent 0ebc5d02d3
commit 30f8efd14a
7 changed files with 122 additions and 8 deletions

View File

@ -0,0 +1,40 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>AD_UNIT_ID_FOR_BANNER_TEST</key>
<string>ca-app-pub-3940256099942544/2934735716</string>
<key>AD_UNIT_ID_FOR_INTERSTITIAL_TEST</key>
<string>ca-app-pub-3940256099942544/4411468910</string>
<key>CLIENT_ID</key>
<string>694767596569-c2cjrca92k99f6nkp3363lsb7ljhdgdr.apps.googleusercontent.com</string>
<key>REVERSED_CLIENT_ID</key>
<string>com.googleusercontent.apps.694767596569-c2cjrca92k99f6nkp3363lsb7ljhdgdr</string>
<key>API_KEY</key>
<string>AIzaSyA-77ZjkxII6GV97CC9rdUl83rzdEXu_rM</string>
<key>GCM_SENDER_ID</key>
<string>694767596569</string>
<key>PLIST_VERSION</key>
<string>1</string>
<key>BUNDLE_ID</key>
<string>com.moodle.moodlemobile</string>
<key>PROJECT_ID</key>
<string>moodlemobile-push</string>
<key>STORAGE_BUCKET</key>
<string>moodlemobile-push.appspot.com</string>
<key>IS_ADS_ENABLED</key>
<true></true>
<key>IS_ANALYTICS_ENABLED</key>
<false></false>
<key>IS_APPINVITE_ENABLED</key>
<true></true>
<key>IS_GCM_ENABLED</key>
<true></true>
<key>IS_SIGNIN_ENABLED</key>
<true></true>
<key>GOOGLE_APP_ID</key>
<string>1:694767596569:ios:a4cdad4d168c9d1a</string>
<key>DATABASE_URL</key>
<string>https://moodlemobile-push.firebaseio.com</string>
</dict>
</plist>

View File

@ -41,6 +41,7 @@
<param name="ios-package" onload="true" value="CDVStatusBar" /> <param name="ios-package" onload="true" value="CDVStatusBar" />
</feature> </feature>
<platform name="android"> <platform name="android">
<resource-file src="google-services.json" target="app/google-services.json" />
<splash qualifier="land-ldpi" src="resources/android/splash/drawable-land-ldpi-screen.png" /> <splash qualifier="land-ldpi" src="resources/android/splash/drawable-land-ldpi-screen.png" />
<splash qualifier="land-mdpi" src="resources/android/splash/drawable-land-mdpi-screen.png" /> <splash qualifier="land-mdpi" src="resources/android/splash/drawable-land-mdpi-screen.png" />
<splash qualifier="land-hdpi" src="resources/android/splash/drawable-land-hdpi-screen.png" /> <splash qualifier="land-hdpi" src="resources/android/splash/drawable-land-hdpi-screen.png" />
@ -77,6 +78,7 @@
<resource-file src="resources/android/splash/drawable-port-xxxhdpi-screen.png" target="app/src/main/res/drawable-port-xxxhdpi/screen.png" /> <resource-file src="resources/android/splash/drawable-port-xxxhdpi-screen.png" target="app/src/main/res/drawable-port-xxxhdpi/screen.png" />
</platform> </platform>
<platform name="ios"> <platform name="ios">
<resource-file src="GoogleService-Info.plist" />
<icon height="57" src="resources/ios/icon/icon.png" width="57" /> <icon height="57" src="resources/ios/icon/icon.png" width="57" />
<icon height="114" src="resources/ios/icon/icon@2x.png" width="114" /> <icon height="114" src="resources/ios/icon/icon@2x.png" width="114" />
<icon height="40" src="resources/ios/icon/icon-40.png" width="40" /> <icon height="40" src="resources/ios/icon/icon-40.png" width="40" />
@ -137,8 +139,9 @@
<plugin name="cordova-plugin-zip" spec="^3.1.0" /> <plugin name="cordova-plugin-zip" spec="^3.1.0" />
<plugin name="cordova-sqlite-storage" spec="^2.6.0" /> <plugin name="cordova-sqlite-storage" spec="^2.6.0" />
<plugin name="nl.kingsquare.cordova.background-audio" spec="^1.0.1" /> <plugin name="nl.kingsquare.cordova.background-audio" spec="^1.0.1" />
<plugin name="phonegap-plugin-push" spec="https://github.com/moodlemobile/phonegap-plugin-push.git#moodle"> <plugin name="phonegap-plugin-push" spec="^2.2.3">
<variable name="SENDER_ID" value="694767596569" /> <variable name="ANDROID_SUPPORT_V13_VERSION" value="27.+" />
<variable name="FCM_VERSION" value="11.6.2" />
</plugin> </plugin>
<edit-config file="AndroidManifest.xml" mode="merge" target="/manifest/application/activity[@android:name='MainActivity']"> <edit-config file="AndroidManifest.xml" mode="merge" target="/manifest/application/activity[@android:name='MainActivity']">
<activity android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|screenLayout|smallestScreenSize" android:debuggable="true" /> <activity android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|screenLayout|smallestScreenSize" android:debuggable="true" />

View File

@ -0,0 +1,45 @@
{
"project_info": {
"project_number": "694767596569",
"firebase_url": "https://moodlemobile-push.firebaseio.com",
"project_id": "moodlemobile-push",
"storage_bucket": "moodlemobile-push.appspot.com"
},
"client": [
{
"client_info": {
"mobilesdk_app_id": "1:694767596569:android:a4cdad4d168c9d1a",
"android_client_info": {
"package_name": "com.moodle.moodlemobile"
}
},
"oauth_client": [
{
"client_id": "694767596569-icveqqa2n56oh44l6ev1dr2oh67nh8il.apps.googleusercontent.com",
"client_type": 3
}
],
"api_key": [
{
"current_key": "AIzaSyCb2zogu0P_aZ2LNgdwzshWExITPKTXJyk"
},
{
"current_key": "AIzaSyDRT1HwT0gSsTty0whOVtoNKAh8SPrJXLE"
}
],
"services": {
"analytics_service": {
"status": 1
},
"appinvite_service": {
"status": 1,
"other_platform_oauth_client": []
},
"ads_service": {
"status": 2
}
}
}
],
"configuration_version": "1"
}

29
package-lock.json generated
View File

@ -1716,6 +1716,11 @@
} }
} }
}, },
"babel-plugin-add-header-comment": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/babel-plugin-add-header-comment/-/babel-plugin-add-header-comment-1.0.3.tgz",
"integrity": "sha1-URxJAQYmQNWkgLSsPt1pRBlYUOw="
},
"bach": { "bach": {
"version": "1.2.0", "version": "1.2.0",
"resolved": "https://registry.npmjs.org/bach/-/bach-1.2.0.tgz", "resolved": "https://registry.npmjs.org/bach/-/bach-1.2.0.tgz",
@ -3220,6 +3225,11 @@
"resolved": "https://registry.npmjs.org/cordova-sqlite-storage-dependencies/-/cordova-sqlite-storage-dependencies-1.2.1.tgz", "resolved": "https://registry.npmjs.org/cordova-sqlite-storage-dependencies/-/cordova-sqlite-storage-dependencies-1.2.1.tgz",
"integrity": "sha512-4ihQApBGVKR1QZ4oOSGctKFfthtCfiWMTcIIfxe97vKxlvGr9NyXOvYG9vXU9S7yVR7Ua+Rj47hkE7pQIKvQTg==" "integrity": "sha512-4ihQApBGVKR1QZ4oOSGctKFfthtCfiWMTcIIfxe97vKxlvGr9NyXOvYG9vXU9S7yVR7Ua+Rj47hkE7pQIKvQTg=="
}, },
"cordova-support-google-services": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/cordova-support-google-services/-/cordova-support-google-services-1.1.0.tgz",
"integrity": "sha1-RjTFIgD4cGDReV6yhw6ZRC12Lm0="
},
"core-js": { "core-js": {
"version": "2.3.0", "version": "2.3.0",
"resolved": "https://registry.npmjs.org/core-js/-/core-js-2.3.0.tgz", "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.3.0.tgz",
@ -6314,6 +6324,11 @@
"integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==", "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==",
"dev": true "dev": true
}, },
"install": {
"version": "0.8.9",
"resolved": "https://registry.npmjs.org/install/-/install-0.8.9.tgz",
"integrity": "sha1-n0tcDRhR74cunfheT3Fi1OXc2+0="
},
"interpret": { "interpret": {
"version": "1.1.0", "version": "1.1.0",
"resolved": "https://registry.npmjs.org/interpret/-/interpret-1.1.0.tgz", "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.1.0.tgz",
@ -8554,9 +8569,19 @@
"integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=",
"dev": true "dev": true
}, },
"phonegap-plugin-multidex": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/phonegap-plugin-multidex/-/phonegap-plugin-multidex-1.0.0.tgz",
"integrity": "sha512-1wvc3iQOQpEBaQbXgLxA2JUiLSQ2azdF/bF29ghXDiQJWSpQ1BF8gSuqttM8WZoj081Ps8OKL0gYxdDBkFNPqA=="
},
"phonegap-plugin-push": { "phonegap-plugin-push": {
"version": "git+https://github.com/moodlemobile/phonegap-plugin-push.git#cf2ed2075d9d2d58a4c4f79543f669ed6366c148", "version": "2.2.3",
"from": "git+https://github.com/moodlemobile/phonegap-plugin-push.git#moodle" "resolved": "https://registry.npmjs.org/phonegap-plugin-push/-/phonegap-plugin-push-2.2.3.tgz",
"integrity": "sha512-5mjT0G1vfRhXVnZFLwjfzcFwYjVRMibgYDCfYvEujGsP8YwwrIIzcf+xBYAjQV/W2JCjzuNaYd7xJ0yVQaPeig==",
"requires": {
"babel-plugin-add-header-comment": "^1.0.3",
"install": "^0.8.2"
}
}, },
"pify": { "pify": {
"version": "2.3.0", "version": "2.3.0",

View File

@ -102,6 +102,7 @@
"cordova-plugin-whitelist": "^1.3.3", "cordova-plugin-whitelist": "^1.3.3",
"cordova-plugin-zip": "^3.1.0", "cordova-plugin-zip": "^3.1.0",
"cordova-sqlite-storage": "^2.6.0", "cordova-sqlite-storage": "^2.6.0",
"cordova-support-google-services": "^1.1.0",
"es6-promise-plugin": "^4.2.2", "es6-promise-plugin": "^4.2.2",
"font-awesome": "^4.7.0", "font-awesome": "^4.7.0",
"ionic-angular": "3.9.3", "ionic-angular": "3.9.3",
@ -109,7 +110,8 @@
"jszip": "^3.1.5", "jszip": "^3.1.5",
"moment": "^2.22.2", "moment": "^2.22.2",
"nl.kingsquare.cordova.background-audio": "^1.0.1", "nl.kingsquare.cordova.background-audio": "^1.0.1",
"phonegap-plugin-push": "git+https://github.com/moodlemobile/phonegap-plugin-push.git#moodle", "phonegap-plugin-multidex": "^1.0.0",
"phonegap-plugin-push": "^2.2.3",
"promise.prototype.finally": "^3.1.0", "promise.prototype.finally": "^3.1.0",
"rxjs": "^5.5.11", "rxjs": "^5.5.11",
"sw-toolbox": "^3.6.0", "sw-toolbox": "^3.6.0",
@ -169,7 +171,8 @@
"cordova-sqlite-storage": {}, "cordova-sqlite-storage": {},
"nl.kingsquare.cordova.background-audio": {}, "nl.kingsquare.cordova.background-audio": {},
"phonegap-plugin-push": { "phonegap-plugin-push": {
"SENDER_ID": "694767596569" "ANDROID_SUPPORT_V13_VERSION": "27.+",
"FCM_VERSION": "11.6.2"
} }
} }
}, },

View File

@ -94,7 +94,6 @@ export class AddonPushNotificationsProvider {
return this.configProvider.get(CoreConstants.SETTINGS_NOTIFICATION_SOUND, true).then((soundEnabled) => { return this.configProvider.get(CoreConstants.SETTINGS_NOTIFICATION_SOUND, true).then((soundEnabled) => {
return { return {
android: { android: {
senderID: CoreConfigConstants.gcmpn,
sound: !!soundEnabled, sound: !!soundEnabled,
icon: 'smallicon' icon: 'smallicon'
}, },

View File

@ -64,7 +64,6 @@
"password": "moodle" "password": "moodle"
} }
}, },
"gcmpn": "694767596569",
"customurlscheme": "moodlemobile", "customurlscheme": "moodlemobile",
"siteurl": "", "siteurl": "",
"multisitesdisplay": "", "multisitesdisplay": "",