| | |
| | | package com.aps.core.domain; |
| | | |
| | | import com.aps.common.core.web.domain.BaseEntity; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serial; |
| | |
| | | * @date 2025-05-08 |
| | | */ |
| | | @Data |
| | | public class ApsPlateOrderPlanDate |
| | | public class ApsPlateOrderPlanDate extends BaseEntity |
| | | { |
| | | @Serial |
| | | private static final long serialVersionUID = 1L; |
| | |
| | | private List<Long> planIds; |
| | | |
| | | /** 自定义日期 */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Timestamp customDate; |
| | | } |
| | |
| | | @Override |
| | | public void updatePlanDate(ApsPlateOrderPlanDate apsPlateOrderPlanDate) { |
| | | if (apsPlateOrderPlanDate.getIsCustom()) { |
| | | apsPlateOrderPlanDate.setUpdateBy(SecurityUtils.getUsername()); |
| | | apsPlateOrderPlanManagerMapper.updatePlanDateByCustom(apsPlateOrderPlanDate); |
| | | } else { |
| | | List<ApsPlateOrderPlanRequireDate> planRequireDates = apsPlateOrderPlanManagerMapper.selectPlanRequireIds(apsPlateOrderPlanDate.getPlanIds()); |
| | |
| | | |
| | | <update id="updatePlanDateByCustom" parameterType="ApsPlateOrderPlanDate"> |
| | | update aps_plate_plan set |
| | | custom_time = #{planRequireDate.customDate}, |
| | | update_by = #{planRequireDate.updateBy}, |
| | | custom_time = #{customDate}, |
| | | update_by = #{updateBy}, |
| | | update_time = now() |
| | | where id in |
| | | <foreach collection="planRequireDate.planIds" item="id" open="(" separator="," close=")"> |
| | | <foreach collection="planIds" item="id" open="(" separator="," close=")"> |
| | | #{id} |
| | | </foreach> |
| | | </update> |