mongodb时间戳转换成格式化时间戳

db.pay_order.find({"id":"5332336532"},{"tradeNo":true,"status":true,"create":true}).forEach(function (a) { a["create"] = (new Date(a["create"]).toString()); printjson(a) })
原文地址:https://www.cnblogs.com/zfyouxi/p/5113010.html