Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add "lastModified" to Incident entity, add column in DataTable #1589

Merged
merged 1 commit into from
Feb 9, 2025

Conversation

srabraham
Copy link
Member

Before this change, we were figuring out last modification time on the client side. That was being calculated incorrectly, since we weren't passing system report entries into the Incidents view (exclude_system_entries = True). This moves over that computation to the server.

Also, this adds a "Modified" column to the Incidents view. I'm theorizing that people might find this useful; possibly more useful than "Created". It could especially be useful as a sort order, so that active Incidents are at the top and older ones fall to the bottom.

NOTE that if we want to remove this DataTables column in the future, we should still keep the server-side piece of this commit, and we should still use the new "last_modified" field in the API to know when an Incident was last modified.

Copy link

codecov bot commented Feb 9, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 70.11%. Comparing base (d4eb6e1) to head (7030f41).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1589      +/-   ##
==========================================
+ Coverage   70.09%   70.11%   +0.01%     
==========================================
  Files         188      188              
  Lines        9317     9331      +14     
  Branches     1509     1515       +6     
==========================================
+ Hits         6531     6542      +11     
- Misses       2673     2674       +1     
- Partials      113      115       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Before this change, we were figuring out last modification time on the
client side. That was being calculated incorrectly, since we weren't
passing system report entries into the Incidents view
(exclude_system_entries = True). This moves over that computation to
the server.

Also, this adds a "Modified" column to the Incidents view. I'm
theorizing that people might find this useful; possibly more useful
than "Created". It could especially be useful as a sort order, so that
active Incidents are at the top and older ones fall to the bottom.

NOTE that if we want to remove this DataTables column in the future,
we should still keep the server-side piece of this commit, and we should
still use the new "last_modified" field in the API to know when an
Incident was last modified.

(finally, there's one little tweak in here for document titles, making
them more concise)
@srabraham srabraham force-pushed the srabraham-2025-01-31-search-re branch from e4a01da to 7030f41 Compare February 9, 2025 21:20
@srabraham srabraham enabled auto-merge (squash) February 9, 2025 21:20
@srabraham srabraham merged commit df77088 into master Feb 9, 2025
13 checks passed
@srabraham srabraham deleted the srabraham-2025-01-31-search-re branch February 9, 2025 21:26
srabraham added a commit that referenced this pull request Feb 27, 2025
I'm not sure why I had it as optional before, but all the tests pass
now with it being required.

#1589 (comment)
srabraham added a commit that referenced this pull request Feb 27, 2025
I'm not sure why I had it as optional before, but all the tests pass
now with it being required.

#1589 (comment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants