aboutsummaryrefslogtreecommitdiff
path: root/Timeline/Models/UserDetail.cs
diff options
context:
space:
mode:
author杨宇千 <crupest@outlook.com>2019-08-24 22:24:04 +0800
committer杨宇千 <crupest@outlook.com>2019-08-24 22:24:04 +0800
commit7d5076a0c5e95380ee872e3898b2654f2757b6a4 (patch)
treef5419e5d6117b329c8e1d17a1a88e81acc9d5909 /Timeline/Models/UserDetail.cs
parent3716d2431de08194d3a107ef640febc47c3ee72a (diff)
downloadtimeline-7d5076a0c5e95380ee872e3898b2654f2757b6a4.tar.gz
timeline-7d5076a0c5e95380ee872e3898b2654f2757b6a4.tar.bz2
timeline-7d5076a0c5e95380ee872e3898b2654f2757b6a4.zip
Rename EMail to Email.
Diffstat (limited to 'Timeline/Models/UserDetail.cs')
-rw-r--r--Timeline/Models/UserDetail.cs6
1 files changed, 4 insertions, 2 deletions
diff --git a/Timeline/Models/UserDetail.cs b/Timeline/Models/UserDetail.cs
index 86866d8b..1a6c0c6a 100644
--- a/Timeline/Models/UserDetail.cs
+++ b/Timeline/Models/UserDetail.cs
@@ -1,6 +1,7 @@
using System.ComponentModel.DataAnnotations;
using Timeline.Entities;
using Timeline.Models.Validation;
+using Newtonsoft.Json;
namespace Timeline.Models
{
@@ -10,10 +11,11 @@ namespace Timeline.Models
public string Nickname { get; set; }
[ValidateWith(typeof(UserDetailValidators.QQValidator))]
+ [JsonProperty(PropertyName = "qq")]
public string QQ { get; set; }
[ValidateWith(typeof(UserDetailValidators.EMailValidator))]
- public string EMail { get; set; }
+ public string Email { get; set; }
[ValidateWith(typeof(UserDetailValidators.PhoneNumberValidator))]
public string PhoneNumber { get; set; }
@@ -34,7 +36,7 @@ namespace Timeline.Models
{
Nickname = CoerceEmptyToNull(entity.Nickname),
QQ = CoerceEmptyToNull(entity.QQ),
- EMail = CoerceEmptyToNull(entity.EMail),
+ Email = CoerceEmptyToNull(entity.Email),
PhoneNumber = CoerceEmptyToNull(entity.PhoneNumber),
Description = CoerceEmptyToNull(entity.Description)
};