0
나는 Bookshelf.js ORM을 사용하고 있으며 날짜별로 질문하고 문제가있을 수 있어야합니다.Bookshelf.js에서 날짜를 쿼리하는 방법
여기에 제가 사용하는 샘플 코드 스 니펫이 있습니다.
this.model.query((q) => {
q.where('created_at', '>=', Date.now());
q.orderBy('created_at', 'DESC');
})
.fetch().then(function (model) {
socket.send(JSON.stringify(model));
});
위의 코드는 null 또는 빈 배열을 반환합니다. 아이디어가 있으십니까?