(force) Update project: Added 60 new features and made various changes
{warning: this all chnaged}
This commit is contained in:
23
src/redux/slices/isPaymentGateway.ts
Normal file
23
src/redux/slices/isPaymentGateway.ts
Normal file
@@ -0,0 +1,23 @@
|
||||
import { createSlice, PayloadAction } from "@reduxjs/toolkit";
|
||||
|
||||
interface isPaymentGatewayState {
|
||||
isPaymentGateway: boolean;
|
||||
}
|
||||
|
||||
const initialState: isPaymentGatewayState = {
|
||||
isPaymentGateway: true,
|
||||
};
|
||||
|
||||
const isPaymentGatewaySlice = createSlice({
|
||||
name: "isPaymentGateway",
|
||||
initialState,
|
||||
reducers: {
|
||||
setIsPaymentGateway: (state, action: PayloadAction<boolean>) => {
|
||||
state.isPaymentGateway = action.payload;
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
export const { setIsPaymentGateway } = isPaymentGatewaySlice.actions;
|
||||
|
||||
export default isPaymentGatewaySlice.reducer;
|
||||
@@ -16,6 +16,7 @@ import {
|
||||
import tokenReducer from "./slices/token";
|
||||
import configId from "./slices/configId";
|
||||
import categoryId from "./slices/categoryId";
|
||||
import isPaymentGateway from "./slices/isPaymentGateway";
|
||||
|
||||
// Encryption settings
|
||||
const secretKey = "token-encrypt-api";
|
||||
@@ -47,6 +48,7 @@ const store = configureStore({
|
||||
token: persistedTokenReducer,
|
||||
configIdState: configId,
|
||||
categoryIdState: categoryId,
|
||||
isPaymentGatewayState: isPaymentGateway,
|
||||
},
|
||||
middleware: (getDefaultMiddleware) =>
|
||||
getDefaultMiddleware({
|
||||
|
||||
Reference in New Issue
Block a user