|
|
@@ -18,6 +18,7 @@ using System.Data;
|
|
|
using TencentCloud.Omics.V20221128.Models;
|
|
|
using TencentCloud.Csip.V20221121.Models;
|
|
|
using COSXML.Network;
|
|
|
+using System.Security.Policy;
|
|
|
|
|
|
|
|
|
namespace molilian.core
|
|
|
@@ -610,9 +611,12 @@ namespace molilian.core
|
|
|
}
|
|
|
if (!response.ip.Contains("127.0.0"))
|
|
|
{
|
|
|
- saveParseCache(response.channel.ToString(), response.accountId, response.accountName, response.success, response.message, response.reason);
|
|
|
+ saveParseCache(response.channel.ToString(), response.accountId,
|
|
|
+ response.accountName, response.success, response.message, response.reason,
|
|
|
+ response.deeplink_url);
|
|
|
}
|
|
|
|
|
|
+
|
|
|
if (!string.IsNullOrEmpty(response.itemId)) TkOrderTrackingCore.SaveLinkSummary(response);
|
|
|
|
|
|
if (!response.success && "nologin".Equals(response.message))
|
|
|
@@ -696,7 +700,8 @@ namespace molilian.core
|
|
|
|
|
|
if (!response.ip.Contains("127.0.0"))
|
|
|
{
|
|
|
- saveCpsCache(response.channel.ToString(), response.accountId, response.success, response.message, response.reason);
|
|
|
+ saveCpsCache(response.channel.ToString(), response.accountId,
|
|
|
+ response.success, response.message, response.reason);
|
|
|
}
|
|
|
}
|
|
|
catch (Exception ex)
|
|
|
@@ -718,7 +723,9 @@ namespace molilian.core
|
|
|
|
|
|
if (!response.ip.Contains("127.0.0"))
|
|
|
{
|
|
|
- saveParseCache(response.channel.ToString(), response.accountId, response.accountName, response.success, response.message, response.reason);
|
|
|
+ saveParseCache(response.channel.ToString(), response.accountId,
|
|
|
+ response.accountName, response.success, response.message, response.reason,
|
|
|
+ response.deeplink_url);
|
|
|
}
|
|
|
|
|
|
if (response.success || response.message.Equals("转链失败"))
|
|
|
@@ -798,7 +805,9 @@ namespace molilian.core
|
|
|
|
|
|
if (!response.ip.Contains("127.0.0"))
|
|
|
{
|
|
|
- saveParseCache(response.channel.ToString(), response.accountId, response.accountName, response.success, response.message, response.reason);
|
|
|
+ saveParseCache(response.channel.ToString(), response.accountId,
|
|
|
+ response.accountName, response.success, response.message, response.reason,
|
|
|
+ response.deeplink_url);
|
|
|
}
|
|
|
|
|
|
if (response.success || response.message.Equals("转链失败"))
|
|
|
@@ -840,7 +849,9 @@ namespace molilian.core
|
|
|
|
|
|
if (!response.ip.Contains("127.0.0"))
|
|
|
{
|
|
|
- saveParseCache(response.channel.ToString(), response.accountId, response.accountName, response.success, response.message, response.reason);
|
|
|
+ saveParseCache(response.channel.ToString(), response.accountId,
|
|
|
+ response.accountName, response.success, response.message, response.reason,
|
|
|
+ response.deeplink_url);
|
|
|
}
|
|
|
|
|
|
}
|
|
|
@@ -856,7 +867,9 @@ namespace molilian.core
|
|
|
|
|
|
if (!response.ip.Contains("127.0.0"))
|
|
|
{
|
|
|
- saveParseCache(response.channel.ToString(), 0, "tool", response.success, response.message, response.reason);
|
|
|
+ saveParseCache(response.channel.ToString(), 0, "tool",
|
|
|
+ response.success, response.message, response.reason,
|
|
|
+ response.deeplink_url);
|
|
|
}
|
|
|
}
|
|
|
catch (Exception ex) { }
|
|
|
@@ -990,8 +1003,29 @@ namespace molilian.core
|
|
|
|
|
|
|
|
|
|
|
|
- private static void saveParseCache(string channel, int accountId, string accountName, bool success, string message, string reason)
|
|
|
+ private static void saveParseCache(string channel, int accountId, string accountName,
|
|
|
+ bool success, string message, string reason, string deeplink)
|
|
|
{
|
|
|
+ string dp_flag = deeplink switch
|
|
|
+ {
|
|
|
+ "" => "none",
|
|
|
+ "tbopen://m.taobao.com/tbopen/index.html" or
|
|
|
+ "pinduoduo://com.xunmeng.pinduoduo/" or
|
|
|
+ "snssdk1128://feed?refer=web" or
|
|
|
+ "bdnetdisk://n/action.EXTERNAL_ACTIVITY" or
|
|
|
+ "openapp.jdmobile://virtual?params=" => "home",
|
|
|
+ _ => success ? "success" : "fail",
|
|
|
+ };
|
|
|
+
|
|
|
+ //关于dp的缓存
|
|
|
+ saveParseAccountCache($"dp_{dp_flag}:all", success, message, reason);
|
|
|
+ saveParseAccountCache($"dp_{dp_flag}:{channel}", success, message, reason);
|
|
|
+ saveParseAccountCache($"dp_{dp_flag}:{accountName}", success, message, reason);
|
|
|
+ if (accountId != 0)
|
|
|
+ {
|
|
|
+ saveParseAccountCache($"dp_{dp_flag}:{channel}_{accountId}", success, message, reason);
|
|
|
+ }
|
|
|
+
|
|
|
saveParseAccountCache("all", success, message, reason);
|
|
|
saveParseAccountCache($"{channel}", success, message, reason);
|
|
|
saveParseAccountCache($"{accountName}", success, message, reason);
|
|
|
@@ -1002,8 +1036,11 @@ namespace molilian.core
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- private static void saveParseAccountCache(string accountName, bool success, string message, string reason)
|
|
|
+
|
|
|
+ private static void saveParseAccountCache(string accountName, bool success,
|
|
|
+ string message, string reason)
|
|
|
{
|
|
|
+
|
|
|
RedisHelper.IncrBy($":parse_total:{accountName}:{DateTime.Now:yyyyMM}");
|
|
|
RedisHelper.IncrBy($":parse_total:{accountName}:{DateTime.Now:yyyyMMdd}");
|
|
|
RedisHelper.IncrBy($":parse_total:{accountName}:{DateTime.Now:yyyyMMddHH}");
|