forked from Jorixon/JASM
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Added presets overview (Jorixon#162)
chore: Possible set preset as Read Only
- Loading branch information
Showing
28 changed files
with
1,581 additions
and
136 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
src/GIMI-ModManager.Core/Services/ModPresetService/JsonModels/JsonModPreset.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
namespace GIMI_ModManager.Core.Services.ModPresetService.JsonModels; | ||
|
||
internal class JsonModPreset | ||
{ | ||
public bool IsReadOnly { get; set; } | ||
public DateTime Created { get; set; } = DateTime.Now; | ||
public int Index { get; set; } | ||
public List<JsonModPresetEntry> Mods { get; set; } = new(); | ||
} |
25 changes: 25 additions & 0 deletions
25
src/GIMI-ModManager.Core/Services/ModPresetService/JsonModels/JsonModPresetEntry.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
using System.Diagnostics.CodeAnalysis; | ||
using System.Text.Json.Serialization; | ||
|
||
namespace GIMI_ModManager.Core.Services.ModPresetService.JsonModels; | ||
|
||
[SuppressMessage("ReSharper", "PropertyCanBeMadeInitOnly.Global", Justification = "This is a json model")] | ||
internal class JsonModPresetEntry | ||
{ | ||
public required Guid ModId { get; set; } | ||
public required string FullPath { get; set; } | ||
public bool IsMissing { get; set; } | ||
|
||
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)] | ||
public string? CustomName { get; set; } | ||
|
||
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)] | ||
public string? SourceUrl { get; set; } | ||
|
||
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)] | ||
public Dictionary<string, string>? Preferences { get; set; } | ||
|
||
|
||
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)] | ||
public string? AddedAt { get; set; } | ||
} |
Oops, something went wrong.