Preheat oven to 400 degrees F
Heat oil in heavy-bottomed sauté pan. Put in onion and cook until translucent, but not browned.
Remove with slotted spoon and set aside.
Sauté squash slices in batches so the pan does not get overcrowded, just until slightly tender, but never soft. Stir in garlic, tomato, chiles, corn and cheese. Stir to combine well.
,br>Pour mixture in buttered 1-quart casserole and bake in preheated 400 degree F oven for 20 minutes.