fix: issue of tenant status for all features
This commit is contained in:
@@ -62,7 +62,7 @@ func (s *PerfKPIController) GoldKPI(c *gin.Context) {
|
||||
|
||||
// multi-tenancy, useName->tenantID->rmUID
|
||||
selectSQL := fmt.Sprintf(`SELECT t.tenancy_key FROM sys_tenant t WHERE t.status='1' AND t.tenancy_type='UPF' AND t.parent_id =
|
||||
(SELECT u.tenant_id FROM sys_user u WHERE u.user_name='%s')`, userName)
|
||||
(SELECT u.tenant_id FROM sys_user u WHERE u.user_name='%s' and u.status=1)`, userName)
|
||||
err := datasource.DefaultDB().Raw(selectSQL).Scan(&rmUID).Error
|
||||
if err != nil {
|
||||
c.JSON(200, result.ErrMsgFmt("DB Get error: %v", err))
|
||||
|
||||
Reference in New Issue
Block a user