Input validation for view flight

Hoon this is my example.
I used js