思迅查询去除淘汰商品
This commit is contained in:
parent
5891ecd7c0
commit
bb709ab69d
@ -98,6 +98,7 @@ public class DynamicTaskScheduler {
|
|||||||
sxDataService.SyncCategory(dataBaseInfo,commentModel);
|
sxDataService.SyncCategory(dataBaseInfo,commentModel);
|
||||||
sxDataService.SyncGoods(dataBaseInfo,commentModel);//todo 暂时同步全部的商品如果后期修改,需要增加服务器的字段
|
sxDataService.SyncGoods(dataBaseInfo,commentModel);//todo 暂时同步全部的商品如果后期修改,需要增加服务器的字段
|
||||||
sxDataService.SyncVipList(dataBaseInfo,commentModel);
|
sxDataService.SyncVipList(dataBaseInfo,commentModel);
|
||||||
|
sxDataService.syncAtiveShops(dataBaseInfo,commentModel);
|
||||||
isRuning=false;
|
isRuning=false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -38,7 +38,16 @@ public class WebController {
|
|||||||
public void syncCategory(){
|
public void syncCategory(){
|
||||||
log.info("syncCategory");
|
log.info("syncCategory");
|
||||||
//sxDataService.getAppSign();
|
//sxDataService.getAppSign();
|
||||||
sxDataService.SyncCategory(new DataBaseInfo(),sxDataService.getCommentModel());
|
CommentModel commentModel= sxDataService.getCommentModel();
|
||||||
|
DataBaseInfo dataBaseInfo=sxDataService.getDataBaseInfo(commentModel);
|
||||||
|
if(dataBaseInfo==null){
|
||||||
|
log.error("syncGoods dataBaseInfo is null");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if(ObjectUtil.isNotEmpty(dataBaseInfo.getRefreshTime())){
|
||||||
|
commentModel.setSyncTime(DateUtil.formatDateTime(dataBaseInfo.getRefreshTime()));
|
||||||
|
}
|
||||||
|
sxDataService.SyncCategory(dataBaseInfo,sxDataService.getCommentModel());
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequestMapping("/syncGoods")
|
@RequestMapping("/syncGoods")
|
||||||
|
|||||||
@ -24,7 +24,7 @@ import java.util.*;
|
|||||||
public class SxDataDao extends BaseDao{
|
public class SxDataDao extends BaseDao{
|
||||||
|
|
||||||
private final static String T_BD_ITEM_CLS="t_bd_item_cls";//商品分类
|
private final static String T_BD_ITEM_CLS="t_bd_item_cls";//商品分类
|
||||||
private final static String T_BD_ITEM_INFO="t_bd_item_info";//商品表
|
private final static String T_BD_ITEM_INFO="t_bd_item_info b";//商品表
|
||||||
private final static String T_RM_VIP_INFO="t_rm_vip_info";//会员表
|
private final static String T_RM_VIP_INFO="t_rm_vip_info";//会员表
|
||||||
|
|
||||||
private final static String ITEM_CLSNO="item_clsno";//商品分类排序字段
|
private final static String ITEM_CLSNO="item_clsno";//商品分类排序字段
|
||||||
|
|||||||
@ -295,7 +295,8 @@ public class SxDataServiceImp extends SxDataAbstService implements SxDataService
|
|||||||
* @param commentModel
|
* @param commentModel
|
||||||
*/
|
*/
|
||||||
private void syncAllGoods(DataBaseInfo dataBaseInfo, CommentModel commentModel){
|
private void syncAllGoods(DataBaseInfo dataBaseInfo, CommentModel commentModel){
|
||||||
String where="where 1=1";
|
//String where="where 1=1";
|
||||||
|
String where="where b.status='1'";
|
||||||
Integer total =0;
|
Integer total =0;
|
||||||
String parentId=getAndCacheTree(dataBaseInfo,dataBaseInfo.getCategoryName());//加载缓存用的
|
String parentId=getAndCacheTree(dataBaseInfo,dataBaseInfo.getCategoryName());//加载缓存用的
|
||||||
if(DicEnum.SYNCTYPE_02.getCode().equals(dataBaseInfo.getSyncType())){
|
if(DicEnum.SYNCTYPE_02.getCode().equals(dataBaseInfo.getSyncType())){
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user