Decision making based on the existance of an association

Hi, im trying to show the user a screen in which he can see his request (“Solicitud” in spanish) or create one if he doesnt have one. Im not shure how to do thisn in a microflow. Thanks This is my Domain Model.
1 answers

From a button, call a microflow. In the microflow:

  • Case $currentUser to Usuario or retrieve Usuario another way.
  • Retrieve the $Solicitud from the $currentUser
  • Check if $Solicitud !=empty
    • If true, return $Solicitud
    • If false, create a new Solicitud and return $NewSolicitud