操作日志记录时指定默认租户.

pull/10/head
chen.ma 3 years ago
parent 3ad6b6d65d
commit deaeb00f74

@ -148,8 +148,9 @@ public class LogRecordAspect {
Map<String, String> expressionValues = logRecordValueParser.processTemplate(spElTemplates, ret, targetClass, method, args, errorMsg, functionNameAndReturnMap);
if (logConditionPassed(operation.getCondition(), expressionValues)) {
String tenant = environment.getProperty("tenant");
LogRecordInfo logRecordInfo = LogRecordInfo.builder()
.tenant(environment.getProperty("tenant"))
.tenant(StringUtils.isEmpty(tenant) ? "hippo4j" : tenant)
.bizKey(expressionValues.get(operation.getBizKey()))
.bizNo(expressionValues.get(operation.getBizNo()))
.operator(getRealOperatorId(operation, operatorIdFromService, expressionValues))

Loading…
Cancel
Save