Description of problem: In Rails console, after setting user object to admin, the value of the current_tenant name is different when you run user.current_tenant and user.current_tenant.name. This only affects the top level tenant...subtenants report fine with both current_tenant and current_tenant.name Version-Release number of selected component (if applicable): 5.5.2.4 How reproducible: 100% Steps to Reproduce: 1. In rails console... 2. user = $evm.vmdb(:user).first 3. user.current_tenant 4. user.current_tenant.name Actual results: user.current_tenant shows "My Company" for the name Expected results: user.current_tenant should show actual name of the tenant for the name Additional info: In this test environment, RedHat is the top level tenant. irb(main):070:0> user = $evm.vmdb(:user).first User Inst Including Associations (0.3ms - 1rows) => #<MiqAeServiceUser:0x133e48c @object=#<User id: 199000000000001, name: "Administrator", email: "t", icon: nil, created_on: "2016-02-23 23:46:31", updated_on: "2016-02-29 18:04:19", userid: "admin", settings: {}, filters: nil, lastlogon: "2016-02-29 18:04:19", lastlogoff: nil, region: 199, current_group_id: 199000000000002, first_name: nil, last_name: nil, password_digest: "$2a$10$JZqrr1QI824cfiZIJDvsOOJEeuxBKN8Ip/N/4Z8Z8Op...">, @virtual_columns=["allocated_memory", "allocated_storage", "allocated_vcpu", "custom_1", "custom_2", "custom_3", "custom_4", "custom_5", "custom_6", "custom_7", "custom_8", "custom_9", "ldap_group", "miq_group_description", "miq_user_role_name", "provisioned_storage", "region_description", "region_number"], @associations=["current_group", "current_tenant", "miq_requests", "vms"]> irb(main):085:0* user.current_tenant MiqGroup Inst Including Associations (3.7ms - 1rows) Tenant Inst Including Associations (3.1ms - 1rows) => #<MiqAeServiceTenant:0x12f70dc @object=#<Tenant id: 199000000000001, domain: nil, subdomain: nil, name: "My Company", login_text: nil, logo_file_name: nil, logo_content_type: nil, logo_file_size: nil, logo_updated_at: nil, login_logo_file_name: nil, login_logo_content_type: nil, login_logo_file_size: nil, login_logo_updated_at: nil, ancestry: nil, divisible: true, description: "Tenant for My Company", use_config_for_attributes: true, default_miq_group_id: 199000000000001>, @virtual_columns=["allocated_memory", "allocated_storage", "allocated_vcpu", "display_type", "parent_name", "provisioned_storage", "region_description", "region_number"], @associations=["ae_domains", "ext_management_systems", "miq_groups", "miq_request_tasks", "miq_requests", "miq_templates", "providers", "service_templates", "services", "tenant_quotas", "users", "vm_or_templates", "vms"]> irb(main):090:0* user.current_tenant.name MiqServer Inst Including Associations (5.3ms - 1rows) Configuration Inst Including Associations (0.2ms - 1rows) => "RedHat"
This bug has been open for more than a year and is assigned to an older release of CloudForms. If you would like to keep this Bugzilla open and if the issue is still present in the latest version of the product, please file a new Bugzilla which will be added and assigned to the latest release of CloudForms.