Merge pull request #10309 from tb365/automated-cherry-pick-of-#10305-upstream-release-3.7

Automated cherry pick of #10305: infos copyright add brand_en&brand_cn
This commit is contained in:
Zexi Li
2021-03-04 15:25:57 +08:00
committed by GitHub
+10
View File
@@ -36,6 +36,8 @@ func init() {
Email string `help:"The Email"`
Docs *string `help:"the Docs website address"`
License *string `help:"the license generator website address"`
BrandCn *string `help:"the brand name in Chinese"`
BrandEn *string `help:"the brand name in English"`
}
R(&CopyrightUpdateOptions{}, "copyright-update", "update copyright", func(s *mcclient.ClientSession, args *CopyrightUpdateOptions) error {
@@ -52,6 +54,14 @@ func init() {
params.Add(jsonutils.NewString(*args.License), "license")
}
if args.BrandCn != nil {
params.Add(jsonutils.NewString(args.Email), "brand_cn")
}
if args.BrandEn != nil {
params.Add(jsonutils.NewString(args.Email), "brand_en")
}
if len(args.Copyright) > 0 {
params.Add(jsonutils.NewString(args.Copyright), "copyright")
}