|
@@ -102,6 +102,18 @@ namespace Util
|
|
|
}
|
|
|
return key;
|
|
|
}
|
|
|
+ public static string getRequestParamsIndex(int projectId, string content)
|
|
|
+ {
|
|
|
+ string result = ",";
|
|
|
+ JsonData jsonData = JsonMapper.ToObject(content);
|
|
|
+ var paramService = App.GetService<IPriProjectParamService>();
|
|
|
+ var paramList = paramService.GetList(m => m.projectId == projectId && m.queryIndex == "1");
|
|
|
+ foreach(var param in paramList)
|
|
|
+ {
|
|
|
+ if(content.Contains("\"" + param.fieldEnName + "\"")) result += jsonData[param.fieldEnName].ToString() + ",";
|
|
|
+ }
|
|
|
+ return result;
|
|
|
+ }
|
|
|
|
|
|
//数据库链接
|
|
|
public static SqlSugarClient initDb(int id)
|
|
@@ -1095,7 +1107,7 @@ namespace Util
|
|
|
var recursionStartTableService = App.GetService<IPriRecursionStartTableService>();
|
|
|
var recursionStartConditionService = App.GetService<IPriRecursionStartConditionService>();
|
|
|
Function.WriteLog(batchNo + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff") + "-s1", "接收mq数据日志");
|
|
|
- addLog(projectId, sub.id, prizeInId, content, queueName); //初始化日志
|
|
|
+ addLog(projectId, sub.id, prizeInId, content, queueName, content); //初始化日志
|
|
|
Function.WriteLog(batchNo + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff") + "-s2", "接收mq数据日志");
|
|
|
string prizeObjectId = prizeObject(sub.id, sub.prizeObj, content);
|
|
|
Function.WriteLog(batchNo + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff") + "-s3", "接收mq数据日志");
|
|
@@ -2871,9 +2883,10 @@ namespace Util
|
|
|
}
|
|
|
|
|
|
//记录日志
|
|
|
- public static void addLog(int projectId, int listId, int prizeIn, string requestParam, string prizeInUrl)
|
|
|
+ public static void addLog(int projectId, int listId, int prizeIn, string requestParam, string prizeInUrl, string content = "")
|
|
|
{
|
|
|
if(!logFlag) return;
|
|
|
+
|
|
|
var logService = App.GetService<IPriLogService>();
|
|
|
logService.Add(new PriLog()
|
|
|
{
|
|
@@ -2884,6 +2897,7 @@ namespace Util
|
|
|
prizeIn = prizeIn,
|
|
|
requestParam = requestParam,
|
|
|
prizeInUrl = prizeInUrl,
|
|
|
+ stepListIndex = getRequestParamsIndex(projectId, content), //获取参数索引字段值
|
|
|
});
|
|
|
}
|
|
|
public static void setLogPrizeAmount(int listId, decimal prizeAmount)
|