feat: 出库/借库记录记录并展示库位快照(DB加列+后端写入+记录页展示)
This commit is contained in:
@ -23,6 +23,8 @@ class TransBorrow(db.Model):
|
||||
return_operator = db.Column(db.String(100))
|
||||
return_signature = db.Column(db.Text)
|
||||
return_location = db.Column(db.String(100))
|
||||
# [新增] 借出时的库位快照(从源库存记录带出,便于历史追溯)
|
||||
location = db.Column(db.String(100))
|
||||
status = db.Column(db.String(20), default='borrowed')
|
||||
remark = db.Column(db.Text)
|
||||
|
||||
@ -49,6 +51,7 @@ class TransBorrow(db.Model):
|
||||
'return_operator': self.return_operator,
|
||||
'return_signature': self.return_signature,
|
||||
'return_location': self.return_location,
|
||||
'location': self.location or '',
|
||||
'status': self.status,
|
||||
'remark': self.remark,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user