It is narrated from Sayyiduna Abdullah bin Abbas (may Allah be pleased with them both) that the Messenger of Allah (peace and blessings be upon him) said on the day of Badr: "Whoever kills someone shall have such and such, and whoever takes a captive shall have such and such." And this was before (the ruling of) the khumus. Then Allah Almighty revealed this verse: "And know that whatever you take as spoils of war, one fifth of it is for Allah" [Surah al-Anfal: 41], so the matter was handed over to him (peace and blessings be upon him).
Hadith Referenceالسنن الكبرى للبيهقي / كتاب قسم الفيء والغنيمة / 12818