Skip to content

Commit

Permalink
Database updates to handle new data coming from IGDB
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-j-green committed Feb 2, 2024
1 parent aba6e24 commit 54abbce
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 32 deletions.
4 changes: 2 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@
"request": "launch",
"preLaunchTask": "build",
// If you have changed target frameworks, make sure to update the program path.
"program": "${workspaceFolder}/gaseous-server/bin/Debug/net7.0/gaseous-server.dll",
"program": "${workspaceFolder}/gaseous-server/bin/Debug/net8.0/gaseous-server.dll",
"args": [],
"cwd": "${workspaceFolder}/gaseous-server",
"stopAtEntry": false,
// Enable launching a web browser when ASP.NET Core starts. For more information: https://aka.ms/VSCode-CS-LaunchJson-WebBrowser
"serverReadyAction": {
"action": "openExternally",
"pattern": "\\bNow listening on:\\s+(https?://\\S+)"
"pattern": "\\bNow listening on:\\s+(http?://\\S+)"
},
"env": {
"ASPNETCORE_ENVIRONMENT": "Development"
Expand Down
2 changes: 1 addition & 1 deletion gaseous-server/Classes/Metadata/Collections.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ namespace gaseous_server.Classes.Metadata
{
public class Collections
{
const string fieldList = "fields checksum,created_at,games,name,slug,updated_at,url;";
const string fieldList = "fields as_child_relations,as_parent_relations,checksum,created_at,games,name,slug,type,updated_at,url;";

public Collections()
{
Expand Down
2 changes: 1 addition & 1 deletion gaseous-server/Classes/Metadata/Covers.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace gaseous_server.Classes.Metadata
{
public class Covers
{
const string fieldList = "fields alpha_channel,animated,checksum,game,height,image_id,url,width;";
const string fieldList = "fields alpha_channel,animated,checksum,game,game_localization,height,image_id,url,width;";

public Covers()
{
Expand Down
2 changes: 1 addition & 1 deletion gaseous-server/Classes/Metadata/Games.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ namespace gaseous_server.Classes.Metadata
{
public class Games
{
const string fieldList = "fields age_ratings,aggregated_rating,aggregated_rating_count,alternative_names,artworks,bundles,category,checksum,collection,cover,created_at,dlcs,expanded_games,expansions,external_games,first_release_date,follows,forks,franchise,franchises,game_engines,game_localizations,game_modes,genres,hypes,involved_companies,keywords,language_supports,multiplayer_modes,name,parent_game,platforms,player_perspectives,ports,rating,rating_count,release_dates,remakes,remasters,screenshots,similar_games,slug,standalone_expansions,status,storyline,summary,tags,themes,total_rating,total_rating_count,updated_at,url,version_parent,version_title,videos,websites;";
const string fieldList = "fields age_ratings,aggregated_rating,aggregated_rating_count,alternative_names,artworks,bundles,category,checksum,collection,collections,cover,created_at,dlcs,expanded_games,expansions,external_games,first_release_date,follows,forks,franchise,franchises,game_engines,game_localizations,game_modes,genres,hypes,involved_companies,keywords,language_supports,multiplayer_modes,name,parent_game,platforms,player_perspectives,ports,rating,rating_count,release_dates,remakes,remasters,screenshots,similar_games,slug,standalone_expansions,status,storyline,summary,tags,themes,total_rating,total_rating_count,updated_at,url,version_parent,version_title,videos,websites;";

public Games()
{
Expand Down
28 changes: 1 addition & 27 deletions gaseous-server/Properties/launchSettings.json
Original file line number Diff line number Diff line change
@@ -1,41 +1,15 @@
{
"$schema": "https://json.schemastore.org/launchsettings.json",
"iisSettings": {
"windowsAuthentication": false,
"anonymousAuthentication": true,
"iisExpress": {
"applicationUrl": "http://localhost:38715",
"sslPort": 44314
}
},
"profiles": {
"http": {
"commandName": "Project",
"launchBrowser": true,
"launchUrl": "swagger",
"launchUrl": "/",
"applicationUrl": "http://localhost:5198",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"dotnetRunMessages": true
},
"https": {
"commandName": "Project",
"launchBrowser": true,
"launchUrl": "swagger",
"applicationUrl": "https://localhost:7282;http://localhost:5198",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"dotnetRunMessages": true
},
"IIS Express": {
"commandName": "IISExpress",
"launchBrowser": true,
"launchUrl": "swagger",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
}
}
}
17 changes: 17 additions & 0 deletions gaseous-server/Support/Database/MySQL/gaseous-1018.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
ALTER TABLE `Collection`
ADD COLUMN `AsParentRelations` LONGTEXT NULL AFTER `Id`,
ADD COLUMN `AsChildRelations` LONGTEXT NULL AFTER `AsParentRelations`,
ADD COLUMN `Type` INT NULL AFTER `UpdatedAt`;

ALTER TABLE `Cover`
ADD COLUMN `GameLocalization` BIGINT NULL AFTER `Game`;

ALTER TABLE `Game`
ADD COLUMN `Collections` LONGTEXT NULL AFTER `Collection`,
ADD COLUMN `ExpandedGames` LONGTEXT NULL AFTER `Dlcs`,
ADD COLUMN `Forks` LONGTEXT NULL AFTER `Follows`,
ADD COLUMN `GameLocalizations` LONGTEXT NULL AFTER `GameEngines`,
ADD COLUMN `LanguageSupports` LONGTEXT NULL AFTER `Keywords`,
ADD COLUMN `Ports` LONGTEXT NULL AFTER `PlayerPerspectives`,
ADD COLUMN `Remakes` LONGTEXT NULL AFTER `ReleaseDates`,
ADD COLUMN `Remasters` LONGTEXT NULL AFTER `Remakes`;
2 changes: 2 additions & 0 deletions gaseous-server/gaseous-server.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
<None Remove="Support\Database\MySQL\gaseous-1015.sql" />
<None Remove="Support\Database\MySQL\gaseous-1016.sql" />
<None Remove="Support\Database\MySQL\gaseous-1017.sql" />
<None Remove="Support\Database\MySQL\gaseous-1018.sql" />
<None Remove="Classes\Metadata\" />
</ItemGroup>
<ItemGroup>
Expand Down Expand Up @@ -98,5 +99,6 @@
<EmbeddedResource Include="Support\Database\MySQL\gaseous-1015.sql" />
<EmbeddedResource Include="Support\Database\MySQL\gaseous-1016.sql" />
<EmbeddedResource Include="Support\Database\MySQL\gaseous-1017.sql" />
<EmbeddedResource Include="Support\Database\MySQL\gaseous-1018.sql" />
</ItemGroup>
</Project>

0 comments on commit 54abbce

Please sign in to comment.