Commit Graph

2018 Commits

Author SHA1 Message Date
27c488e3a3 Merge branch 'master' into feat/approval 2018-05-23 20:33:04 +02:00
4ec8551490 fix webhook bug of response info is not displayed in UI (#4000) 2018-05-23 14:12:02 +08:00
e60b3f6e09 Merge branch 'master' into feat/approval
# Conflicts:
#	vendor/vendor.json
2018-05-22 17:53:02 +02:00
d94472e89b fix #4003 (#4004)
Webhook and hook_task not cleaned up when delete repository
2018-05-21 21:30:30 +08:00
a550052b96 Merge branch 'master' into feat/approval 2018-05-21 11:15:51 +02:00
6bdc556b7f Fix some webhooks bugs (#3981)
* fix some webhooks bugs

* update vendor

Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>

* fix test

* fix clearlabels

* fix pullrequest webhook bug fix #3492

* update release webhook description

* remove unused code

* fix push webhook in pull request

* small changes
2018-05-21 10:28:29 +08:00
a8dc699e74 Merge branch 'master' into feat/approval-new
# Conflicts:
#	models/error.go
#	models/migrations/migrations.go
#	models/models.go
#	public/js/index.js
2018-05-19 18:17:01 +02:00
e5bde1405f Resolve conflicts
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-19 18:15:09 +02:00
951309f76a Add support for FIDO U2F (#3971)
* Add support for U2F

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add vendor library
Add missing translations

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Minor improvements

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add U2F support for Firefox, Chrome (Android) by introducing a custom JS library
Add U2F error handling

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add U2F login page to OAuth

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Move U2F user settings to a separate file

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add unit tests for u2f model
Renamed u2f table name

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fix problems caused by refactoring

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add U2F documentation

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Remove not needed console.log-s

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add default values to app.ini.sample
Add FIDO U2F to comparison

Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-19 17:12:37 +03:00
6e55557228 Add support for new webhooks
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-17 14:04:43 +02:00
0f64dad74b Merge branch 'master' into feat/approval-new 2018-05-17 14:00:21 +02:00
24941a1046 Add more webhooks support and refactor webhook templates directory (#3929)
* add more webhook support

* move hooks templates to standalone dir and add more webhooks ui

* fix tests

* update vendor checksum

* add more webhook support

* move hooks templates to standalone dir and add more webhooks ui

* fix tests

* update vendor checksum

* update vendor

Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>

* load attributes when created release

* update comparsion doc
2018-05-16 22:01:55 +08:00
8bb51135b6 Add support for "Show/Hide outdated"
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-15 16:34:19 +02:00
4ea74e5327 Add support for showing code comments of reviews in conversation
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-15 12:52:28 +02:00
6ae32b27e3 Fix problems caused by files in subdirectories
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-14 19:04:45 +02:00
de7081c2ab Comments will be shown at the right place now
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-14 14:05:38 +02:00
ed695c1bf9 Fix unit tests by updating fixtures and updating outdated test
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-14 10:55:50 +02:00
5f55edea84 gofmt
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-13 22:43:02 +02:00
7723e15e64 Moved review migration from v64 to v65
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-13 22:15:16 +02:00
6d00c1a7ce Merge branch 'master' into feat/approval-new
# Conflicts:
#	models/issue_comment.go
#	models/migrations/migrations.go
#	models/migrations/v64.go
#	models/models.go
#	public/css/index.css
2018-05-13 22:14:34 +02:00
7986d6ed22 Add support for invalidating comments
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-13 13:24:19 +02:00
066086c390 Improved comment rendering in "Files" view by adding Comments to DiffLine
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-12 19:09:42 +02:00
58fb672d0d gofmt
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-12 10:53:38 +02:00
bc9359222a Fetch all review ids at once
Add unit tests

Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-11 20:28:44 +02:00
9c6bb4b1e9 Add unit tests for Review
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-11 14:36:08 +02:00
3e5f3c349e Implement Review form
Show Review comments on comment stream

Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-11 12:50:44 +02:00
75b7d9b86a Preview for listing comments
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-11 10:59:20 +02:00
ff3971b830 Add LDAP integration tests (#3897)
* Add LDAP service for tests

* Add LDAP login source and test user sign-in

* Add checks to test if user data is correct

* Add LDAP user sync test

* Add failed user sign-in test
2018-05-11 15:55:32 +08:00
17af2d17be Add GetCurrentReview to simplify fetching current review
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-10 21:50:57 +02:00
4ad563d66f Moved "Pending" to first position
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-10 21:43:07 +02:00
0f772d1bf4 Simplified create and find functions for review
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-10 20:41:31 +02:00
9544c46052 Add create review comment implementation
Add migration for review
Other small changes

Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-10 16:35:25 +02:00
2c18552576 Add load functions
Add ReviewID to findComments

Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-10 14:48:08 +02:00
382e7276b8 Fix multiple asssingee table migration (#3931) 2018-05-10 09:18:01 +08:00
95f2e2b57b Multiple assignees (#3705) 2018-05-09 19:29:04 +03:00
73370b8cf7 consistent IsOverdue field name capitalization (#3909)
Milestone.IsOverDue vs Issue.IsOverdue, the former was also causing the
milestone list page template to fail to render if any milestones have a
due date assigned.

Signed-off-by: Travis J Parker <travis.parker@gmail.com>
2018-05-07 12:50:27 +03:00
aeb057755a Replace ReviewComment with Content
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-06 23:32:24 +02:00
623a9f6e3c Add Review
Add IssueComment types

Signed-off-by: Jonas Franz <info@jonasfranz.software>

(cherry picked from commit 2b4daab)
Signed-off-by: Jonas Franz <info@jonasfranz.software>
2018-05-06 23:06:11 +02:00
1fdf560678 Added user language setting (#3875)
* Added user language setting

* Added translation string for setting

* Fixed import order + typo

* improved checking if the user has a language saved in the db

* The current saved language is now set a default inside the dropdown

* fmt

* When a user signs in and doesn't have a language saved, the current browser language is saved

* updated gitea-sdk

* Merge branch 'master' of https://github.com/go-gitea/gitea into save-user-language

# Conflicts:
#	models/migrations/migrations.go
#	models/migrations/v62.go

* Made tests work again

* trigger CI

* trigger CI

* fmt

* re-trigger that FUCKING CI SO IT REALLY PICKS UP THE LATEST COMMIT ISTEAD OF PREDENDING TO DO SO

* re-trigger that FUCKING CI SO IT REALLY PICKS UP THE LATEST COMMIT ISTEAD OF PREDENDING TO DO SO

* When loggin in, only the language col gets updated instead of everything
2018-05-05 08:28:30 +08:00
1e1ece8f3d Do not allow to reuse TOTP passcode (#3878) 2018-05-02 18:02:02 +03:00
c58e1e437b test: reduce testing time. (#3885) 2018-05-02 21:56:19 +08:00
9495429982 Add "error" as reserved username (#3882) 2018-05-02 11:06:31 +03:00
5ffdf9388b Fix to use only needed columns from tables to get repository git paths (#3870) 2018-05-02 09:10:19 +03:00
1a97030017 Issue due date (#3794)
* Started adding deadline to ui

* Implemented basic issue due date managing

* Improved UI for due date managing

* Added at least write access to the repo in order to modify issue due dates

* Ui improvements

* Added issue comments creation when adding/modifying/removing a due date

* Show due date in issue list

* Added api support for issue due dates

* Fixed lint suggestions

* Added deadline to sdk

* Updated css

* Added support for adding/modifiying deadlines for pull requests via api

* Fixed comments not created when updating or removing a deadline

* update sdk (will do properly once go-gitea/go-sdk#103 is merged)

* enhanced updateIssueDeadline

* Removed unnessecary Issue.DeadlineString

* UI improvements

* Small improvments to comment creation
+ ui & validation improvements

* Check if an issue is overdue is now a seperate function

* Updated go-sdk with govendor as it was merged

* Simplified isOverdue method

* removed unessecary deadline to 0 set

* Update swagger definitions

* Added missing return

* Added an explanary comment

* Improved updateIssueDeadline method so it'll only update `deadline_unix`

* Small changes and improvements
* no need to explicitly load the issue when updating a deadline, just use whats already there
* small optimisations

* Added check if a deadline was modified before updating it

* Moved comment creating logic into its own function

* Code cleanup for creating deadline comment

* locale improvement

* When modifying a deadline, the old deadline is saved with the comment

* small improvments to xorm session handling when updating an issue deadline
+ style nitpicks

* style nitpicks

* Moved checking for if the user has write acces to middleware
2018-05-01 22:05:28 +03:00
85d14cc229 Symlink icons (#1416) (#3826)
* Updated vendor code for code.gitea.io/git

* Display symlinks correctly for files and directories

* Added symlink tests

* Applied silverwinds stylesheet patch

Signed-off-by: Tris Forster <tris.git@shoddynet.org>
2018-05-01 10:04:36 +03:00
181b3a8f09 Fix path cleanup in multiple places (#3871) 2018-05-01 09:46:04 +08:00
7ea4bfc561 API endpoint for testing webhook (#3550)
* API endpoint for testing webhook

* Empty commit to rerun CI
2018-04-29 14:21:33 +08:00
5a62eb30df Store OAuth2 session data in database (#3660)
* Store OAuth2 session data in database

* Rename table to `oauth2_session` and do not skip xormstorage initialization error
2018-04-29 09:09:24 +03:00
8d5f58d834 Shows total tracked time in issue and milestone list (#3341)
* Show total tracked time in issue and milestone list
Show total tracked time at issue page

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Optimizing TotalTimes by using SumInt

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fixing wrong total times for milestones caused by a missing JOIN
Adding unit tests for total times

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Logging error instead of ignoring it

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Correcting spelling mistakes

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Change error message to a short version

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add error handling to TotalTimes
Add variable for totalTimes

Signed-off-by: Jonas Franz <info@jonasfranz.de>

* Introduce TotalTrackedTimes as variable of issue
Load TotalTrackedTimes by loading attributes of IssueList
Load TotalTrackedTimes by loading attributes of single issue
Add Sec2Time as helper to use it in templates

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fixed test + gofmt

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Load TotalTrackedTimes via MilestoneList instead of single requests

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add documentation for MilestoneList

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Add documentation for MilestoneList

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fix test

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Change comment from SQL query to description

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fix unit test by using int64 instead of int

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fix unit test by using int64 instead of int

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Check if timetracker is enabled

Signed-off-by: Jonas Franz <info@jonasfranz.software>

* Fix test by enabling timetracking

Signed-off-by: Jonas Franz <info@jonasfranz.de>
2018-04-29 13:58:47 +08:00
fd8d6405c8 Fix only updated_unix when adding a comment (#3855) 2018-04-29 12:48:14 +08:00