...
|
...
|
@@ -5,7 +5,7 @@ import CategoryBService from '../../services/CategoryBService'; |
|
|
import Immutable, {Map} from 'immutable';
|
|
|
const {
|
|
|
SET_TYPE,
|
|
|
SET_PERLOAD_STATUS,
|
|
|
SET_DELAY_EXPOSE_DATA,
|
|
|
|
|
|
GET_CATEGORY_B_LIST_REQUEST,
|
|
|
GET_CATEGORY_B_LIST_SUCCESS,
|
...
|
...
|
@@ -25,10 +25,10 @@ const { |
|
|
} = require('../../constants/actionTypes').default;
|
|
|
|
|
|
|
|
|
export function setPerloadStatus(perload) {
|
|
|
export function setDelayExposeData(delayExposeData) {
|
|
|
return {
|
|
|
type: SET_PERLOAD_STATUS,
|
|
|
payload: perload,
|
|
|
type: SET_DELAY_EXPOSE_DATA,
|
|
|
payload: delayExposeData,
|
|
|
}
|
|
|
}
|
|
|
|
...
|
...
|
@@ -93,7 +93,7 @@ export function fetchSubCategory(categoryId, categoryValue, callback) { |
|
|
currentCateId,
|
|
|
currentCateValue,
|
|
|
cacheSubCateData,
|
|
|
perload,
|
|
|
delayExposeData,
|
|
|
} = categoryB;
|
|
|
|
|
|
//检查缓存是否存在数据,如果不存在则获取
|
...
|
...
|
@@ -103,7 +103,7 @@ export function fetchSubCategory(categoryId, categoryValue, callback) { |
|
|
if (categoryData) {
|
|
|
dispatch(getCategoryBSubDetailFromCache(categoryData));
|
|
|
//曝光从缓存获取的数据
|
|
|
if (perload) {
|
|
|
if (delayExposeData) {
|
|
|
|
|
|
} else {
|
|
|
//曝光从缓存获取的数据
|
...
|
...
|
@@ -195,7 +195,7 @@ export function getCategoryBSubDetail(channel_id, category_id, category_value) { |
|
|
.then(json => {
|
|
|
let payload = parseCategoryBSubDetail(channel_id, category_id, json, categoryB);
|
|
|
dispatch(getCategoryBSubDetailSuccess(payload));
|
|
|
if (categoryB.perload) {
|
|
|
if (categoryB.delayExposeData) {
|
|
|
|
|
|
} else {
|
|
|
//曝光从网络获取的数据
|
...
|
...
|
@@ -331,7 +331,7 @@ export function startExposeData() { |
|
|
currentCateId,
|
|
|
currentCateValue,
|
|
|
cacheSubCateData,
|
|
|
perload,
|
|
|
delayExposeData,
|
|
|
} = categoryB;
|
|
|
|
|
|
//检查缓存是否存在数据,如果不存在则获取
|
...
|
...
|
|