@@ -307,51 +307,74 @@ type Repository struct {
307
307
308
308
// ObjectAttributes contains all of the GitLab object attributes information
309
309
type ObjectAttributes struct {
310
- ID int64 `json:"id"`
311
- Title string `json:"title"`
312
- AssigneeID int64 `json:"assignee_id"`
313
- AuthorID int64 `json:"author_id"`
314
- ProjectID int64 `json:"project_id"`
315
- CreatedAt customTime `json:"created_at"`
316
- UpdatedAt customTime `json:"updated_at"`
317
- Position int64 `json:"position"`
318
- BranchName string `json:"branch_name"`
319
- Description string `json:"description"`
320
- MilestoneID int64 `json:"milestone_id"`
321
- State string `json:"state"`
322
- IID int64 `json:"iid"`
323
- URL string `json:"url"`
324
- Action string `json:"action"`
325
- TargetBranch string `json:"target_branch"`
326
- SourceBranch string `json:"source_branch"`
327
- SourceProjectID int64 `json:"source_project_id"`
328
- TargetProjectID int64 `json:"target_project_id"`
329
- StCommits string `json:"st_commits"`
330
- MergeStatus string `json:"merge_status"`
331
- Content string `json:"content"`
332
- Format string `json:"format"`
333
- Message string `json:"message"`
334
- Slug string `json:"slug"`
335
- Ref string `json:"ref"`
336
- Tag bool `json:"tag"`
337
- SHA string `json:"sha"`
338
- BeforeSHA string `json:"before_sha"`
339
- Status string `json:"status"`
340
- Stages []string `json:"stages"`
341
- Duration int64 `json:"duration"`
342
- Note string `json:"note"`
343
- NotebookType string `json:"noteable_type"`
344
- At customTime `json:"attachment"`
345
- LineCode string `json:"line_code"`
346
- CommitID string `json:"commit_id"`
347
- NoteableID int64 `json:"noteable_id"`
348
- System bool `json:"system"`
349
- WorkInProgress bool `json:"work_in_progress"`
350
- StDiffs []StDiff `json:"st_diffs"`
351
- Source Source `json:"source"`
352
- Target Target `json:"target"`
353
- LastCommit LastCommit `json:"last_commit"`
354
- Assignee Assignee `json:"assignee"`
310
+ ID int64 `json:"id"`
311
+ Title string `json:"title"`
312
+ AssigneeID int64 `json:"assignee_id"`
313
+ AuthorID int64 `json:"author_id"`
314
+ ProjectID int64 `json:"project_id"`
315
+ CreatedAt customTime `json:"created_at"`
316
+ UpdatedAt customTime `json:"updated_at"`
317
+ ChangePosition Position `json:"change_position"`
318
+ OriginalPosition Position `json:"original_position"`
319
+ Position Position `json:"position"`
320
+ BranchName string `json:"branch_name"`
321
+ Description string `json:"description"`
322
+ MilestoneID int64 `json:"milestone_id"`
323
+ State string `json:"state"`
324
+ IID int64 `json:"iid"`
325
+ URL string `json:"url"`
326
+ Action string `json:"action"`
327
+ TargetBranch string `json:"target_branch"`
328
+ SourceBranch string `json:"source_branch"`
329
+ SourceProjectID int64 `json:"source_project_id"`
330
+ TargetProjectID int64 `json:"target_project_id"`
331
+ StCommits string `json:"st_commits"`
332
+ MergeStatus string `json:"merge_status"`
333
+ Content string `json:"content"`
334
+ Format string `json:"format"`
335
+ Message string `json:"message"`
336
+ Slug string `json:"slug"`
337
+ Ref string `json:"ref"`
338
+ Tag bool `json:"tag"`
339
+ SHA string `json:"sha"`
340
+ BeforeSHA string `json:"before_sha"`
341
+ Status string `json:"status"`
342
+ Stages []string `json:"stages"`
343
+ Duration int64 `json:"duration"`
344
+ Note string `json:"note"`
345
+ NotebookType string `json:"noteable_type"`
346
+ At customTime `json:"attachment"`
347
+ LineCode string `json:"line_code"`
348
+ CommitID string `json:"commit_id"`
349
+ NoteableID int64 `json:"noteable_id"`
350
+ System bool `json:"system"`
351
+ WorkInProgress bool `json:"work_in_progress"`
352
+ StDiffs []StDiff `json:"st_diffs"`
353
+ Source Source `json:"source"`
354
+ Target Target `json:"target"`
355
+ LastCommit LastCommit `json:"last_commit"`
356
+ Assignee Assignee `json:"assignee"`
357
+ }
358
+
359
+ // Position defines a specific location, identified by paths line numbers and
360
+ // image coordinates, within a specific diff, identified by start, head and
361
+ // base commit ids.
362
+ //
363
+ // Text position will have: new_line and old_line
364
+ // Image position will have: width, height, x, y
365
+ type Position struct {
366
+ BaseSHA string `json:"base_sha"`
367
+ StartSHA string `json:"start_sha"`
368
+ HeadSHA string `json:"head_sha"`
369
+ OldPath string `json:"old_path"`
370
+ NewPath string `json:"new_path"`
371
+ PositionType string `json:"position_type"`
372
+ OldLine int64 `json:"old_line"`
373
+ NewLine int64 `json:"new_line"`
374
+ Width int64 `json:"width"`
375
+ Height int64 `json:"height"`
376
+ X int64 `json:"x"`
377
+ Y int64 `json:"y"`
355
378
}
356
379
357
380
// MergeRequest contains all of the GitLab merge request information
0 commit comments