Commit ed405e6e by zhiwj

修改bug

parent 7bd23a7a
......@@ -64,5 +64,5 @@ public interface TabStoreBusinessTimeMapper {
int deleteAllByEnterpriseId(@Param("enterpriseId") Integer enterpriseId);
int deleteBystoreInfoIds(@Param("enterpriseId") Integer enterpriseId, @Param("storeInfoIdList") List<Integer> storeIdList);
int deleteBystoreInfoIds(@Param("enterpriseId") Integer enterpriseId, @Param("storeInfoIdList") List<Integer> storeInfoIdList);
}
\ No newline at end of file
......@@ -79,7 +79,7 @@ public interface TabStoreInfoMapper {
int updateAllStoreBrand(@Param("enterpriseId") Integer enterpriseId, @Param("value") String value);
int updateStoreBrandBystoreInfoIds(@Param("enterpriseId") Integer enterpriseId, @Param("value") String value, @Param("storeInfoIdList") List<Integer> storeIdList);
int updateStoreBrandBystoreInfoIds(@Param("enterpriseId") Integer enterpriseId, @Param("value") String value, @Param("storeInfoIdList") List<Integer> storeInfoIdList);
StoreDTO getByStoreNameAndStoreCode(@Param("enterpriseId") Integer enterpriseId,@Param("storeName") String storeName, @Param("storeCode") String storeCode);
......
......@@ -22,20 +22,20 @@ public class StoreBrandUpdateStrategyImpl implements BulkUpdateStoreStrtegy {
private StoreBrandService storeBrandService;
@Override
public int bulkUpdateStore(String storeIds, Integer enterpriseId, String value, StoreService storeService, Integer operatorId, String operatorName) {
int i = storeService.bulkUpdateStoreBrands(storeIds, enterpriseId, value);
public int bulkUpdateStore(String storeInfoIds, Integer enterpriseId, String value, StoreService storeService, Integer operatorId, String operatorName) {
int i = storeService.bulkUpdateStoreBrands(storeInfoIds, enterpriseId, value);
if (i > 0) {
List<Integer> storeIdList;
if ("all".equals(storeIds)) {
if ("all".equals(storeInfoIds)) {
storeIdList = storeService.listAllStoreId(enterpriseId);
} else {
storeIdList = new ArrayList<>();
String[] storeIdArr = storeIds.split(",");
String[] storeIdArr = storeInfoIds.split(",");
for (String s : storeIdArr) {
storeIdList.add(Integer.valueOf(s));
}
}
List<TabStoreBrand> storeBrandList = storeBrandService.listStoreBrandByIds(storeIds);
List<TabStoreBrand> storeBrandList = storeBrandService.listStoreBrandByIds(storeInfoIds);
String content = Optional.ofNullable(storeBrandList).orElse(Collections.emptyList()).stream().map(TabStoreBrand::getStoreBrandName).reduce((x, y) -> x + "," + y).orElse("");
storeLogService.saveBulkStoreInfoLog(storeIdList, enterpriseId, operatorId, operatorName, "门店品牌变更为【" + content + "】");
}
......
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