فهرست منبع

fix: ensure view access control state reloads when editing

Add key prop to ViewModal to force remount when editing different views,
ensuring useState initializers run again to load the saved access control
settings from the view's settings object.
Fszontagh 6 ماه پیش
والد
کامیت
1999dacc11
1فایلهای تغییر یافته به همراه1 افزوده شده و 0 حذف شده
  1. 1 0
      webui/src/pages/Views.tsx

+ 1 - 0
webui/src/pages/Views.tsx

@@ -997,6 +997,7 @@ function Views() {
       {/* Modals */}
       {(showCreateModal || editingView) && (
         <ViewModal
+          key={editingView?.id || 'new'}
           view={editingView}
           collections={collections}
           workspaceId={currentWorkspace.id}