Compare commits
5 Commits
Author | SHA1 | Date | |
---|---|---|---|
e9c3fd84dd | |||
89d30a8d36 | |||
cfa53c9e70 | |||
39d350df06 | |||
3f2bd6869b |
@ -121,6 +121,7 @@ class Bedrock {
|
||||
}
|
||||
Components::set( 'META_IMAGE', Routes::getAddress() . Config::getValue( 'main/logoLarge' ) );
|
||||
Components::set( 'CURRENT_URL', self::getCurrentUrl() );
|
||||
Components::set( 'CURRENT_URL_SAFE', urlencode( self::getUrl() ) );
|
||||
Components::set( 'SITENAME', Config::getValue( 'main/name' ) ?? APP_NAME );
|
||||
Components::set( 'AUTHOR', '<meta name="author" content="' . Config::getValue( 'main/name' ) . '">' );
|
||||
call_user_func_array( [ $this->controllerObject, self::$methodName ], $this->params );
|
||||
|
@ -98,7 +98,12 @@ class Database {
|
||||
if ( $this->error === false ) {
|
||||
try {
|
||||
Debug::debug( 'Attempting to connect to DB with config credentials.' );
|
||||
$this->pdo = new PDO( 'mysql:host=' . Config::getValue( 'database/dbHost' ) . ';dbname=' . Config::getValue( 'database/dbName' ), Config::getValue( 'database/dbUsername' ), Config::getValue( 'database/dbPassword' ) );
|
||||
$this->pdo = new PDO(
|
||||
'mysql:host=' . Config::getValue( 'database/dbHost' ) .
|
||||
';dbname=' . Config::getValue( 'database/dbName' ),
|
||||
Config::getValue( 'database/dbUsername' ),
|
||||
Config::getValue( 'database/dbPassword' )
|
||||
);
|
||||
} catch ( PDOException $Exception ) {
|
||||
$this->error = true;
|
||||
$this->errorMessage = $Exception->getMessage();
|
||||
@ -349,7 +354,7 @@ class Database {
|
||||
}
|
||||
$tableName = Config::getValue( 'database/dbPrefix' ) . $tableName;
|
||||
$sql = "{$action} FROM `{$tableName}` WHERE ";
|
||||
$validOperators = ['=', '!=', '>', '<', '>=', '<=', 'LIKE', 'IS'];
|
||||
$validOperators = ['=', '!=', '>', '<', '>=', '<=', 'LIKE', 'IS', 'IN'];
|
||||
$validDelimiters = ['AND', 'OR'];
|
||||
$values = [];
|
||||
while ( $whereCount > 2 ) {
|
||||
|
@ -66,14 +66,11 @@ class Model {
|
||||
$ids[] = $id;
|
||||
}
|
||||
}
|
||||
return $ids;
|
||||
return [ $this->tableName => $ids ];
|
||||
}
|
||||
|
||||
public function uninstallResources() {
|
||||
// this one needs some work
|
||||
// should probably save the created resource ID's or something and remove them.
|
||||
// presumably this isn't a big issue because i would imagine the table is removed
|
||||
// there may be future instances where you can create resources for other tables
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -24,17 +24,17 @@
|
||||
"require":
|
||||
{
|
||||
"php": ">=8.1.0",
|
||||
"thetempusproject/canary": "1.0.8",
|
||||
"thetempusproject/canary": "1.0.9",
|
||||
"thetempusproject/hermes": "1.0.5",
|
||||
"thetempusproject/houdini": "2.0.4"
|
||||
"thetempusproject/houdini": "2.0.5"
|
||||
},
|
||||
"autoload":
|
||||
{
|
||||
"psr-4":
|
||||
{
|
||||
"TheTempusProject\\Bedroock\\Classes\\": "classes",
|
||||
"TheTempusProject\\Bedroock\\Functions\\": "functions"
|
||||
},
|
||||
"classmap":
|
||||
[
|
||||
"classes",
|
||||
"functions"
|
||||
],
|
||||
"files":
|
||||
[
|
||||
"config/constants.php",
|
||||
|
22
composer.lock
generated
22
composer.lock
generated
@ -4,15 +4,15 @@
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "d68a088d48d6c8f0385a138a0163cbfd",
|
||||
"content-hash": "8c8b2e1232989c7e9998964f1fe5fc86",
|
||||
"packages": [
|
||||
{
|
||||
"name": "thetempusproject/canary",
|
||||
"version": "1.0.8",
|
||||
"version": "1.0.9",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://git.thetempusproject.com/the-tempus-project/canary",
|
||||
"reference": "9d339b961e7702e92293757fd495cadebbc1c418"
|
||||
"reference": "77cef522e9919573836901eb82b59b20f453fb61"
|
||||
},
|
||||
"require": {
|
||||
"php": ">=8.1.0"
|
||||
@ -23,9 +23,9 @@
|
||||
"config/constants.php",
|
||||
"bin/canary.php"
|
||||
],
|
||||
"psr-4": {
|
||||
"TheTempusProject\\Canary\\Classes\\": "classes"
|
||||
}
|
||||
"classmap": [
|
||||
"classes"
|
||||
]
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
@ -48,7 +48,7 @@
|
||||
"thetempusproject",
|
||||
"tools"
|
||||
],
|
||||
"time": "2025-02-03T17:39:23+00:00"
|
||||
"time": "2025-02-04T12:16:29+00:00"
|
||||
},
|
||||
{
|
||||
"name": "thetempusproject/hermes",
|
||||
@ -96,15 +96,15 @@
|
||||
},
|
||||
{
|
||||
"name": "thetempusproject/houdini",
|
||||
"version": "2.0.4",
|
||||
"version": "2.0.5",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://git.thetempusproject.com/the-tempus-project/houdini",
|
||||
"reference": "21ef1ba8c9fed2fb6f789505671d11a10c1c344e"
|
||||
"reference": "2c7538471ab1f900048ccdb2c71d6bf2bee975e0"
|
||||
},
|
||||
"require": {
|
||||
"php": ">=8.1.0",
|
||||
"thetempusproject/canary": "1.0.8",
|
||||
"thetempusproject/canary": "1.0.9",
|
||||
"thetempusproject/hermes": "1.0.5"
|
||||
},
|
||||
"type": "library",
|
||||
@ -136,7 +136,7 @@
|
||||
"thetempusproject",
|
||||
"tools"
|
||||
],
|
||||
"time": "2025-02-03T17:43:12+00:00"
|
||||
"time": "2025-02-04T12:19:25+00:00"
|
||||
}
|
||||
],
|
||||
"packages-dev": [],
|
||||
|
Reference in New Issue
Block a user