<% sidebar_menu = { {"value" => "Monitor", "icon" => "dashboard"} => [{"value"=>"Dashboard".html_safe, "link"=>root_path, "visible" => (current_user.role.name != 'inventory')}, {"value"=>"Clients".html_safe, "link"=>clients_clients_upload_download_path, "visible" => (current_user.role.name != 'inventory')}, {"value"=>"Network devices".html_safe, "link"=>access_points_access_point_path, "visible" => true}, {"value"=>"Report".html_safe, "link"=>reports_report_path, "visible" => (can? :manage, Report) || (can? :read, Report) }, {"value"=>"Activity Log".html_safe, "link"=>activity_log_index_path, "visible" => (can? :read, PublicActivity::Activity)}, {"value"=>"Event Logging".html_safe, "link"=>event_logging_logging_index_path, "visible" => (can? :read, EventLogging)}, {"value"=>"Notifications".html_safe, "link"=>notifications_alerts_path, "visible" => (can? :read, Notification)}, {"value"=>"Tools".html_safe, "link"=>configuration_ap_diagonstic_path, "visible" => !['guest', 'inventory', "monitor_only"].include?(current_user.role.name)}], {"value" => "AIOPs", "icon" => "bar-chart-o"} => [ {"value"=>"Create Dashboard".html_safe, "link"=>monitoring_aiops_path(dashboard_name: "create"), "visible" => (current_user.role.name != 'inventory' && (current_user.email == 'ankur@wavespot.net' || ["Cox"].include?(current_user.organisation.organisation_name) || [191].include?(current_user.organisation_id)))}, {"value"=>"AP Dashboard".html_safe, "link"=>monitoring_aiops_path(dashboard_name: "ap"), "visible" => (current_user.role.name != 'inventory' && (current_user.email == 'ankur@wavespot.net' || ["Cox"].include?(current_user.organisation.organisation_name) || [191].include?(current_user.organisation_id)))}, {"value"=>"Client Dashboard".html_safe, "link"=>monitoring_aiops_path(dashboard_name: "client"), "visible" => (current_user.role.name != 'inventory' && (current_user.email == 'ankur@wavespot.net' || ["Cox"].include?(current_user.organisation.organisation_name) || [191].include?(current_user.organisation_id)))}, #{"value"=>"Meraki Dashboard".html_safe, "link"=>monitoring_aiops_path(dashboard_name: "meraki"), "visible" => (current_user.role.name != 'inventory' && (current_user.email == 'ankur@wavespot.net' || ["Cox"].include?(current_user.organisation.organisation_name) || [191].include?(current_user.organisation_id)))}, {"value"=>"Intelligence".html_safe, "link"=>monitoring_aiops_path(dashboard_name: "intelligence"), "visible" => (current_user.role.name != 'inventory' && (current_user.email == 'ankur@wavespot.net' || ["Cox"].include?(current_user.organisation.organisation_name) || [191].include?(current_user.organisation_id)))}, {"value"=>"DYOA".html_safe, "link"=>monitoring_aiops_path(dashboard_name: "DYOA"), "visible" => (current_user.role.name != 'inventory' && (current_user.email == 'ankur@wavespot.net' || ["Cox"].include?(current_user.organisation.organisation_name) || [191].include?(current_user.organisation_id)))}, ], {"value" => "Configuration", "icon" => "gears"} => [ {"value"=>"Network".html_safe, "link"=>home_index_path, "visible" => (current_user.role.name != 'inventory') && (can? :read, NetworkSsid)}, {"value"=>"Inventory".html_safe, "link"=>inventory_index_path, "visible" => ((can? :manage, RouterInventory) || !['monitor_only', 'network_monitor'].include?(current_user.role.name) if (current_user.role.name != 'inventory'))}, {"value"=>"Upgrade".html_safe, "link"=>upgrades_path, "visible" => (can? :read, Upgrade)}, {"value"=>"NTP Configuration".html_safe, "link"=>ntp_servers_path, "visible" => (can? :read, NtpServer)}, {"value"=>"Firewall Configuration".html_safe, "link"=>firewall_config_index_path, "visible" => (can? :read, FirewallConfig)}, {"value"=>"Logging".html_safe, "link"=>logging_index_path, "visible" => (can? :read, Logging)}, {"value"=>"VPN Configuration".html_safe, "link"=>vpn_config_inventory_index_path, "visible" => (can? :read, VpnConfig)}, {"value"=>"Radio Profiles".html_safe, "link"=>radio_profiles_path, "visible" => (can? :read, RadioProfile)}, {"value"=>"Alerts".html_safe, "link"=>alerts_path, "visible" => (can? :read, Alert)}, {"value"=>"Static Routes".html_safe, "link"=>static_routes_path, "visible" => (can? :read, StaticRoute)}, #{"value"=>"Switch Configuration".html_safe, "link"=>switch_configurations_path, "visible" => (can? :read, SwitchConfiguration)}, {"value"=>"Init Templates".html_safe, "link"=>init_templates_path, "visible" => (can? :read, InitTemplate)}], {"value" => "Organization", "icon" => "sitemap"} => [ {"value"=>"RADIUS Configuration".html_safe, "link"=>radius_configurations_path, "visible" => (can? :read, RadiusConfiguration)}, {"value"=>"Commands".html_safe, "link"=>commands_path, "visible" => (session[:access_command] == true || current_user.is_super_admin || "verizon@wavespot.net".eql?(current_user.email))}, {"value"=>"Port Forwarding".html_safe, "link"=>portforwarding_groups_path, "visible" => (can? :read, PortforwardingGroup)}, {"value"=>"ACL Groups".html_safe, "link"=>acl_groups_path, "visible" => (can? :read, AclGroup)}, {"value"=>"Integration Types".html_safe, "link"=>integration_types_path, "visible" => (can? :read, IntegrationType)}, {"value"=>"SNMP Configuration".html_safe, "link"=>snmp_configs_path, "visible" => (can? :read, SnmpConfig)}, {"value"=>"Smart Queues".html_safe, "link"=>sqms_path, "visible" => (can? :read, Sqm)}, {"value"=>"Notification Group".html_safe, "link"=>notification_group_alerts_path, "visible" => (can? :read, NotificationGroup)}, {"value"=>"Gateway Settings".html_safe, "link"=>organisation_index_path, "visible" => (can? :manage, Organisation)}, {"value"=>"Settings".html_safe, "link"=>settings_path, "visible" => ((can? :manage, Organisation) && (!current_user.is_super_admin))}, {"value"=>"Users".html_safe, "link"=>admin_users_path, "visible" => (can? :manage, User)}, {"value"=>"Generated Tokens List".html_safe, "link"=>assume_user_details_path, "visible" => (can? :read, AssumeUserDetail) }, {"value"=>"Assume User".html_safe, "link"=>assume_user_assume_user_details_path, "visible" => (can? :read, AssumeUserDetail) }, {"value"=>"Sim Management".html_safe, "link"=> sim_managements_path, "visible" => ((current_user.is_super_admin? || current_user.organisation.sim_managements.any?) && (can? :manage, SimManagement))}, {"value"=>"Billings".html_safe, "link"=>billings_payment_invoice_index_path, "visible" => ((current_user.is_super_admin? || current_user.organisation.sim_managements.any?) && (can? :manage, SimManagement))}, ], {"value" => "Superadmin", "icon" => "user"} => [ {"value"=>"Master Inventory".html_safe, "link"=>admin_master_inventory_index_path, "visible" => (current_user.is_super_admin)}, {"value"=>"Default WPA Password".html_safe, "link"=>default_wpa_password_admin_master_inventory_index_path, "visible" => (current_user.is_super_admin)}, {"value"=>"Upload Firmware".html_safe, "link"=>admin_upgrade_datas_path, "visible" => (current_user.is_super_admin)}, {"value"=>"Presence Dashboard".html_safe, "link"=>dashboard_visitor_details_path, "visible" => (current_user.is_super_admin)}, {"value"=>" Sim Management".html_safe, "link"=>admin_sim_managements_path, "visible" => (current_user.is_super_admin)}, {"value"=>" Non Provisioning Inventory".html_safe, "link"=>non_provisioning_index_path, "visible" => (current_user.is_super_admin)}] } %>