| 34 | } |
| 35 | |
| 36 | func (i *imlStrategyController) ToPublish(ctx *gin.Context, driver string) ([]*strategy_dto.ToPublishItem, string, string, bool, error) { |
| 37 | list, err := i.strategyModule.ToPublish(ctx, driver) |
| 38 | if err != nil { |
| 39 | return nil, "", "", false, err |
| 40 | } |
| 41 | data, _ := json.Marshal(list) |
| 42 | source := base64.StdEncoding.EncodeToString(data) |
| 43 | return list, source, time.Now().Format("20060102150405") + "-release", len(list) > 0, nil |
| 44 | } |
| 45 | |
| 46 | func (i *imlStrategyController) FilterGlobalRemote(ctx *gin.Context, name string) ([]*strategy_dto.Title, []any, int64, string, string, error) { |
| 47 | f, has := strategy_filter.RemoteFilter(name) |