Skip to content

Commit

Permalink
fix(calendar): fix some functionality and add missing ones
Browse files Browse the repository at this point in the history
closes #184
  • Loading branch information
ihadeed committed Jun 11, 2016
1 parent 7cf622b commit a15fb01
Showing 1 changed file with 33 additions and 3 deletions.
36 changes: 33 additions & 3 deletions src/plugins/calendar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,45 @@ export class Calendar {
* - You've already granted permission
*
* If this returns false, you should call `requestReadWritePermissions` function
* @returns {Promise<boolean>}
*/
@Cordova()
static hasReadWritePermissions(): Promise<boolean> { return; }
static hasReadWritePermission(): Promise<boolean> { return; }

/**
* Check if we have read permission
* @returns {Promise<boolean>}
*/
@Cordova()
static hasReadPermission(): Promise<boolean> {return; }

/**
* Check if we have write permission
* @returns {Promise<boolean>}
*/
@Cordova()
static hasWritePermission(): Promise<boolean> {return; }

/**
* Request write permission
* @returns {Promise<any>}
*/
@Cordova()
static requestWritePermission(): Promise<any> {return; }

/**
* Request read permission
* @returns {Promise<any>}
*/
@Cordova()
static requestReadPermission(): Promise<any> {return; }

/**
* Requests read/write permissions
* @returns {Promise<any>}
*/
@Cordova({sync: true})
static requestReadWritePermissions(): void {}
@Cordova()
static requestReadWritePermission(): Promise<any> {return; }

/**
* Create a calendar. (iOS only)
Expand Down

0 comments on commit a15fb01

Please sign in to comment.