Explorar o código

台账修订,修订前台账数据记录问题

MaiXinRong %!s(int64=3) %!d(string=hai) anos
pai
achega
d9cd2bebdd
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      app/service/ledger_history.js

+ 1 - 1
app/service/ledger_history.js

@@ -29,7 +29,7 @@ module.exports = app => {
          */
         async getLatestHistory(tid) {
             const his = await this.db.select(this.tableName, {
-                where: { tid },
+                where: { tid, valid: 1 },
                 orders: [['in_time', 'desc']],
                 limit: 1, offset: 0,
             });