a good time was had by all

When someone uses the cliche, a good time was had by all, they are speaking in the literal sense that everyone had a good time. For instance, if there is a party or social gathering and everyone there enjoyed themselves, someone might paraphrase this meaning by simply saying that a good time was had by all. It is an old way of speaking for new and modern lifestyles.