2024-05-30 23:45:36 +03:00
|
|
|
package main
|
|
|
|
|
|
|
|
import "surdeus.su/core/amo"
|
|
|
|
import "surdeus.su/core/ss/urlenc"
|
|
|
|
import "surdeus.su/core/cli/mtool"
|
2024-06-05 00:08:54 +03:00
|
|
|
//import "encoding/json"
|
|
|
|
//import "strconv"
|
|
|
|
//import "log"
|
|
|
|
//import "fmt"
|
2024-05-30 23:45:36 +03:00
|
|
|
//import "os"
|
|
|
|
|
|
|
|
|
2024-06-05 00:08:54 +03:00
|
|
|
type CompanyGetter struct{}
|
2024-05-30 23:45:36 +03:00
|
|
|
|
2024-06-05 00:08:54 +03:00
|
|
|
func (l CompanyGetter) GetValues(
|
|
|
|
c *amo.Client,
|
|
|
|
opts ...urlenc.Builder,
|
|
|
|
) ([]amo.Company, amo.NextFunc[[]amo.Company], error) {
|
|
|
|
return c.GetCompanies(opts...)
|
|
|
|
}
|
2024-05-30 23:45:36 +03:00
|
|
|
|
2024-06-05 00:08:54 +03:00
|
|
|
func (l CompanyGetter) GetNameMul() string {
|
|
|
|
return "companies"
|
|
|
|
}
|
2024-05-30 23:45:36 +03:00
|
|
|
|
2024-06-05 00:08:54 +03:00
|
|
|
func (l CompanyGetter) GetFuncName() string {
|
|
|
|
return "amo.GetCompanies"
|
|
|
|
}
|
|
|
|
|
|
|
|
var getComs = mtool.T("get-companies").Func(func(
|
|
|
|
flags *mtool.Flags,
|
|
|
|
){
|
|
|
|
RunGetter(CompanyGetter{}, flags)
|
2024-05-30 23:45:36 +03:00
|
|
|
})
|