-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Notes for Project-Board-Columns #29045
Open
zokkis
wants to merge
47
commits into
go-gitea:main
Choose a base branch
from
zokkis:feature/project-board-notes
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
47 commits
Select commit
Hold shift + click to select a range
cfa01d6
feat(board-notes): add, edit and delete of BoardNotes
zokkis 79f5d58
feat(board-notes): styles for card-content and modals
zokkis c668d8e
feat(board-notes): move notes like issues
zokkis 90d0b60
feat(board-notes): set boardID to 0 on when board gets deleted
zokkis a9924b6
feat(board-notes): add projectID to BoardNote
zokkis 423404c
feat(board-notes): better styles for large cards
zokkis c369889
fix: update note content on frontend and backend
zokkis 962ea45
enhance: don't reload page to remove deleted column and cards
zokkis ac79a31
fix: max-width for cards and attachments (fixes: #29029)
zokkis bff8dc6
enhance: can add notes to 'Uncategorized'-Column
zokkis 2c63ee1
enhance: don't reload page after moving note
zokkis 696a632
enhance: new sort-order -> newest BoardNote on top
zokkis a29422f
refactor: use form-fetch-action instead of own $.ajax
zokkis 0f4b806
enhance: content of BoardNotes with MD support
zokkis 12f8cda
fix: whole project-column has cursor grab
zokkis 51c8e09
enhance: smaller cards and view-modal
zokkis 4e17cf2
enhance: create issue from board-note
zokkis 0d8f8a2
i18n: translations for board-notes
zokkis 965f70d
fix: edit the column-title don't remove the count-div (fixes: #29031)
zokkis 762f2ce
fix: v1.21 to main
zokkis 76b90eb
chore: lint
zokkis 4815e7a
fix: required changes from CI and Bot
zokkis 410b286
enhance: show amount of tasks in board-notes card
zokkis 5084134
enhance: board-notes can now be pinned
zokkis abb5152
chore: rename BoardNote to ProjectBoardNote
zokkis 1c12d87
refactor: LoadAttributes function
zokkis 7b28107
fix: missed translations for form
zokkis f3ce631
fix: projectBoardNote delete
zokkis 99cf2d1
enhance: add tags to project-board-notes
zokkis 1bd15a4
fix: init markdownEditor on pinned notes
zokkis dd7cb77
enhance: select labels while creating note
zokkis 0c77014
fix: unique note_label
zokkis 313016e
style: break note card title
zokkis c87b630
fix: issue content was set with old data
zokkis be88ded
enhance: link milestone to note
zokkis 1f1c997
permissions: only admin and creator can edit notes
zokkis 67e5a86
fix: cursor-grap only on columns and cards if column-id != 0 and use …
zokkis 1c50683
fix: moving pinned cards need permissions
zokkis f1387ca
enhance: show pinned note in list
zokkis 0aa0c5c
fix: show milestone in view-modal of note
zokkis 50e8545
enhance: notes are now available in orgs
zokkis 2f4631a
enhance: milestone and label selectors with search
zokkis 6222c42
chore: add migration
zokkis 98cb5c0
i18n: translations for milestone
zokkis 0f74de6
chore: fmt and lint
zokkis afcd5d8
fix: prefill of issue form is now from pinned notes possible
zokkis 7e470d9
Merge branch 'main' into feature/project-board-notes
6543 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
// Copyright 2023 The Gitea Authors. All rights reserved. | ||
// SPDX-License-Identifier: MIT | ||
|
||
package v1_22 //nolint | ||
|
||
import ( | ||
"code.gitea.io/gitea/modules/timeutil" | ||
|
||
"xorm.io/xorm" | ||
) | ||
|
||
type BoardNote struct { | ||
ID int64 `xorm:"pk autoincr"` | ||
Title string `xorm:"TEXT NOT NULL"` | ||
Content string `xorm:"LONGTEXT"` | ||
Sorting int64 `xorm:"NOT NULL DEFAULT 0"` | ||
PinOrder int64 `xorm:"NOT NULL DEFAULT 0"` | ||
MilestoneID int64 `xorm:"INDEX"` | ||
|
||
ProjectID int64 `xorm:"INDEX NOT NULL"` | ||
BoardID int64 `xorm:"INDEX NOT NULL"` | ||
CreatorID int64 `xorm:"NOT NULL"` | ||
|
||
CreatedUnix timeutil.TimeStamp `xorm:"INDEX created"` | ||
UpdatedUnix timeutil.TimeStamp `xorm:"INDEX updated"` | ||
} | ||
|
||
// TableName xorm will read the table name from this method | ||
func (BoardNote) TableName() string { | ||
return "project_board_note" | ||
} | ||
|
||
type BoardNoteLabel struct { | ||
ID int64 `xorm:"pk autoincr"` | ||
BoardNoteID int64 `xorm:"UNIQUE(s) NOT NULL"` | ||
LabelID int64 `xorm:"UNIQUE(s) NOT NULL"` | ||
} | ||
|
||
// TableName xorm will read the table name from this method | ||
func (BoardNoteLabel) TableName() string { | ||
return "project_board_note_label" | ||
} | ||
|
||
func CreateTablesForBoardNotes(x *xorm.Engine) error { | ||
err := x.Sync(new(BoardNote)) | ||
if err != nil { | ||
return err | ||
} | ||
|
||
return x.Sync(new(BoardNoteLabel)) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since
Board
has been renamed toColumn
, this should beColumnNote
now.