Split the problem in two cases, one when the first box contains a green ball and the second one when it doesn't
If the first box contains a green ball then first choose the boxes containing the green balls, as they are indistinguishable there are $\binom{11}{6}$ choices, as the first ball already has a ball. Now each of the 23 blue balls can be put in any of the boxes, so there are $\binom{11}{6} \cdot 12^{23}$ configurations.
Now if the first box doesn't contain a green ball similarly there are $\binom{11}{7}$ ways to choose the boxes containin the green balls and $12^{23}$ ways to distribute the blue balls. But note it's possible for the first boxes to be empty, so we have to subtract the "bad" configurations. There are exactly $\binom{11}{7} \cdot 11^{23}$ such configurations and finally the wanted number is:
$$\binom{11}{6} \cdot 12^{23} + \binom{11}{7} \cdot 12^{23} - \binom{11}{7} \cdot 11^{23}$$