mchades commented on code in PR #12900:
URL: https://github.com/apache/gravitino/pull/12900#discussion_r4291245773


##########
web-v2/web/src/lib/store/metalakes/index.js:
##########
@@ -2364,6 +2535,25 @@ export const appMetalakesSlice = createSlice({
     currentEntityPolicies: []
   },
   reducers: {
+    setActiveCatalogEntity(state, action) {
+      const key = catalogEntityKey(action.payload)
+      const schemaKey = action.payload.schema ? 
semanticModelSchemaKey(action.payload) : null
+      if (state.activeSemanticModelSchema !== schemaKey) state.semanticModels 
= []
+      state.activeSemanticModelSchema = schemaKey
+      if (state.activeCatalogEntity === key) return
+      state.activeCatalogEntity = key
+      state.activatedDetails = null

Review Comment:
   [P2] Version-route saves still leave the parent header stale on `2b3242275`. 
Opening `...&model=forecast&version=0` now loads correctly, but changing the 
parent model's comment through the title's Edit action saves successfully and 
leaves the old comment displayed. I reproduced this in Chrome against the local 
server and verified that the refresh GET returned the new value. A regression 
using the real thunk/reducer passes for the model URL and fails for the version 
URL.
   
   `updateModel(init: true)` refreshes via `getModelDetails({ init, ..., model 
})` without `version`, so `isVisible` rejects its model key against the active 
version key. Please carry the current version identity through the save/refresh 
path, or explicitly allow a parent-model refresh for its active version while 
still rejecting other models. Cover editing comment/properties from a version 
URL.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to