Module: Lesli::NavigationHelper
- Defined in:
- app/helpers/lesli/navigation_helper.rb
Instance Method Summary collapse
-
#navigation_engine_admin(title: "Administration", subtitle: "Administration area.") ⇒ Object
01.01 Admin engine.
-
#navigation_engine_audit(title: "Audit", subtitle: "Activity, logs, security and more") ⇒ Object
05.02 Audit engine.
-
#navigation_engine_babel(title: "Babel", subtitle: "Translation Management System") ⇒ Object
09.01 Babel engine.
-
#navigation_engine_bell(title: "Notifications", subtitle: "Notifications & Announcements") ⇒ Object
03.08 Bell engine.
-
#navigation_engine_books(title: "Books", subtitle: "cloud_books/books-logo.svg") ⇒ Object
04.01 Books engine.
-
#navigation_engine_calendar(title: "Calendar", subtitle: "Unified calendar app") ⇒ Object
03.01 Calendar engine.
-
#navigation_engine_contacts(title: "Contacts", subtitle: "Customer Relationship Management") ⇒ Object
02.02 Contacts engine.
-
#navigation_engine_dashboard(title: "Dashboard", subtitle: "Dashboard Manager") ⇒ Object
03.06 Dashboard engine.
-
#navigation_engine_development(title: "Dev", subtitle: "Development notes") ⇒ Object
09.06 Development engine.
-
#navigation_engine_dispatcher(title: "Dispatcher", subtitle: "cloud_dispatcher/dispatcher-logo.svg") ⇒ Object
09.02 Dispatcher engine.
-
#navigation_engine_federation(title: "Federation", subtitle: "cloud_federation/federation-logo.svg") ⇒ Object
09.03 Federation engine.
-
#navigation_engine_focus(title: "Tasks", subtitle: "Task Management") ⇒ Object
03.03 Focus engine.
-
#navigation_engine_house(title: "House", subtitle: "cloud_house/house-logo.svg") ⇒ Object
02.04 House engine.
-
#navigation_engine_kb(title: "Kb", subtitle: "cloud_kb/kb-logo.svg") ⇒ Object
07.01 Kb engine.
-
#navigation_engine_letter(title: "Letter", subtitle: "Notes & Notebooks") ⇒ Object
03.05 Letter engine.
-
#navigation_engine_mailer(title: "Mailer", subtitle: "Email automation system") ⇒ Object
02.05 Mailer engine.
-
#navigation_engine_one(title: "One", subtitle: "Cloud Enterprise Resource Management") ⇒ Object
09.04 One engine.
-
#navigation_engine_papers(title: "Papers", subtitle: "Smart Document Management") ⇒ Object
03.12 Papers engine.
-
#navigation_engine_portal(title: "Portal", subtitle: "cloud_portal/portal-logo.svg") ⇒ Object
07.03 Portal engine.
-
#navigation_engine_proposal(title: "Proposal", subtitle: "cloud_proposal/proposal-logo.svg") ⇒ Object
02.08 Proposal engine.
-
#navigation_engine_realty(title: "Realty", subtitle: "cloud_realty/realty-logo.svg") ⇒ Object
04.05 Realty engine.
-
#navigation_engine_scraper(title: "Scraper", subtitle: "Scraper") ⇒ Object
06.06 Scraper engine.
-
#navigation_engine_security(title: "Security", subtitle: "Users Authorization Management.") ⇒ Object
08.02 Security engine.
-
#navigation_engine_shared(title: "Shared", subtitle: "Shared & Open resources") ⇒ Object
07.05 Shared engine.
-
#navigation_engine_shield(title: "Shield", subtitle: "Users & Security Management") ⇒ Object
08.01 Shield engine.
-
#navigation_engine_social(title: "Social", subtitle: "Team social network") ⇒ Object
03.07 Social engine.
-
#navigation_engine_storage(title: "Storage", subtitle: "Cloud files management") ⇒ Object
03.11 Storage engine.
-
#navigation_engine_support(title: "Support", subtitle: "Support Ticket System") ⇒ Object
07.02 Help engine.
-
#navigation_engine_talk(title: "Talk", subtitle: "Real-time communication") ⇒ Object
03.10 Talk engine.
-
#navigation_engine_team(title: "Team", subtitle: "Human Resources Management") ⇒ Object
01.02 Team engine.
-
#navigation_engine_things(title: "Things", subtitle: "cloud_things/things-logo.svg") ⇒ Object
04.03 Things engine.
-
#navigation_engine_time(title: "Time managment", subtitle: "Track your time") ⇒ Object
03.09 Time engine.
-
#navigation_item(path, label, icon = nil, reload: false) ⇒ Object
Prints a html link inside a list item.
- #navigation_link(path, label, icon = nil, reload: false) ⇒ Object
- #navigation_partial ⇒ Object
-
#navigation_separator ⇒ Object
Prints a separator line.
Instance Method Details
#navigation_engine_admin(title: "Administration", subtitle: "Administration area.") ⇒ Object
01.01 Admin engine
74 75 76 77 |
# File 'app/helpers/lesli/navigation_helper.rb', line 74 def (title: "Administration", subtitle: "Administration area.") return unless defined? LesliAdmin (title,subtitle,"admin",lesli_admin.root_path,controller_path.include?("lesli_admin")) end |
#navigation_engine_audit(title: "Audit", subtitle: "Activity, logs, security and more") ⇒ Object
05.02 Audit engine
202 203 204 205 |
# File 'app/helpers/lesli/navigation_helper.rb', line 202 def (title: "Audit", subtitle: "Activity, logs, security and more") return unless defined? LesliAudit (title, subtitle, "audit", lesli_audit.root_path, controller_path.include?("lesli_audit")) end |
#navigation_engine_babel(title: "Babel", subtitle: "Translation Management System") ⇒ Object
09.01 Babel engine
267 268 269 270 271 272 |
# File 'app/helpers/lesli/navigation_helper.rb', line 267 def (title: "Babel", subtitle: "Translation Management System") return unless defined? LesliBabel (title, subtitle, "babel", lesli_babel.root_path, controller_path.include?("lesli_babel")) end |
#navigation_engine_bell(title: "Notifications", subtitle: "Notifications & Announcements") ⇒ Object
03.08 Bell engine
144 145 146 147 |
# File 'app/helpers/lesli/navigation_helper.rb', line 144 def (title: "Notifications", subtitle: "Notifications & Announcements") return unless defined? LesliBell (title, subtitle, "bell", lesli_bell.root_path, controller_path.include?("lesli_bell")) end |
#navigation_engine_books(title: "Books", subtitle: "cloud_books/books-logo.svg") ⇒ Object
04.01 Books engine
176 177 178 179 180 181 |
# File 'app/helpers/lesli/navigation_helper.rb', line 176 def (title: "Books", subtitle: "cloud_books/books-logo.svg") return unless defined? CloudBooks (title, subtitle, "books", cloud_books.root_path, controller_path.include?("cloud_books")) end |
#navigation_engine_calendar(title: "Calendar", subtitle: "Unified calendar app") ⇒ Object
03.01 Calendar engine
114 115 116 117 |
# File 'app/helpers/lesli/navigation_helper.rb', line 114 def (title: "Calendar", subtitle: "Unified calendar app") return unless defined? LesliCalendar (title, subtitle, "calendar", lesli_calendar.root_path, controller_path.include?("lesli_calendar")) end |
#navigation_engine_contacts(title: "Contacts", subtitle: "Customer Relationship Management") ⇒ Object
02.02 Contacts engine
88 89 90 91 |
# File 'app/helpers/lesli/navigation_helper.rb', line 88 def (title: "Contacts", subtitle: "Customer Relationship Management") return unless defined? LesliContacts (title,subtitle,"contacts",lesli_contacts.root_path,controller_path.include?("lesli_contacts")) end |
#navigation_engine_dashboard(title: "Dashboard", subtitle: "Dashboard Manager") ⇒ Object
03.06 Dashboard engine
132 133 134 135 |
# File 'app/helpers/lesli/navigation_helper.rb', line 132 def (title: "Dashboard", subtitle: "Dashboard Manager") return unless defined? LesliDashboard (title,subtitle,"dashboard",lesli_dashboard.root_path,controller_path.include?("lesli_dashboard")) end |
#navigation_engine_development(title: "Dev", subtitle: "Development notes") ⇒ Object
09.06 Development engine
299 300 301 302 303 304 |
# File 'app/helpers/lesli/navigation_helper.rb', line 299 def (title: "Dev", subtitle: "Development notes") return unless defined? CloudDevelopment (title, subtitle, "development", cloud_development.root_path, controller_path.include?("cloud_development")) end |
#navigation_engine_dispatcher(title: "Dispatcher", subtitle: "cloud_dispatcher/dispatcher-logo.svg") ⇒ Object
09.02 Dispatcher engine
275 276 277 278 279 280 |
# File 'app/helpers/lesli/navigation_helper.rb', line 275 def (title: "Dispatcher", subtitle: "cloud_dispatcher/dispatcher-logo.svg") return unless defined? CloudDispatcher (title, subtitle, "api", cloud_dispatcher.root_path, controller_path.include?("cloud_dispatcher")) end |
#navigation_engine_federation(title: "Federation", subtitle: "cloud_federation/federation-logo.svg") ⇒ Object
09.03 Federation engine
283 284 285 286 287 288 |
# File 'app/helpers/lesli/navigation_helper.rb', line 283 def (title: "Federation", subtitle: "cloud_federation/federation-logo.svg") return unless defined? CloudFederation (title, subtitle, "federation", cloud_federation.root_path, controller_path.include?("cloud_federation")) end |
#navigation_engine_focus(title: "Tasks", subtitle: "Task Management") ⇒ Object
03.03 Focus engine
120 121 122 123 |
# File 'app/helpers/lesli/navigation_helper.rb', line 120 def (title: "Tasks", subtitle: "Task Management") return unless defined? CloudFocus (title,subtitle,"focus",cloud_focus.root_path,controller_path.include?("cloud_focus")) end |
#navigation_engine_house(title: "House", subtitle: "cloud_house/house-logo.svg") ⇒ Object
02.04 House engine
94 95 96 97 |
# File 'app/helpers/lesli/navigation_helper.rb', line 94 def (title: "House", subtitle: "cloud_house/house-logo.svg") return unless defined? CloudHouse (title,subtitle,"house",cloud_house.root_path,controller_path.include?("cloud_house")) end |
#navigation_engine_kb(title: "Kb", subtitle: "cloud_kb/kb-logo.svg") ⇒ Object
07.01 Kb engine
221 222 223 224 225 |
# File 'app/helpers/lesli/navigation_helper.rb', line 221 def (title: "Kb", subtitle: "cloud_kb/kb-logo.svg") return unless defined? CloudKb (title, subtitle, "kb", cloud_kb.root_path, controller_path.include?("cloud_kb")) end |
#navigation_engine_letter(title: "Letter", subtitle: "Notes & Notebooks") ⇒ Object
03.05 Letter engine
126 127 128 129 |
# File 'app/helpers/lesli/navigation_helper.rb', line 126 def (title: "Letter", subtitle: "Notes & Notebooks") return unless defined? LesliLetter (title,subtitle,"letter",lesli_letter.root_path,controller_path.include?("lesli_letter")) end |
#navigation_engine_mailer(title: "Mailer", subtitle: "Email automation system") ⇒ Object
02.05 Mailer engine
100 101 102 103 |
# File 'app/helpers/lesli/navigation_helper.rb', line 100 def (title: "Mailer", subtitle: "Email automation system") return unless defined? LesliMailer (title,subtitle,"mailer", lesli_mailer.root_path,controller_path.include?("lesli_mailer")) end |
#navigation_engine_one(title: "One", subtitle: "Cloud Enterprise Resource Management") ⇒ Object
09.04 One engine
291 292 293 294 295 296 |
# File 'app/helpers/lesli/navigation_helper.rb', line 291 def (title: "One", subtitle: "Cloud Enterprise Resource Management") return unless defined? CloudOne (title, subtitle, "one", cloud_one.root_path, controller_path.include?("cloud_one")) end |
#navigation_engine_papers(title: "Papers", subtitle: "Smart Document Management") ⇒ Object
03.12 Papers engine
168 169 170 171 |
# File 'app/helpers/lesli/navigation_helper.rb', line 168 def (title: "Papers", subtitle: "Smart Document Management") return unless defined? LesliPapers (title,subtitle,"papers",lesli_papers.root_path,controller_path.include?("lesli_papers")) end |
#navigation_engine_portal(title: "Portal", subtitle: "cloud_portal/portal-logo.svg") ⇒ Object
07.03 Portal engine
234 235 236 237 238 239 |
# File 'app/helpers/lesli/navigation_helper.rb', line 234 def (title: "Portal", subtitle: "cloud_portal/portal-logo.svg") return unless defined? CloudPortal (title, subtitle, "portal", cloud_portal.root_path, controller_path.include?("cloud_portal")) end |
#navigation_engine_proposal(title: "Proposal", subtitle: "cloud_proposal/proposal-logo.svg") ⇒ Object
02.08 Proposal engine
106 107 108 109 |
# File 'app/helpers/lesli/navigation_helper.rb', line 106 def (title: "Proposal", subtitle: "cloud_proposal/proposal-logo.svg") return unless defined? CloudProposal (title,subtitle,"proposal",cloud_proposal.root_path,controller_path.include?("cloud_proposal")) end |
#navigation_engine_realty(title: "Realty", subtitle: "cloud_realty/realty-logo.svg") ⇒ Object
04.05 Realty engine
192 193 194 195 196 197 |
# File 'app/helpers/lesli/navigation_helper.rb', line 192 def (title: "Realty", subtitle: "cloud_realty/realty-logo.svg") return unless defined? CloudRealty (title, subtitle, "realty", cloud_realty.root_path, controller_path.include?("cloud_realty")) end |
#navigation_engine_scraper(title: "Scraper", subtitle: "Scraper") ⇒ Object
06.06 Scraper engine
211 212 213 214 215 216 |
# File 'app/helpers/lesli/navigation_helper.rb', line 211 def (title: "Scraper", subtitle: "Scraper") return unless defined? CloudScraper (title, subtitle, "scraper", cloud_scraper.root_path, controller_path.include?("cloud_scraper")) end |
#navigation_engine_security(title: "Security", subtitle: "Users Authorization Management.") ⇒ Object
08.02 Security engine
258 259 260 261 |
# File 'app/helpers/lesli/navigation_helper.rb', line 258 def (title: "Security", subtitle: "Users Authorization Management.") return unless defined? LesliSecurity (title, subtitle, "security", lesli_security.root_path, controller_path.include?("lesli_security")) end |
#navigation_engine_shared(title: "Shared", subtitle: "Shared & Open resources") ⇒ Object
07.05 Shared engine
242 243 244 245 246 247 |
# File 'app/helpers/lesli/navigation_helper.rb', line 242 def (title: "Shared", subtitle: "Shared & Open resources") return unless defined? CloudShared (title, subtitle, "shared", cloud_shared.root_path, controller_path.include?("cloud_shared")) end |
#navigation_engine_shield(title: "Shield", subtitle: "Users & Security Management") ⇒ Object
08.01 Shield engine
252 253 254 255 |
# File 'app/helpers/lesli/navigation_helper.rb', line 252 def (title: "Shield", subtitle: "Users & Security Management") return unless defined? LesliShield (title, subtitle, "shield", lesli_shield.root_path, controller_path.include?("lesli_shield")) end |
#navigation_engine_social(title: "Social", subtitle: "Team social network") ⇒ Object
03.07 Social engine
138 139 140 141 |
# File 'app/helpers/lesli/navigation_helper.rb', line 138 def (title: "Social", subtitle: "Team social network") return unless defined? CloudSocial (title,subtitle,"social",.root_path,controller_path.include?("cloud_social")) end |
#navigation_engine_storage(title: "Storage", subtitle: "Cloud files management") ⇒ Object
03.11 Storage engine
162 163 164 165 |
# File 'app/helpers/lesli/navigation_helper.rb', line 162 def (title: "Storage", subtitle: "Cloud files management") return unless defined? CloudStorage (title,subtitle,"storage",cloud_storage.root_path,controller_path.include?("cloud_storage")) end |
#navigation_engine_support(title: "Support", subtitle: "Support Ticket System") ⇒ Object
07.02 Help engine
228 229 230 231 |
# File 'app/helpers/lesli/navigation_helper.rb', line 228 def (title: "Support", subtitle: "Support Ticket System") return unless defined? LesliSupport (title, subtitle, "support", lesli_support.root_path, controller_path.include?("lesli_support")) end |
#navigation_engine_talk(title: "Talk", subtitle: "Real-time communication") ⇒ Object
03.10 Talk engine
156 157 158 159 |
# File 'app/helpers/lesli/navigation_helper.rb', line 156 def (title: "Talk", subtitle: "Real-time communication") return unless defined? CloudTalk (title,subtitle,"talk",cloud_talk.root_path,controller_path.include?("cloud_talk")) end |
#navigation_engine_team(title: "Team", subtitle: "Human Resources Management") ⇒ Object
01.02 Team engine
80 81 82 83 |
# File 'app/helpers/lesli/navigation_helper.rb', line 80 def (title: "Team", subtitle: "Human Resources Management") return unless defined? CloudTeam (title,subtitle,"team",cloud_team.root_path,controller_path.include?("cloud_team")) end |
#navigation_engine_things(title: "Things", subtitle: "cloud_things/things-logo.svg") ⇒ Object
04.03 Things engine
184 185 186 187 188 189 |
# File 'app/helpers/lesli/navigation_helper.rb', line 184 def (title: "Things", subtitle: "cloud_things/things-logo.svg") return unless defined? CloudThings (title, subtitle, "things", cloud_things.root_path, controller_path.include?("cloud_things")) end |
#navigation_engine_time(title: "Time managment", subtitle: "Track your time") ⇒ Object
03.09 Time engine
150 151 152 153 |
# File 'app/helpers/lesli/navigation_helper.rb', line 150 def (title: "Time managment", subtitle: "Track your time") return unless defined? CloudTime (title,subtitle,"time",cloud_time.root_path,controller_path.include?("cloud_time")) end |
#navigation_item(path, label, icon = nil, reload: false) ⇒ Object
Prints a html link inside a list item
50 51 52 53 54 |
# File 'app/helpers/lesli/navigation_helper.rb', line 50 def (path, label, icon = nil, reload: false) content_tag(:li, { class: "navbar-item"}) do (path, label, icon, reload:reload) end end |
#navigation_link(path, label, icon = nil, reload: false) ⇒ Object
56 57 58 59 60 61 62 63 64 65 66 67 68 69 |
# File 'app/helpers/lesli/navigation_helper.rb', line 56 def (path, label, icon = nil, reload: false) #content_tag(html_element, html_options) do link_to path, data: { turbo_frame: '_top' } do # print a simple menu item (without icon) concat content_tag(:span, label, class: "text iconless") unless icon # print a full menu item if icon was requested if icon concat content_tag(:span, nil, class: icon) concat content_tag(:span, label, class: "text") end end end |
#navigation_partial ⇒ Object
36 37 38 39 40 |
# File 'app/helpers/lesli/navigation_helper.rb', line 36 def engine = lesli_engine[:code] path = engine == "root" ? "partials/navigation" : "#{engine}/partials/navigation" lookup_context.exists?(path, [], true) ? path : nil end |
#navigation_separator ⇒ Object
Prints a separator line
43 44 45 46 47 |
# File 'app/helpers/lesli/navigation_helper.rb', line 43 def content_tag(:li) do content_tag(:hr) end end |