mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-03-22 13:01:22 +08:00
fix(diagnostic): permissionStatus gets values from plugin in runtime
fixes #872
This commit is contained in:
parent
8b809de568
commit
9986e0d0b3
@ -1,4 +1,4 @@
|
|||||||
import { Cordova, Plugin } from './plugin';
|
import {Cordova, Plugin, CordovaProperty} from './plugin';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @name Diagnostic
|
* @name Diagnostic
|
||||||
@ -27,6 +27,7 @@ import { Cordova, Plugin } from './plugin';
|
|||||||
* }).catch(e => console.error(e));
|
* }).catch(e => console.error(e));
|
||||||
*
|
*
|
||||||
* ```
|
* ```
|
||||||
|
*
|
||||||
*/
|
*/
|
||||||
@Plugin({
|
@Plugin({
|
||||||
pluginName: 'Diagnostic',
|
pluginName: 'Diagnostic',
|
||||||
@ -63,18 +64,19 @@ export class Diagnostic {
|
|||||||
BODY_SENSORS: 'BODY_SENSORS'
|
BODY_SENSORS: 'BODY_SENSORS'
|
||||||
};
|
};
|
||||||
|
|
||||||
static permissionStatus = {
|
@CordovaProperty
|
||||||
GRANTED: 'GRANTED',
|
static permissionStatus: {
|
||||||
GRANTED_WHEN_IN_USE: 'GRANTED_WHEN_IN_USE', // iOS
|
GRANTED;
|
||||||
RESTRICTED: 'RESTRICTED', // iOS
|
DENIED;
|
||||||
DENIED: 'DENIED',
|
NOT_REQUESTED;
|
||||||
DENIED_ALWAYS: 'DENIED_ALWAYS', // android
|
DENIED_ALWAYS;
|
||||||
NOT_REQUESTED: 'NOT_REQUESTED'
|
RESTRICTED;
|
||||||
|
GRANTED_WHEN_IN_USE;
|
||||||
};
|
};
|
||||||
|
|
||||||
static locationAuthorizationMode = {
|
static locationAuthorizationMode = {
|
||||||
ALWAYS: 'ALWAYS',
|
ALWAYS: 'always',
|
||||||
WHEN_IN_USE: 'WHEN_IN_USE'
|
WHEN_IN_USE: 'when_in_use'
|
||||||
};
|
};
|
||||||
|
|
||||||
static permissionGroups = {
|
static permissionGroups = {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user