hicommonwealth / commonwealth

A platform for decentralized communities
https://commonwealth.im
GNU General Public License v3.0
67 stars 44 forks source link

🪣 Namespace Admin token Issuance #8650

Open ianrowan opened 3 months ago

ianrowan commented 3 months ago

Description

In order to interact with on-chain namespace based contracts at the admin level users will need to hold an admin token on the namespace(ie id=0). The user who deploys the namespace automatically receives this token and therefore is the only user who can configure stake or deploy contests. This behavior is necessary for contract security as the contracts are permissionless(ie we can't rely on the common UI to determine who can and cant do admin things on chain)

Given this consideration there are two new flows that need to be added to the app if communities desire all admins to have access to on-chain admin functions.

  1. new admin is added to community with existing namespace -> prompt user who added the admin(presumably must be an admin on-chain) to assign a new admin token on chain = metamask transaction
  2. Existing community adds a namespace/contest -> Deploying user will become an admin -> other admins will need to be manually assigned token with 1 tx each no some UI in the admin panel

Overall this will include new UI components as well as a single basic protocol helper to make the call to the namespace

Project Owner

@sachben91

PRD

N/A

Tasks

Design Links

TODO

Design Screenshots

TODO

Additional Context

No response

ianrowan commented 3 months ago

@ForestMars @jnaviask created this ticket as requested. Left the PENG tickets un-created as those will need product and design context but this should represent eng effort in general. @sachben91 please feel free to add more product side requests/requirements for this feature

dillchen commented 3 months ago

noting this, will get u smth here