Files
dev-chiefworks f76abffdcd first commit
2022-05-31 16:21:53 -04:00

199 lines
7.0 KiB
PHP

<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*
|--------------------------------------------------------------------------
| Display Debug backtrace
|--------------------------------------------------------------------------
|
| If set to TRUE, a backtrace will be displayed along with php errors. If
| error_reporting is disabled, the backtrace will not display, regardless
| of this setting
|
*/
defined('SHOW_DEBUG_BACKTRACE') OR define('SHOW_DEBUG_BACKTRACE', TRUE);
/*
|--------------------------------------------------------------------------
| File and Directory Modes
|--------------------------------------------------------------------------
|
| These prefs are used when checking and setting modes when working
| with the file system. The defaults are fine on servers with proper
| security, but you may wish (or even need) to change the values in
| certain environments (Apache running a separate process for each
| user, PHP under CGI with Apache suEXEC, etc.). Octal values should
| always be used to set the mode correctly.
|
*/
defined('FILE_READ_MODE') OR define('FILE_READ_MODE', 0644);
defined('FILE_WRITE_MODE') OR define('FILE_WRITE_MODE', 0666);
defined('DIR_READ_MODE') OR define('DIR_READ_MODE', 0755);
defined('DIR_WRITE_MODE') OR define('DIR_WRITE_MODE', 0755);
/*
|--------------------------------------------------------------------------
| File Stream Modes
|--------------------------------------------------------------------------
|
| These modes are used when working with fopen()/popen()
|
*/
defined('FOPEN_READ') OR define('FOPEN_READ', 'rb');
defined('FOPEN_READ_WRITE') OR define('FOPEN_READ_WRITE', 'r+b');
defined('FOPEN_WRITE_CREATE_DESTRUCTIVE') OR define('FOPEN_WRITE_CREATE_DESTRUCTIVE', 'wb'); // truncates existing file data, use with care
defined('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE') OR define('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE', 'w+b'); // truncates existing file data, use with care
defined('FOPEN_WRITE_CREATE') OR define('FOPEN_WRITE_CREATE', 'ab');
defined('FOPEN_READ_WRITE_CREATE') OR define('FOPEN_READ_WRITE_CREATE', 'a+b');
defined('FOPEN_WRITE_CREATE_STRICT') OR define('FOPEN_WRITE_CREATE_STRICT', 'xb');
defined('FOPEN_READ_WRITE_CREATE_STRICT') OR define('FOPEN_READ_WRITE_CREATE_STRICT', 'x+b');
/*
|--------------------------------------------------------------------------
| Exit Status Codes
|--------------------------------------------------------------------------
|
| Used to indicate the conditions under which the script is exit()ing.
| While there is no universal standard for error codes, there are some
| broad conventions. Three such conventions are mentioned below, for
| those who wish to make use of them. The CodeIgniter defaults were
| chosen for the least overlap with these conventions, while still
| leaving room for others to be defined in future versions and user
| applications.
|
| The three main conventions used for determining exit status codes
| are as follows:
|
| Standard C/C++ Library (stdlibc):
| http://www.gnu.org/software/libc/manual/html_node/Exit-Status.html
| (This link also contains other GNU-specific conventions)
| BSD sysexits.h:
| http://www.gsp.com/cgi-bin/man.cgi?section=3&topic=sysexits
| Bash scripting:
| http://tldp.org/LDP/abs/html/exitcodes.html
|
*/
defined('EXIT_SUCCESS') OR define('EXIT_SUCCESS', 0); // no errors
defined('EXIT_ERROR') OR define('EXIT_ERROR', 1); // generic error
defined('EXIT_CONFIG') OR define('EXIT_CONFIG', 3); // configuration error
defined('EXIT_UNKNOWN_FILE') OR define('EXIT_UNKNOWN_FILE', 4); // file not found
defined('EXIT_UNKNOWN_CLASS') OR define('EXIT_UNKNOWN_CLASS', 5); // unknown class
defined('EXIT_UNKNOWN_METHOD') OR define('EXIT_UNKNOWN_METHOD', 6); // unknown class member
defined('EXIT_USER_INPUT') OR define('EXIT_USER_INPUT', 7); // invalid user input
defined('EXIT_DATABASE') OR define('EXIT_DATABASE', 8); // database error
defined('EXIT__AUTO_MIN') OR define('EXIT__AUTO_MIN', 9); // lowest automatically-assigned error code
defined('EXIT__AUTO_MAX') OR define('EXIT__AUTO_MAX', 125); // highest automatically-assigned error code
define('SITE_NAME', 'Float');
define('SITE_EMAIL', 'support@float.sg');
define('SITE_PHONE', '+1 911 9110');
define('SITE_FAX', '+1 9FX 9110');
define('PHP_API_OK', 0);
define('MAX_ADMIN_SESSION', 19600);
// SAVVY BACK OFFICE FUNCTION*****************
define('SAVVY_BKO_START', 100000);
define('SAVVY_BKO_LOGIN', 100005);
define('SAVVY_BKO_CREATEUSER', 100010);
define('SAVVY_BKO_EDITUSER', 100011);
define('SAVVY_BKO_UPDATEMEMBER', 100012);
define('SAVVY_BKO_ADDREASON', 100020);
define('SAVVYEXT_BKO_DELETEALLCARDS', 100022);
define('SAVVYEXT_BKO_CARDASSIGNED', 100027);
define('SAVVYEXT_BKO_ADDCARD', 100028);
define('SAVVYEXT_BKO_MOVECARD', 100029);
define('SAVVYEXT_BKO_REFRESHCARD', 100031);
define('SAVVY_BKO_LANGUAGE_STATUS', 100030);
define('SAVVYEXT_BKO_REFRESHGROUP', 100033);
define('SAVVY_BKO_CARPOOL_FRIENDMESSAGE', 100035);
define('SAVVY_BKO_SURVEY_LOGIC', 100041);
define('SAVVY_BKO_GPSTRIGGER_LOGIC', 100042);
define('SAVVY_BKO_PROCESS_POINTS', 100039);
define('SAVVY_BKO_MAINCARD_CREATE', 40200);
define('SAVVY_BKO_MAINCARD_UPDATE', 40210);
define('SAVVY_BKO_USERCARD_ADD', 40220);
define('SAVVY_BKO_USERCARD_DELETE', 40223);
define('SAVVY_BKO_MOVECARD', 40225);
define('SAVVY_BKO_ASSIGN_POINTS', 100047);
//define('FLOAT_SYSTEM_CREATE_DYNAMICCARD', 92026);
//define('SAVVY_BKO_SURVEY_LOGIC', 40230);
define('MIN_INT_2', -32768);
define('MAX_INT_2', 32768);
define('MIN_INT_4', -2147483648);
define('MAX_INT_4', 2147483648);
define("FLOAT_SYSTEM_CREATE_NOTIFICATION", 92025);
define("FLOAT_SYSTEM_EMAIL_NOTIFICATION", 92027);
define('FLOAT_SYSTEM_CREATE_DYNAMICCARD', 92026);
$trigger_card = array(
"ETRG0001" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0001KEY"
),
"ETRG0002" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0002KEY"
),
"ETRG0003" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0003KEY"
),
"ETRG0004" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0004KEY"
),
"ETRG0005" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0005KEY"
),
"ETRG0006" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0006KEY"
),
"ETRG0011" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0011KEY"
),
"ETRG0014" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0014KEY"
),
"ETRG0015" => array(
"active" => 1,
"cat" => 'GOACTIVITY',
"dynamic_key" => "ETRG0015KEY"
),
"ETRG0021" => array(
"active" => 1,
"cat" => 'GOPROFILE',
"dynamic_key" => "ETRG0021KEY"
)
);