Commit e6b961be by fudahua

企业门店初始化

parent 7e750ded
......@@ -323,8 +323,8 @@ public class WxEnterpriseRelatedApiServiceImpl implements WxEnterpriseRelatedApi
@Override
public void flushBindStoreByDelayMq(String message) {
logger.info("刷新绑定门店:{}", message);
FlushStoreMqDTO flushStoreMqDTO = JSONObject.parseObject(message, FlushStoreMqDTO.class);
logger.info("刷新绑定门店队列开始:{}", message);
FlushStoreMqDTO flushStoreMqDTO = JSONObject.parseObject(message, FlushStoreMqDTO.class);
ServiceResponse response = this.flushBindStoreByEnterpriseId(flushStoreMqDTO.getEnterpriseId(), flushStoreMqDTO.getWxEnterpriseId()
, flushStoreMqDTO.getOptStaffId(), flushStoreMqDTO.getChannalCode());
logger.info("刷新绑定结束:{}", JSONObject.toJSONString(response));
......
import com.alibaba.fastjson.JSONObject;
import com.gic.commons.util.GICMQClientUtil;
import com.gic.haoban.base.api.common.ServiceResponse;
import com.gic.haoban.manage.api.dto.FlushStoreMqDTO;
import com.gic.haoban.manage.api.dto.MaterialDTO;
import com.gic.haoban.manage.api.enums.ChannelCodeEnum;
import com.gic.haoban.manage.api.service.*;
......@@ -58,11 +59,23 @@ public class ServiceTest {
@Test
public void test11() {
List<String> ids = new ArrayList<>();
ids.add("8f5ddb9df0a54332acfa2d5804e90c64");
List<MaterialDTO> materialDTOS = materialApiService.listMaterialByIds(ids);
FlushStoreMqDTO flushStoreMqDTO = new FlushStoreMqDTO();
flushStoreMqDTO.setEnterpriseId("testEnteroriseId");
int i = 2;
while (i-- > 0) {
try {
Thread.sleep(1000);
} catch (InterruptedException e) {
e.printStackTrace();
}
wxEnterpriseRelatedApiService.flushBindStoreToDelayMq("testEnteroriseId", flushStoreMqDTO);
}
System.out.println(JSONObject.toJSONString(materialDTOS));
// List<String> ids = new ArrayList<>();
// ids.add("8f5ddb9df0a54332acfa2d5804e90c64");
// List<MaterialDTO> materialDTOS = materialApiService.listMaterialByIds(ids);
//
// System.out.println(JSONObject.toJSONString(materialDTOS));
// ServiceResponse response = wxEnterpriseRelatedApiService.flushBindStoreByEnterpriseId("ff8080815dacd3a2015dacd3ef5c0000"
// , "ca66a01b79474c40b3e7c7f93daf1a3b", "-1", ChannelCodeEnum.SYNC_UNBIND.getCode());
// System.out.println(JSONObject.toJSONString(response));
......
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