| | |
| | | package cn.gistack.sm.sjztmd.service.impl; |
| | | |
| | | import cn.gistack.sm.sjztmd.dto.TbProjectDTO; |
| | | import cn.gistack.sm.sjztmd.dto.TbProjectIsfillDTO; |
| | | import cn.gistack.sm.sjztmd.entity.AttAdBase; |
| | | import cn.gistack.sm.sjztmd.entity.TbProject; |
| | | import cn.gistack.sm.sjztmd.entity.TbProjectSchedule; |
| | |
| | | import cn.gistack.sm.sjztmd.util.CalculateUtils; |
| | | import cn.gistack.sm.sjztmd.vo.StatisticsPrice; |
| | | import cn.gistack.sm.sjztmd.vo.StatisticsPriceVO; |
| | | import cn.gistack.sm.sjztmd.vo.TbProjectIsfillVO; |
| | | import cn.gistack.sm.sjztmd.vo.TbProjectVO; |
| | | import com.baomidou.dynamic.datasource.annotation.DS; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import java.math.BigDecimal; |
| | | import java.text.ParseException; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Arrays; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | @Service |
| | |
| | | List<StatisticsPriceVO> statisticsPieBar =baseMapper.getStatisticsPieBars(statisticsParams); |
| | | return statisticsPieBar; |
| | | } |
| | | |
| | | @Override |
| | | public void updateallcheck() throws Exception { |
| | | Date now = new Date(); |
| | | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
| | | String today = sdf.format(now); |
| | | |
| | | // 转换为年月格式,用于检查是否为月初 |
| | | String yearMonth = sdf.format(sdf.parse(today).getTime()).substring(0, 7); |
| | | // 检查当前日期是否为月初 |
| | | if (today.startsWith(yearMonth + "-01")) { |
| | | baseMapper.updateallcheck(); |
| | | } else { |
| | | System.out.println("不是月初,不予修改状态"); |
| | | } |
| | | |
| | | } |
| | | |
| | | @Override |
| | | public void updateFill(TbProjectIsfillDTO fil) { |
| | | baseMapper.updateFill(fil); |
| | | } |
| | | |
| | | @Override |
| | | public TbProjectIsfillVO getfill() { |
| | | return baseMapper.getfill(); |
| | | } |
| | | } |