Skip to content

Commit

Permalink
Revert "enable cloning in SimpleEditMode
Browse files Browse the repository at this point in the history
This change break DCD GUI

A requested clone action has to be set as _new=True.
However in the _get_render_settings() a new entry was hard reset to a new default entry and ignoring a possible cloned entry.

Change-Id: I23cc0024d11cf2991ef9678774bb4674f709407c"

This reverts commit 8867ff0.
  • Loading branch information
s-kipnis committed Feb 7, 2025
1 parent f82d837 commit c1dffc5
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions cmk/gui/wato/pages/_simple_modes.py
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,6 @@ def _from_vars(self, ident_var: str = "ident") -> None:
)

self._new = True
self._clone = self._default_id()
self._ident = None
self._entry = self._clone_entry(entry)
return
Expand Down Expand Up @@ -802,13 +801,10 @@ def _get_render_settings(self) -> tuple[Any, DataOrigin, DoValidate]:
True,
)

if self._new and not self._clone:
if self._new:
# New form, no validation
return DEFAULT_VALUE, DataOrigin.DISK, False

if self._clone:
self._ident = self._clone

# Existing entry from disk
catalog_converter = self._get_catalog_converter()

Expand Down

0 comments on commit c1dffc5

Please sign in to comment.