diff --git a/contract/battery.go b/contract/battery.go index 653f6dd..9a3017b 100644 --- a/contract/battery.go +++ b/contract/battery.go @@ -170,8 +170,6 @@ func Cases() []Case { Notes: "All seeded tickets, last activity DESC; empty next_cursor, has_more false."}, {Name: "tickets/list_repeated_status_filter", Method: "GET", Path: "/api/v1/tickets?status_id=1&status_id=5", Auth: AuthReadTickets, Notes: "Repeated query params build a repeated field: tickets 43 and 42 only."}, - {Name: "tickets/list_state_filter", Method: "GET", Path: "/api/v1/tickets?ticket_state=resolved", Auth: AuthReadTickets, - Notes: "String filter: resolved only."}, {Name: "tickets/list_category_includes_subcategories", Method: "GET", Path: "/api/v1/tickets?category_id=1", Auth: AuthReadTickets, Notes: "Category filter expands the subtree by default: parent 1 pulls in child category 5."}, {Name: "tickets/list_category_exclude_subcategories", Method: "GET", Path: "/api/v1/tickets?category_id=1&exclude_subcategories=true", Auth: AuthReadTickets, diff --git a/contract/fake_datastore_test.go b/contract/fake_datastore_test.go index 80a6d92..2780f8d 100644 --- a/contract/fake_datastore_test.go +++ b/contract/fake_datastore_test.go @@ -405,7 +405,6 @@ func seedTickets() []*types.Ticket { CategoryId: 5, CategoryTitle: "S1 Personnel", CategoryAncestorIds: []uint32{1}, - TicketState: "open", StatusId: 2, StatusName: "In Progress", PriorityId: 2, @@ -439,7 +438,6 @@ func seedTickets() []*types.Ticket { CategoryId: 7, CategoryTitle: "S6 Technical Support", CategoryAncestorIds: []uint32{}, - TicketState: "resolved", StatusId: 5, StatusName: "Resolved", PriorityId: 1, @@ -465,7 +463,6 @@ func seedTickets() []*types.Ticket { CategoryId: 1, CategoryTitle: "Recruiting", CategoryAncestorIds: []uint32{}, - TicketState: "open", StatusId: 1, StatusName: "New", PriorityId: 3, @@ -632,9 +629,6 @@ func matchTicket(t *types.Ticket, f *datastores.ListTicketsFilter) bool { return false } } - if len(f.TicketStates) > 0 && !containsStr(f.TicketStates, t.TicketState) { - return false - } if len(f.StatusIDs) > 0 && !containsU32(f.StatusIDs, t.StatusId) { return false } @@ -662,15 +656,6 @@ func containsU32(haystack []uint32, needle uint32) bool { return false } -func containsStr(haystack []string, needle string) bool { - for _, v := range haystack { - if v == needle { - return true - } - } - return false -} - func (recordingDatastore) GetTicket(_ context.Context, _ datastores.TicketReferenceCache, ticketID uint32, _ string) (*types.Ticket, error) { for _, t := range seedTickets() { if t.TicketId == ticketID { diff --git a/contract/goldens/tickets/get_by_id_happy.golden.json b/contract/goldens/tickets/get_by_id_happy.golden.json index 178712e..b30a6ae 100644 --- a/contract/goldens/tickets/get_by_id_happy.golden.json +++ b/contract/goldens/tickets/get_by_id_happy.golden.json @@ -76,7 +76,6 @@ "ticketId": 42, "ticketLocked": false, "ticketRef": "MF1UI9HE", - "ticketState": "open", "title": "Enlistment — John.Doe", "totalMessageCount": 3 }, diff --git a/contract/goldens/tickets/get_by_ref_happy.golden.json b/contract/goldens/tickets/get_by_ref_happy.golden.json index 154b3a7..dbaba38 100644 --- a/contract/goldens/tickets/get_by_ref_happy.golden.json +++ b/contract/goldens/tickets/get_by_ref_happy.golden.json @@ -76,7 +76,6 @@ "ticketId": 42, "ticketLocked": false, "ticketRef": "MF1UI9HE", - "ticketState": "open", "title": "Enlistment — John.Doe", "totalMessageCount": 3 }, diff --git a/contract/goldens/tickets/list_category_exclude_subcategories.golden.json b/contract/goldens/tickets/list_category_exclude_subcategories.golden.json index 7d730d7..02a5410 100644 --- a/contract/goldens/tickets/list_category_exclude_subcategories.golden.json +++ b/contract/goldens/tickets/list_category_exclude_subcategories.golden.json @@ -38,7 +38,6 @@ "ticketId": 42, "ticketLocked": false, "ticketRef": "MF1UI9HE", - "ticketState": "open", "title": "Enlistment — John.Doe", "totalMessageCount": 3 } diff --git a/contract/goldens/tickets/list_category_includes_subcategories.golden.json b/contract/goldens/tickets/list_category_includes_subcategories.golden.json index 8e21138..8fd7339 100644 --- a/contract/goldens/tickets/list_category_includes_subcategories.golden.json +++ b/contract/goldens/tickets/list_category_includes_subcategories.golden.json @@ -45,7 +45,6 @@ "ticketId": 44, "ticketLocked": false, "ticketRef": "ZZTOP44Q", - "ticketState": "open", "title": "Transfer request: Bravo to Alpha", "totalMessageCount": 2 }, @@ -83,7 +82,6 @@ "ticketId": 42, "ticketLocked": false, "ticketRef": "MF1UI9HE", - "ticketState": "open", "title": "Enlistment — John.Doe", "totalMessageCount": 3 } diff --git a/contract/goldens/tickets/list_default.golden.json b/contract/goldens/tickets/list_default.golden.json index 0f5b5df..d7ca43c 100644 --- a/contract/goldens/tickets/list_default.golden.json +++ b/contract/goldens/tickets/list_default.golden.json @@ -45,7 +45,6 @@ "ticketId": 44, "ticketLocked": false, "ticketRef": "ZZTOP44Q", - "ticketState": "open", "title": "Transfer request: Bravo to Alpha", "totalMessageCount": 2 }, @@ -76,7 +75,6 @@ "ticketId": 43, "ticketLocked": false, "ticketRef": "QQWW43RR", - "ticketState": "resolved", "title": "TeamSpeak issues & errors", "totalMessageCount": 1 }, @@ -114,7 +112,6 @@ "ticketId": 42, "ticketLocked": false, "ticketRef": "MF1UI9HE", - "ticketState": "open", "title": "Enlistment — John.Doe", "totalMessageCount": 3 } diff --git a/contract/goldens/tickets/list_page_two.golden.json b/contract/goldens/tickets/list_page_two.golden.json index a9acf41..3454e7c 100644 --- a/contract/goldens/tickets/list_page_two.golden.json +++ b/contract/goldens/tickets/list_page_two.golden.json @@ -31,7 +31,6 @@ "ticketId": 43, "ticketLocked": false, "ticketRef": "QQWW43RR", - "ticketState": "resolved", "title": "TeamSpeak issues & errors", "totalMessageCount": 1 } diff --git a/contract/goldens/tickets/list_per_page_camel.golden.json b/contract/goldens/tickets/list_per_page_camel.golden.json index ff8c798..ac4b46c 100644 --- a/contract/goldens/tickets/list_per_page_camel.golden.json +++ b/contract/goldens/tickets/list_per_page_camel.golden.json @@ -45,7 +45,6 @@ "ticketId": 44, "ticketLocked": false, "ticketRef": "ZZTOP44Q", - "ticketState": "open", "title": "Transfer request: Bravo to Alpha", "totalMessageCount": 2 } diff --git a/contract/goldens/tickets/list_per_page_snake.golden.json b/contract/goldens/tickets/list_per_page_snake.golden.json index d60e5cd..f20aae4 100644 --- a/contract/goldens/tickets/list_per_page_snake.golden.json +++ b/contract/goldens/tickets/list_per_page_snake.golden.json @@ -45,7 +45,6 @@ "ticketId": 44, "ticketLocked": false, "ticketRef": "ZZTOP44Q", - "ticketState": "open", "title": "Transfer request: Bravo to Alpha", "totalMessageCount": 2 } diff --git a/contract/goldens/tickets/list_repeated_status_filter.golden.json b/contract/goldens/tickets/list_repeated_status_filter.golden.json index e699554..37e84d5 100644 --- a/contract/goldens/tickets/list_repeated_status_filter.golden.json +++ b/contract/goldens/tickets/list_repeated_status_filter.golden.json @@ -31,7 +31,6 @@ "ticketId": 43, "ticketLocked": false, "ticketRef": "QQWW43RR", - "ticketState": "resolved", "title": "TeamSpeak issues & errors", "totalMessageCount": 1 }, @@ -69,7 +68,6 @@ "ticketId": 42, "ticketLocked": false, "ticketRef": "MF1UI9HE", - "ticketState": "open", "title": "Enlistment — John.Doe", "totalMessageCount": 3 } diff --git a/contract/goldens/tickets/list_starter_filter.golden.json b/contract/goldens/tickets/list_starter_filter.golden.json index 7e58d72..7d0e221 100644 --- a/contract/goldens/tickets/list_starter_filter.golden.json +++ b/contract/goldens/tickets/list_starter_filter.golden.json @@ -45,7 +45,6 @@ "ticketId": 44, "ticketLocked": false, "ticketRef": "ZZTOP44Q", - "ticketState": "open", "title": "Transfer request: Bravo to Alpha", "totalMessageCount": 2 }, @@ -83,7 +82,6 @@ "ticketId": 42, "ticketLocked": false, "ticketRef": "MF1UI9HE", - "ticketState": "open", "title": "Enlistment — John.Doe", "totalMessageCount": 3 } diff --git a/contract/goldens/tickets/list_state_filter.golden.json b/contract/goldens/tickets/list_state_filter.golden.json deleted file mode 100644 index bdb8d1c..0000000 --- a/contract/goldens/tickets/list_state_filter.golden.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "auth": "read:tickets", - "body": { - "hasMore": false, - "nextCursor": "", - "tickets": [ - { - "assignedUserId": 0, - "assignedUsername": "", - "categoryAncestorIds": [], - "categoryId": 7, - "categoryTitle": "S6 Technical Support", - "customFields": {}, - "discussionState": "visible", - "forumUrl": "https://7cav.us/tickets/43/", - "lastMessageDate": 1748590000, - "lastMessageUserId": 3, - "lastMessageUsername": "Jarvis.A", - "lastModifiedDate": 1748600000, - "participants": [], - "prefixId": 0, - "prefixName": "", - "priorityId": 1, - "priorityName": "Low", - "replyCount": 0, - "startDate": 1748500000, - "starterUserId": 3, - "starterUsername": "Jarvis.A", - "statusId": 5, - "statusName": "Resolved", - "ticketId": 43, - "ticketLocked": false, - "ticketRef": "QQWW43RR", - "ticketState": "resolved", - "title": "TeamSpeak issues & errors", - "totalMessageCount": 1 - } - ] - }, - "case": "tickets/list_state_filter", - "header": { - "Content-Type": "application/json" - }, - "method": "GET", - "notes": "String filter: resolved only.", - "path": "/api/v1/tickets?ticket_state=resolved", - "status": 200 -} diff --git a/contract/goldens/tickets/list_unknown_param_ignored.golden.json b/contract/goldens/tickets/list_unknown_param_ignored.golden.json index bbef927..e5f38bf 100644 --- a/contract/goldens/tickets/list_unknown_param_ignored.golden.json +++ b/contract/goldens/tickets/list_unknown_param_ignored.golden.json @@ -45,7 +45,6 @@ "ticketId": 44, "ticketLocked": false, "ticketRef": "ZZTOP44Q", - "ticketState": "open", "title": "Transfer request: Bravo to Alpha", "totalMessageCount": 2 }, @@ -76,7 +75,6 @@ "ticketId": 43, "ticketLocked": false, "ticketRef": "QQWW43RR", - "ticketState": "resolved", "title": "TeamSpeak issues & errors", "totalMessageCount": 1 }, @@ -114,7 +112,6 @@ "ticketId": 42, "ticketLocked": false, "ticketRef": "MF1UI9HE", - "ticketState": "open", "title": "Enlistment — John.Doe", "totalMessageCount": 3 } diff --git a/datastores/tickets.go b/datastores/tickets.go index 5c90f8f..32da89d 100644 --- a/datastores/tickets.go +++ b/datastores/tickets.go @@ -20,7 +20,6 @@ import ( type ListTicketsFilter struct { CategoryIDs []uint32 ExcludeSubcategories bool - TicketStates []string StatusIDs []uint32 PrefixIDs []uint32 AssignedUserIDs []uint32 @@ -154,9 +153,6 @@ func (ds *Mysql) ListTickets(ctx context.Context, rc TicketReferenceCache, f *Li } q = q.Where("ticket_category_id IN ?", ids) } - if len(f.TicketStates) > 0 { - q = q.Where("ticket_state IN ?", f.TicketStates) - } if len(f.StatusIDs) > 0 { q = q.Where("status_id IN ?", f.StatusIDs) } @@ -276,7 +272,6 @@ func generateTicketProto(t *xenforo.Ticket, rc TicketReferenceCache, forumBase s Title: t.Title, CategoryId: t.TicketCategoryID, CategoryAncestorIds: ancestors, - TicketState: t.TicketState, StatusId: t.StatusID, StatusName: rc.StatusName(t.StatusID), PriorityId: t.Priority, diff --git a/datastores/tickets_harness_test.go b/datastores/tickets_harness_test.go index 483a316..7dcf14e 100644 --- a/datastores/tickets_harness_test.go +++ b/datastores/tickets_harness_test.go @@ -80,8 +80,8 @@ func TestListTickets_HydratesTicketShape(t *testing.T) { if len(got.CategoryAncestorIds) != 0 { t.Errorf("root category has no ancestors, got %v", got.CategoryAncestorIds) } - if got.TicketState != "open" || got.DiscussionState != "visible" || got.TicketLocked { - t.Errorf("state = %q/%q locked=%v", got.TicketState, got.DiscussionState, got.TicketLocked) + if got.DiscussionState != "visible" || got.TicketLocked { + t.Errorf("state = %q locked=%v", got.DiscussionState, got.TicketLocked) } if got.StarterUserId != 400 || got.StarterUsername != "TicketGuy.G" { t.Errorf("starter = %d %q", got.StarterUserId, got.StarterUsername) @@ -188,7 +188,6 @@ func TestListTickets_Filters(t *testing.T) { }{ {"status ids", datastores.ListTicketsFilter{StatusIDs: []uint32{3}}, []uint32{4, 7}}, {"repeated status ids", datastores.ListTicketsFilter{StatusIDs: []uint32{2, 3}}, []uint32{2, 4, 7, 6}}, - {"ticket states", datastores.ListTicketsFilter{TicketStates: []string{"resolved"}}, []uint32{4, 7}}, {"prefix ids", datastores.ListTicketsFilter{PrefixIDs: []uint32{1}}, []uint32{2, 7}}, {"assigned user", datastores.ListTicketsFilter{AssignedUserIDs: []uint32{401}}, []uint32{9, 1, 2, 4, 7, 6}}, {"starter user", datastores.ListTicketsFilter{StarterUserIDs: []uint32{400}}, []uint32{1}}, diff --git a/openapi/openapi.yaml b/openapi/openapi.yaml index 229450a..55190ff 100644 --- a/openapi/openapi.yaml +++ b/openapi/openapi.yaml @@ -678,13 +678,6 @@ paths: required: false schema: type: boolean - - name: ticketState - in: query - required: false - schema: - type: array - items: - type: string - name: statusId in: query required: false @@ -1721,8 +1714,6 @@ components: items: type: integer minimum: 0 - ticketState: - type: string statusId: type: integer minimum: 0 @@ -1807,7 +1798,6 @@ components: - categoryId - categoryTitle - categoryAncestorIds - - ticketState - statusId - statusName - priorityId diff --git a/rest/fake_tickets_test.go b/rest/fake_tickets_test.go index ba5bfa1..8bc7391 100644 --- a/rest/fake_tickets_test.go +++ b/rest/fake_tickets_test.go @@ -33,7 +33,6 @@ func seedTickets() []*types.Ticket { CategoryId: 5, CategoryTitle: "S1 Personnel", CategoryAncestorIds: []uint32{1}, - TicketState: "open", StatusId: 2, StatusName: "In Progress", PriorityId: 2, @@ -67,7 +66,6 @@ func seedTickets() []*types.Ticket { CategoryId: 7, CategoryTitle: "S6 Technical Support", CategoryAncestorIds: []uint32{}, - TicketState: "resolved", StatusId: 5, StatusName: "Resolved", PriorityId: 1, @@ -93,7 +91,6 @@ func seedTickets() []*types.Ticket { CategoryId: 1, CategoryTitle: "Recruiting", CategoryAncestorIds: []uint32{}, - TicketState: "open", StatusId: 1, StatusName: "New", PriorityId: 3, @@ -264,9 +261,6 @@ func matchTicket(t *types.Ticket, f *datastores.ListTicketsFilter) bool { return false } } - if len(f.TicketStates) > 0 && !containsStr(f.TicketStates, t.TicketState) { - return false - } if len(f.StatusIDs) > 0 && !containsU32(f.StatusIDs, t.StatusId) { return false } @@ -294,15 +288,6 @@ func containsU32(haystack []uint32, needle uint32) bool { return false } -func containsStr(haystack []string, needle string) bool { - for _, v := range haystack { - if v == needle { - return true - } - } - return false -} - func (f *fakeDatastore) GetTicket(_ context.Context, rc datastores.TicketReferenceCache, ticketID uint32, _ string) (*types.Ticket, error) { f.lastRC = rc if f.getTicket != nil { diff --git a/rest/query.go b/rest/query.go index 46098c4..2d6661e 100644 --- a/rest/query.go +++ b/rest/query.go @@ -117,8 +117,7 @@ func (b *queryBinder) bracketGroups(snake string) [][]string { // the cross-group order here is the deterministic ruling. nil when absent. // Always a fresh slice once anything joins the snake values: appending onto // b.values[snake] directly would write into the url.Values backing array -// when it has spare capacity (and stringSliceField hands the result to -// callers). +// when it has spare capacity. func (b *queryBinder) raw(snake string) []string { vals := b.values[snake] var camelVals []string @@ -191,10 +190,6 @@ func (b *queryBinder) stringField(snake string) string { return vals[len(vals)-1] // camel wins (ruling, see package comment) } -func (b *queryBinder) stringSliceField(snake string) []string { - return b.raw(snake) -} - func (b *queryBinder) uint32Field(snake string) uint32 { var out uint32 for _, raw := range b.scalar(snake) { diff --git a/rest/query_fuzz_test.go b/rest/query_fuzz_test.go index 0393ba0..a1dee94 100644 --- a/rest/query_fuzz_test.go +++ b/rest/query_fuzz_test.go @@ -32,8 +32,7 @@ func FuzzQueryBinder(f *testing.F) { "status_id[0]=5", // bracket fold "status_id[x]=5", // non-numeric bracket content "per_page=1&per_page=2&per_page=3", // pathological repetition - "ticket_state=open&ticket_state=closed", - "a[b][c]=1", // greedy bracket fold to unknown base + "a[b][c]=1", // greedy bracket fold to unknown base } { f.Add(seed) } @@ -45,7 +44,7 @@ func FuzzQueryBinder(f *testing.F) { } b := newQueryBinder(values) - // Bind a spread that hits scalar/slice × uint32/bool/string and a + // Bind a spread that hits scalar uint32/bool/string, a uint32 slice and a // multi-word name (camel-fold path). After each read, the first error // must never change once set. var firstErr error @@ -67,9 +66,7 @@ func FuzzQueryBinder(f *testing.F) { check() b.boolField("include_hidden") check() - b.stringField("ticket_state") - check() - b.stringSliceField("ticket_state") + b.stringField("after_cursor") check() }) } diff --git a/rest/query_test.go b/rest/query_test.go index c937399..f9fc964 100644 --- a/rest/query_test.go +++ b/rest/query_test.go @@ -35,7 +35,6 @@ func TestQueryBinder_AbsentKeysBindZeroValues(t *testing.T) { assert.Equal(t, "", b.stringField("after_cursor")) assert.False(t, b.boolField("include_hidden")) assert.Empty(t, b.uint32SliceField("status_id")) - assert.Empty(t, b.stringSliceField("ticket_state")) assert.NoError(t, b.Err()) } @@ -153,5 +152,4 @@ func TestSnakeToCamel(t *testing.T) { assert.Equal(t, "afterCursor", snakeToCamel("after_cursor")) assert.Equal(t, "excludeSubcategories", snakeToCamel("exclude_subcategories")) assert.Equal(t, "starterUserId", snakeToCamel("starter_user_id")) - assert.Equal(t, "ticketState", snakeToCamel("ticket_state")) } diff --git a/rest/rest_test.go b/rest/rest_test.go index c59b028..8cac8ed 100644 --- a/rest/rest_test.go +++ b/rest/rest_test.go @@ -298,7 +298,6 @@ var implementedCases = []string{ "tickets/statuses", "tickets/list_default", "tickets/list_repeated_status_filter", - "tickets/list_state_filter", "tickets/list_category_includes_subcategories", "tickets/list_category_exclude_subcategories", "tickets/list_starter_filter", diff --git a/rest/tickets.go b/rest/tickets.go index f713ede..f7bd856 100644 --- a/rest/tickets.go +++ b/rest/tickets.go @@ -31,7 +31,6 @@ func listTickets(ds datastores.Datastore, rc datastores.TicketReferenceCache) ht filter := &datastores.ListTicketsFilter{ CategoryIDs: b.uint32SliceField("category_id"), ExcludeSubcategories: b.boolField("exclude_subcategories"), - TicketStates: b.stringSliceField("ticket_state"), StatusIDs: b.uint32SliceField("status_id"), PrefixIDs: b.uint32SliceField("prefix_id"), AssignedUserIDs: b.uint32SliceField("assigned_user_id"), diff --git a/rest/tickets_test.go b/rest/tickets_test.go index 9ecf50a..d8dee75 100644 --- a/rest/tickets_test.go +++ b/rest/tickets_test.go @@ -372,7 +372,6 @@ func TestNewStack_ListTicketsBindsEveryFilterField(t *testing.T) { query := strings.Join([]string{ "category_id=1", "categoryId=9", // repeated, both spellings (snake first) "exclude_subcategories=true", - "ticket_state=open", "ticketState=closed", "status_id=2", "statusId=6", "prefix_id=3", "assignedUserId=4", @@ -389,7 +388,6 @@ func TestNewStack_ListTicketsBindsEveryFilterField(t *testing.T) { assert.Equal(t, &datastores.ListTicketsFilter{ CategoryIDs: []uint32{1, 9}, ExcludeSubcategories: true, - TicketStates: []string{"open", "closed"}, StatusIDs: []uint32{2, 6}, PrefixIDs: []uint32{3}, AssignedUserIDs: []uint32{4}, diff --git a/testdb/testdb_test.go b/testdb/testdb_test.go index 273806a..29303f1 100644 --- a/testdb/testdb_test.go +++ b/testdb/testdb_test.go @@ -288,15 +288,14 @@ func TestFixtures_AwolContrastHoldsRelativeToNow(t *testing.T) { // Ticket fixtures must span categories, statuses and states so the // tickets datastore tests (#120) can exercise every filter knob: // multiple categories (with a parent/child pair for subtree expansion), -// multiple status_ids, all three ticket_states, and at least one -// non-visible ticket for the include_hidden switch. +// multiple status_ids, and at least one non-visible ticket for the +// include_hidden switch. func TestFixtures_TicketsSpanCategoriesAndStatuses(t *testing.T) { db, _ := testdb.Open(t) counts := map[string]string{ "distinct ticket categories": `SELECT COUNT(DISTINCT ticket_category_id) FROM xf_nf_tickets_ticket`, "distinct status ids": `SELECT COUNT(DISTINCT status_id) FROM xf_nf_tickets_ticket`, - "distinct ticket states": `SELECT COUNT(DISTINCT ticket_state) FROM xf_nf_tickets_ticket`, "child categories (depth > 0)": `SELECT COUNT(*) FROM xf_nf_tickets_category WHERE parent_category_id > 0`, } for label, q := range counts { diff --git a/types/tickets.go b/types/tickets.go index 387462a..4e297b6 100644 --- a/types/tickets.go +++ b/types/tickets.go @@ -5,8 +5,9 @@ package types // this surface are 32-bit and stay JSON numbers; the emit-everything and // allocation disciplines from the package doc apply throughout (empty // collections are []/{} on the wire, never null). State strings -// (ticketState, discussionState, messageState) are raw XenForo states frozen -// as-is — deliberately NOT lifted into RosterType-style enums. +// (discussionState, messageState) are raw XenForo states frozen as-is — +// deliberately NOT lifted into RosterType-style enums. The ticket_state +// column is not exposed: NF Tickets leaves it 'open' on every ticket. // Ticket is one forum ticket thread: identity, category, workflow state, // people, activity timestamps, custom fields. forumUrl is populated when the @@ -19,7 +20,6 @@ type Ticket struct { CategoryId uint32 `json:"categoryId"` CategoryTitle string `json:"categoryTitle"` CategoryAncestorIds []uint32 `json:"categoryAncestorIds"` - TicketState string `json:"ticketState"` StatusId uint32 `json:"statusId"` StatusName string `json:"statusName"` PriorityId uint32 `json:"priorityId"` diff --git a/xenforo/tickets.go b/xenforo/tickets.go index 387e6d2..735ed2a 100644 --- a/xenforo/tickets.go +++ b/xenforo/tickets.go @@ -13,7 +13,6 @@ type Ticket struct { FirstMessageDate uint32 `gorm:"column:first_message_date"` Priority uint32 `gorm:"column:priority"` StatusID uint32 `gorm:"column:status_id"` - TicketState string `gorm:"column:ticket_state"` TicketLocked uint32 `gorm:"column:ticket_locked"` DiscussionState string `gorm:"column:discussion_state"` AssignedUserID uint32 `gorm:"column:assigned_user_id"`