Commit 4b0099a3 by guojuxing

门店分组转移上级门店修改:转移门店逻辑修复

parent f04cdee7
...@@ -147,16 +147,10 @@ public class StoreGroupApiServiceImpl implements StoreGroupApiService { ...@@ -147,16 +147,10 @@ public class StoreGroupApiServiceImpl implements StoreGroupApiService {
tabStoreGroup.setUpdateTime(new Date()); tabStoreGroup.setUpdateTime(new Date());
storeGroupService.update(tabStoreGroup); storeGroupService.update(tabStoreGroup);
//如果上级分组有门店,则新建一个未分组数据,然后把所有门店放进去 //如果上级分组有门店
if (isNeedTransferStore(storeGroupParentId)) { if (isNeedTransferStoreWhenNew(storeGroupParentId)) {
StoreGroupDTO noStoreGroup = new StoreGroupDTO();
noStoreGroup.setEnterpriseId(storeGroupDTO.getEnterpriseId());
noStoreGroup.setGroupLevel(oldStoreGroup.getGroupLevel());
noStoreGroup.setStoreGroupName("未分组门店" + System.currentTimeMillis());
noStoreGroup.setParentStoreGroupId(storeGroupParentId);
ServiceResponse<Integer> noStoreGroupId = save(noStoreGroup);
//转移门店 //转移门店
storeService.updateGroupId(storeGroupParentId, noStoreGroupId.getResult()); storeService.updateGroupId(storeGroupParentId, storeGroupId);
} }
//刷新缓存 //刷新缓存
......
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