Commit 00304f8f by guojuxing

tab_store&tab_store_field_rel&tab_store_region_rel&tab_store_brand_ref own_type改成owner_flag

parent ed21f41a
......@@ -11,7 +11,7 @@ import com.gic.binlog.base.entity.enums.GicRecordType;
import com.gic.message.service.MessageHandler;
import com.gic.message.utils.ListToMapUtil;
import com.gic.redis.data.util.RedisUtil;
import com.gic.store.constant.StoreOwnTypeEnum;
import com.gic.store.constant.StoreOwnerFlagEnum;
import com.gic.store.dto.StoreDTO;
import com.gic.store.dto.StoreSearchDTO;
import com.gic.store.dto.StoreWidgetDTO;
......@@ -78,7 +78,7 @@ public class StoreCustomMessageHandler implements MessageHandler {
ServiceResponse<List<StoreDTO>> listStoreResponse = this.storeApiService.listStoreByStoreInfoId(storeInfoId);
List<StoreDTO> listStore = listStoreResponse.getResult();
for(StoreDTO storeDTO : listStore){
if(StoreOwnTypeEnum.OWNER.getCode() == storeDTO.getOwnType()){
if(StoreOwnerFlagEnum.OWNER.getCode() == storeDTO.getOwnerFlag()){
this.storeIndexRefreshHandler.refreshStoreIndex(storeDTO.getEnterpriseId(), storeDTO.getStoreId());
}
}
......
......@@ -10,7 +10,7 @@ import com.gic.binlog.base.entity.GicRecord;
import com.gic.binlog.base.entity.enums.GicRecordType;
import com.gic.message.service.MessageHandler;
import com.gic.message.utils.ListToMapUtil;
import com.gic.store.constant.StoreOwnTypeEnum;
import com.gic.store.constant.StoreOwnerFlagEnum;
import com.gic.store.dto.StoreDTO;
import com.gic.store.dto.StoreSearchDTO;
import com.gic.store.dto.StoreWidgetDTO;
......@@ -61,7 +61,7 @@ public class StoreInfoMessageHandler implements MessageHandler {
ServiceResponse<List<StoreDTO>> listStoreResponse = this.storeApiService.listStoreByStoreInfoId(storeInfoId);
List<StoreDTO> listStore = listStoreResponse.getResult();
for(StoreDTO storeDTO : listStore){
if(storeDTO.getOwnType() == StoreOwnTypeEnum.OWNER.getCode()){
if(storeDTO.getOwnerFlag() == StoreOwnerFlagEnum.OWNER.getCode()){
if(Integer.valueOf(fieldMap.get("new_status").getValue()) == 0){
this.storeApiService.deleteStoreFromEs(storeDTO.getEnterpriseId(), storeDTO.getStoreId());
}else {
......
package com.gic.message.service.impl;
import com.gic.api.base.commons.Page;
import com.gic.api.base.commons.ServiceResponse;
import com.gic.auth.constant.AuthModeEnum;
import com.gic.auth.dto.ResourceDTO;
import com.gic.auth.dto.ResourceGroupDTO;
import com.gic.auth.dto.UnionEnterpriseResourceDTO;
import com.gic.auth.service.ResourceApiService;
import com.gic.auth.service.ResourceGroupApiService;
import com.gic.auth.service.UnionEnterpriseApiService;
import com.gic.binlog.base.entity.GicField;
import com.gic.binlog.base.entity.GicRecord;
import com.gic.binlog.base.entity.enums.GicRecordType;
import com.gic.enterprise.dto.union.UnionEnterpriseAuthDTO;
import com.gic.enterprise.dto.union.UnionEnterpriseAuthListDTO;
import com.gic.enterprise.service.UnionEnterpriseAuthApiService;
import com.gic.message.service.MessageHandler;
import com.gic.message.utils.ListToMapUtil;
import com.gic.store.constant.StoreOwnTypeEnum;
import com.gic.store.constant.StoreOwnerFlagEnum;
import com.gic.store.dto.StoreDTO;
import com.gic.store.dto.StoreSearchDTO;
import com.gic.store.dto.StoreWidgetDTO;
......@@ -80,7 +74,7 @@ public class StoreMessageHandler implements MessageHandler {
storeId = Integer.valueOf(fieldMap.get("store_id").getValue());
storeInfoId = Integer.valueOf(fieldMap.get("store_info_id").getValue());
this.storeIndexRefreshHandler.refreshStoreIndex(enterpriseId, storeId);
Integer ownType = Integer.valueOf(fieldMap.get("own_type").getValue());
Integer ownerFlag = Integer.valueOf(fieldMap.get("owner_flag").getValue());
this.dealStoreChange(enterpriseId, storeId, storeInfoId, GicRecordType.INSERT.value());
}
if(GicRecordType.UPDATE.value() == value.getRecordType().value()) {
......@@ -100,7 +94,7 @@ public class StoreMessageHandler implements MessageHandler {
storeId = Integer.valueOf(fieldMap.get("store_id").getValue());
storeInfoId = Integer.valueOf(fieldMap.get("store_info_id").getValue());
this.storeApiService.deleteStoreFromEs(enterpriseId, storeId);
Integer ownType = Integer.valueOf(fieldMap.get("own_type").getValue());
Integer ownerFlag = Integer.valueOf(fieldMap.get("owner_flag").getValue());
this.dealStoreChange(enterpriseId, storeId, storeInfoId, GicRecordType.DELETE.value());
}
}
......@@ -130,7 +124,7 @@ public class StoreMessageHandler implements MessageHandler {
storeSearchDTO.setStoreIds(String.valueOf(storeId));
storeSearchDTO.setSearchJson(storeWidgetDTO.getSearchParam());
storeSearchDTO.setEnterpriseId(enterpriseId);
storeSearchDTO.setOwnType(StoreOwnTypeEnum.OWNER.getCode());
storeSearchDTO.setOwnerFlag(StoreOwnerFlagEnum.OWNER.getCode());
Long count = this.storeApiService.queryStoreCountFromEs(storeSearchDTO).getResult();
boolean ownExist = count > 0 ? true : false;
Integer unionEnterpriseId = dto.getUnionEnterpriseId();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment