Overview
  • Package
  • Class
  • Tree
  • Deprecated
  • Todo
  • Hook Reference
  • Docs Home

Packages

  • None
  • Product-Delivery-Date-Pro-for-WooCommerce
    • Addon
    • Admin
      • Settings
        • Field-Labels
        • General
        • Google-Sync
      • View-Deliveries
    • Calendar
    • Common-Functions
    • Configuration
    • Delivery-Charges
    • Edit-Deliveries
    • Emails
    • Frontend
      • Cart
      • Checkout
    • Google-Calendar
    • Languages
    • License
    • Reschedule-Deliveries
    • View-Deliveries

Classes

  • ts_google_calendar_sync
  • TsGcal

Class TsGcal

Sync Delivery Dte & Time to Google Calendar.

Package: Product-Delivery-Date-Pro-for-WooCommerce\Google-Calendar
Author: Tyche Softwares
Class: TsGcal
Located at includes/class.gcal.php

Methods summary

public
# __construct( )

Default constructor

Default constructor

Since

1.0
public
# exception_error_handler( $exception )

Refresh the page with the exception as GET parameter, so that page is not killed

Refresh the page with the exception as GET parameter, so that page is not killed

Since

1.0
public
# ts_display_nag( )

Displays nag

Displays nag

Since

1.0

Hook

wp_ajax_display_nag
public
# ts_init( )

Copy the key file to the uploads folder.

Copy the key file to the uploads folder.

Since

1.0

Hook

init
public string
# get_api_mode( )

Return GCal API mode (Manually, Directly or Disabled )

Return GCal API mode (Manually, Directly or Disabled )

Returns

string
Setting value

Since

1.0
public string
# get_service_account( )

Return GCal service account

Return GCal service account

Returns

string

Since

1.0
public string
# get_key_file( )

Return GCal key file name without the extension

Return GCal key file name without the extension

Returns

string
Key file name

Since

1.0
public string
# get_selected_calendar( )

Return GCal selected calendar ID

Return GCal selected calendar ID

Returns

string
Calendar ID

Since

1.0
public string
# get_summary( )

Return GCal Summary (name of Event)

Return GCal Summary (name of Event)

Returns

string

Since

1.0
public string
# get_description( )

Return GCal description

Return GCal description

Returns

string

Since

1.0
public string
# is_not_suitable( )

Checks if php version and extentions are correct

Checks if php version and extentions are correct

Returns

string
Error is not Suitable. Empty string means suitable.

Since

1.0
public boolean
# _file_exists( )

Checks if key file exists

Checks if key file exists

Returns

boolean

Since

1.0
public string
# _file_get_contents( )

Get contents of the key file

Get contents of the key file

Returns

string

Since

1.0
public string
# create_key_file_folder( )

Try to create an encrypted key file folder

Try to create an encrypted key file folder

Returns

string

Since

1.0
public string
# key_file_folder( )

Return key file folder name

Return key file folder name

Returns

string

Since

1.0
public boolean
# is_active( )

Checks for settings and prerequisites

Checks for settings and prerequisites

Returns

boolean

Since

1.0
public boolean
# connect( )

Connects to GCal API

Connects to GCal API

Returns

boolean
Return true if connected successfully, else false.

Since

1.0
public
# set_event_parameters( array $app )

Creates a Google Event object and set its parameters

Creates a Google Event object and set its parameters

Parameters

$app
Data to export

Since

1.0
public
# delete_event( integer $order_id )

Delete event from Gcal when an order is cancelled.

Delete event from Gcal when an order is cancelled.

Parameters

$order_id
Order ID

Since

1.0
public boolean
# insert_event( array $event_details, integer $event_id, boolean $test = false )

Inserts an event to the selected calendar with delivery date & time

Inserts an event to the selected calendar with delivery date & time

Parameters

$event_details
Event details
$event_id
Even ID
$test
Check if it is a test event or not.

Returns

boolean
True if event inserted successfully, else false.

Since

1.0

Globals

resource $wpdb
public
# log( string $message = '' )

Logs the error if something went wrong.

Logs the error if something went wrong.

Parameters

$message
Message to be sent to the log file.

Since

1.0
public string
# gcal( resource $prdd )

Build GCal url for GCal Button. It requires UTC time.

Build GCal url for GCal Button. It requires UTC time.

Parameters

$prdd
Event Details Object

Returns

string
URL

Since

1.0
public string
# other_cal( resource $prdd )

Build url for Other calendar Button. It requires UTC time.

Build url for Other calendar Button. It requires UTC time.

Parameters

$prdd
Event Details Object

Returns

string
URL

Since

1.0
API documentation generated by ApiGen