Update xorm version (#26128)
Test new xorm version compatible with Gitea --------- Co-authored-by: KN4CK3R <admin@oldschoolhack.me>
This commit is contained in:
parent
5a56f9699c
commit
c7f6e9fc2f
4
go.mod
4
go.mod
|
@ -119,8 +119,8 @@ require (
|
||||||
gopkg.in/yaml.v3 v3.0.1
|
gopkg.in/yaml.v3 v3.0.1
|
||||||
mvdan.cc/xurls/v2 v2.5.0
|
mvdan.cc/xurls/v2 v2.5.0
|
||||||
strk.kbt.io/projects/go/libravatar v0.0.0-20191008002943-06d1c002b251
|
strk.kbt.io/projects/go/libravatar v0.0.0-20191008002943-06d1c002b251
|
||||||
xorm.io/builder v0.3.12
|
xorm.io/builder v0.3.13
|
||||||
xorm.io/xorm v1.3.3-0.20230623150031-18f8e7a86c75
|
xorm.io/xorm v1.3.3-0.20230725140238-59b727260d35
|
||||||
)
|
)
|
||||||
|
|
||||||
require (
|
require (
|
||||||
|
|
|
@ -241,7 +241,10 @@ func GetSearchOrderByBySortType(sortType string) db.SearchOrderBy {
|
||||||
|
|
||||||
// FindProjects returns a list of all projects that have been created in the repository
|
// FindProjects returns a list of all projects that have been created in the repository
|
||||||
func FindProjects(ctx context.Context, opts SearchOptions) ([]*Project, int64, error) {
|
func FindProjects(ctx context.Context, opts SearchOptions) ([]*Project, int64, error) {
|
||||||
e := db.GetEngine(ctx).Where(opts.toConds()).OrderBy(opts.OrderBy.String())
|
e := db.GetEngine(ctx).Where(opts.toConds())
|
||||||
|
if opts.OrderBy.String() != "" {
|
||||||
|
e = e.OrderBy(opts.OrderBy.String())
|
||||||
|
}
|
||||||
projects := make([]*Project, 0, setting.UI.IssuePagingNum)
|
projects := make([]*Project, 0, setting.UI.IssuePagingNum)
|
||||||
|
|
||||||
if opts.Page > 0 {
|
if opts.Page > 0 {
|
||||||
|
|
Loading…
Reference in a new issue