Hmm, you have really jumped into the deep end there!
There are a few things you are going to have to learn so I hope you are sitting down.
The first thing you need to learn is some JavaScript basics. In particular, how to split a string using a token. So, for example:
var splitted = msg.payload.split(',')
var mydate = splitted[0]
var topic = splitted[1]
var temperature = splitted[2]
var topicSplit = topic.split('/')
var camera = topicSplit[1]
Would split the incoming MQTT message into 3 parts as an array. Then further splits the MQTT topic and extracts the camera device name.
The next issue is how to group up the data. This is called pivoting. Your data is coming in with a timestamp, and you want to pivot that to have 1 record per day. There are a number of issues there and I don't really have time to go through them all now. But let me at least start by asking whether you can be sure that you will always get the same number of temperature values per day? Because if you can't do that, I wouldn't recommend the format you are asking for since your CSV won't always have the same number of columns and the trailing camera name column won't always be in the same place.
So maybe another question would be - what do you intend to do with the CSV file?