I'm not sure of what really happens in these 2 steps o two synthetic pathways.
In the first case, compound A reacts with MeOH/H+ (forgot to drawn in the img), to give compound B, and I'm not sure if I can explain it well:
In my opinion, MeOH's oxygen attacks carbonyl, and after some protonation equilibriums (acid media), the O of the carbonyl at start, leaves the molecule as H
2O allowing elimination and generates the alkene + eter.
The main problem I find is that I think is that in this case, almost 100% of the 1,3-dicarbonyl compound would be in enol form, so adition to carbonyl of MeOH couldn't happen.
In the second case I have that 1,3-dicarbonyl compound and is treated first with MeOH/H+ to give, enol(
or it can happen the same as in the last reaction and give alkene-eter??), and then Me
2CuLi, as weak organometallic nucleophile, would form the compound I've drawn. I don't know if that's what would happen or it would do it another way, like in the first case. The result seems quite obvious too.