存酒接口
This commit is contained in:
@@ -1,10 +1,14 @@
|
||||
|
||||
package com.czg.account.dto;
|
||||
package com.czg.account.dto.storage;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import com.alibaba.fastjson2.annotation.JSONField;
|
||||
import java.io.Serial;
|
||||
|
||||
import com.czg.validator.group.UpdateGroup;
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
@@ -20,26 +24,27 @@ import lombok.NoArgsConstructor;
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public class ShopStorageGoodDTO implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
public class ShopStorageGoodDTO {
|
||||
|
||||
@NotNull(message = "id不为空", groups = UpdateGroup.class)
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 酒品名
|
||||
*/
|
||||
@NotEmpty(message = "酒品名不为空")
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 图片地址
|
||||
*/
|
||||
@NotEmpty(message = "酒品名不为空")
|
||||
private String imgUrl;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@NotEmpty(message = "单位不为空")
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
@@ -47,22 +52,9 @@ public class ShopStorageGoodDTO implements Serializable {
|
||||
*/
|
||||
private Integer period;
|
||||
|
||||
/**
|
||||
* 0:未删除;1:已删除
|
||||
*/
|
||||
private Integer isDel;
|
||||
|
||||
@JSONField(format = "yyyy-MM-dd HH:mm:ss")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
/**
|
||||
* 0:手动;1:商品;
|
||||
*/
|
||||
private Integer source;
|
||||
|
||||
/**
|
||||
* 商户Id
|
||||
*/
|
||||
private Long shopId;
|
||||
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
package com.czg.account.service;
|
||||
|
||||
import com.czg.account.dto.storage.ShopStorageGoodDTO;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
import com.czg.account.entity.ShopStorageGood;
|
||||
|
||||
@@ -11,4 +12,7 @@ import com.czg.account.entity.ShopStorageGood;
|
||||
*/
|
||||
public interface ShopStorageGoodService extends IService<ShopStorageGood> {
|
||||
|
||||
Boolean edit(Long shopId, ShopStorageGoodDTO shopStorageGoodDTO);
|
||||
|
||||
Boolean saveInfo(Long shopId, ShopStorageGoodDTO shopStorageGoodDTO);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user