From e78da8ca397fbfca8d57ab518e1778dd57e0dd90 Mon Sep 17 00:00:00 2001
From: xuhy <3313886187@qq.com>
Date: 星期三, 22 一月 2025 18:42:30 +0800
Subject: [PATCH] 租户类型属性

---
 ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TTenantServiceImpl.java |   13 ++++++++++---
 1 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TTenantServiceImpl.java b/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TTenantServiceImpl.java
index 068a061..c6d65f1 100644
--- a/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TTenantServiceImpl.java
+++ b/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/TTenantServiceImpl.java
@@ -1,12 +1,15 @@
 package com.ruoyi.system.service.impl;
 
 import com.ruoyi.common.basic.PageInfo;
+import com.ruoyi.common.constant.DictConstants;
+import com.ruoyi.common.utils.DictUtils;
 import com.ruoyi.system.mapper.TTenantMapper;
 import com.ruoyi.system.model.TTenant;
 import com.ruoyi.system.query.TTenantQuery;
 import com.ruoyi.system.service.TTenantService;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.ruoyi.system.vo.SysUserVO;
+import com.ruoyi.system.vo.TenantVO;
 import org.springframework.stereotype.Service;
 
 import java.util.List;
@@ -23,9 +26,13 @@
 public class TTenantServiceImpl extends ServiceImpl<TTenantMapper, TTenant> implements TTenantService {
 
     @Override
-    public PageInfo<TTenant> pageList(TTenantQuery query) {
-        PageInfo<TTenant> pageInfo = new PageInfo<>(query.getPageNum(), query.getPageSize());
-        List<TTenant> list = this.baseMapper.pageList(query,pageInfo);
+    public PageInfo<TenantVO> pageList(TTenantQuery query) {
+        PageInfo<TenantVO> pageInfo = new PageInfo<>(query.getPageNum(), query.getPageSize());
+        List<TenantVO> list = this.baseMapper.pageList(query,pageInfo);
+        for (TenantVO tenantVO : list) {
+            tenantVO.setTenantAttributesName(DictUtils.getDictLabel(DictConstants.DICT_TYPE_TENANT_ATTRIBUTE,tenantVO.getTenantAttributes()));
+            tenantVO.setTenantTypeName(DictUtils.getDictLabel(DictConstants.DICT_TYPE_TENANT_TYPE,tenantVO.getTenantType()));
+        }
         pageInfo.setRecords(list);
         return pageInfo;
     }

--
Gitblit v1.7.1