github.com/decred/politeia@v1.4.0/politeiawww/cmd/cmswww/generatepayouts.go (about) 1 // Copyright (c) 2017-2019 The Decred developers 2 // Use of this source code is governed by an ISC 3 // license that can be found in the LICENSE file. 4 5 package main 6 7 import ( 8 "github.com/decred/politeia/politeiawww/api/cms/v1" 9 "github.com/decred/politeia/politeiawww/cmd/shared" 10 ) 11 12 // GeneratePayoutsCmd 13 type GeneratePayoutsCmd struct { 14 } 15 16 // Execute executes the generate payouts command. 17 func (cmd *GeneratePayoutsCmd) Execute(args []string) error { 18 // Generate payouts 19 gpr, err := client.GeneratePayouts( 20 &v1.GeneratePayouts{}) 21 if err != nil { 22 return err 23 } 24 25 // Print user invoices 26 return shared.PrintJSON(gpr) 27 }