diff options
author | chai <chaifix@163.com> | 2021-01-25 14:28:30 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2021-01-25 14:28:30 +0800 |
commit | 6eb915c129fc90c6f4c82ae097dd6ffad5239efc (patch) | |
tree | 7dd2be50edf41f36b60fac84696e731c13afe617 /Client/Assets/Scripts/XMainClient/PartnerLivenessRecord.cs |
+scripts
Diffstat (limited to 'Client/Assets/Scripts/XMainClient/PartnerLivenessRecord.cs')
-rw-r--r-- | Client/Assets/Scripts/XMainClient/PartnerLivenessRecord.cs | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/Client/Assets/Scripts/XMainClient/PartnerLivenessRecord.cs b/Client/Assets/Scripts/XMainClient/PartnerLivenessRecord.cs new file mode 100644 index 00000000..f28d0129 --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/PartnerLivenessRecord.cs @@ -0,0 +1,74 @@ +using System;
+using KKSG;
+using XMainClient.UI;
+using XUtliPoolLib;
+
+namespace XMainClient
+{
+ public class PartnerLivenessRecord : LoopItemData
+ {
+ public string ShowString
+ {
+ get
+ {
+ return this.m_showString;
+ }
+ }
+
+ public string ShowTimeStr
+ {
+ get
+ {
+ return this.m_showTimeStr;
+ }
+ }
+
+ public string Name
+ {
+ get
+ {
+ return this.m_name;
+ }
+ }
+
+ public uint Time
+ {
+ get
+ {
+ return this.m_time;
+ }
+ }
+
+ private string m_showString = "";
+
+ private string m_showTimeStr = "";
+
+ private string m_name;
+
+ private uint m_time;
+
+ public PartnerLivenessRecord(PartnerLivenessItem item)
+ {
+ this.SetString(item);
+ this.m_time = item.time;
+ this.m_name = item.name;
+ this.m_showTimeStr = XSingleton<UiUtility>.singleton.TimeAgoFormatString((int)item.time);
+ }
+
+ private void SetString(PartnerLivenessItem item)
+ {
+ XDailyActivitiesDocument specificDocument = XDocuments.GetSpecificDocument<XDailyActivitiesDocument>(XDailyActivitiesDocument.uuID);
+ ActivityTable.RowData activityBasicInfo = specificDocument.GetActivityBasicInfo(item.actid);
+ bool flag = activityBasicInfo == null;
+ if (flag)
+ {
+ this.m_showString = null;
+ XSingleton<XDebug>.singleton.AddErrorLog(string.Format("id is error,{0}", item.actid), null, null, null, null, null);
+ }
+ else
+ {
+ this.m_showString = string.Format(XSingleton<XStringTable>.singleton.GetString("PartnerLivenessRecord"), item.name, activityBasicInfo.name, activityBasicInfo.value);
+ }
+ }
+ }
+}
|