generated from spknetwork/js-typescript-template
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hive vote #28
Merged
Merged
Hive vote #28
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
a609d72
This should be a private method
43dc2b0
Teasts and implementation for hive voting
ae06704
Must've forgot to do these ones in the last pr
50cdc9f
Update src/repositories/hive-chain/hive-chain.repository.ts
sisygoboom 83e3cac
Api uses specified hive account for voting
f43c200
Update src/services/uploader/uploading.controller.ts
sisygoboom 87f8592
Update src/services/uploader/uploading.controller.ts
sisygoboom File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,28 @@ | ||
import { ApiProperty } from '@nestjs/swagger'; | ||
import { IsNotEmpty } from 'class-validator'; | ||
|
||
export class VotePostDto { | ||
@IsNotEmpty() | ||
@ApiProperty({ | ||
default: 'sagarkothari88', | ||
}) | ||
author: string; | ||
|
||
@IsNotEmpty() | ||
@ApiProperty({ | ||
default: 'actifit-sagarkothari88-20230211t122818265z', | ||
}) | ||
permlink: string; | ||
|
||
@IsNotEmpty() | ||
@ApiProperty({ | ||
default: 10000, | ||
}) | ||
weight: number; | ||
|
||
@IsNotEmpty() | ||
@ApiProperty({ | ||
default: 'test', | ||
}) | ||
votingAccount: string; | ||
} |
Empty file.
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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doesn't this need username (
account
) validation as well? If not, I would assume that the above checks are just sanity checks.This also brings up a bigger question. What do usernames look like for DID accounts?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe they're just ceramic IDs. account is just any network dependant unique identifier in this case
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What are ceramic IDs? Do you mean
did:key:....
s?Also, what about the question about validation?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah they're just sanity checks, they allow us to return them types the type for a username is just string
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok cool. I don't think this should block this PR, but it would probably be better for us to have a better understand of what the
account
portion of thesub
look like for each network type.