Commit Graph

69 Commits

Author SHA1 Message Date
Jankees van Woezik 477b4d65f2 API: Support created_at for API card and comment creation (#2056)
* Add support to set `created_at`

Discussed in
https://github.com/basecamp/fizzy/pull/1766#issuecomment-3637846074,
this allows users to import cards from another system with entries from
the past. For instance I'm importing all our Github issues (including
the closed onces) to Fizzy.

* Iron out published state tracking

---------

Co-authored-by: Jeremy Daer <jeremy@37signals.com>
2025-12-10 19:57:38 -08:00
Stanko K.R. 7b30ca203e Add index actions for Comments and Columns
Also, fix crash when a deactivated user is serialized (they don't have
an identity).
2025-12-10 09:23:52 +01:00
Stanko K.R. d16b3756de Add API for reactions 2025-12-10 09:23:52 +01:00
Stanko K.R. eeed2a8416 Add API for watching cards 2025-12-10 09:23:52 +01:00
Stanko K.R. ed1002f6c5 Add API for card triage 2025-12-10 09:23:52 +01:00
Stanko K.R. 8a84785056 Add API for tagging cards 2025-12-10 09:23:52 +01:00
Stanko K.R. c517ef6063 Add API for CRUD actions on steps 2025-12-10 09:23:52 +01:00
Stanko K.R. 8a61ca2a79 Add API for postponing cards 2025-12-10 09:23:52 +01:00
Stanko K.R. 52e65b3c08 Add API for removing card images 2025-12-10 09:23:52 +01:00
Stanko K.R. 1caeea541d Add API for gilding cards 2025-12-10 09:23:52 +01:00
Stanko K.R. 41115eaf87 Add API for comments CRUD 2025-12-10 09:23:52 +01:00
Stanko K.R. b4012dfb40 Add API for closing and opening cards 2025-12-10 09:23:52 +01:00
Stanko K.R. cf52982b8b Add API for mobing cards between boards 2025-12-10 09:23:52 +01:00
Stanko K.R. 23e6f3b095 Add API for assigning cards 2025-12-10 09:23:52 +01:00
Stanko K.R. 77f1110020 Allow only the owner of a reaction to delete it 2025-12-03 11:10:44 +01:00
Mike Dalessio 79c9ea2ce1 Remove a bunch of N+1s
related to notification and comment rendering
2025-11-27 11:08:45 -05:00
Kevin McConnell bd259f7795 Add optimistic pausing to avoid stale reads
Instead of writer pinning, we'll track the last transaction ID of each
write in the session. Then on each read we'll wait for the replica to
report that this transaction is available.

If it doesn't become available within a reasonable timeout, we'll
proceed anyway, and accept the possibility of a stale read.

The hope here is that most of the time, the replica is caught up in the
time between a write request and the following read request. If it's
not, we now have a little tolerance to wait for it, which hopefully
proves enough to stale reads are not encountered in normal use.

We also disable the writer affinity opt-out mechanism that we had
before, since we will no longer be using writer affinity at the load
balancer.
2025-11-24 13:29:52 +00:00
Kevin McConnell 59dd8ca549 Make IDs more time-sortable in tests
In order for model ordering to work as expected in tests, we need to
keep two properties:

- Fixtures are all created in the past
- Models sort in the order that they were created

This allows us to do things like this:

    post cards_path, params: { ... }
    created_card = Card.last

When using UUIDv7 PKs rather than sequential integers, we have to make
sure a couple of things happen in order for this still to be true:

- Fixtures should generate deterministic IDs that translate to UUIDs
  that would have been created in the past (i.e. before today)
- Newly created objects must have enough precision in their timestamps
  so that they sort in the order they were created, and their random
  component doesn't come into play.

To solve this, we use the deterministic numeric ID as a number of
milliseconds after an early year. And we ensure that the new timestamps
we create have sub-millisecond precision.
2025-11-17 09:12:40 -05:00
Kevin McConnell 1959e15f7e Fix more tests
These are mainly because the fixture's UUIDs are deterministic rather
than time-sortable, and more places where we need to correct the fixture
IDs as well.
2025-11-17 09:12:31 -05:00
Jorge Manrubia eea9afb639 Fix: dismiss grouped notifications by card from the notifications tray
This also splits the templates into two: index and tray, since the URL now changes.
2025-11-14 12:58:24 +01:00
Jorge Manrubia 17876b30d4 Manage comments with streams
We replacing the full list of comments within a turbo frame, which didn't feel great when you had several comments.
2025-11-13 17:12:46 +01:00
Jorge Manrubia 2dab14ef64 Replace the full container since we want to get back to the initial state
To see the boost button again
2025-11-12 18:14:31 +01:00
Jorge Manrubia 2d96e7c9c6 Use streams to update/remove reactions
Prevents race condition causing flickering https://app.fizzy.do/5986089/cards/2906

This will prevent these from udpating live, but we will tackle that as part of live card
updates with page refreshes, which I will tackle soon.
2025-11-12 18:04:20 +01:00
Jorge Manrubia 285328ec60 Smoother tag updates with streams 2025-11-12 17:29:35 +01:00
Jorge Manrubia 39ec6cf062 Replace collection with board in the code, tests green 2025-11-05 13:41:12 +01:00
Jorge Manrubia 03a345609e Baseline replacing collection with board across code 2025-11-05 13:31:54 +01:00
Jorge Manrubia 24da4066b7 Refresh the full meta area so that the assignee name gets updated too 2025-11-03 16:11:53 +01:00
Jorge Manrubia 00818697ef Use page refreshes with morphing to avoid flickering
Replacing the card container will reload the frame. Also, see
https://github.com/basecamp/fizzy/commit/5b70320a6b64adf2d1e0be4bd7dc221a5ba80c95
2025-11-03 16:11:53 +01:00
Jorge Manrubia da6d1011fd Replace card replacement with stream actions to prevent flickering when managing steps 2025-11-03 10:59:24 +01:00
Jorge Manrubia 9d4dd3b00e Remove "save as draft"
Removes the creating status completely as well as the abandoned cards system. It will
always resume drafts if they exist, for a given collection and user.

https://app.box-car.com/5986089/cards/2489
2025-11-03 09:32:29 +01:00
Jason Zimdars 1c8a9fdc67 Update tests 2025-10-23 07:54:46 -07:00
Jason Zimdars da413e7540 Remove closure reasons 2025-10-15 16:15:56 -05:00
Jorge Manrubia 38116f64e4 Higher fidelity for watching/unwatching cards 2025-10-06 10:48:31 +02:00
Jorge Manrubia 5e09944606 Separate card and collection watchers
https://fizzy.37signals.com/5986089/cards/375
2025-10-03 19:04:01 +02:00
Jorge Manrubia 23895e53aa Add tests for new controllers 2025-09-28 21:11:07 +02:00
Jorge Manrubia e14262dc01 Fix tests, remove workflow controllers 2025-09-28 18:50:26 +02:00
Jorge Manrubia d7ef9749c0 Remove old drop controller 2025-09-26 12:33:29 +02:00
Jorge Manrubia 2f6a639682 Prepare entropy code for the new auto postpone approach 2025-09-24 16:22:42 +02:00
Jorge Manrubia be246d204f Replace assignees with a turbo stream instead of replacing the full card
So that we don't lose th editing context if you do it while editing a card

https://fizzy.37signals.com/5986089/collections/2/cards/1479
2025-09-09 15:32:18 +02:00
Jason Zimdars aa13853ae4 Add a third, "On deck" column in Collections 2025-08-12 17:58:12 -05:00
Jorge Manrubia 919211244b Review the code to move cards
- Scope accessed records
- Keep consistency by moving events too
2025-07-04 19:56:48 +02:00
Jason Zimdars f02215c5b7 Add steps to cards 2025-07-01 20:05:20 -05:00
Kevin McConnell 5a9f9692f2 Track collection access when viewing cards 2025-06-24 15:48:05 -05:00
Kevin McConnell 63ddb23585 Opt out of writer affinity on readings controller 2025-06-16 15:05:47 +01:00
Jorge Manrubia 303a3faea1 Merge pull request #607 from basecamp/drag-and-drop-cards
Drag and drop cards to move between doing/considering
2025-06-13 10:04:59 +02:00
Jorge Manrubia 7a4e59391b Add test 2025-06-13 09:55:37 +02:00
Jorge Manrubia 9dc221f0b2 Add test 2025-06-13 08:58:06 +02:00
Jorge Manrubia fa04016cbe Revert "Revert "Replace House with Lexical"" 2025-05-29 14:25:16 +02:00
Jorge Manrubia 08d8b2e5ff Revert "Replace House with Lexical" 2025-05-29 14:22:27 +02:00
Jorge Manrubia 34eb8f1672 Format 2025-05-29 12:38:07 +02:00