New Timeline (#4936)
Refactored the code to introduce two different concepts: - AuditLogs (immutable, raw data) - TimelineActivities (user-friendly, transformed data) Still some work needed: - Add message, files, calendar events to timeline (~2 hours if done naively) - Refactor repository to try to abstract concept when we can (tbd, wait for Twenty ORM) - Introduce ability to display child timelines on parent timeline with filtering (~2 days) - Improve UI: add links to open note/task, improve diff display, etc (half a day) - Decide the path forward for Task vs Notes: either introduce a new field type "Record Type" and start going into that direction ; or split in two objects? - Trigger updates when a field is changed (will be solved by real-time / websockets: 2 weeks) - Integrate behavioral events (1 day for POC, 1 week for clean/documented) <img width="1248" alt="Screenshot 2024-04-12 at 09 24 49" src="https://github.com/twentyhq/twenty/assets/6399865/9428db1a-ab2b-492c-8b0b-d4d9a36e81fa">
This commit is contained in:
@ -1,14 +1,14 @@
|
||||
import { Event } from '@/activities/events/types/Event';
|
||||
import { TimelineActivity } from '@/activities/timelineActivities/types/TimelineActivity';
|
||||
|
||||
export const mockedEvents: Array<Event> = [
|
||||
export const mockedTimelineActivities: Array<TimelineActivity> = [
|
||||
{
|
||||
properties: '{"diff": {"address": {"after": "TEST", "before": ""}}}',
|
||||
updatedAt: '2023-04-26T10:12:42.33625+00:00',
|
||||
id: '79f84835-b2f9-4ab5-8ab9-17dbcc45dda3',
|
||||
personId: null,
|
||||
companyId: 'ce40eca0-8f4b-4bba-ba91-5cbd870c64d0',
|
||||
linkedObjectMetadataId: '1ad72a42-6ab4-4474-a62a-a57cae3c0298',
|
||||
linkedRecordCachedName: 'Test',
|
||||
linkedRecordId: 'ce40eca0-8f4b-4bba-ba91-5cbd870c64d0',
|
||||
name: 'updated.company',
|
||||
opportunityId: null,
|
||||
createdAt: '2023-04-26T10:12:42.33625+00:00',
|
||||
workspaceMember: {
|
||||
__typename: 'WorkspaceMember',
|
||||
@ -30,10 +30,10 @@ export const mockedEvents: Array<Event> = [
|
||||
'{"after": {"id": "ce40eca0-8f4b-4bba-ba91-5cbd870c64d0", "name": "", "xLink": {"url": "", "label": ""}, "events": {"edges": [], "__typename": "eventConnection"}, "people": {"edges": [], "__typename": "personConnection"}, "address": "", "position": 0.5, "createdAt": "2024-03-24T21:33:45.765295", "employees": null, "favorites": {"edges": [], "__typename": "favoriteConnection"}, "updatedAt": "2024-03-24T21:33:45.765295", "__typename": "company", "domainName": "", "attachments": {"edges": [], "__typename": "attachmentConnection"}, "accountOwner": null, "linkedinLink": {"url": "", "label": ""}, "opportunities": {"edges": [], "__typename": "opportunityConnection"}, "accountOwnerId": null, "activityTargets": {"edges": [], "__typename": "activityTargetConnection"}, "idealCustomerProfile": false, "annualRecurringRevenue": {"amountMicros": null, "currencyCode": ""}}}',
|
||||
updatedAt: new Date().toISOString(),
|
||||
id: '1ad72a42-6ab4-4474-a62a-a57cae3c0298',
|
||||
personId: null,
|
||||
companyId: 'ce40eca0-8f4b-4bba-ba91-5cbd870c64d0',
|
||||
name: 'created.company',
|
||||
opportunityId: null,
|
||||
linkedObjectMetadataId: '1ad72a42-6ab4-4474-a62a-a57cae3c0298',
|
||||
linkedRecordCachedName: 'Test',
|
||||
linkedRecordId: 'ce40eca0-8f4b-4bba-ba91-5cbd870c64d0',
|
||||
createdAt: new Date().toISOString(),
|
||||
workspaceMember: {
|
||||
__typename: 'WorkspaceMember',
|
||||
Reference in New Issue
Block a user