推荐工具
RoboMongo
推荐书目
50 Tips and Tricks for MongoDB Developers
Related Blogs
Snail in a Turtleneck
tonghuashuai
V2EX  ›  MongoDB

我想在 .mongorc.js 中写一个函数处理时间戳,大家有没有什么好办法啊

  •  
  •   tonghuashuai · Jun 4, 2015 · 4062 views
    This topic created in 4011 days ago, the information mentioned may be changed or developed.
    DBQuery.prototype.h = function (col) {
    this._prettyShell = true;
    this['_' + col] = getTime(this[col]);

    return this
    }

    开始是用上边的写法,发现 BSON 数据不能按 js object 来处理,大家有没有什么好的办法呢?
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2533 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 15:57 · PVG 23:57 · LAX 08:57 · JFK 11:57
    ♥ Do have faith in what you're doing.