Last active
December 8, 2019 04:27
-
-
Save pyoner/d2d087201261dd50d15ac86aa26f606b to your computer and use it in GitHub Desktop.
Job State Sketch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Job State Sketch | |
Init | |
client draft -> Draft | |
client publish -> AcceptingOffers | |
Draft | |
client close -> Closed | |
client publish -> AcceptingOffers | |
AcceptingOffers | |
client closeOffer -> Closed | |
client makeOffer -> Offer | |
provider makeOffer -> AcceptingOffers | |
Offer | |
AwaitingOffer* | |
provider acceptOffer -> OfferAccepted | |
provider counterOffer -> ProviderCounterOffer | |
client counterOffer -> ClientCounterOffer | |
ProviderCounterOffer | |
client acceptCounterOffer -> OfferAccepted | |
client cancelCounterOffer -> Closed | |
provider cancelOffer -> Closed | |
ClientCounterOffer | |
provider acceptCounterOffer -> OfferAccepted | |
provider cancelCounterOffer -> Closed | |
client cancelOffer -> Closed | |
OfferAccepted | |
AwaitingEscrow* | |
client sendEscrow -> Escrow | |
client cancelOffer -> Closed | |
Escrow | |
InEscrow* | |
markAsComplete -> WorkPendingCompletion | |
dispute -> InDispute | |
# The provider has marked the job as complete and is awaiting the client's acceptance | |
WorkPendingCompletion | |
releaseEscrow -> Complete | |
dispute -> InDispute | |
# The provider or the client has raised a dispute. This is being resolved by the CanYa DAO | |
InDispute | |
releaseEscrow -> Complete | |
refundEscrow -> Fail | |
# This job has been marked as complete by the client. | |
Complete | |
review -> Review | |
Fail | |
review -> Review | |
Review | |
Closed | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function render(model){ | |
let current_state_name = model.active_states[0].name; | |
return $("h1", | |
{style: {color: "darkBlue"}}, | |
`The current state is: ${current_state_name}`); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment