|
@@ -43,7 +43,7 @@ namespace DataTransfer.tongji
|
|
|
retainedlist.Add(5);
|
|
|
retainedlist.Add(6);
|
|
|
retainedlist.Add(7);
|
|
|
- retainedlist.Add(14);
|
|
|
+ //retainedlist.Add(14);
|
|
|
//retainedlist.Add(30);
|
|
|
|
|
|
HashEntry[] zoneidList = mem.HashGetAll(MemKey_Statistics.Zonelist());
|
|
@@ -59,13 +59,7 @@ namespace DataTransfer.tongji
|
|
|
foreach (int type in retainedlist)
|
|
|
{
|
|
|
Console.WriteLine("type............" + type);
|
|
|
- if (mem.KeyExists(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day)))
|
|
|
- {
|
|
|
- //loseUserDataTransfer.excelText(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), type, zoneid,day);
|
|
|
-
|
|
|
- continue;
|
|
|
- }
|
|
|
-
|
|
|
+
|
|
|
List<string> loseUIdList = loseUserListCollect(type,zoneid,day);
|
|
|
if (loseUIdList.Count <= 0)
|
|
|
{
|
|
@@ -133,9 +127,9 @@ namespace DataTransfer.tongji
|
|
|
JObject baseInfoDic = JObject.Parse(baseInfo);
|
|
|
int level = int.Parse(baseInfoDic["level"].ToString());
|
|
|
string k = "level-" + level;
|
|
|
- if (mem.HashExists(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), k))
|
|
|
+ if (mem.HashExists(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day-type), k))
|
|
|
{
|
|
|
- mem.HashIncrement(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), k, 1);
|
|
|
+ mem.HashIncrement(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type), k, 1);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
@@ -143,7 +137,7 @@ namespace DataTransfer.tongji
|
|
|
HashEntry d = new HashEntry(k, 1);
|
|
|
list.Add(d);
|
|
|
|
|
|
- mem.HashSet(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), list.ToArray());
|
|
|
+ mem.HashSet(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type), list.ToArray());
|
|
|
}
|
|
|
#endregion
|
|
|
|
|
@@ -168,9 +162,9 @@ namespace DataTransfer.tongji
|
|
|
JObject dict = JObject.Parse(taskcardsDic[taskId].ToString());
|
|
|
string typeId = dict["typeId"].ToString();
|
|
|
string taskKey = "task-" + typeId;
|
|
|
- if (mem.HashExists(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), taskKey))
|
|
|
+ if (mem.HashExists(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type), taskKey))
|
|
|
{
|
|
|
- mem.HashIncrement(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), taskKey, 1);
|
|
|
+ mem.HashIncrement(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type), taskKey, 1);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
@@ -178,7 +172,7 @@ namespace DataTransfer.tongji
|
|
|
HashEntry d = new HashEntry(taskKey, 1);
|
|
|
list.Add(d);
|
|
|
|
|
|
- mem.HashSet(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), list.ToArray());
|
|
|
+ mem.HashSet(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type), list.ToArray());
|
|
|
}
|
|
|
}
|
|
|
#endregion
|
|
@@ -196,9 +190,9 @@ namespace DataTransfer.tongji
|
|
|
}
|
|
|
|
|
|
string gateKey = "gateId-" + gateId;
|
|
|
- if (mem.HashExists(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), gateKey))
|
|
|
+ if (mem.HashExists(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type), gateKey))
|
|
|
{
|
|
|
- mem.HashIncrement(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), gateKey, 1);
|
|
|
+ mem.HashIncrement(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type), gateKey, 1);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
@@ -206,12 +200,12 @@ namespace DataTransfer.tongji
|
|
|
HashEntry d = new HashEntry(gateKey, 1);
|
|
|
list.Add(d);
|
|
|
|
|
|
- mem.HashSet(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day), list.ToArray());
|
|
|
+ mem.HashSet(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type), list.ToArray());
|
|
|
}
|
|
|
#endregion
|
|
|
}
|
|
|
|
|
|
- loseUserDataTransfer.excelText(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day),type,zoneid,day);
|
|
|
+ loseUserDataTransfer.excelText(MemKey_Statistics.LoseUserKeyCount(type, zoneid, day - type),type,zoneid,day - type);
|
|
|
|
|
|
}
|
|
|
|