mirror of https://github.com/langgenius/dify.git
fix: _model_to_insertion_dict missing id (#30603)
This commit is contained in:
parent
d6e9c3310f
commit
4f74e90f51
|
|
@ -1506,6 +1506,7 @@ class WorkflowDraftVariable(Base):
|
|||
file_id: str | None = None,
|
||||
) -> "WorkflowDraftVariable":
|
||||
variable = WorkflowDraftVariable()
|
||||
variable.id = str(uuid4())
|
||||
variable.created_at = naive_utc_now()
|
||||
variable.updated_at = naive_utc_now()
|
||||
variable.description = description
|
||||
|
|
|
|||
|
|
@ -679,6 +679,7 @@ def _batch_upsert_draft_variable(
|
|||
|
||||
def _model_to_insertion_dict(model: WorkflowDraftVariable) -> dict[str, Any]:
|
||||
d: dict[str, Any] = {
|
||||
"id": model.id,
|
||||
"app_id": model.app_id,
|
||||
"last_edited_at": None,
|
||||
"node_id": model.node_id,
|
||||
|
|
|
|||
Loading…
Reference in New Issue