Sanji had the intentions of reducing enemy forces. But guess what? P1 isnt fodder.
This is only speculation, but I believe Sanji just underestimated P1's strength because the other beast pirates were trash.
Fact of the matter is, Oda left the ending ambiguous. There is nothing confirming whether Sanji did or didnt defeat him in the manga rn. We'll find out how that shit went down if P1 talks about it at the feast.