add rag-view frontend
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
import fetchGetChat from "../../fetch-async/fetchGetChat";
|
||||
|
||||
export const buildGetChatExtraReducers = (builder) => {
|
||||
builder
|
||||
.addCase(fetchGetChat.fulfilled, (state, action) => {
|
||||
const chat = action.payload;
|
||||
|
||||
if (chat) {
|
||||
state.messages = chat.history || [];
|
||||
}
|
||||
})
|
||||
.addCase(fetchGetChat.rejected, (_state, action) => {
|
||||
console.log("fetchGetChat error:", action.payload?.status);
|
||||
});
|
||||
};
|
||||
Reference in New Issue
Block a user