add photo id when insert photo