I have copied most of the part of resolve action, you can make required changes to state and other values  as per your requirement.

Please appreciate the efforts of community contributors by marking appropriate response as correct answer and helpful, this may help other community users to follow correct solution in future.
Thanks
Anil Lande