fix: tenant account issue

This commit is contained in:
2024-10-18 11:25:19 +08:00
parent 79957d4756
commit 368b09e8c8

View File

@@ -140,7 +140,7 @@ func (r *SysTenantImpl) SelectTenantById(tenantId string) model.SysTenant {
querySql := `select t.tenant_id, t.parent_id, t.ancestors,
t.tenant_name, t.order_num, t.tenancy_type, t.tenancy_key, t.status,
(select tenant_name from sys_tenant where tenant_id = t.parent_id and status = 1) parent_name
from sys_tenant t where t.tenant_id = ? and t.status = 1 `
from sys_tenant t where t.tenant_id = ? and t.del_flag = 0 `
results, err := datasource.RawDB("", querySql, []any{tenantId})
if err != nil {
logger.Errorf("query err => %v", err)