调整依赖结构,jxutils不依赖于dao,dao依赖于jxutils
This commit is contained in:
@@ -20,7 +20,6 @@ import (
|
||||
"git.rosy.net.cn/baseapi/platformapi"
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/business/model"
|
||||
"git.rosy.net.cn/jx-callback/business/model/dao"
|
||||
"git.rosy.net.cn/jx-callback/globals"
|
||||
"github.com/boombuler/barcode"
|
||||
"github.com/boombuler/barcode/code128"
|
||||
@@ -370,11 +369,19 @@ func IsEmptyID(id int64) bool {
|
||||
}
|
||||
|
||||
func FormalizePageSize(pageSize int) int {
|
||||
return dao.FormalizePageSize(pageSize)
|
||||
if pageSize == 0 {
|
||||
return model.DefPageSize
|
||||
} else if pageSize < 0 {
|
||||
return model.UnlimitedPageSize
|
||||
}
|
||||
return pageSize
|
||||
}
|
||||
|
||||
func FormalizePageOffset(pageSize int) int {
|
||||
return dao.FormalizePageOffset(pageSize)
|
||||
func FormalizePageOffset(offset int) int {
|
||||
if offset < 0 {
|
||||
offset = 0
|
||||
}
|
||||
return offset
|
||||
}
|
||||
|
||||
func FormalizeName(name string) string {
|
||||
|
||||
Reference in New Issue
Block a user