fix(fixture): 保存工装参数时记录操作日志
This commit is contained in:
@@ -224,6 +224,15 @@ def api_save_fixture_param(dnt_id):
|
|||||||
if not data:
|
if not data:
|
||||||
return jsonify({"ok": False, "error": "数据为空"}), 400
|
return jsonify({"ok": False, "error": "数据为空"}), 400
|
||||||
upsert_fixture_param(dnt_id, **data)
|
upsert_fixture_param(dnt_id, **data)
|
||||||
|
device = get_device_by_id(dnt_id)
|
||||||
|
target = f"{device['serial']}" if device else f"dnt_id={dnt_id}"
|
||||||
|
insert_log(
|
||||||
|
current_user.id, current_user.username, "update",
|
||||||
|
target=target,
|
||||||
|
detail="保存工装配置参数",
|
||||||
|
result="ok",
|
||||||
|
ip=request.remote_addr or "",
|
||||||
|
)
|
||||||
return jsonify({"ok": True})
|
return jsonify({"ok": True})
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user