24 lines
483 B
Go
24 lines
483 B
Go
package certs
|
|
|
|
import (
|
|
"github.com/TeaOSLab/EdgeCommon/pkg/rpc/pb"
|
|
"github.com/TeaOSLab/EdgeUser/internal/web/actions/actionutils"
|
|
)
|
|
|
|
type CountAction struct {
|
|
actionutils.ParentAction
|
|
}
|
|
|
|
func (this *CountAction) RunPost(params struct{}) {
|
|
countResp, err := this.RPC().SSLCertRPC().CountSSLCerts(this.UserContext(), &pb.CountSSLCertRequest{
|
|
UserId: this.UserId(),
|
|
})
|
|
if err != nil {
|
|
this.ErrorPage(err)
|
|
return
|
|
}
|
|
this.Data["count"] = countResp.Count
|
|
|
|
this.Success()
|
|
}
|