swarmcity / SwarmCityConcept

This is the high level description of what needs to be built
9 stars 1 forks source link

As a Hashtagmaintainer I can resolve conflicts, so users have a safe and fair marketplace. #24

Open kikipluche opened 6 years ago

kikipluche commented 6 years ago

Abstract:

In the first hashtags on Swarm City Boardwalk, a request becomes a deal when both parties agree to the deal, and are equally invested in it.

Both Seeker and Provider can put the deal in a state of conflict. This means the funds are locked, and only the Hashtagmaintainer can decide how the funds will be paid out.

How it could work:

When a deal is in state "Disputed", the Hashtagmaintainer will see the deal on top of the hashtaglist. On the detail view, the Hashtagmaintainer now can enter the chat to figure out what went wrong.

The Hashtagmaintainer can resolve the disputed deal. The Hashtagmaintainer chooses what portion of the pledged funds get returned to Provider and Seeker. The Hashtagmaintainer then pays out those amounts by triggering function resolve in the hastagcontract.

The Hashtagmaintainer signs the transaction on the client and sends it to the API.

How the API could work:

Re-use sendSignedTx: The api receives the signed transaction and returns a transaction hash.

The API emits hashtagItemChanged event.


What it looks like:

Userflow: https://invis.io/ABGM89SX3V5#/299316514_-Hashtag--contractadress---dealhash-_RESOLVE_I ( > in Invision, hold shift to see clickable areas)


route: /hashtag/[contractadress]/[dealhash]

When a deal is in conflict (1), directly below the shareable link, the hashtag maintainer of that specific hashtag sees:

When the maintainer taps the resolve-button, the detailview of the item changes to show the resolve-view (2). This view consists of:

On this view, the maintainer can decide how to divide the funds among Seeker and Provider by:

When the maintainer wants to confirm this division and carry it out, he/she taps the white iconbutton with blue Vmark. This will change the view to confirm-resolve-page (3).

The copy on confirm-resolve-page (3) is "Send [Seekeramount] SWT to [Seeker] and [Provideramount] SWT to [Provider]?". The small copy is "This can not be undone."

When the maintainer taps the big white button with blue V-mark, he triggers the password-unlock (3b) for signing the transaction.

When the white button of password-unlock (3b) is enabled and tapped by the user, the page changes to resolve-processing-page (4).

resolve-processing-page (4) is a processing page (swarmcity/SwarmCityPM#26), in this case the copy on succes is "[Seeker] and [Provider] have been paid."

In the chatview it will also be visible that the conflict is now in resolved.


Desktop view:


Invisionlinks with login (for inspect mode!): mobile: https://projects.invisionapp.com/d/main#/console/13838256/299316514/inspect desktop: https://projects.invisionapp.com/d/main#/console/14147648/299114362/inspect

Documentation / references


With ♡ from Swarm City