新增菜谱
This commit is contained in:
parent
dde1a45475
commit
8708c17555
|
|
@ -6,6 +6,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
|
|||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.ToString;
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
|
|
@ -39,7 +40,7 @@ public class CookRecipeDetailDTO extends BaseEntity {
|
|||
@ApiModelProperty(value = "启用时间(天)")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "启用时间(天)", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date applyDate;
|
||||
private LocalDate applyDate;
|
||||
|
||||
/** 启用时间(周) */
|
||||
@Excel(name = "启用时间(周)")
|
||||
|
|
|
|||
|
|
@ -155,7 +155,8 @@ public class CookRecipeServiceImpl implements ICookRecipeService {
|
|||
|
||||
private void insertDetailAndDishes(CookRecipeDTO cookRecipeDTO, CookRecipeDateDTO recipeDateDTO, CookRecipeDetailDTO detailDTO) {
|
||||
CookRecipeDetail cookRecipeDetail = new CookRecipeDetail();
|
||||
BeanUtils.copyProperties(recipeDateDTO, detailDTO);
|
||||
detailDTO.setApplyDate(recipeDateDTO.getApplyDate());
|
||||
detailDTO.setApplyWeek(recipeDateDTO.getApplyWeek());
|
||||
BeanUtils.copyProperties(detailDTO, cookRecipeDetail);
|
||||
cookRecipeDetail.setRecipeId(cookRecipeDTO.getRecipeId());
|
||||
if (Objects.isNull(cookRecipeDetail.getApplyDate())) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue