Subversion Repositories SmartDukaan

Rev

Blame | Last modification | View Log | RSS feed

package com.spice.profitmandi.dao.entity.dtr;

import java.io.Serializable;
import java.time.LocalDateTime;

import javax.persistence.Column;
import javax.persistence.Convert;
import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

import com.spice.profitmandi.dao.convertor.LocalDateTimeAttributeConverter;

@Entity
@Table(name = "dtr.credit_block_log")
public class CreditBlockLog implements Serializable {

        private static final long serialVersionUID = 1L;

        @Id
        @Column(name = "id", unique = true, updatable = false)
        @GeneratedValue(strategy = GenerationType.IDENTITY)
        private long id;

        @Column(name = "credit_account_id")
        private int creditAccountId;

        @Column(name = "fofo_id")
        private int fofoId;

        @Column(name = "action")
        @Enumerated(EnumType.STRING)
        private CreditBlockAction action;

        @Column(name = "reason")
        private String reason;

        @Column(name = "performed_by")
        private String performedBy;

        @Column(name = "created_on")
        @Convert(converter = LocalDateTimeAttributeConverter.class)
        private LocalDateTime createdOn;

        public long getId() {
                return id;
        }

        public void setId(long id) {
                this.id = id;
        }

        public int getCreditAccountId() {
                return creditAccountId;
        }

        public void setCreditAccountId(int creditAccountId) {
                this.creditAccountId = creditAccountId;
        }

        public int getFofoId() {
                return fofoId;
        }

        public void setFofoId(int fofoId) {
                this.fofoId = fofoId;
        }

        public CreditBlockAction getAction() {
                return action;
        }

        public void setAction(CreditBlockAction action) {
                this.action = action;
        }

        public String getReason() {
                return reason;
        }

        public void setReason(String reason) {
                this.reason = reason;
        }

        public String getPerformedBy() {
                return performedBy;
        }

        public void setPerformedBy(String performedBy) {
                this.performedBy = performedBy;
        }

        public LocalDateTime getCreatedOn() {
                return createdOn;
        }

        public void setCreatedOn(LocalDateTime createdOn) {
                this.createdOn = createdOn;
        }

        @Override
        public String toString() {
                return "CreditBlockLog [id=" + id + ", creditAccountId=" + creditAccountId + ", fofoId=" + fofoId + ", action="
                                + action + ", reason=" + reason + ", performedBy=" + performedBy + ", createdOn=" + createdOn + "]";
        }
}