Files
todo-backend/src/main/java/com/example/building/entity/Customer.java
Agent 02383f1f3a
All checks were successful
continuous-integration/drone/push Build is passing
feat: 客户支持type字段,按种类过滤
2026-03-29 05:44:42 +00:00

80 lines
1.3 KiB
Java

package com.example.building.entity;
import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;
import java.math.BigDecimal;
import java.time.LocalDateTime;
/**
* 客户实体类
*/
@Data
@TableName("customers")
public class Customer {
@TableId(type = IdType.ASSIGN_UUID)
private String customerId;
/**
* 客户名称
*/
private String name;
/**
* 联系电话
*/
private String phone;
/**
* 客户微信OpenID(用于推送)
*/
private String wechatOpenid;
/**
* 微信昵称
*/
private String wechatNickname;
/**
* 微信头像
*/
private String wechatAvatar;
/**
* 地址
*/
private String address;
/**
* 备注
*/
private String remark;
/**
* 客户种类: customer=顾客, carpenter=木匠, company=装修公司
*/
private String type;
/**
* 累计消费金额
*/
private BigDecimal totalAmount;
/**
* 创建人ID
*/
private String createdBy;
/**
* 最后登录时间(用于订单客户排序)
*/
private LocalDateTime lastLoginAt;
@TableField(fill = FieldFill.INSERT)
private LocalDateTime createdAt;
@TableField(fill = FieldFill.INSERT_UPDATE)
private LocalDateTime updatedAt;
}