Fix payment dates not being set correctly

This commit is contained in:
FrancescoUK committed 2020-01-19 23:02:26 +00:00
1 parent 6e523a30ab
commit c871c68aeb
2 files changed
+23

No files matched your search

@@ -0,0 +1,20 @@
<?php if (!defined('BASEPATH')) exit('No direct script access allowed');
class Migration_PaymentDateFix extends CI_Migration
{
public function __construct()
{
parent::__construct();
}
public function up()
{
execute_script(APPPATH . 'migrations/sqlscripts/3.3.2_paymentdatefix.sql');
}
public function down()
{
}
}
?>
@@ -0,0 +1,3 @@
UPDATE `ospos_sales_payments`
JOIN `ospos_sales` ON `ospos_sales`.`sale_id`=`ospos_sales_payments`.`sale_id`
SET `ospos_sales_payments`.`payment_time`=`ospos_sales`.`sale_time`;