diff --git a/db/migrations/20250627103000_asset_management_schema_v2.php b/db/migrations/20250627103000_asset_management_schema_v2.php index 887dbfffd..4a18b262c 100644 --- a/db/migrations/20250627103000_asset_management_schema_v2.php +++ b/db/migrations/20250627103000_asset_management_schema_v2.php @@ -10,6 +10,7 @@ final class AssetManagementSchemaV2 extends AbstractMigration */ public function up(): void { + if($this->getEnvironment() == "thetool") { // 1. Add columns to AssetManagement table $assetManagement = $this->table('AssetManagement'); $assetManagement @@ -91,6 +92,7 @@ final class AssetManagementSchemaV2 extends AbstractMigration ]) ->addIndex(['assetId']) ->create(); + } } /** @@ -98,6 +100,7 @@ final class AssetManagementSchemaV2 extends AbstractMigration */ public function down(): void { + if($this->getEnvironment() == "thetool") { // Remove columns from AssetManagement $this->table('AssetManagement') ->removeColumn('imageId') @@ -111,5 +114,6 @@ final class AssetManagementSchemaV2 extends AbstractMigration // Drop reservation table $this->table('AssetManagementReservation')->drop()->save(); + } } }