Commit Graph

11 Commits (a48d6ba4b4be4207a2c78c36b095fb69938e5ae5)

Author SHA1 Message Date
Lunny Xiao 86c85c19b6
Refactor AssertExistsAndLoadBean to use generics ()
* Refactor AssertExistsAndLoadBean to use generics

* Fix tests

Co-authored-by: zeripath <art27@cantab.net>
Lunny Xiao 1dfa26e00e
Move milestone to models/issues/ ()
* Move milestone to models/issues/

* Fix lint

* Fix test

* Fix lint

* Fix lint
Lunny Xiao 719bddcd76
Move repository model into models/repo ()
* Some refactors related repository model

* Move more methods out of repository

* Move repository into models/repo

* Fix test

* Fix test

* some improvements

* Remove unnecessary function
Lunny Xiao a666829a37
Move user related model into models/user ()
* Move user related model into models/user

* Fix lint for windows

* Fix windows lint

* Fix windows lint

* Move some tests in models

* Merge
Gusted c98dd7a3e0
Remove unnecessary variable assignments ()
* Remove unnecessary variable assignments

As title

* enable ineffassign

Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
wxiaoguang 81926d61db
Decouple unit test, remove intermediate `unittestbridge` package ()
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Lunny Xiao a4bfef265d
Move db related basic functions to models/db ()
* Move db related basic functions to models/db

* Fix lint

* Fix lint

* Fix test

* Fix lint

* Fix lint

* revert unnecessary change

* Fix test

* Fix wrong replace string

* Use *Context

* Correct committer spelling and fix wrong replaced words

Co-authored-by: zeripath <art27@cantab.net>
6543 00a806de68
[API] Milestone endpoints accept names too ()
* API: Milestone endpoints accept names too

* add test

* rename

Co-authored-by: Lauris BH <lauris@nix.lv>
6543 8bdc9795d8
Add name filter to API for GetMilestoneList ()
Adds a name filter to the API for GetMilestoneList

Includes a small refactor: merge GetMilestones and GetMilestonesByRepoID

Close 

Needed for https://gitea.com/gitea/go-sdk/issues/383 and https://gitea.com/gitea/tea/pulls/149
6543 1ac46186ff
API allow to create closed milestones ()
* API allow to create closed milestones

* set CloseDate too

Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Lunny Xiao c09e020558
Fix milestone API state parameter unhandled ()
* Fix milestone API state parameter unhandled

* Fix test