January 2018
Beginner to intermediate
312 pages
7h 22m
English
Now let’s move on to the steps in the workflow pipeline. It’s clear from our previous understanding of the workflow that the Order isn’t just a static document but actually transitions through a series of different states:

How should we model these states? A naïve approach would be to create a single record type that captures all the different states with flags, like this:
| | type Order = { |
| | OrderId : OrderId |
| | ... |
| | IsValidated : bool // set when validated |
| | IsPriced : bool // set when priced |
| | AmountToBill : decimal option // also set when priced |
| | } |
But this approach has lots of problems:
The ...
Read now
Unlock full access