Feature: Late Fees can now be assessed to unpaid invoices

This commit is contained in:
johnnyq
2023-07-11 11:40:53 -04:00
parent eb1e792e77
commit bb16c4b7b8
6 changed files with 46 additions and 6 deletions

View File

@@ -1139,11 +1139,22 @@ if (LATEST_DATABASE_VERSION > CURRENT_DATABASE_VERSION) {
mysqli_query($mysqli, "UPDATE `settings` SET `config_current_database_version` = '0.6.2'");
}
//if (CURRENT_DATABASE_VERSION == '0.6.2') {
//Insert queries here required to update to DB version 0.6.2
if (CURRENT_DATABASE_VERSION == '0.6.2') {
//Insert queries here required to update to DB version 0.6.3
mysqli_query($mysqli, "ALTER TABLE `settings` ADD `config_invoice_late_fee_enable` TINYINT(1) NOT NULL DEFAULT 0 AFTER `config_invoice_from_email`");
mysqli_query($mysqli, "ALTER TABLE `settings` ADD `config_invoice_late_fee_percent` DECIMAL(5,2) NOT NULL DEFAULT 0 AFTER `config_invoice_late_fee_enable`");
// Then, update the database to the next sequential version
//mysqli_query($mysqli, "UPDATE `settings` SET `config_current_database_version` = '0.6.2'");
mysqli_query($mysqli, "UPDATE `settings` SET `config_current_database_version` = '0.6.3'");
}
//if (CURRENT_DATABASE_VERSION == '0.6.3') {
//Insert queries here required to update to DB version 0.6.4
// Then, update the database to the next sequential version
//mysqli_query($mysqli, "UPDATE `settings` SET `config_current_database_version` = '0.6.4'");
//}
} else {