When repairing headsets, never trust the colour codes, or that the colours will be the same on different headsets, microphones, or left/right speakers.
get a volt/ohm multimeter and buzz the wires out to verify their function.
the two speakers will likely have a very similar ohm reading, and you will likely hear a click in each speaker as test them. If you don’t, connect up a single 1.5 volt cell to the speaker wires one at a time and you will hear a small click in eight head phone speaker. You may also hear a click in the microphone, depending on its type, dynamic, capacitive, or electret.
Once again, the ohms reading for the speakers will be very similar, and the ohms reading for the microphone will be different than the speakers, and likely much higher.
when soldering the wires together, make sure you heat the wire and apply solder to it, before attaching it to the other wires, in order to burn/melt the shellac insulation from the tip of the wire, or you will never get it to take solder, tin, and attach to the other wire you are attempting to splice together.
I hope this helps! I’ve been repairing intercom headsets for years at a tv station.