Skip to content
CCPEDIAby Unity Nodes
Discussions/App Development/Contract to keep list of contracts or partysForum ↗

Contract to keep list of contracts or partys

App Development2 posts551 views1 likesLast activity Jun 2020
DA
DavidBelinchonOP
Jun 2020

I’m doing a project where I have to register users and these users can create something similar to a service, it’s a good idea to have a contract where I keep the list of users and another contract where I keep the list of services for when a new user registers giving the visibility to all the services and when a new service is created giving the visibility to all users?

CO
cocreature
Jun 2020

Hi @DavidBelinchon, you might want to read through User aliases, a tale of two approaches. A developer grapples with DAML and the comments. There are roughly two approaches here:

  1. Keep a single contract that stores all information

  2. Split the information up into multiple contracts, e.g., one per party/contract/… that you want to store.

The linked post and the comments go through the tradeoffs between the two

← Back to Discussions