diff --git a/src/modules/system/repository/sys_tenant.impl.go b/src/modules/system/repository/sys_tenant.impl.go index 60f144a3..f7bf8b01 100644 --- a/src/modules/system/repository/sys_tenant.impl.go +++ b/src/modules/system/repository/sys_tenant.impl.go @@ -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)