mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-01-31 18:49:43 +08:00
fix(unvired-cordova-sdk): Update the return type for startDiscoveryService api (#3647)
* feat(unvired-cordova-sdk): support login via email * fix(unvired-cordova-sdk): return typed promise object for user settings * fix(unvired-cordova-sdk): change return type to string for guid() * doc(unvired-cordova-sdk): doc update * doc(unvired-cordova-sdk): update doc * feat(unvired-cordova-sdk): add support for metadata JSON * doc(unvired-cordova-sdk): update doc * doc(unvired-cordova-sdk): update doc * feat(unvired-cordova-sdk): add methods to get and set log level * fix(unvired-cordova-sdk): update the return type for getLog() * feat(unvired-cordova-sdk): return platform name * feat(unvired-cordova-sdk): add method to get log file path * feat(unvired-cordova-sdk): test push notifications * fix(unvired-cordova-sdk): define return for logRead * doc(unvired-cordova-sdk): remove mobile only restriction for some apis * feat(unvired-cordova-sdk): add new property containing HTTP status code. * feat(unvired-cordova-sdk): add new functions to lock & unlock sending of data * fix(unvired-cordova-sdk): update the return type for lock and unlock functions. * fix(unvired-cordova-sdk): change the return type for lockDataSender api * fix(unvired-cordova-sdk): fix the data type for ResultType and OutboxLockStatus * doc(unvired-cordova-sdk): Update doc * doc(unvired-cordova-sdk): Update doc * feat(unvired-cordova-sdk): Added new notification type * feat(unvired-cordova-sdk): delete outbox item based on lid * fix(unvired-cordova-sdk): Update doc * doc(unvired-cordova-sdk): Update doc for userSettings() * feat(unvired-cordova-sdk): add new discovery api * fix(unvired-cordova-sdk): rename the property * doc(unvired-cordova-sdk): Doc update * fix(unvired-cordova-sdk): Update the return type for startDiscoveryService api * doc(unvired-cordova-sdk): Rename the loginParameter languageCode to loginLanguage. * changes after doing npm install Co-authored-by: Srinidhi Anand Rao <srinidhi.rao@unvired.io>
This commit is contained in:
parent
da4ce96be4
commit
b2da307837
26
package-lock.json
generated
26
package-lock.json
generated
@ -1222,7 +1222,7 @@
|
||||
},
|
||||
"@types/cordova": {
|
||||
"version": "0.0.34",
|
||||
"resolved": "https://registry.npmjs.org/@types/cordova/-/cordova-0.0.34.tgz",
|
||||
"resolved": "http://registry.npmjs.org/@types/cordova/-/cordova-0.0.34.tgz",
|
||||
"integrity": "sha1-6nrd907Ow9dimCegw54smt3HPQQ=",
|
||||
"dev": true
|
||||
},
|
||||
@ -1695,7 +1695,7 @@
|
||||
},
|
||||
"ansi-colors": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-1.1.0.tgz",
|
||||
"resolved": "http://registry.npmjs.org/ansi-colors/-/ansi-colors-1.1.0.tgz",
|
||||
"integrity": "sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
@ -2943,7 +2943,7 @@
|
||||
},
|
||||
"colors": {
|
||||
"version": "1.0.3",
|
||||
"resolved": "https://registry.npmjs.org/colors/-/colors-1.0.3.tgz",
|
||||
"resolved": "http://registry.npmjs.org/colors/-/colors-1.0.3.tgz",
|
||||
"integrity": "sha1-BDP0TYCWgP3rYO0mDxsMJi6CpAs=",
|
||||
"dev": true
|
||||
},
|
||||
@ -4020,7 +4020,7 @@
|
||||
},
|
||||
"typescript": {
|
||||
"version": "1.8.10",
|
||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-1.8.10.tgz",
|
||||
"resolved": "http://registry.npmjs.org/typescript/-/typescript-1.8.10.tgz",
|
||||
"integrity": "sha1-tHXW4N/wv1DyluXKbvn7tccyDx4=",
|
||||
"dev": true
|
||||
}
|
||||
@ -4579,7 +4579,7 @@
|
||||
},
|
||||
"expand-range": {
|
||||
"version": "1.8.2",
|
||||
"resolved": "https://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz",
|
||||
"resolved": "http://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz",
|
||||
"integrity": "sha1-opnv/TNf4nIeuujiV+x5ZE/IUzc=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
@ -10402,7 +10402,7 @@
|
||||
},
|
||||
"nunjucks": {
|
||||
"version": "2.5.2",
|
||||
"resolved": "https://registry.npmjs.org/nunjucks/-/nunjucks-2.5.2.tgz",
|
||||
"resolved": "http://registry.npmjs.org/nunjucks/-/nunjucks-2.5.2.tgz",
|
||||
"integrity": "sha1-6n00bnhbikh0Zmw8yp4YxXf7oiw=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
@ -11788,7 +11788,7 @@
|
||||
},
|
||||
"os-tmpdir": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz",
|
||||
"resolved": "http://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz",
|
||||
"integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=",
|
||||
"dev": true
|
||||
},
|
||||
@ -12032,7 +12032,7 @@
|
||||
},
|
||||
"path-is-absolute": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz",
|
||||
"resolved": "http://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz",
|
||||
"integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=",
|
||||
"dev": true
|
||||
},
|
||||
@ -12233,7 +12233,7 @@
|
||||
},
|
||||
"pretty-hrtime": {
|
||||
"version": "1.0.3",
|
||||
"resolved": "https://registry.npmjs.org/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz",
|
||||
"resolved": "http://registry.npmjs.org/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz",
|
||||
"integrity": "sha1-t+PqQkNaTJsnWdmeDyAesZWALuE=",
|
||||
"dev": true
|
||||
},
|
||||
@ -12973,7 +12973,7 @@
|
||||
},
|
||||
"safe-regex": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "https://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz",
|
||||
"resolved": "http://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz",
|
||||
"integrity": "sha1-QKNmnzsHfR6UPURinhV91IAjvy4=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
@ -13420,7 +13420,7 @@
|
||||
},
|
||||
"spdx-license-list": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/spdx-license-list/-/spdx-license-list-2.1.0.tgz",
|
||||
"resolved": "http://registry.npmjs.org/spdx-license-list/-/spdx-license-list-2.1.0.tgz",
|
||||
"integrity": "sha1-N4j/tcgLJK++goOTTp5mhOpqIY0=",
|
||||
"dev": true
|
||||
},
|
||||
@ -13956,7 +13956,7 @@
|
||||
},
|
||||
"through": {
|
||||
"version": "2.3.8",
|
||||
"resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz",
|
||||
"resolved": "http://registry.npmjs.org/through/-/through-2.3.8.tgz",
|
||||
"integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=",
|
||||
"dev": true
|
||||
},
|
||||
@ -15461,7 +15461,7 @@
|
||||
},
|
||||
"wrap-ansi": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz",
|
||||
"resolved": "http://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz",
|
||||
"integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
|
@ -400,7 +400,7 @@ export class LoginParameters {
|
||||
* Language code to be sent to UMP. Specify a two-letter language code.
|
||||
* The default value of this is 'en'.
|
||||
*/
|
||||
languageCode: string;
|
||||
loginLanguage: string;
|
||||
}
|
||||
export class LoginResult extends UnviredResult {
|
||||
type: LoginListenerType;
|
||||
@ -1494,24 +1494,23 @@ export class UnviredCordovaSDK extends IonicNativePlugin {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an observable to return the UMP URLs which are discoverable within the network.
|
||||
* Clients can use this information to allow users to select UMP servers in login page.
|
||||
* Returns a promise containing UMP servers which are discoverable within the network.
|
||||
* Clients can use this information to allow users to select appropriate UMP server in the login page.
|
||||
* ```
|
||||
* this.unviredSDK.startDiscoveryService().subscribe( (result) => {
|
||||
* if (result.type == ResultType.success) {
|
||||
* console.log('Discovered URLs: ' + JSON.stringify(result.data))
|
||||
* // {"name":"Chyme 98","url":"http://192.168.98.98:8080/UMP/","root":"UNVIRED","type":"DEVELOPMENT"}
|
||||
* }
|
||||
* else {
|
||||
* console.log('Error in discovering URLs: ' + result.error)
|
||||
* }
|
||||
* })
|
||||
* let discoveryServiceResult = await this.unviredSDK.startDiscoveryService()
|
||||
* if (discoveryServiceResult.type == ResultType.success) {
|
||||
* let UMPServers: any[] = discoveryServiceResult.data
|
||||
* UMPServers.forEach(element => {
|
||||
* console.log(JSON.stringify(element)) // {"name":"Chyme 98","url":"http://192.168.98.98:8080/UMP/","root":"UNVIRED","type":"DEVELOPMENT"}
|
||||
* });
|
||||
* }
|
||||
* else {
|
||||
* console.log('Error searching for UMP Servers: ' + discoveryServiceResult.error)
|
||||
* }
|
||||
* ```
|
||||
*/
|
||||
@Cordova({
|
||||
observable: true,
|
||||
})
|
||||
startDiscoveryService(): Observable<UnviredResult> {
|
||||
@Cordova()
|
||||
startDiscoveryService(): Promise<UnviredResult> {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user