diff --git a/application/config/migration.php b/application/config/migration.php index 90c77c9d..9399b8d8 100644 --- a/application/config/migration.php +++ b/application/config/migration.php @@ -22,7 +22,7 @@ $config['migration_enabled'] = TRUE; | */ -$config['migration_version'] = 197; +$config['migration_version'] = 198; /* |-------------------------------------------------------------------------- diff --git a/application/migrations/198_sat_name_change_hadesicm_so125.php b/application/migrations/198_sat_name_change_hadesicm_so125.php new file mode 100644 index 00000000..45eb207e --- /dev/null +++ b/application/migrations/198_sat_name_change_hadesicm_so125.php @@ -0,0 +1,37 @@ +db->set('COL_SAT_NAME', 'SO-125'); + $this->db->where('COL_SAT_NAME', 'HADES-ICM'); + $this->db->update($this->config->item('table_name')); + log_message('info', 'Migration: Updated COL_SAT_NAME to SO-125 for HADES-ICM'); + + // update column COL_LOTW_QSL_SENT to N if its SO-125 + $this->db->set('COL_LOTW_QSL_SENT', 'N'); + $this->db->where('COL_SAT_NAME', 'SO-125'); + $this->db->update($this->config->item('table_name')); + log_message('info', 'Migration: Set COL_LOTW_QSL_SENT to N for SO-125'); + + } + + public function down() + { + //Change back to HADES-ICM + $this->db->set('COL_SAT_NAME', 'HADES-ICM'); + $this->db->where('COL_SAT_NAME', 'SO-125'); + $this->db->update($this->config->item('table_name')); + log_message('info', 'Migration: Reverted COL_SAT_NAME back to HADES-ICM'); + + // Set COL_LOTW_QSL_SENT back to N for HADES-ICM + $this->db->set('COL_LOTW_QSL_SENT', 'N'); + $this->db->where('COL_SAT_NAME', 'HADES-ICM'); + $this->db->update($this->config->item('table_name')); + log_message('info', 'Migration: Reverted COL_LOTW_QSL_SENT back to N for HADES-ICM'); + } +} diff --git a/assets/json/satellite_data.json b/assets/json/satellite_data.json index 2e7e9b6f..6ad5964a 100644 --- a/assets/json/satellite_data.json +++ b/assets/json/satellite_data.json @@ -499,7 +499,7 @@ ] } }, - "HADES-ICM":{ + "SO-125":{ "Modes":{ "V/U":[ {