Commit 442b8c6b by zhiwj

添加门店日志

parent e0be2ec0
......@@ -207,17 +207,19 @@ public class StoreApiServiceImpl implements StoreApiService {
sb.append("门店电话").append("【").append(oldStore.getConactsPhone()).append("】")
.append("变更为【").append(newStore.getConactsPhone()).append("】");
}
if (!CollectionUtils.isEqualCollection(oldStore.getBusinessTimeList(), newStore.getBusinessTimeList())) {
this.storeBusinessTimeService.convertBusinessTime(newStore.getBusinessTimeList());
String oldBusinessTimeShow = oldStore.getBusinessTimeList().stream()
.map(e -> e.getWeekdayShow() + ":" + DateUtil.dateToStr(e.getOpenTime(), DateUtil.FORMAT_MINUTE_TIME) + "~" + DateUtil.dateToStr(e.getCloseTime(), DateUtil.FORMAT_MINUTE_TIME))
.reduce((x, y) -> x + "" + y).orElse("");
String newBusinessTimeShow = newStore.getBusinessTimeList().stream()
.map(e -> e.getWeekdayShow() + ":" + DateUtil.dateToStr(e.getOpenTime(), DateUtil.FORMAT_MINUTE_TIME) + "~" + DateUtil.dateToStr(e.getCloseTime(), DateUtil.FORMAT_MINUTE_TIME))
.reduce((x, y) -> x + "," + y)
.orElse("");
sb.append("营业时间").append("【").append(oldBusinessTimeShow).append("】")
.append("变更为【").append(newBusinessTimeShow).append("】");
if (CollectionUtils.isNotEmpty(oldStore.getBusinessTimeList())) {
if (!CollectionUtils.isEqualCollection(oldStore.getBusinessTimeList(), newStore.getBusinessTimeList())) {
this.storeBusinessTimeService.convertBusinessTime(newStore.getBusinessTimeList());
String oldBusinessTimeShow = oldStore.getBusinessTimeList().stream()
.map(e -> e.getWeekdayShow() + ":" + DateUtil.dateToStr(e.getOpenTime(), DateUtil.FORMAT_MINUTE_TIME) + "~" + DateUtil.dateToStr(e.getCloseTime(), DateUtil.FORMAT_MINUTE_TIME))
.reduce((x, y) -> x + "" + y).orElse("");
String newBusinessTimeShow = newStore.getBusinessTimeList().stream()
.map(e -> e.getWeekdayShow() + ":" + DateUtil.dateToStr(e.getOpenTime(), DateUtil.FORMAT_MINUTE_TIME) + "~" + DateUtil.dateToStr(e.getCloseTime(), DateUtil.FORMAT_MINUTE_TIME))
.reduce((x, y) -> x + "," + y)
.orElse("");
sb.append("营业时间").append("【").append(oldBusinessTimeShow).append("】")
.append("变更为【").append(newBusinessTimeShow).append("】");
}
}
if (StringUtils.isNotBlank(newStore.getBrandIds()) && !StringUtils.equals(newStore.getBrandIds(), oldStore.getBrandIds())) {
List<TabStoreBrand> tabStoreBrands = this.storeBrandService.listStoreBrandByIds(newStore.getBrandIds());
......
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