| Age | Commit message (Collapse) | Author |
|
regarding the functional scope of the current organozation
|
|
Rewrite table builder calls to work with the new
`TableBuilderHelper::Column#link_to` mechanism for defining the linked
column and what it points to. This takes the link out of the
`TableBuilderHelper`, and puts it into the hands of the view.
It gives us more flexibility with regards to what can be defined as a
link in our tables and what those links point to.
This will be used in a more meaningful way in the `imports#show` page to
list `NetexImport`s and provide links to both the referential associated
with a Netex import and the imported file status page from a table row.
|
|
|
|
|
|
|
|
Needed to add a new decorator to provide links to this table's gear
menu. The links correspond to those in the header on the
"referential_lines/show.html.slim" page.
Call `#human_attribute_name` on the model directly instead of the
collection because the decorated collection doesn't expose that method.
Refs #3479
|
|
|
|
|
|
date input elements
|
|
3479-refactor-table_builder-helper
|
|
Refs #3657
|
|
Now that we've integrated the `#action_links` from
`ReferentialDecorator`, all these `link_to`s are taken care of by our
loop just below the removed commented code.
Refs #3479
|
|
Referentials#show has a button "Purger" that isn't a link. Instead, it's
a `<button>` element that opens a modal.
Previously, we only knew how to put `Link`s in the `#action_links`, and
only these could then be rendered in the header bar as buttons.
This change allows us to accept non-Link objects. Since the button is
rather simple, I decided to create a simple `HTMLElement` class to
represent it and output it in the resulting HTML. The class uses the
`#content_tag` `ActionView` helper to render the final HTML.
Update "referentials/show.html.slim" to output the button correctly in
addition to the normal links.
Update `TableBuilderHelper#build_links` to not add anything that's not a
`Link` to the gear menu. This allows us to display the "Purger" button
on the Referentials#show page but not in the table on Workbenches#show.
Refs #3479
|
|
Now that the `Link` class no longer has a :name attribute, use the
:content attribute instead and get our delete button markup handling
from `ReferentialDecorator`.
TODO: This messes up the styles on this page as here there's a `<span>`
around the link text and in the tables there's no span.
Refs #3479
|
|
Add a new `ReferentialDecorator` that we can use to define the links
that appear as buttons in the header of the `/referentials/:id` page.
The idea is that these links will take the place of the existing view
code and in the view, we'll instead loop over the links provided by the
decorator and render them as buttons.
I decided to do it this way because there's a requirement that the links
in the gear menu in tables show the same links that appear in the header
of the page. So the Workbenches#show page would show a table of
referentials, and their gear menu links should ostensibly be the same as
the header links in the Referentials#show page.
My goal was to abstract links, and try to separate them from the
presentation layer. Still having trouble with this though. I created a
new `Link` class to represent a link. We can then use this in the
template to create a `link_to`. It becomes messy, though, when we want
to put other elements inside a certain link, as evidenced by the
`:delete` link. Don't like how that's done, but still working out the
best approach to make it cleaner.
Refs #3479
|
|
Refs #3662
|
|
Refs #3662
|
|
|
|
|
|
|
|
|
|
Refs #3122
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Refs #2866
|
|
Refs #2858
|
|
|
|
(first pass)
|
|
|
|
|
|
|
|
referentials#show
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
updates
|
|
|
|
|
|
|
|
|