Commit 80723fe8 authored by 332784038@qq.com's avatar 332784038@qq.com Committed by wux

批量修改价格的缓存key格式修改

(cherry picked from commit c286e83a)
parent 3d0f4f0b
......@@ -133,7 +133,7 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
// private ZTestMapper3 zTestMapper;
private static final String PREFIX = "price_batch_update_";
private static final String PREFIX = "price_batch_update:";
private static final Integer DATA_THRESHOLD = 30;
private static final String BATCH_DEL_SCRIPT = "for k,v in pairs(ARGV) do \n " +
......@@ -699,7 +699,7 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
List<Long> dbStepIdList = dbStepList.stream()
.map(ProductPriceStepDO::getId)
.collect(toList());
if (!batchUpdate) {
// if (!batchUpdate) {
List<Long> updateIdList = updateList.stream()
.map(ProductPriceStepDO::getId)
.collect(toList());
......@@ -708,7 +708,7 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
if (CollectionUtil.isNotEmpty(dbIdList)) {
productPriceStepMapper.physicsDeleteById(Joiner.on(",").join(dbIdList));
}
}
// }
insertList1.addAll(updateList);
List<ProductPriceStepSpecialDO> allUpdateStepSpecialList = insertList1.stream()
......@@ -902,15 +902,15 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
.collect(toList());
productPriceStepPackagingMapper.deleteBatchIds(dIdList);
}
if (!batchUpdate) {
List<Long> updateIdList = packagingUpdateList.stream()
// if (!batchUpdate) {
List<Long> updatePackingIdList = packagingUpdateList.stream()
.map(ProductPriceStepPackagingDO::getId)
.collect(toList());
dbPackingIdList.removeAll(updateIdList);
dbPackingIdList.removeAll(updatePackingIdList);
if (CollectionUtil.isNotEmpty(dbPackingIdList)) {
productPriceStepPackagingMapper.physicsDeleteById(Joiner.on(",").join(dbPackingIdList));
}
}
// }
}
private void initBasePackagingPrice(BasePackagingPrice basePackagingPrice, String transportType) {
......
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