diff --git a/ruoyi-common/ruoyi-common-log/src/main/java/com/ruoyi/common/log/aspect/LogAspect.java b/ruoyi-common/ruoyi-common-log/src/main/java/com/ruoyi/common/log/aspect/LogAspect.java
index 470514913..b5b9a88d0 100644
--- a/ruoyi-common/ruoyi-common-log/src/main/java/com/ruoyi/common/log/aspect/LogAspect.java
+++ b/ruoyi-common/ruoyi-common-log/src/main/java/com/ruoyi/common/log/aspect/LogAspect.java
@@ -13,6 +13,7 @@ import com.ruoyi.common.log.annotation.Log;
import com.ruoyi.common.log.enums.BusinessStatus;
import com.ruoyi.common.log.event.OperLogEvent;
import com.ruoyi.common.satoken.utils.LoginHelper;
+import com.ruoyi.system.api.model.LoginUser;
import lombok.extern.slf4j.Slf4j;
import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.annotation.AfterReturning;
@@ -75,7 +76,9 @@ public class LogAspect {
operLog.setOperIp(ip);
operLog.setOperLocation(AddressUtils.getRealAddressByIP(ip));
operLog.setOperUrl(StringUtils.substring(ServletUtils.getRequest().getRequestURI(), 0, 255));
- operLog.setOperName(LoginHelper.getUsername());
+ LoginUser loginUser = LoginHelper.getLoginUser();
+ operLog.setOperName(loginUser.getUsername());
+ operLog.setDeptName(loginUser.getDeptName());
if (e != null) {
operLog.setStatus(BusinessStatus.FAIL.ordinal());
diff --git a/ruoyi-ui-vue3/src/views/system/operlog/index.vue b/ruoyi-ui-vue3/src/views/system/operlog/index.vue
index 296aa6505..630ca9590 100644
--- a/ruoyi-ui-vue3/src/views/system/operlog/index.vue
+++ b/ruoyi-ui-vue3/src/views/system/operlog/index.vue
@@ -117,8 +117,10 @@
-
+
+
+
@@ -153,15 +155,16 @@
-
- {{ form.title }} / {{ typeFormat(form) }}
+
{{ form.operName }} / {{ form.operIp }}
+ >{{ form.operName }} / {{form.deptName}} / {{ form.operIp }} / {{ form.operLocation }}
- {{ form.operUrl }}
- {{ form.requestMethod }}
+ {{ form.requestMethod }} {{form.operUrl }}
+
+
+ {{ form.title }} / {{ typeFormat(form) }}
{{ form.method }}
diff --git a/ruoyi-ui/src/views/system/operlog/index.vue b/ruoyi-ui/src/views/system/operlog/index.vue
index fae581141..f68889c42 100644
--- a/ruoyi-ui/src/views/system/operlog/index.vue
+++ b/ruoyi-ui/src/views/system/operlog/index.vue
@@ -121,8 +121,10 @@
-
-
+
+
+
+
@@ -158,15 +160,16 @@
-
- {{ form.title }} / {{ typeFormat(form) }}
+
{{ form.operName }} / {{ form.operIp }}
+ >{{ form.operName }} / {{form.deptName}} / {{ form.operIp }} / {{ form.operLocation }}
- {{ form.operUrl }}
- {{ form.requestMethod }}
+ {{ form.requestMethod }} {{form.operUrl }}
+
+
+ {{ form.title }} / {{ typeFormat(form) }}
{{ form.method }}