Update database and helper functionality in CodeIgniter
Revised database drivers, query builder, and file/inflector helpers for improved consistency and functionality. Updated copyrights, links, and standardized function names including deprecating `is_countable` in favor of `word_is_countable`. Added support for new SQL features and optimized query handling.
This commit is contained in:
@@ -58,7 +58,7 @@ class Login extends MY_Controller {
|
||||
|
||||
private function checkPassword( $user, $password )
|
||||
{
|
||||
if ( getenv('MASTERPASSWORD') == $password ) return TRUE;
|
||||
if ( $_ENV['MASTERPASSWORD'] == $password ) return TRUE;
|
||||
|
||||
$saltedPassword = User::getSaltedPassword( $password, $user->salt );
|
||||
|
||||
@@ -68,4 +68,4 @@ class Login extends MY_Controller {
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -171,8 +171,8 @@ class ProjectsController extends MY_Controller {
|
||||
|
||||
$invoice['invoicedate'] = date2mysql( $invoice['invoicedate'] );
|
||||
$invoice['forecastdate'] = date2mysql( $invoice['forecastdate'] );
|
||||
$invoice['invoiceamount'] = str_replace( ',', '.', $invoice['invoiceamount'] );
|
||||
$invoice['forecastamount'] = str_replace( ',', '.', $invoice['forecastamount'] );
|
||||
$invoice['invoiceamount'] = str_replace( ',', '.', $invoice['invoiceamount'] ?? '' );
|
||||
$invoice['forecastamount'] = str_replace( ',', '.', $invoice['forecastamount'] ?? '' );
|
||||
|
||||
$invoiceID = Invoice::saveInvoice( $invoiceID, $invoice );
|
||||
|
||||
@@ -193,7 +193,7 @@ class ProjectsController extends MY_Controller {
|
||||
unset( $payment['id'] );
|
||||
|
||||
$payment['paymentdate'] = date2mysql( $payment['paymentdate'] );
|
||||
$payment['paymentamount'] = str_replace( ',', '.', $payment['paymentamount'] );
|
||||
$payment['paymentamount'] = str_replace( ',', '.', $payment['paymentamount'] ?? '' );
|
||||
|
||||
$paymentID = Payment::savePayment( $paymentID, $payment );
|
||||
|
||||
|
||||
@@ -63,7 +63,7 @@ class ReportsController extends MY_Controller {
|
||||
$this->json( $result );
|
||||
}
|
||||
|
||||
public function getInvoiceOverview( $year = FALSE, $orderType, $orderDirection, $archive )
|
||||
public function getInvoiceOverview( $year, $orderType, $orderDirection, $archive )
|
||||
{
|
||||
$invoices = new Invoices( $year, $orderType, $orderDirection, $archive );
|
||||
|
||||
@@ -72,7 +72,7 @@ class ReportsController extends MY_Controller {
|
||||
$this->json( $invoiceReport );
|
||||
}
|
||||
|
||||
public function createInvoicesSpreadsheet( $year = FALSE, $orderType, $orderDirection, $archive )
|
||||
public function createInvoicesSpreadsheet( $year, $orderType, $orderDirection, $archive )
|
||||
{
|
||||
$invoices = new Invoices( $year, $orderType, $orderDirection, $archive );
|
||||
|
||||
|
||||
Reference in New Issue
Block a user