-
Notifications
You must be signed in to change notification settings - Fork 203
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
CNS-169: create module subscription #328
Conversation
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.
scaffold generated files not always follow our linter rules.
please go over those errors and fix the linter issues, if we dont do that main will break
00eaf54
to
92389df
Compare
done. |
command: ignite scaffold module subscription
GetPlan() - drop block arg, because we always use current block. PutPlan() - do not return the Plan, because we drop it anway.
Porperly initialize the module in app.go, and add deps account,bank.
ignite scaffold type subscription \ creator:string \ consumer:string \ block:uint \ plan_index:string \ plan_block:uint \ is_yearly:bool \ expiry_time:uint \ usedCU:uint \ remainingCU:uint \ --no-message \ --module subscription
ignite scaffold message subscribe \ consumer:string index:string is_yearly:bool --module subscription --desc "Subscribe to a service plan"
To add a subscription: lavad tx subscription subscribe [CONSUMER] [PLAN] [IS_YEARLY] [flags] Where: CONSUMER: address of the consumer that will use this subscription PLAN: unique index of the plan to subscribe to IS_YEARLY: whether the subscription is for a year (for discounted rate)
ignite scaffold query CurrentSubscription \ consumer:string \ --module subscription \ --desc "Query current subscription to a service plan" \ --response sub:Subscription
92389df
to
cb24608
Compare
…ption CNS-169 implement module subscription
…subscription CNS-175 implement query current subscription
This PR holds the the result of the scaffolding module subscription.
The code was auto-generated using:
ignite scaffold module subscription
Pushed in a separate PR to simplify the review of the upcoming changes.
What kind of change does this PR introduce? (Bug fix, feature, unit tests, docs update, ...)
What is the current behavior? (You can also link to an open issue here)
What is the new behavior (if this is a feature change)?
Please describe what manual tests you ran, if applicable
Other information: