Merge remote-tracking branch 'origin/master' into UselessToucan/EfCore

# Conflicts:
#	osu-framework
#	osu.Game/Beatmaps/BeatmapMetadata.cs
#	osu.Game/osu.Game.csproj
#	osu.Game/packages.config
This commit is contained in:
smoogipoo
2017-10-14 16:36:37 +09:00
47 changed files with 474 additions and 189 deletions

View File

@ -4,6 +4,7 @@
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using Newtonsoft.Json;
using osu.Game.Users;
namespace osu.Game.Beatmaps
{
@ -20,8 +21,21 @@ namespace osu.Game.Beatmaps
public string Artist { get; set; }
public string ArtistUnicode { get; set; }
/// <summary>
/// Helper property to deserialize a username to <see cref="User"/>.
/// </summary>
[JsonProperty(@"creator")]
public string Author { get; set; }
[Column("Author")]
public string AuthorString
{
get { return Author?.Username; }
set { Author = new User { Username = value }; }
}
/// <summary>
/// The author of the beatmaps in this set.
/// </summary>
public User Author;
public string Source { get; set; }
@ -33,7 +47,7 @@ namespace osu.Game.Beatmaps
public string[] SearchableTerms => new[]
{
Author,
Author?.Username,
Artist,
ArtistUnicode,
Title,