Place the eggplant cubes in a colander and sprinkle them generously with salt. Let stand at least 1/2 hour; rinse well under cold water, drain, and pat dry with paper towels.
Heat 1/4 cup oil in a large heavy skillet over medium-high heat. Gradually add the eggplant, stirring constantly. Add more oil as needed to keep the eggplant from sticking.
As soon as all the eggplant is in the pan, gradually add the garlic, onion and celery. Cook until hot through but not browned, keeping the heat as high as possible. Stir in the tomatoes, bay leaves, vinegar, capers, and olives. Mix well and lower the heat to simmer. Cook for about 15 to 20 minutes, or until the eggplant is tender and the flavor is well developed.
Season the caponata with salt, pepper, and additional vinegar as needed. Add basil leaves, nuts, and parsley. Serve hot, at room temperature, or chilled.
Variation: Add chopped anchovies, chunks of fish or shellfish, ham, Italian sausage, or other cooked meat to the vegetables in the last few minutes of cooking time.