-
Notifications
You must be signed in to change notification settings - Fork 75
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wwwcli: Add new help messages, fix filename
This commit adds new help messages for the commands: - commentslikes - inventory - proposalvotes - tally - vote - votestatus It also renames the file 'commentsvotes.go' to 'commentslikes.go'. This fixes an oversight in a previous refactoring. I'm guessing from the folowing commit: eae628c
- Loading branch information
Showing
8 changed files
with
184 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
package commands | ||
|
||
// Help message displayed for the command 'politeiawwwcli help commentslikes' | ||
var CommentsLikesCmdHelpMsg = `commentslikes "token" | ||
Fetch all the comments voted on by the user for a given proposal. | ||
Arguments: | ||
1. token (string, required) Proposal censorship token | ||
Result: | ||
{ | ||
"commentslikes": [ | ||
{ | ||
"action": (string) Vote (upvote or downvote) | ||
"commentid" (string) Id of the comment | ||
"token": (string) Proposal censorship token | ||
}, | ||
] | ||
}` | ||
|
||
type CommentsLikesCmd struct { | ||
Args struct { | ||
Token string `positional-arg-name:"token"` | ||
} `positional-args:"true" required:"true"` | ||
} | ||
|
||
func (cmd *CommentsLikesCmd) Execute(args []string) error { | ||
cvr, err := c.UserCommentsLikes(cmd.Args.Token) | ||
if err != nil { | ||
return err | ||
} | ||
return Print(cvr, cfg.Verbose, cfg.RawJSON) | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters