File tree Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ function update100to101(Migration $migration)
4141 $ update_dir = __DIR__ . "/update_ {$ from_version }_to_ {$ to_version }/ " ;
4242
4343 //TRANS: %s is the number of new version
44- $ migration ->displayTitle (sprintf (__ ('Update to %s ' ), $ to_version ));
44+ $ migration ->addInfoMessage (sprintf (__ ('Update to %s ' ), $ to_version ));
4545 $ migration ->setVersion ($ to_version );
4646
4747 // New tables from enpty.sql file after the migration
@@ -58,7 +58,7 @@ function update100to101(Migration $migration)
5858
5959 $ dbFile = plugin_carbon_getSchemaPath ($ to_version );
6060 if ($ dbFile === null || !$ DB ->runFile ($ dbFile )) {
61- $ migration ->displayWarning ("Error creating tables : " . $ DB ->error ());
61+ $ migration ->addWarningMessage ("Error creating tables : " . $ DB ->error ());
6262 $ updateresult = false ;
6363 }
6464
Original file line number Diff line number Diff line change 3030 * -------------------------------------------------------------------------
3131 */
3232
33+ use Glpi \DBAL \QuerySubQuery ;
3334use GlpiPlugin \Carbon \CarbonEmission ;
3435use GlpiPlugin \Carbon \CarbonIntensitySource ;
3536use GlpiPlugin \Carbon \CarbonIntensitySource_Zone ;
Original file line number Diff line number Diff line change @@ -777,9 +777,9 @@ public function checkSourceZoneRelation()
777777 /** @var DBmysql */
778778 global $ DB ;
779779
780- $ source_table = CarbonIntensitySource ::getTable ();
780+ $ source_table = Source ::getTable ();
781781 $ zone_table = Zone::getTable ();
782- $ source_zone_table = CarbonIntensitySource_Zone ::getTable ();
782+ $ source_zone_table = Source_Zone ::getTable ();
783783
784784 $ iterator = $ DB ->request ([
785785 'SELECT ' => $ source_zone_table . '.id ' ,
You can’t perform that action at this time.
0 commit comments