Clicking a company's name on the companies page renames it instead of opening it #252

Closed
opened 2026-09-17 13:50:35 +00:00 by tiagoagueda · 0 comments
Owner

On Companies, the company's name is the obvious thing to click, and it does the one thing
nobody clicks a name for: it turns into a one-field box for renaming. Everything else about
that company — its identifiers, industries, parent, addresses, contacts, its postings — is
somewhere else, and the row does not say where.

The companies table is the only list in Postulo where a record's name does not open the
record. On Applications the title opens the application and the company beside it opens
the company (application_row.html uses get_absolute_url for both). On Companies the
name is an editable cell, and the company's own page is not linked from the row at all.

Where it is

templates/jobs/partials/company_row.html renders the name through
partials/table/cell.html with cell_url = jobs:company_cell <pk> 'name' and
form_url = jobs:company_update <pk>. The cell is an <a> whose href is the full edit
form
and whose hx-get swaps in the inline editor, so:

  • with htmx — which is everybody — clicking the name opens the rename box;
  • without it, the same click opens the full edit form, which is at least the whole
    record, and is what the table did before inline editing existed (#135).

Company.get_absolute_url() returns jobs:company_detail, and CompanyDetailView exists
and is prefetched for exactly this view. Nothing in the row links to it. The only other
links in the row are the parent-company filter and the two external addresses.

Why it is worth fixing rather than explaining

Renaming in place was a deliberate addition (#135) and is worth keeping — a typo in an
employer's name is the commonest correction there is, and a refusal has somewhere to go now.
The mistake is which gesture it took: the name is a record's front door everywhere else in
Postulo, and here it is a text box.

Proposal

The name opens the company. Renaming keeps a way in that is unmistakably a rename:

  • the name cell becomes a plain link to company_detail, like every other list;
  • inline renaming moves to an affordance of its own — a pencil beside the name, or the
    edit action already in the row's action column — keeping company_cell and everything
    #135 built;
  • or, if the row should stay editable-first, the company's page gets a link of its own in
    the row, and the name says what it does.

Worth deciding at the same time: whether company_detail or company_update is the right
destination. The detail page is the record; the edit form is the record with every field
open at once, which is what somebody who clicked a name expecting to change something may
have wanted. Applications open their detail page, so consistency argues for the detail page
with its own edit button.

A test belongs with it: the companies row links to company.get_absolute_url(), which is
the assertion that would have caught this and would catch it coming back.

On *Companies*, the company's name is the obvious thing to click, and it does the one thing nobody clicks a name for: it turns into a one-field box for renaming. Everything else about that company — its identifiers, industries, parent, addresses, contacts, its postings — is somewhere else, and the row does not say where. The companies table is the only list in Postulo where a record's name does not open the record. On *Applications* the title opens the application and the company beside it opens the company (`application_row.html` uses `get_absolute_url` for both). On *Companies* the name is an editable cell, and the company's own page is not linked from the row at all. ## Where it is `templates/jobs/partials/company_row.html` renders the name through `partials/table/cell.html` with `cell_url = jobs:company_cell <pk> 'name'` and `form_url = jobs:company_update <pk>`. The cell is an `<a>` whose `href` is the *full edit form* and whose `hx-get` swaps in the inline editor, so: - **with htmx** — which is everybody — clicking the name opens the rename box; - **without it**, the same click opens the full edit form, which is at least the whole record, and is what the table did before inline editing existed (#135). `Company.get_absolute_url()` returns `jobs:company_detail`, and `CompanyDetailView` exists and is prefetched for exactly this view. Nothing in the row links to it. The only other links in the row are the parent-company filter and the two external addresses. ## Why it is worth fixing rather than explaining Renaming in place was a deliberate addition (#135) and is worth keeping — a typo in an employer's name is the commonest correction there is, and a refusal has somewhere to go now. The mistake is which gesture it took: the name is a record's front door everywhere else in Postulo, and here it is a text box. ## Proposal The name opens the company. Renaming keeps a way in that is unmistakably a rename: - the name cell becomes a plain link to `company_detail`, like every other list; - inline renaming moves to an affordance of its own — a pencil beside the name, or the edit action already in the row's action column — keeping `company_cell` and everything #135 built; - or, if the row should stay editable-first, the company's page gets a link of its own in the row, and the name says what it does. Worth deciding at the same time: whether *company_detail* or *company_update* is the right destination. The detail page is the record; the edit form is the record with every field open at once, which is what somebody who clicked a name expecting to change something may have wanted. Applications open their detail page, so consistency argues for the detail page with its own edit button. A test belongs with it: the companies row links to `company.get_absolute_url()`, which is the assertion that would have caught this and would catch it coming back.
tiagoagueda added this to the 0.4.0 milestone 2026-09-17 13:50:35 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Postulo/postulo#252
No description provided.