This commit is contained in:
lwl0608 2024-05-07 23:33:45 +08:00
parent 1f87040636
commit 2b9b87c57b
1 changed files with 11 additions and 2 deletions

View File

@ -25,8 +25,17 @@ for m in lis:
vas_moment = col_zone_moment_price.find_one({"_id": mmid})
vas_price = safe_get_int(vas_moment, "price")
if price != vas_price:
print(mmid, price, vas_price)
if price != vas_price:
q = {
"_id": mmid,
}
up = {
"$set": {
"price": price
}
}
ret = col_zone_moment_price.update_one(q, up)
print(mmid, price, vas_price, ret.modified_count)
col_zone_moment.close()
col_zone_moment_price.close()