Don't mix links and actions in an admin table

In some tables, we had "actions", and some columns were also links
pointing to some places. Having both of them at the same time is
confusing, particularly since traditionally the links in the columns
pointed to the same place as some of the actions (although that's not
the case since commit 48db31cd).

We're still keeping links in tables which don't have an action column.
For instance, the proposals table has a "select" button which would be
harder to use if we had action buttons next to it.
This commit is contained in:
Javi Martín
2020-07-06 21:59:56 +02:00
parent beaff17bec
commit 99dad7a7b6
13 changed files with 32 additions and 45 deletions

View File

@@ -25,7 +25,7 @@ describe "Admin legislation questions" do
visit admin_legislation_processes_path(filter: "all")
click_link "An example legislation process"
within("tr", text: "An example legislation process") { click_link "Edit" }
click_link "Debate"
expect(page).to have_content("Question 1")
@@ -43,9 +43,7 @@ describe "Admin legislation questions" do
click_link "All"
expect(page).to have_content "An example legislation process"
click_link "An example legislation process"
within("tr", text: "An example legislation process") { click_link "Edit" }
click_link "Debate"
click_link "Create question"
@@ -71,9 +69,8 @@ describe "Admin legislation questions" do
expect(page).not_to have_link "All"
click_link "An example legislation process"
within("tr", text: "An example legislation process") { click_link "Edit" }
click_link "Debate"
click_link "Question 2"
fill_in "Question", with: "Question 2b"