MDL-47255 core_grades: Save aggregationcoef2 and weightoverride in history

Part of: MDL-46576