Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • C chouette-core
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 36
    • Merge requests 36
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Infrastructure Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Administrator
  • chouette-core
  • Merge requests
  • !60

Merged
Created Sep 01, 2017 by Administrator@rootMaintainer

Table builder allow column links to be customised

  • Overview 2
  • Commits 10
  • Changes 20

Created by: teddywing

Removes automatic link creation in the table builder helper. Previously, name and comment columns would always be linked to the #show page of the row object.

This change now requires the link to be defined at the TableBuilderHelper::Column level using a new link_to argument.

Example:

TableBuilderHelper::Column.new(
  key: :comment,
  attribute: 'comment',
  link_to: lambda do |time_table|
    referential_time_table_path(@referential, time_table)
  end
)

This enables us to have multiple columns be links in tables, and to have those links point wherever we want, not just the #show of the row object.

Assignee
Assign to
Reviewer
Request review from
None
Milestone
None
Assign milestone
Time tracking
Source branch: table-builder--allow-column-links-to-be-customised