package com.aip.gateway.api.entity;

import com.aip.gateway.api.dto.LinkedSystemDto;
import lombok.Builder;
import lombok.Data;
import lombok.ToString;

import java.time.LocalDateTime;

@Data
@Builder
@ToString
public class TbLinkedSystem {

    private int systemId;
    private String systemName;
    private String systemDesc;
    private LocalDateTime createdAt;
    private LocalDateTime deletedAt;
    private boolean useYn;

    public LinkedSystemDto toDto() {
        return LinkedSystemDto.builder()
                .systemId(this.systemId)
                .systemName(this.systemName)
                .createdAt(this.createdAt)
                .useYn(this.useYn)
                .systemDesc(this.systemDesc)
                .deletedAt(this.deletedAt)
                .build();
    }
}
