dishwasher repair

Hello everyone here’s my problem. Dishwasher fills with water and water is hot. You can hear motor kick on like it’s beginning to wash. Comes on an off a couple seconds apart.Does this four times then all lights go blank and never comes on again.you hit the start/cancel button pump kicks on and drains water with no problem.Any ideas on what to check.Thanks