초기커밋
This commit is contained in:
113
ServerCommon/z.Backup/ClaimRewardEntity.cs
Normal file
113
ServerCommon/z.Backup/ClaimRewardEntity.cs
Normal file
@@ -0,0 +1,113 @@
|
||||
//using Google.Protobuf.WellKnownTypes;
|
||||
//using Newtonsoft.Json;
|
||||
//using ServerCore; using ServerBase;
|
||||
//using Amazon.DynamoDBv2.DocumentModel;
|
||||
|
||||
|
||||
//namespace ServerCommon
|
||||
//{
|
||||
|
||||
|
||||
// public class DBClaimInfo
|
||||
// {
|
||||
// public int ClaimId { get; set; } = 0;
|
||||
// public int ActiveRewardIdx { get; set; } = 0;
|
||||
// public Timestamp ActiveTime { get; set; } = new();
|
||||
// public Timestamp CreateTime { get; set; } = new();
|
||||
// public Timestamp CompleteTime { get; set; } = new();
|
||||
// public int IsComplete { get; set; } = 0;
|
||||
// }
|
||||
|
||||
|
||||
// public class ClaimAttr
|
||||
// {
|
||||
// public Dictionary<int, DBClaimInfo> Infos;
|
||||
|
||||
// public ClaimAttr()
|
||||
// {
|
||||
// Infos = new();
|
||||
// }
|
||||
// }
|
||||
|
||||
// public class ClaimNormalEntity
|
||||
// {
|
||||
// public string PK_Guid { get; private set; } = string.Empty;
|
||||
// public string SK_Empty { get; private set; } = string.Empty;
|
||||
|
||||
// public ClaimAttr Attr { get; set; } = new();
|
||||
|
||||
// public ClaimNormalEntity() { }
|
||||
|
||||
// public ClaimNormalEntity(Document document)
|
||||
// {
|
||||
// ReadFrom(document);
|
||||
// }
|
||||
|
||||
// public bool ReadFrom(Document document)
|
||||
// {
|
||||
//// PK_Guid = document["PK"].AsString().Replace(MainDB.GetPKPrefix(EEntityType.ClaimRewardNormal), "");
|
||||
//// SK_Empty = document["SK"].AsString().Replace(MainDB.GetSKPrefix(EEntityType.ClaimRewardNormal), "");
|
||||
////
|
||||
//// ClaimAttr? attr = JsonConvert.DeserializeObject<ClaimAttr>(document["Attr"].AsString());
|
||||
//// if (attr == null)
|
||||
//// {
|
||||
//// Log.getLogger().error($"{PK_Guid} Attr DeserializeObject error");
|
||||
//// return false;
|
||||
//// }
|
||||
////
|
||||
//// Attr = attr;
|
||||
// return true;
|
||||
// }
|
||||
|
||||
// public Document DocumentForUpdate()
|
||||
// {
|
||||
// var document = new Document();
|
||||
//// document["PK"] = MainDB.MakePK(EEntityType.ClaimRewardNormal, PK_Guid);
|
||||
//// document["SK"] = MainDB.MakeSK(EEntityType.ClaimRewardNormal, SK_Empty);
|
||||
//// document["Attr"] = JsonConvert.SerializeObject(Attr);
|
||||
// return document;
|
||||
// }
|
||||
|
||||
// }
|
||||
|
||||
|
||||
// public class ClaimMembershipEntity
|
||||
// {
|
||||
// public string PK_Guid { get; private set; } = string.Empty;
|
||||
// public string SK_Empty { get; private set; } = string.Empty;
|
||||
|
||||
// public ClaimAttr Attr { get; set; } = new();
|
||||
|
||||
// public ClaimMembershipEntity() { }
|
||||
|
||||
// public ClaimMembershipEntity(Document document)
|
||||
// {
|
||||
// ReadFrom(document);
|
||||
// }
|
||||
|
||||
// public bool ReadFrom(Document document)
|
||||
// {
|
||||
//// PK_Guid = document["PK"].AsString().Replace(MainDB.GetPKPrefix(EEntityType.ClaimRewardMembership), "");
|
||||
//// SK_Empty = document["SK"].AsString().Replace(MainDB.GetSKPrefix(EEntityType.ClaimRewardMembership), "");
|
||||
////
|
||||
//// ClaimAttr? attr = JsonConvert.DeserializeObject<ClaimAttr>(document["Attr"].AsString());
|
||||
//// if (attr == null)
|
||||
//// {
|
||||
//// Log.getLogger().error($"{PK_Guid} Attr DeserializeObject error");
|
||||
//// return false;
|
||||
//// }
|
||||
////
|
||||
//// Attr = attr;
|
||||
// return true;
|
||||
// }
|
||||
|
||||
// public Document DocumentForUpdate()
|
||||
// {
|
||||
// var document = new Document();
|
||||
//// document["PK"] = MainDB.MakePK(EEntityType.ClaimRewardMembership, PK_Guid);
|
||||
//// document["SK"] = MainDB.MakeSK(EEntityType.ClaimRewardMembership, SK_Empty);
|
||||
//// document["Attr"] = JsonConvert.SerializeObject(Attr);
|
||||
// return document;
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
Reference in New Issue
Block a user