Chop potatoes and onion in small pieces. Fry in the oil. Once it is cooked, drain and put into a bowl with the eggs. Mix well. Then cook mixture in a frying pan, both sides until cooked.