package com.gameplatform.server.model.dto.account;

import io.swagger.v3.oas.annotations.media.Schema;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;

@Schema(description = "账户更新请求")
public class AccountUpdateRequest {
    @Schema(description = "用户类型", example = "AGENT", allowableValues = {"ADMIN", "AGENT"})
    @Pattern(regexp = "^(ADMIN|AGENT)$", message = "userType 只能是 ADMIN 或 AGENT")
    private String userType;

    @Schema(description = "用户名", example = "newuser")
    @Size(min = 3, max = 64, message = "用户名长度必须在3-64字符之间")
    @Pattern(regexp = "^[a-zA-Z0-9_]+$", message = "用户名只能包含字母、数字、下划线")
    private String username;

    @Schema(description = "账户状态", example = "ENABLED", allowableValues = {"ENABLED", "DISABLED"})
    @Pattern(regexp = "^(ENABLED|DISABLED)$", message = "status 只能是 ENABLED 或 DISABLED")
    private String status;

    @Schema(description = "积分余额（仅AGENT类型有效）", example = "100")
    private Long pointsBalance;

    public String getUserType() { return userType; }
    public void setUserType(String userType) { this.userType = userType; }

    public String getUsername() { return username; }
    public void setUsername(String username) { this.username = username; }

    public String getStatus() { return status; }
    public void setStatus(String status) { this.status = status; }

    public Long getPointsBalance() { return pointsBalance; }
    public void setPointsBalance(Long pointsBalance) { this.pointsBalance = pointsBalance; }
}

