|
|
@@ -1119,6 +1119,7 @@ def get_photo_records(page: int = 1, size: int = 5):
|
|
|
select(PhotoRecord, DeviceConfig.action_name)
|
|
|
.join(DeviceConfig, PhotoRecord.action_id == DeviceConfig.id)
|
|
|
.where(PhotoRecord.goods_art_no.in_(current_goods_art_nos))
|
|
|
+ .where(PhotoRecord.delete_time == None)
|
|
|
.order_by(PhotoRecord.goods_art_no, desc("id")) # 按货号分组并按ID倒序
|
|
|
)
|
|
|
all_items = session.exec(query).mappings().all()
|