-
Notifications
You must be signed in to change notification settings - Fork 1
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
Data types to enrich Decide #1
Comments
Consider adding the user's Gno address as TeamId implies the user can only be in one team; I would advise against this. Consider instead either having
Maybe it should have an owner, not sure. Definitely there should be ways to get the team's members, for instance.
Seems weird to track A better way to link to the "Object" may be through an interface: I suggest a
Aside from Object to Workable,
This one confuses me. |
@thehowl Thank you! Will add an I also think adding As for the |
Just a note, use This way you can keep a tree that keeps all the actor (
I wouldn't know where to get it, so here's a reference: package main
type Workable interface {
// nobody outside your realm will be able to implement this
assertWorkable()
}
type Task struct {
// ...
}
func (*Task) assertWorkable() {}
var _ Workable = &Task{}
type Project struct {
// ...
}
func (*Project) assertWorkable() {}
var _ Workable = &Project{} With this code, you guarantee that if you have a
I struggle to understand where it would be used in practice. I'd suggest you drop it for now and reconsider it if there is a clear use-case; which might help to suggest also what the data structure should really look like. |
Thanks, good point about using pointers, it's a part that I often overlook in Go, as it's not on my daily JS / React toolset. Also got your point about |
Here's a basic implementation of WorkDuration:
The main point is that I still kept the ObjectType for some fine grain filtering. We may need to assess the WorkDurations for specific types (Tasks / Projects). I don't see how we can do that with just the interface. Am I missing something, is this doable without keeping the ObjectType in the struct? |
This is intended as conversation starter for the data types we may use to enrich Decide, types which may be specific only to the Gno ecosystem project management processes. Comments welcome!
Proposed data structures / rich types for a DAO / team
These types are intended to be used in the Decide realm.
Actor
The basic working unit for an individual. Actors can be team members, or individual contributors.
Team
Teams are collective entities, they may or may not have actors assigned.
WorkHour
WorkHours are abstract time measurements assignable to a Task / Projet. They may or may not be combined with Actors or Teams.
RewardsPoints
RewardsPoints are abstract denominations for how much a certain task or project should be worth on completion. They may or may not be assigned to Actors or Teams, but they are releasable once a Task / Project is completed (moving a Task / Project with assigned RewardsPoints from Do to a Collection releases the assigned rewards points from the total existing).
Resources
Resources are abstract denominations for what needs to be spent, e.g. money, electricity, for a specific Task / Project.
The text was updated successfully, but these errors were encountered: