package com.zhongshu.card.server.core.domain.devices;

import com.zhongshu.card.client.type.DataState;
import com.zhongshu.card.server.core.domain.base.SuperMain;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.data.mongodb.core.mapping.DBRef;
import org.springframework.data.mongodb.core.mapping.Document;

import java.math.BigDecimal;

/**
 * 产品可提供的服务
 *
 * @author TRX
 * @date 2025/1/8
 */
@Data
@Document
@NoArgsConstructor
@AllArgsConstructor
public class DeviceProductProvideServe extends SuperMain {

    @Schema(description = "所属产品")
    @DBRef(lazy = true)
    private DeviceProduct deviceProduct;

    @Schema(description = "所属产品ID")
    private String deviceProductId;

    @Schema(description = "服务名称")
    private String name;

    @Schema(description = "价格")
    private BigDecimal price = BigDecimal.ZERO;

    @Schema(description = "其他参数")
    private Object param;

    @Schema(description = "状态")
    private DataState state = DataState.Enable;
}
