place attachment upload function to the panel