SFoS pg 187 has a chart outlining the campaign sequence. Phase 4 is "Fight Battle" and Phase 5 is stated as "Ship Experience". Under the actual section for Experience, though, it gets fuzzy. I can easily see you're interpretation that the XP is immediate as it states that "During every battle, ships will acquire Experience Point (XP) Dice for various actions they successfully perform." The expenditures for XPD do NOT state when they can be used with the exception of "Tactical Judgement" stating that you keep the dice "ready for use in future battles."
Based on how the other uses for XPD are written (assuming you are not allowing Refitting in the middle of battle), the presence of XP sources requiring knowledge of how the engagement ended (win/loss) and the fact that there is a separate experience phase, I'd say that XP is acquired at the end of the scenario.
EDIT: Yes, you could interpret the "Ship Experience" as the point when you spend the XPD for Refits/OD, etc. If that were the case, however, why not include it in the 'Repairs and Reinforcements' as they tend to be enhancements or repairs or reinforcements for your fleet?