We wish that we had had more time last night.
Why 'had' used twice here?
We wish that we had had more time last night.
Why 'had' used twice here?
I wish I had had…
is a way to talk about past wishes that weren't fulfilled. You can read more about this here:
To talk about past wishes, we can use the structure I wish I had had… Note that the second had in this structure is the past participle form of have. Past participle forms of other verbs are also possible in this case.
In your sentence, We wish that we had had more time last night, they wanted to have more time last night but they didn't and so they regret it now.
The first "had" is an auxiliary verb that is used to form the perfect aspect. The second is a verb indicating possession or experience. Basically, they are different verbs that have the same form.