detailsoutput.js realize,but also need to improve