2017-01-28 01:41:29 -05:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace DataAccess;
|
|
|
|
|
|
|
|
|
|
|
|
use Exception;
|
|
|
|
|
2017-09-11 21:03:03 -04:00
|
|
|
class CommonDao extends \BaseClass {
|
2017-01-28 01:41:29 -05:00
|
|
|
/**
|
|
|
|
* @throws Exception if the database isn't properly configured
|
|
|
|
*/
|
|
|
|
function init() {
|
|
|
|
if (!function_exists('hesk_dbConnect')) {
|
|
|
|
throw new Exception('Database not loaded!');
|
|
|
|
}
|
|
|
|
hesk_dbConnect();
|
|
|
|
}
|
|
|
|
|
|
|
|
function close() {
|
|
|
|
hesk_dbClose();
|
|
|
|
}
|
|
|
|
}
|