Skip to content
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

Assess/contest claim #5

Open
bitbeckers opened this issue Apr 19, 2024 · 0 comments
Open

Assess/contest claim #5

bitbeckers opened this issue Apr 19, 2024 · 0 comments
Assignees
Labels
fresh baked New feature or request P0 High Priority

Comments

@bitbeckers
Copy link
Collaborator

bitbeckers commented Apr 19, 2024

As a member of a CookieJar I should be able to attest other members claims.

This should be a signal of if members believe the ReachInJar function, with their reason specified, preformed by a user was a good or bad use of a given Jar.

Contract function

/**
     * @notice Allows a member to assess the reason for a claim.
     * @dev The member can give a thumbs up or thumbs down to a claim reason. The assessment is posted to the Poster
     * contract. This function can only be called by a member.
     * @param cookieUid The unique identifier of the claim reason to be assessed.
     * @param message The message to be posted with the assessment.
     * @param isGood A boolean indicating whether the assessment is positive (true) or negative (false).
     */
    function assessReason(bytes32 cookieUid, string calldata message, bool isGood) public {
        if (!_isAllowList(msg.sender)) {
            revert NOT_ALLOWED("not a member");
        }

        emit AssessReason(cookieUid, message, isGood);
    }

Primary components to look / work in.
app/jars/[jarId]/page.tsx
components/claims-list.tsx

I believe this assessReason function signature is outdated. I think it should take an object.

reason: {
  // I haven't thought about what this should look like yet. maybe just a uuid, maybe it needs to reference the claim but I don't think so.
  id: number  
  // Validate in the form with zod. That's what we've been using for form validation. Chat GPT is an excellent tool for zod schemas
  link: string 
  reason: string
  // probably leave this as an empty string for now. We can figure out what we want to do with tags later.
  tag: string
@bitbeckers bitbeckers changed the title Review claims flow Assess/contest claims flow Apr 19, 2024
@0xRowdy 0xRowdy changed the title Assess/contest claims flow Assess/contest claim Oct 3, 2024
@0xRowdy 0xRowdy added fresh baked New feature or request P0 High Priority labels Oct 21, 2024
@0xRowdy 0xRowdy assigned 0xRowdy and michaelgreen06 and unassigned 0xRowdy Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fresh baked New feature or request P0 High Priority
Projects
None yet
Development

No branches or pull requests

3 participants