|
@@ -32,6 +32,7 @@ import org.springframework.stereotype.Service;
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
|
import java.math.BigDecimal;
|
|
|
+import java.util.ArrayList;
|
|
|
import java.util.Date;
|
|
|
import java.util.List;
|
|
|
import java.util.Map;
|
|
@@ -124,6 +125,28 @@ public class MesNoticeServiceImpl extends SuperServiceImpl<MesNoticeMapper, MesN
|
|
|
return baseMapper.pageList(page, queryWrapper);
|
|
|
}
|
|
|
|
|
|
+ @Transactional(rollbackFor = Exception.class)
|
|
|
+ @Override
|
|
|
+ public boolean addNoticeMore(List<MesNotice> models) {
|
|
|
+ baseMapper.insertBatchSomeColumn(models);
|
|
|
+
|
|
|
+ List<MesNoticeLog> mesNoticeLogs = new ArrayList<>();
|
|
|
+ for (MesNotice model : models) {
|
|
|
+ MesNoticeLog build = MesNoticeLog.builder().build();
|
|
|
+
|
|
|
+ BeanUtils.copyProperties(model, build);
|
|
|
+ build.setNoticeId(model.getId());
|
|
|
+ build.setId(null);
|
|
|
+
|
|
|
+ mesNoticeLogs.add(build);
|
|
|
+ }
|
|
|
+ mesNoticeLogMapper.insertBatchSomeColumn(mesNoticeLogs);
|
|
|
+
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ @Transactional(rollbackFor = Exception.class)
|
|
|
@Override
|
|
|
public boolean addNotice(MesNotice model, double plmenge) {
|
|
|
BaseContextHandler.setTenant("0000");
|