|
@@ -81,6 +81,10 @@ func GetPack(c *gin.Context, apictx *ApiSession) (interface{}, error) {
|
|
|
func GetPacks(c *gin.Context, apictx *ApiSession) (interface{}, error) {
|
|
|
|
|
|
page, size, query := UtilQueryPageSize(c)
|
|
|
+ if _name, ok := query["name"]; ok {
|
|
|
+ delete(query, "name")
|
|
|
+ query["name"] = bson.M{"$regex": _name.(string)}
|
|
|
+ }
|
|
|
|
|
|
option := &repo.PageSearchOptions{
|
|
|
CollectName: repo.CollectionPack,
|