Adjust UI
This commit is contained in:
parent
65265cdbf3
commit
f37ecb513d
|
|
@ -407,11 +407,18 @@ void viewEntityById({
|
|||
final uiState = store.state.uiState;
|
||||
|
||||
if (!state.prefState.isPreviewEnabled && !entityType.isSetting) {
|
||||
editEntity(
|
||||
context: navigatorKey.currentContext,
|
||||
entity: state.getEntityMap(entityType)[entityId],
|
||||
force: force,
|
||||
);
|
||||
final BaseEntity entity = state.getEntityMap(entityType)[entityId];
|
||||
if (entityType.hasViewPage) {
|
||||
viewEntitiesByType(
|
||||
entityType: entity.entityType.relatedTypes.first,
|
||||
filterEntity: entity);
|
||||
} else {
|
||||
editEntity(
|
||||
context: navigatorKey.currentContext,
|
||||
entity: entity,
|
||||
force: force,
|
||||
);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -528,6 +528,9 @@ Reducer<BuiltList<HistoryRecord>> historyReducer = combineReducers([
|
|||
TypedReducer<BuiltList<HistoryRecord>, EditCredit>((historyList, action) =>
|
||||
_addToHistory(historyList,
|
||||
HistoryRecord(id: action.credit.id, entityType: EntityType.credit))),
|
||||
TypedReducer<BuiltList<HistoryRecord>, FilterByEntity>(
|
||||
(historyList, action) => _addToHistory(historyList,
|
||||
HistoryRecord(id: action.entityId, entityType: action.entityType))),
|
||||
]);
|
||||
|
||||
BuiltList<HistoryRecord> _addToHistory(
|
||||
|
|
|
|||
Loading…
Reference in New Issue