Smart Contract — New Feature
Summary
Owners need an entrypoint to propose a recurring schedule. This adds a create_recurring_payment_proposal function mirroring the existing create_proposal with the same validation gates.
Background
The existing create_proposal entrypoint in contracts/accord/src/lib.rs authorizes the proposer, checks the frozen state, validates description/deadline/category, enforces the active-proposal cap, and snapshots the quorum. A new entrypoint for recurring-payment proposals must do the same but with the schedule-specific parameters.
What Needs to Be Done
- Add a
create_recurring_payment_proposal entrypoint that accepts the schedule parameters alongside the standard proposal fields (description, deadline, category).
- Apply the same gates as
create_proposal: proposer authorization, not-frozen check, description/deadline/category validation, active-proposal cap, and quorum snapshot.
- Create a
Proposal with the CreateRecurringPayment kind and return it.
Acceptance Criteria
Files to Look At
contracts/accord/src/lib.rs — add the entrypoint near create_proposal
Difficulty: Hard
Smart Contract — New Feature
Summary
Owners need an entrypoint to propose a recurring schedule. This adds a
create_recurring_payment_proposalfunction mirroring the existingcreate_proposalwith the same validation gates.Background
The existing
create_proposalentrypoint incontracts/accord/src/lib.rsauthorizes the proposer, checks the frozen state, validates description/deadline/category, enforces the active-proposal cap, and snapshots the quorum. A new entrypoint for recurring-payment proposals must do the same but with the schedule-specific parameters.What Needs to Be Done
create_recurring_payment_proposalentrypoint that accepts the schedule parameters alongside the standard proposal fields (description, deadline, category).create_proposal: proposer authorization, not-frozen check, description/deadline/category validation, active-proposal cap, and quorum snapshot.Proposalwith theCreateRecurringPaymentkind and return it.Acceptance Criteria
create_proposal.CreateRecurringPaymentkind.Files to Look At
contracts/accord/src/lib.rs— add the entrypoint nearcreate_proposalDifficulty: Hard