mirror of
https://gitee.com/mirrors/AllinSSL.git
synced 2026-03-08 07:41:10 +08:00
【调整】插件支持动态参数和参数类型
【调整】获取证书列表支持状态过滤 【新增】dns提供商腾讯云eo
This commit is contained in:
@@ -408,3 +408,26 @@ func GetPlugins(c *gin.Context) {
|
||||
public.SuccessData(c, data, len(data))
|
||||
return
|
||||
}
|
||||
|
||||
func GetPluginRawMetadata(c *gin.Context) {
|
||||
var form struct {
|
||||
Name string `form:"name"`
|
||||
}
|
||||
err := c.Bind(&form)
|
||||
if err != nil {
|
||||
public.FailMsg(c, err.Error())
|
||||
return
|
||||
}
|
||||
form.Name = strings.TrimSpace(form.Name)
|
||||
if form.Name == "" {
|
||||
public.FailMsg(c, "插件名称不能为空")
|
||||
return
|
||||
}
|
||||
data, err := plugin.GetPluginRawMetadata(form.Name)
|
||||
if err != nil {
|
||||
public.FailMsg(c, err.Error())
|
||||
return
|
||||
}
|
||||
public.SuccessData(c, data, 0)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -14,13 +14,14 @@ func GetCertList(c *gin.Context) {
|
||||
Search string `form:"search"`
|
||||
Page int64 `form:"p"`
|
||||
Limit int64 `form:"limit"`
|
||||
Status int64 `form:"status"`
|
||||
}
|
||||
err := c.Bind(&form)
|
||||
if err != nil {
|
||||
public.FailMsg(c, err.Error())
|
||||
return
|
||||
}
|
||||
certList, count, err := cert.GetList(form.Search, form.Page, form.Limit)
|
||||
certList, count, err := cert.GetList(form.Search, form.Page, form.Limit, form.Status)
|
||||
if err != nil {
|
||||
public.FailMsg(c, err.Error())
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user