Skip to content

Logic: appState Decision Tree

Vincent Cardillo edited this page Jan 20, 2016 · 6 revisions

Return strings

  • map,no_service_wall: Nothing is available. Execute the existing map <-> bummer wall logic.
  • closed_wall{n}: No OA available, and we are closed. Show current closed wall. {n} can represent an integer. So you will need test if the string contains "closed_wall" instead of testing for absolute equality.
  • soldout_wall: No OA available, and we are sold out. Show current sold_out wall.
  • build: Open to order something! Show the order flow.

FYI: appState Decision Tree

This is here primarily as an FYI as to how the appState works under the hood, and does not require any action on the part of an app developer. The return strings determine what state the app should be in, given our business logic.

  • Out of zone?
    • Yes: map,no_service_wall
    • No: HasServices?
      • Yes: HasOAService?
        • Yes: Build
        • No: Use OD state
      • No: OD open and has a menu set?
        • Yes: Give existing map,no_service_wall
        • No: closed_wall
Clone this wiki locally