MainSlice적용
getSubCategory작업 관련하여 적용 및 오타수정.
This commit is contained in:
@@ -9,6 +9,7 @@ import { getAuthenticationCode } from "../features/device/deviceSlice";
|
||||
import { getHomeMenu } from "../features/home/homeSlice";
|
||||
import { getMyRecommandedKeyword } from "../features/mypage/myPageSlice";
|
||||
import { getOnSaleInfo } from "../features/onSale/onSaleSlice";
|
||||
import { getSubCategory } from "../features/main/mainSlice";
|
||||
import MainView from "../views/MainView/MainView";
|
||||
import css from "./App.module.less";
|
||||
|
||||
@@ -21,6 +22,15 @@ function AppBase(props) {
|
||||
dispatch(getOnSaleInfo({ categoryIncFlag: "Y", lgCatCd: "" }));
|
||||
dispatch(getBrandList());
|
||||
dispatch(getMyRecommandedKeyword());
|
||||
dispatch(
|
||||
getSubCategory({
|
||||
lgCatCd: "1000",
|
||||
patnrIdList: "",
|
||||
pageSize: "",
|
||||
tabType: "",
|
||||
filterType: "",
|
||||
})
|
||||
);
|
||||
}, [dispatch]);
|
||||
|
||||
return <MainView />;
|
||||
|
||||
@@ -30,6 +30,9 @@ export const URLS = {
|
||||
|
||||
//my-page controller
|
||||
GET_MY_RECOMMANDED_KEYWORD: "/lgsp/v1/mypage/reckeyword.lge",
|
||||
|
||||
//main controller
|
||||
GET_SUB_CATEGORY: "/lgsp/v1/main/subcategory.lge",
|
||||
};
|
||||
|
||||
export const getUrl = (endStr) => {
|
||||
|
||||
@@ -34,7 +34,6 @@ export const getSubCategory = createAsyncThunk(
|
||||
);
|
||||
}
|
||||
);
|
||||
0;
|
||||
|
||||
const initialState = {
|
||||
subCategoryData: {},
|
||||
|
||||
@@ -8,6 +8,7 @@ import homeReducer from "../features/home/homeSlice";
|
||||
import myPageReducer from "../features/mypage/myPageSlice";
|
||||
import onSaleReducer from "../features/onSale/onSaleSlice";
|
||||
import panelsReducer from "../features/panels/panelsSlice";
|
||||
import mainReducer from "../features/main/mainSlice";
|
||||
|
||||
export const store = configureStore({
|
||||
reducer: {
|
||||
@@ -19,5 +20,6 @@ export const store = configureStore({
|
||||
onSale: onSaleReducer,
|
||||
brand: brandReducer,
|
||||
myPage: myPageReducer,
|
||||
main: mainReducer,
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user