Merge branch 'master' into salman-etl
This commit is contained in:
commit
b459e34ede
@ -1,19 +1,12 @@
|
||||
package com.jasamedika.medifirst2000.dao;
|
||||
|
||||
import org.springframework.data.repository.PagingAndSortingRepository;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import com.jasamedika.medifirst2000.entities.Kecamatan;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
/**
|
||||
* Repository class for Kecamatan
|
||||
*
|
||||
* @author Askur
|
||||
*/
|
||||
@Repository("KecamatanDao")
|
||||
public interface KecamatanDao extends PagingAndSortingRepository<Kecamatan, Integer> {
|
||||
// custom query
|
||||
|
||||
|
||||
|
||||
public interface KecamatanDao extends JpaRepository<Kecamatan, Integer> {
|
||||
}
|
||||
|
||||
@ -1,18 +1,12 @@
|
||||
package com.jasamedika.medifirst2000.dao;
|
||||
|
||||
import org.springframework.data.repository.PagingAndSortingRepository;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import com.jasamedika.medifirst2000.entities.Propinsi;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
/**
|
||||
* Repository class for Pegawai
|
||||
*
|
||||
* @author Askur
|
||||
*/
|
||||
@Repository("PropinsiDao")
|
||||
public interface PropinsiDao extends PagingAndSortingRepository<Propinsi, Integer> {
|
||||
// custom query
|
||||
|
||||
|
||||
public interface PropinsiDao extends JpaRepository<Propinsi, Integer> {
|
||||
}
|
||||
|
||||
@ -1,169 +1,87 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.persistence.CascadeType;
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.FetchType;
|
||||
import javax.persistence.JoinColumn;
|
||||
import javax.persistence.ManyToOne;
|
||||
import javax.persistence.OneToMany;
|
||||
import javax.persistence.Table;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.annotations.Fetch;
|
||||
import org.hibernate.annotations.FetchMode;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import com.fasterxml.jackson.annotation.JsonManagedReference;
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import org.hibernate.envers.Audited;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
import static javax.persistence.FetchType.LAZY;
|
||||
|
||||
/**
|
||||
* class DesaKelurahan
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
@Entity // @Audited
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "DesaKelurahan_M")
|
||||
@JsonIgnoreProperties({ "hibernateLazyInitializer", "handler" })
|
||||
public class DesaKelurahan extends BaseMaster {
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.desakelurahan_m_id_seq")
|
||||
@SequenceGenerator(name = "public.desakelurahan_m_id_seq", sequenceName = "public.desakelurahan_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
@NotNull(message = "Kd Desa Kelurahan tidak boleh kosong")
|
||||
@Column(name = "KdDesaKelurahan", nullable = false)
|
||||
@Caption(value = "Kode Desa Kelurahan")
|
||||
private Integer kdDesaKelurahan;
|
||||
|
||||
public void setKdDesaKelurahan(Integer kdDesaKelurahan) {
|
||||
this.kdDesaKelurahan = kdDesaKelurahan;
|
||||
}
|
||||
|
||||
public Integer getKdDesaKelurahan() {
|
||||
return this.kdDesaKelurahan;
|
||||
}
|
||||
|
||||
@ManyToOne(fetch = FetchType.LAZY)
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@Fetch(FetchMode.JOIN)
|
||||
@JoinColumn(name = "ObjectKecamatanFk")
|
||||
@NotNull(message = "Kd Kecamatan tidak boleh kosong")
|
||||
|
||||
@Caption(value = "Object Kecamatan")
|
||||
private Kecamatan kecamatan;
|
||||
|
||||
public void setKecamatan(Kecamatan kecamatan) {
|
||||
this.kecamatan = kecamatan;
|
||||
}
|
||||
|
||||
public Kecamatan getKecamatan() {
|
||||
return this.kecamatan;
|
||||
}
|
||||
|
||||
@Column(name = "ObjectKecamatanFk", insertable = false, updatable = false)
|
||||
private Integer kecamatanId;
|
||||
|
||||
@ManyToOne
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectKotaKabupatenFk")
|
||||
@NotNull(message = "Kd Kota Kabupaten tidak boleh kosong")
|
||||
@Caption(value = "Object Kota Kabupaten")
|
||||
private KotaKabupaten kotaKabupaten;
|
||||
|
||||
public void setKotaKabupaten(KotaKabupaten kotaKabupaten) {
|
||||
this.kotaKabupaten = kotaKabupaten;
|
||||
}
|
||||
|
||||
public KotaKabupaten getKotaKabupaten() {
|
||||
return this.kotaKabupaten;
|
||||
}
|
||||
|
||||
@Column(name = "ObjectKotaKabupatenFk", insertable = false, updatable = false, nullable = false)
|
||||
private Integer kotaKabupatenId;
|
||||
|
||||
@ManyToOne
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectPropinsiFk")
|
||||
@NotNull(message = "Kd Propinsi tidak boleh kosong")
|
||||
|
||||
@Caption(value = "Object Propinsi")
|
||||
private Propinsi propinsi;
|
||||
|
||||
public void setPropinsi(Propinsi propinsi) {
|
||||
this.propinsi = propinsi;
|
||||
}
|
||||
|
||||
public Propinsi getPropinsi() {
|
||||
return this.propinsi;
|
||||
}
|
||||
|
||||
@Column(name = "ObjectPropinsiFk", insertable = false, updatable = false, nullable = false)
|
||||
private Integer propinsiId;
|
||||
|
||||
@Column(name = "KodePos", length = 10)
|
||||
@Caption(value = "Kode Pos")
|
||||
private String kodePos;
|
||||
|
||||
@Column(name = "KodePos", nullable = true, length = 10)
|
||||
public String getKodePos() {
|
||||
return kodePos;
|
||||
}
|
||||
|
||||
public void setKodePos(String kodePos) {
|
||||
this.kodePos = kodePos;
|
||||
}
|
||||
|
||||
@NotNull(message = "Nama Desa Kelurahan tidak boleh kosong")
|
||||
@Column(name = "NamaDesaKelurahan", nullable = false, length = 50)
|
||||
@Caption(value = "Nama Desa Kelurahan")
|
||||
private String namaDesaKelurahan;
|
||||
|
||||
public void setNamaDesaKelurahan(String namaDesaKelurahan) {
|
||||
this.namaDesaKelurahan = namaDesaKelurahan;
|
||||
}
|
||||
|
||||
public String getNamaDesaKelurahan() {
|
||||
return this.namaDesaKelurahan;
|
||||
}
|
||||
|
||||
@NotNull(message = "QDesa Kelurahan tidak boleh kosong")
|
||||
@Column(name = "QDesaKelurahan", nullable = false)
|
||||
@Caption(value = "QDesa Kelurahan")
|
||||
private Integer qDesaKelurahan;
|
||||
|
||||
public void setqDesaKelurahan(Integer qDesaKelurahan) {
|
||||
this.qDesaKelurahan = qDesaKelurahan;
|
||||
}
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "migrasikelurahandesafk")
|
||||
@Caption(value = "Migrasi Kelurahan Desa")
|
||||
private MigrasiKelurahanDesa migrasiKelurahanDesa;
|
||||
|
||||
public Integer getqDesaKelurahan() {
|
||||
return this.qDesaKelurahan;
|
||||
}
|
||||
|
||||
/*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch=FetchType.LAZY, cascade = CascadeType.ALL,
|
||||
* mappedBy="kddesakelurahan") private Set<Alamat> AlamatSet = new
|
||||
* HashSet<Alamat>();
|
||||
*
|
||||
* public Set<Alamat> getAlamatSet() { return AlamatSet; }
|
||||
*
|
||||
* public void setAlamatSet(Set<Alamat> alamatSet) { AlamatSet = alamatSet;
|
||||
* }
|
||||
*/
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.desakelurahan_m_id_seq")
|
||||
@javax.persistence.SequenceGenerator(name = "public.desakelurahan_m_id_seq", sequenceName = "public.desakelurahan_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
public Integer getId() {
|
||||
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
@Column(name = "migrasikelurahandesafk", insertable = false, updatable = false)
|
||||
private Long migrasiKelurahanDesaId;
|
||||
}
|
||||
@ -1,44 +1,32 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import java.io.Serializable;
|
||||
import org.hibernate.envers.Audited;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
||||
import org.hibernate.validator.constraints.NotEmpty;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import org.hibernate.validator.constraints.Length;
|
||||
import org.hibernate.validator.internal.util.logging.Messages;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import com.fasterxml.jackson.annotation.JsonManagedReference;
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import org.hibernate.envers.Audited;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
import static javax.persistence.FetchType.LAZY;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "Kecamatan_M")
|
||||
public class Kecamatan extends BaseMaster {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.kecamatan_m_id_seq")
|
||||
@javax.persistence.SequenceGenerator(name = "public.kecamatan_m_id_seq", sequenceName = "public.kecamatan_m_id_seq", allocationSize = 1)
|
||||
@SequenceGenerator(name = "public.kecamatan_m_id_seq", sequenceName = "public.kecamatan_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
|
||||
@NotNull(message = "Kd Kecamatan tidak boleh kosong")
|
||||
@Column(name = "KdKecamatan", nullable = false)
|
||||
@Caption(value = "Kode Kecamatan")
|
||||
private Integer kdKecamatan;
|
||||
|
||||
@ManyToOne(fetch = FetchType.LAZY)
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectKotaKabupatenFk")
|
||||
@NotNull(message = "Kd Kota Kabupaten tidak boleh kosong")
|
||||
@Caption(value = "Object Kota Kabupaten")
|
||||
@ -47,7 +35,7 @@ public class Kecamatan extends BaseMaster {
|
||||
@Column(name = "ObjectKotaKabupatenFk", insertable = false, updatable = false)
|
||||
private Integer kotaKabupatenId;
|
||||
|
||||
@ManyToOne(fetch = FetchType.LAZY)
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectPropinsiFk")
|
||||
@NotNull(message = "Kd Propinsi tidak boleh kosong")
|
||||
@Caption(value = "Object Propinsi")
|
||||
@ -65,69 +53,4 @@ public class Kecamatan extends BaseMaster {
|
||||
@Column(name = "QKecamatan", nullable = false)
|
||||
@Caption(value = "QKecamatan")
|
||||
private Integer qKecamatan;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Integer getKdKecamatan() {
|
||||
return kdKecamatan;
|
||||
}
|
||||
|
||||
public void setKdKecamatan(Integer kdKecamatan) {
|
||||
this.kdKecamatan = kdKecamatan;
|
||||
}
|
||||
|
||||
public KotaKabupaten getKotaKabupaten() {
|
||||
return kotaKabupaten;
|
||||
}
|
||||
|
||||
public void setKotaKabupaten(KotaKabupaten kotaKabupaten) {
|
||||
this.kotaKabupaten = kotaKabupaten;
|
||||
}
|
||||
|
||||
public Integer getKotaKabupatenId() {
|
||||
return kotaKabupatenId;
|
||||
}
|
||||
|
||||
public void setKotaKabupatenId(Integer kotaKabupatenId) {
|
||||
this.kotaKabupatenId = kotaKabupatenId;
|
||||
}
|
||||
|
||||
public Propinsi getPropinsi() {
|
||||
return propinsi;
|
||||
}
|
||||
|
||||
public void setPropinsi(Propinsi propinsi) {
|
||||
this.propinsi = propinsi;
|
||||
}
|
||||
|
||||
public Integer getPropinsiId() {
|
||||
return propinsiId;
|
||||
}
|
||||
|
||||
public void setPropinsiId(Integer propinsiId) {
|
||||
this.propinsiId = propinsiId;
|
||||
}
|
||||
|
||||
public String getNamaKecamatan() {
|
||||
return namaKecamatan;
|
||||
}
|
||||
|
||||
public void setNamaKecamatan(String namaKecamatan) {
|
||||
this.namaKecamatan = namaKecamatan;
|
||||
}
|
||||
|
||||
public Integer getqKecamatan() {
|
||||
return qKecamatan;
|
||||
}
|
||||
|
||||
public void setqKecamatan(Integer qKecamatan) {
|
||||
this.qKecamatan = qKecamatan;
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,66 +1,46 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import java.io.Serializable;
|
||||
import org.hibernate.envers.Audited;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
||||
import org.hibernate.validator.constraints.NotEmpty;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import org.hibernate.validator.constraints.Length;
|
||||
import org.hibernate.validator.internal.util.logging.Messages;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonBackReference;
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import com.fasterxml.jackson.annotation.JsonManagedReference;
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import org.hibernate.envers.Audited;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
import static javax.persistence.FetchType.LAZY;
|
||||
|
||||
/**
|
||||
* class KotaKabupaten
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
@Entity // @Audited
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "KotaKabupaten_M")
|
||||
@JsonIgnoreProperties({ "hibernateLazyInitializer", "handler" })
|
||||
public class KotaKabupaten extends BaseMaster {
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.kotakabupaten_m_id_seq")
|
||||
@SequenceGenerator(name = "public.kotakabupaten_m_id_seq", sequenceName = "public.kotakabupaten_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
@NotNull(message = "Kd Kota Kabupaten tidak boleh kosong")
|
||||
@Column(name = "KdKotaKabupaten", nullable = false)
|
||||
@Caption(value = "Kode Kota Kabupaten")
|
||||
private short kdKotaKabupaten;
|
||||
|
||||
public void setKdKotaKabupaten(short kdKotaKabupaten) {
|
||||
this.kdKotaKabupaten = kdKotaKabupaten;
|
||||
}
|
||||
|
||||
public short getKdKotaKabupaten() {
|
||||
return this.kdKotaKabupaten;
|
||||
}
|
||||
|
||||
@JsonBackReference
|
||||
@ManyToOne
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectPropinsiFk")
|
||||
@NotNull(message = "Kd Propinsi tidak boleh kosong")
|
||||
@Caption(value = "Object Propinsi")
|
||||
private Propinsi propinsi;
|
||||
|
||||
public void setPropinsi(Propinsi propinsi) {
|
||||
this.propinsi = propinsi;
|
||||
}
|
||||
|
||||
public Propinsi getPropinsi() {
|
||||
return this.propinsi;
|
||||
}
|
||||
|
||||
@Column(name = "ObjectPropinsiFk", insertable = false, updatable = false, nullable = false)
|
||||
private Integer propinsiId;
|
||||
|
||||
@ -69,75 +49,8 @@ public class KotaKabupaten extends BaseMaster {
|
||||
@Caption(value = "Nama Kota Kabupaten")
|
||||
private String namaKotaKabupaten;
|
||||
|
||||
public void setNamaKotaKabupaten(String namaKotaKabupaten) {
|
||||
this.namaKotaKabupaten = namaKotaKabupaten;
|
||||
}
|
||||
|
||||
public String getNamaKotaKabupaten() {
|
||||
return this.namaKotaKabupaten;
|
||||
}
|
||||
|
||||
@NotNull(message = "QKota Kabupaten tidak boleh kosong")
|
||||
@Column(name = "QKotaKabupaten", nullable = false)
|
||||
@Caption(value = "QKota Kabupaten")
|
||||
private short qKotaKabupaten;
|
||||
|
||||
public void setqKotaKabupaten(short qKotaKabupaten) {
|
||||
this.qKotaKabupaten = qKotaKabupaten;
|
||||
}
|
||||
|
||||
public short getqKotaKabupaten() {
|
||||
return this.qKotaKabupaten;
|
||||
}
|
||||
|
||||
/*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch=FetchType.LAZY, cascade = CascadeType.ALL,
|
||||
* mappedBy="kdkotakabupaten") private Set<Alamat> AlamatSet = new
|
||||
* HashSet<Alamat>();
|
||||
*
|
||||
* public Set<Alamat> getAlamatSet() { return AlamatSet; }
|
||||
*
|
||||
* public void setAlamatSet(Set<Alamat> alamatSet) { AlamatSet = alamatSet;
|
||||
* }
|
||||
*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy =
|
||||
* "kdkotakabupaten") private Set<DesaKelurahan> DesaKelurahanSet = new
|
||||
* HashSet<DesaKelurahan>();
|
||||
*
|
||||
* public Set<DesaKelurahan> getDesaKelurahanSet() { return
|
||||
* DesaKelurahanSet; }
|
||||
*
|
||||
* public void setDesaKelurahanSet(Set<DesaKelurahan> desaKelurahanSet) {
|
||||
* DesaKelurahanSet = desaKelurahanSet; }
|
||||
*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy =
|
||||
* "kdkotakabupaten") private Set<Kecamatan> KecamatanSet = new
|
||||
* HashSet<Kecamatan>();
|
||||
*
|
||||
* public Set<Kecamatan> getKecamatanSet() { return KecamatanSet; }
|
||||
*
|
||||
* public void setKecamatanSet(Set<Kecamatan> kecamatanSet) { KecamatanSet =
|
||||
* kecamatanSet; }
|
||||
*/
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.kotakabupaten_m_id_seq")
|
||||
@javax.persistence.SequenceGenerator(name = "public.kotakabupaten_m_id_seq", sequenceName = "public.kotakabupaten_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
public Integer getId() {
|
||||
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,39 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
|
||||
import static javax.persistence.FetchType.LAZY;
|
||||
import static javax.persistence.GenerationType.SEQUENCE;
|
||||
|
||||
/**
|
||||
* @author salmanoe
|
||||
* @version 1.0.0
|
||||
* @since 08/11/2023
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "migrasikecamatan_m")
|
||||
public class MigrasiKecamatan implements Serializable {
|
||||
@Id
|
||||
@GeneratedValue(strategy = SEQUENCE, generator = "sg_migrasikecamatan_m")
|
||||
@SequenceGenerator(name = "sg_migrasikecamatan_m", sequenceName = "migrasikecamatan_m_seq", allocationSize = 1)
|
||||
private Long id;
|
||||
|
||||
@Column(length = 8)
|
||||
@Size(max = 8)
|
||||
private String kodeKemendagri;
|
||||
|
||||
private String kecamatan;
|
||||
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "migrasikotakabupatenfk")
|
||||
@ToString.Exclude
|
||||
private MigrasiKotaKabupaten migrasiKotaKabupaten;
|
||||
}
|
||||
@ -0,0 +1,39 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
|
||||
import static javax.persistence.FetchType.LAZY;
|
||||
import static javax.persistence.GenerationType.SEQUENCE;
|
||||
|
||||
/**
|
||||
* @author salmanoe
|
||||
* @version 1.0.0
|
||||
* @since 08/11/2023
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "migrasikelurahandesa_m")
|
||||
public class MigrasiKelurahanDesa implements Serializable {
|
||||
@Id
|
||||
@GeneratedValue(strategy = SEQUENCE, generator = "sg_migrasikelurahandesa_m")
|
||||
@SequenceGenerator(name = "sg_migrasikelurahandesa_m", sequenceName = "migrasikelurahandesa_m_seq", allocationSize = 1)
|
||||
private Long id;
|
||||
|
||||
@Column(length = 13)
|
||||
@Size(max = 13)
|
||||
private String kodeKemendagri;
|
||||
|
||||
private String kelurahanAtauDesa;
|
||||
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "migrasikecamatanfk")
|
||||
@ToString.Exclude
|
||||
private MigrasiKecamatan migrasiKecamatan;
|
||||
}
|
||||
@ -0,0 +1,39 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import lombok.ToString;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
|
||||
import static javax.persistence.FetchType.LAZY;
|
||||
import static javax.persistence.GenerationType.SEQUENCE;
|
||||
|
||||
/**
|
||||
* @author salmanoe
|
||||
* @version 1.0.0
|
||||
* @since 08/11/2023
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "migrasikotakabupaten_m")
|
||||
public class MigrasiKotaKabupaten implements Serializable {
|
||||
@Id
|
||||
@GeneratedValue(strategy = SEQUENCE, generator = "sg_migrasikotakabupaten_m")
|
||||
@SequenceGenerator(name = "sg_migrasikotakabupaten_m", sequenceName = "migrasikotakabupaten_m_seq", allocationSize = 1)
|
||||
private Long id;
|
||||
|
||||
@Column(length = 5)
|
||||
@Size(max = 5)
|
||||
private String kodeKemendagri;
|
||||
|
||||
private String kotaAtauKabupaten;
|
||||
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "migrasiprovinsifk")
|
||||
@ToString.Exclude
|
||||
private MigrasiProvinsi migrasiProvinsi;
|
||||
}
|
||||
@ -0,0 +1,32 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.Size;
|
||||
import java.io.Serializable;
|
||||
|
||||
import static javax.persistence.GenerationType.SEQUENCE;
|
||||
|
||||
/**
|
||||
* @author salmanoe
|
||||
* @version 1.0.0
|
||||
* @since 08/11/2023
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "migrasiprovinsi_m")
|
||||
public class MigrasiProvinsi implements Serializable {
|
||||
@Id
|
||||
@GeneratedValue(strategy = SEQUENCE, generator = "sg_migrasiprovinsi_m")
|
||||
@SequenceGenerator(name = "sg_migrasiprovinsi_m", sequenceName = "migrasiprovinsi_m_seq", allocationSize = 1)
|
||||
private Long id;
|
||||
|
||||
@Column(length = 2)
|
||||
@Size(max = 2)
|
||||
private String kodeKemendagri;
|
||||
|
||||
private String provinsi;
|
||||
}
|
||||
@ -1,128 +1,52 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import java.io.Serializable;
|
||||
import org.hibernate.envers.Audited;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
||||
import org.hibernate.validator.constraints.NotEmpty;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import org.hibernate.validator.constraints.Length;
|
||||
import org.hibernate.validator.internal.util.logging.Messages;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import com.fasterxml.jackson.annotation.JsonManagedReference;
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import org.hibernate.envers.Audited;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import static javax.persistence.GenerationType.SEQUENCE;
|
||||
|
||||
/**
|
||||
* class Propinsi
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
@Entity // @Audited
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "Propinsi_M")
|
||||
@JsonIgnoreProperties({ "hibernateLazyInitializer", "handler" })
|
||||
public class Propinsi extends BaseMaster {
|
||||
@Id
|
||||
@GeneratedValue(strategy = SEQUENCE, generator = "public.propinsi_m_id_seq")
|
||||
@SequenceGenerator(name = "public.propinsi_m_id_seq", sequenceName = "public.propinsi_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
@NotNull(message = "Kd Propinsi tidak boleh kosong")
|
||||
@Column(name = "KdPropinsi", nullable = false)
|
||||
@Caption(value = "Kode Propinsi")
|
||||
private Byte kdPropinsi;
|
||||
|
||||
public void setKdPropinsi(Byte kdPropinsi) {
|
||||
this.kdPropinsi = kdPropinsi;
|
||||
}
|
||||
|
||||
public Byte getKdPropinsi() {
|
||||
return this.kdPropinsi;
|
||||
}
|
||||
|
||||
@NotNull(message = "Nama Propinsi tidak boleh kosong")
|
||||
@Column(name = "NamaPropinsi", nullable = false, length = 50)
|
||||
@Caption(value = "Nama Propinsi")
|
||||
private String namaPropinsi;
|
||||
|
||||
public void setNamaPropinsi(String namaPropinsi) {
|
||||
this.namaPropinsi = namaPropinsi;
|
||||
}
|
||||
|
||||
public String getNamaPropinsi() {
|
||||
return this.namaPropinsi;
|
||||
}
|
||||
|
||||
@NotNull(message = "QPropinsi tidak boleh kosong")
|
||||
@Column(name = "QPropinsi", nullable = false)
|
||||
@Caption(value = "QPropinsi")
|
||||
private Byte qPropinsi;
|
||||
|
||||
public void setqPropinsi(Byte qPropinsi) {
|
||||
this.qPropinsi = qPropinsi;
|
||||
}
|
||||
|
||||
public Byte getqPropinsi() {
|
||||
return this.qPropinsi;
|
||||
}
|
||||
|
||||
/*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch=FetchType.LAZY, cascade = CascadeType.ALL,
|
||||
* mappedBy="kdpropinsi") private Set<Alamat> AlamatSet = new
|
||||
* HashSet<Alamat>();
|
||||
*
|
||||
* public Set<Alamat> getAlamatSet() { return AlamatSet; }
|
||||
*
|
||||
* public void setAlamatSet(Set<Alamat> alamatSet) { AlamatSet = alamatSet;
|
||||
* }
|
||||
*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy =
|
||||
* "kdpropinsi") private Set<DesaKelurahan> DesaKelurahanSet = new
|
||||
* HashSet<DesaKelurahan>();
|
||||
*
|
||||
* public Set<DesaKelurahan> getDesaKelurahanSet() { return
|
||||
* DesaKelurahanSet; }
|
||||
*
|
||||
* public void setDesaKelurahanSet(Set<DesaKelurahan> desaKelurahanSet) {
|
||||
* DesaKelurahanSet = desaKelurahanSet; }
|
||||
*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy =
|
||||
* "kdpropinsi") private Set<Kecamatan> KecamatanSet = new
|
||||
* HashSet<Kecamatan>();
|
||||
*
|
||||
* public Set<Kecamatan> getKecamatanSet() { return KecamatanSet; }
|
||||
*
|
||||
* public void setKecamatanSet(Set<Kecamatan> kecamatanSet) { KecamatanSet =
|
||||
* kecamatanSet; }
|
||||
*/
|
||||
|
||||
@JsonManagedReference
|
||||
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy = "propinsi")
|
||||
private Set<KotaKabupaten> kotaKabupaten = new HashSet<KotaKabupaten>();
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.propinsi_m_id_seq")
|
||||
@javax.persistence.SequenceGenerator(name = "public.propinsi_m_id_seq", sequenceName = "public.propinsi_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
public Integer getId() {
|
||||
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
private Set<KotaKabupaten> kotaKabupaten = new HashSet<>();
|
||||
}
|
||||
@ -53,6 +53,10 @@ public class RekapLogbookDokter extends BaseTransaction {
|
||||
@Column(name = "kelompokpasienfk", insertable = false, updatable = false, nullable = false)
|
||||
private Integer kelompokPasienId;
|
||||
|
||||
@Column(length = 8)
|
||||
@Size(max = 8, message = "Bulan pulang ibu maksimal {max} karaketer")
|
||||
private String bulanPulangIbu;
|
||||
|
||||
@Column(nullable = false)
|
||||
@NotNull(message = "Bulan logbook tidak boleh kosong")
|
||||
@Temporal(DATE)
|
||||
|
||||
@ -1,146 +1,47 @@
|
||||
package com.jasamedika.medifirst2000.vo;
|
||||
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.persistence.CascadeType;
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.FetchType;
|
||||
import javax.persistence.JoinColumn;
|
||||
import javax.persistence.ManyToOne;
|
||||
import javax.persistence.OneToMany;
|
||||
import javax.persistence.Table;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonManagedReference;
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* class DesaKelurahan
|
||||
* class DesaKelurahan
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
//@Entity
|
||||
//@Table(name = "DesaKelurahan_M")
|
||||
@Getter
|
||||
@Setter
|
||||
public class DesaKelurahanVO extends BaseMasterVO {
|
||||
@Caption(value="Kode Desa Kelurahan")
|
||||
@Caption(value = "Kode Desa Kelurahan")
|
||||
private Integer kdDesaKelurahan;
|
||||
|
||||
public void setKdDesaKelurahan(Integer kdDesaKelurahan) {
|
||||
this.kdDesaKelurahan = kdDesaKelurahan;
|
||||
}
|
||||
|
||||
@Column(name = "KdDesaKelurahan", nullable = false )
|
||||
public Integer getKdDesaKelurahan(){
|
||||
return this.kdDesaKelurahan;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ObjectKecamatanFk")
|
||||
@NotNull(message="Object KecamatanVO Harus Diisi")
|
||||
@Caption(value="Object Kecamatan")
|
||||
@NotNull(message = "Object KecamatanVO Harus Diisi")
|
||||
@Caption(value = "Object Kecamatan")
|
||||
private KecamatanVO kecamatan;
|
||||
|
||||
public void setKecamatan(KecamatanVO kecamatan) {
|
||||
this.kecamatan = kecamatan;
|
||||
}
|
||||
|
||||
@Column(name = "KdKecamatan", nullable = false )
|
||||
public KecamatanVO getKecamatan(){
|
||||
return this.kecamatan;
|
||||
}
|
||||
|
||||
@Column(name = "ObjectKecamatanFk", insertable=false,updatable=false)
|
||||
private Integer kecamatanId;
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ObjectKotaKabupatenFk")
|
||||
@NotNull(message="Object Kota Kabupaten Harus Diisi")
|
||||
@Caption(value="Object Kota Kabupaten")
|
||||
@NotNull(message = "Object Kota Kabupaten Harus Diisi")
|
||||
@Caption(value = "Object Kota Kabupaten")
|
||||
private KotaKabupatenVO kotaKabupaten;
|
||||
|
||||
public void setKotaKabupaten(KotaKabupatenVO kotaKabupaten) {
|
||||
this.kotaKabupaten = kotaKabupaten;
|
||||
}
|
||||
|
||||
@Column(name = "KdKotaKabupaten", nullable = false )
|
||||
public KotaKabupatenVO getKotaKabupaten(){
|
||||
return this.kotaKabupaten;
|
||||
}
|
||||
|
||||
@Column(name = "ObjectKotaKabupatenFk", insertable=false,updatable=false)
|
||||
private Integer kotaKabupatenId;
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ObjectPropinsiFk")
|
||||
@NotNull(message="Object PropinsiVO Harus Diisi")
|
||||
@Caption(value="Object Propinsi")
|
||||
@NotNull(message = "Object PropinsiVO Harus Diisi")
|
||||
@Caption(value = "Object Propinsi")
|
||||
private PropinsiVO propinsi;
|
||||
|
||||
public void setPropinsi(PropinsiVO propinsi) {
|
||||
this.propinsi = propinsi;
|
||||
}
|
||||
|
||||
@Column(name = "KdPropinsi", nullable = false )
|
||||
public PropinsiVO getPropinsi(){
|
||||
return this.propinsi;
|
||||
}
|
||||
|
||||
@Column(name = "ObjectPropinsiFk", insertable=false,updatable=false)
|
||||
private Integer propinsiId;
|
||||
|
||||
@Caption(value="Kode Pos")
|
||||
@Caption(value = "Kode Pos")
|
||||
private String kodePos;
|
||||
|
||||
|
||||
@Column(name = "KodePos", nullable = true , length = 10)
|
||||
public String getKodePos() {
|
||||
return kodePos;
|
||||
}
|
||||
|
||||
public void setKodePos(String kodePos) {
|
||||
this.kodePos = kodePos;
|
||||
}
|
||||
|
||||
@Caption(value="Nama Desa Kelurahan")
|
||||
@Caption(value = "Nama Desa Kelurahan")
|
||||
private String namaDesaKelurahan;
|
||||
|
||||
public void setNamaDesaKelurahan(String namaDesaKelurahan) {
|
||||
this.namaDesaKelurahan = namaDesaKelurahan;
|
||||
}
|
||||
|
||||
@Column(name = "NamaDesaKelurahan", nullable = false , length = 50)
|
||||
public String getNamaDesaKelurahan(){
|
||||
return this.namaDesaKelurahan;
|
||||
}
|
||||
|
||||
@Caption(value="QDesa Kelurahan")
|
||||
@Caption(value = "QDesa Kelurahan")
|
||||
private Integer qDesaKelurahan;
|
||||
|
||||
public void setqDesaKelurahan(Integer qDesaKelurahan) {
|
||||
this.qDesaKelurahan = qDesaKelurahan;
|
||||
}
|
||||
|
||||
@Column(name = "QDesaKelurahan", nullable = false )
|
||||
public Integer getqDesaKelurahan(){
|
||||
return this.qDesaKelurahan;
|
||||
}
|
||||
|
||||
|
||||
/*//
|
||||
@OneToMany(fetch=FetchType.LAZY, cascade = CascadeType.ALL, mappedBy="kddesakelurahan")
|
||||
private Set<Alamat> AlamatSet = new HashSet<Alamat>();
|
||||
|
||||
public Set<Alamat> getAlamatSet() {
|
||||
return AlamatSet;
|
||||
}
|
||||
|
||||
public void setAlamatSet(Set<Alamat> alamatSet) {
|
||||
AlamatSet = alamatSet;
|
||||
}*/
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -1,37 +1,23 @@
|
||||
package com.jasamedika.medifirst2000.vo;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.util.Date;
|
||||
import org.hibernate.validator.constraints.NotEmpty;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
|
||||
import com.jasamedika.medifirst2000.entities.KotaKabupaten;
|
||||
import com.jasamedika.medifirst2000.entities.Propinsi;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import org.hibernate.validator.constraints.Length;
|
||||
import org.hibernate.validator.internal.util.logging.Messages;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonManagedReference;
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
public class KecamatanVO extends BaseMasterVO {
|
||||
|
||||
@NotNull(message = "Kd Kecamatan tidak boleh kosong")
|
||||
@Caption(value = "Kode Kecamatan")
|
||||
private Integer kdKecamatan;
|
||||
|
||||
@ManyToOne(fetch = FetchType.LAZY)
|
||||
@NotNull(message = "Kd Kota Kabupaten tidak boleh kosong")
|
||||
@Caption(value = "Object Kota Kabupaten")
|
||||
private KotaKabupatenVO kotaKabupaten;
|
||||
|
||||
@ManyToOne(fetch = FetchType.LAZY)
|
||||
@NotNull(message = "Kd Propinsi tidak boleh kosong")
|
||||
@Caption(value = "Object Propinsi")
|
||||
private PropinsiVO propinsi;
|
||||
@ -43,45 +29,4 @@ public class KecamatanVO extends BaseMasterVO {
|
||||
@NotNull(message = "QKecamatan tidak boleh kosong")
|
||||
@Caption(value = "QKecamatan")
|
||||
private Integer qKecamatan;
|
||||
|
||||
public Integer getKdKecamatan() {
|
||||
return kdKecamatan;
|
||||
}
|
||||
|
||||
public void setKdKecamatan(Integer kdKecamatan) {
|
||||
this.kdKecamatan = kdKecamatan;
|
||||
}
|
||||
|
||||
public KotaKabupatenVO getKotaKabupaten() {
|
||||
return kotaKabupaten;
|
||||
}
|
||||
|
||||
public void setKotaKabupaten(KotaKabupatenVO kotaKabupaten) {
|
||||
this.kotaKabupaten = kotaKabupaten;
|
||||
}
|
||||
|
||||
public PropinsiVO getPropinsi() {
|
||||
return propinsi;
|
||||
}
|
||||
|
||||
public void setPropinsi(PropinsiVO propinsi) {
|
||||
this.propinsi = propinsi;
|
||||
}
|
||||
|
||||
public String getNamaKecamatan() {
|
||||
return namaKecamatan;
|
||||
}
|
||||
|
||||
public void setNamaKecamatan(String namaKecamatan) {
|
||||
this.namaKecamatan = namaKecamatan;
|
||||
}
|
||||
|
||||
public Integer getqKecamatan() {
|
||||
return qKecamatan;
|
||||
}
|
||||
|
||||
public void setqKecamatan(Integer qKecamatan) {
|
||||
this.qKecamatan = qKecamatan;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -1,120 +1,32 @@
|
||||
package com.jasamedika.medifirst2000.vo;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.util.Date;
|
||||
import org.hibernate.validator.constraints.NotEmpty;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import org.hibernate.validator.constraints.Length;
|
||||
import org.hibernate.validator.internal.util.logging.Messages;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonManagedReference;
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* class KotaKabupaten
|
||||
* class KotaKabupaten
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
//@Entity
|
||||
//@Table(name = "KotaKabupaten_M")
|
||||
@Getter
|
||||
@Setter
|
||||
public class KotaKabupatenVO extends BaseMasterVO {
|
||||
@Caption(value="Kode Kota Kabupaten")
|
||||
@Caption(value = "Kode Kota Kabupaten")
|
||||
private short kdKotaKabupaten;
|
||||
|
||||
public void setKdKotaKabupaten(short kdKotaKabupaten) {
|
||||
this.kdKotaKabupaten = kdKotaKabupaten;
|
||||
}
|
||||
|
||||
@Column(name = "KdKotaKabupaten", nullable = false )
|
||||
public short getKdKotaKabupaten(){
|
||||
return this.kdKotaKabupaten;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ObjectPropinsiFk")
|
||||
@NotNull(message="Object PropinsiVO Harus Diisi")
|
||||
@Caption(value="Object Propinsi")
|
||||
@NotNull(message = "Object PropinsiVO Harus Diisi")
|
||||
@Caption(value = "Object Propinsi")
|
||||
private PropinsiVO propinsi;
|
||||
|
||||
public void setPropinsi(PropinsiVO propinsi) {
|
||||
this.propinsi = propinsi;
|
||||
}
|
||||
|
||||
@Column(name = "KdPropinsi", nullable = false )
|
||||
public PropinsiVO getPropinsi(){
|
||||
return this.propinsi;
|
||||
}
|
||||
|
||||
@Column(name = "ObjectPropinsiFk", insertable=false,updatable=false)
|
||||
private Integer propinsiId;
|
||||
|
||||
@Caption(value="Nama Kota Kabupaten")
|
||||
@Caption(value = "Nama Kota Kabupaten")
|
||||
private String namaKotaKabupaten;
|
||||
|
||||
public void setNamaKotaKabupaten(String namaKotaKabupaten) {
|
||||
this.namaKotaKabupaten = namaKotaKabupaten;
|
||||
}
|
||||
|
||||
@Column(name = "NamaKotaKabupaten", nullable = false , length = 50)
|
||||
public String getNamaKotaKabupaten(){
|
||||
return this.namaKotaKabupaten;
|
||||
}
|
||||
|
||||
@Caption(value="QKota Kabupaten")
|
||||
@Caption(value = "QKota Kabupaten")
|
||||
private short qKotaKabupaten;
|
||||
|
||||
public void setqKotaKabupaten(short qKotaKabupaten) {
|
||||
this.qKotaKabupaten = qKotaKabupaten;
|
||||
}
|
||||
|
||||
@Column(name = "QKotaKabupaten", nullable = false )
|
||||
public short getqKotaKabupaten(){
|
||||
return this.qKotaKabupaten;
|
||||
}
|
||||
|
||||
/*
|
||||
//
|
||||
@OneToMany(fetch=FetchType.LAZY, cascade = CascadeType.ALL, mappedBy="kdkotakabupaten")
|
||||
private Set<Alamat> AlamatSet = new HashSet<Alamat>();
|
||||
|
||||
public Set<Alamat> getAlamatSet() {
|
||||
return AlamatSet;
|
||||
}
|
||||
|
||||
public void setAlamatSet(Set<Alamat> alamatSet) {
|
||||
AlamatSet = alamatSet;
|
||||
}
|
||||
|
||||
//
|
||||
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy = "kdkotakabupaten")
|
||||
private Set<DesaKelurahan> DesaKelurahanSet = new HashSet<DesaKelurahan>();
|
||||
|
||||
public Set<DesaKelurahan> getDesaKelurahanSet() {
|
||||
return DesaKelurahanSet;
|
||||
}
|
||||
|
||||
public void setDesaKelurahanSet(Set<DesaKelurahan> desaKelurahanSet) {
|
||||
DesaKelurahanSet = desaKelurahanSet;
|
||||
}
|
||||
|
||||
//
|
||||
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy = "kdkotakabupaten")
|
||||
private Set<Kecamatan> KecamatanSet = new HashSet<Kecamatan>();
|
||||
|
||||
public Set<Kecamatan> getKecamatanSet() {
|
||||
return KecamatanSet;
|
||||
}
|
||||
|
||||
public void setKecamatanSet(Set<Kecamatan> kecamatanSet) {
|
||||
KecamatanSet = kecamatanSet;
|
||||
}*/
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -1,56 +1,29 @@
|
||||
package com.jasamedika.medifirst2000.vo;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* class Propinsi
|
||||
* class Propinsi
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
public class PropinsiVO extends BaseMasterVO {
|
||||
|
||||
@Caption(value="Kode Propinsi")
|
||||
@Column(name = "KdPropinsi", nullable = false )
|
||||
@NotNull(message="Kd Propinsi tidak boleh kosong")
|
||||
@Caption(value = "Kode Propinsi")
|
||||
@NotNull(message = "Kd Propinsi tidak boleh kosong")
|
||||
private Byte kdPropinsi;
|
||||
|
||||
@Caption(value="Nama Propinsi")
|
||||
@Column(name = "NamaPropinsi", nullable = false , length = 50)
|
||||
@NotNull(message="Kd Propinsi tidak boleh kosong")
|
||||
@Caption(value = "Nama Propinsi")
|
||||
@NotNull(message = "Kd Propinsi tidak boleh kosong")
|
||||
private String namaPropinsi;
|
||||
|
||||
@Caption(value="QPropinsi")
|
||||
@Column(name = "QPropinsi", nullable = false )
|
||||
@NotNull(message="Kd Propinsi tidak boleh kosong")
|
||||
@Caption(value = "QPropinsi")
|
||||
@NotNull(message = "Kd Propinsi tidak boleh kosong")
|
||||
private Byte qPropinsi;
|
||||
|
||||
public Byte getKdPropinsi() {
|
||||
return kdPropinsi;
|
||||
}
|
||||
|
||||
public void setKdPropinsi(Byte kdPropinsi) {
|
||||
this.kdPropinsi = kdPropinsi;
|
||||
}
|
||||
|
||||
public String getNamaPropinsi() {
|
||||
return namaPropinsi;
|
||||
}
|
||||
|
||||
public void setNamaPropinsi(String namaPropinsi) {
|
||||
this.namaPropinsi = namaPropinsi;
|
||||
}
|
||||
|
||||
public Byte getqPropinsi() {
|
||||
return qPropinsi;
|
||||
}
|
||||
|
||||
public void setqPropinsi(Byte qPropinsi) {
|
||||
this.qPropinsi = qPropinsi;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -2,7 +2,8 @@ package com.jasamedika.medifirst2000.vo;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseTransactionVO;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import lombok.*;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import org.hibernate.validator.constraints.NotBlank;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
@ -36,6 +37,9 @@ public class RekapLogbookDokterVO extends BaseTransactionVO {
|
||||
|
||||
private Integer kelompokPasienId;
|
||||
|
||||
@Size(max = 8, message = "Bulan pulang ibu maksimal {max} karaketer")
|
||||
private String bulanPulangIbu;
|
||||
|
||||
private Date bulan;
|
||||
|
||||
private Double jumlah;
|
||||
|
||||
@ -49,9 +49,9 @@ public class LogbookTask {
|
||||
DateFormat df = new SimpleDateFormat("yyyy-MM");
|
||||
String bulan = df.format(date);
|
||||
List<RekapLogbookDokter> models = new ArrayList<>();
|
||||
idPegawaiByTglPelayanan.forEach(id -> {
|
||||
idPegawaiByTglPelayanan.forEach(idPegawai -> {
|
||||
{
|
||||
Map<String, Object> kinerjaDokter = pelayananPasienService.logbookRemunTarifDokter(id, bulan);
|
||||
Map<String, Object> kinerjaDokter = pelayananPasienService.logbookRemunTarifDokter(idPegawai, bulan);
|
||||
List<Map<String, Object>> remun = (List<Map<String, Object>>) kinerjaDokter.get("data");
|
||||
List<Integer> listIdKelompokPasien = new ArrayList<>();
|
||||
remun.forEach(r -> {
|
||||
@ -67,7 +67,7 @@ public class LogbookTask {
|
||||
rekapLogbookDokter.setKdProfile((short) 0);
|
||||
rekapLogbookDokter.setStatusEnabled(true);
|
||||
Pegawai pegawai = new Pegawai();
|
||||
pegawai.setId(id);
|
||||
pegawai.setId(idPegawai);
|
||||
rekapLogbookDokter.setPegawai(pegawai);
|
||||
rekapLogbookDokter.setJenisLogbook("JKN");
|
||||
KelompokPasien kelompokPasien = new KelompokPasien();
|
||||
@ -80,7 +80,7 @@ public class LogbookTask {
|
||||
});
|
||||
}
|
||||
{
|
||||
List<Map<String, Object>> ffs = pelayananPasienService.logbookFfsTarifDokter(id, bulan);
|
||||
List<Map<String, Object>> ffs = pelayananPasienService.logbookFfsTarifDokter(idPegawai, bulan);
|
||||
List<String> listJenisRuangan = new ArrayList<>();
|
||||
List<Integer> listIdKelompokPasien = new ArrayList<>();
|
||||
ffs.forEach(r -> {
|
||||
@ -102,7 +102,7 @@ public class LogbookTask {
|
||||
rekapLogbookDokter.setKdProfile((short) 0);
|
||||
rekapLogbookDokter.setStatusEnabled(true);
|
||||
Pegawai pegawai = new Pegawai();
|
||||
pegawai.setId(id);
|
||||
pegawai.setId(idPegawai);
|
||||
rekapLogbookDokter.setPegawai(pegawai);
|
||||
rekapLogbookDokter.setJenisLogbook("NON_JKN");
|
||||
rekapLogbookDokter.setJenisRuangan(jenisRuangan);
|
||||
@ -116,40 +116,47 @@ public class LogbookTask {
|
||||
}));
|
||||
}
|
||||
{
|
||||
List<Map<String, Object>> fixedPay = pelayananPasienService.logbookFixedPayDokter(id, bulan);
|
||||
List<Map<String, Object>> fixedPay = pelayananPasienService.logbookFixedPayDokter(idPegawai, bulan);
|
||||
List<String> listJenisRuangan = new ArrayList<>();
|
||||
List<Integer> listIdKelompokPasien = new ArrayList<>();
|
||||
List<String> listBulanIbuPulangRanap = new ArrayList<>();
|
||||
fixedPay.forEach(r -> {
|
||||
if (!listJenisRuangan.contains(r.get("jenisRuangan").toString()))
|
||||
listJenisRuangan.add(r.get("jenisRuangan").toString());
|
||||
if (!listIdKelompokPasien.contains(Integer.parseInt(r.get("idKelompokPasien").toString())))
|
||||
listIdKelompokPasien.add(Integer.parseInt(r.get("idKelompokPasien").toString()));
|
||||
if (!listBulanIbuPulangRanap.contains(r.get("bulanPulangIbu").toString()))
|
||||
listBulanIbuPulangRanap.add(r.get("bulanPulangIbu").toString());
|
||||
});
|
||||
listJenisRuangan.forEach(jenisRuangan -> listIdKelompokPasien.forEach(idKelompokPasien -> {
|
||||
double jumlah = fixedPay.stream()
|
||||
.filter(r -> jenisRuangan.equals(r.get("jenisRuangan"))
|
||||
&& idKelompokPasien.equals(r.get("idKelompokPasien")))
|
||||
.mapToDouble(r -> Double.parseDouble(r.get("jumlah").toString())).sum();
|
||||
double hargaJasa = fixedPay.stream()
|
||||
.filter(r -> jenisRuangan.equals(r.get("jenisRuangan"))
|
||||
&& idKelompokPasien.equals(r.get("idKelompokPasien")))
|
||||
.mapToDouble(r -> Double.parseDouble(r.get("jumlahHargaJasa").toString())).sum();
|
||||
RekapLogbookDokter rekapLogbookDokter = new RekapLogbookDokter();
|
||||
rekapLogbookDokter.setKdProfile((short) 0);
|
||||
rekapLogbookDokter.setStatusEnabled(true);
|
||||
Pegawai pegawai = new Pegawai();
|
||||
pegawai.setId(id);
|
||||
rekapLogbookDokter.setPegawai(pegawai);
|
||||
rekapLogbookDokter.setJenisLogbook("FIXED_PAY");
|
||||
rekapLogbookDokter.setJenisRuangan(jenisRuangan);
|
||||
KelompokPasien kelompokPasien = new KelompokPasien();
|
||||
kelompokPasien.setId(idKelompokPasien);
|
||||
rekapLogbookDokter.setKelompokPasien(kelompokPasien);
|
||||
rekapLogbookDokter.setBulan(date);
|
||||
rekapLogbookDokter.setJumlah(jumlah);
|
||||
rekapLogbookDokter.setCapaian(hargaJasa);
|
||||
models.add(rekapLogbookDokter);
|
||||
}));
|
||||
listJenisRuangan.forEach(jenisRuangan -> listIdKelompokPasien
|
||||
.forEach(idKelompokPasien -> listBulanIbuPulangRanap.forEach(bulanIbuPulangRanap -> {
|
||||
double jumlah = fixedPay.stream()
|
||||
.filter(r -> jenisRuangan.equals(r.get("jenisRuangan"))
|
||||
&& idKelompokPasien.equals(r.get("idKelompokPasien"))
|
||||
&& bulanIbuPulangRanap.equals(r.get("bulanIbuPulang")))
|
||||
.mapToDouble(r -> Double.parseDouble(r.get("jumlah").toString())).sum();
|
||||
double hargaJasa = fixedPay.stream()
|
||||
.filter(r -> jenisRuangan.equals(r.get("jenisRuangan"))
|
||||
&& idKelompokPasien.equals(r.get("idKelompokPasien"))
|
||||
&& bulanIbuPulangRanap.equals(r.get("bulanIbuPulang")))
|
||||
.mapToDouble(r -> Double.parseDouble(r.get("jumlahHargaJasa").toString())).sum();
|
||||
RekapLogbookDokter rekapLogbookDokter = new RekapLogbookDokter();
|
||||
rekapLogbookDokter.setKdProfile((short) 0);
|
||||
rekapLogbookDokter.setStatusEnabled(true);
|
||||
Pegawai pegawai = new Pegawai();
|
||||
pegawai.setId(idPegawai);
|
||||
rekapLogbookDokter.setPegawai(pegawai);
|
||||
rekapLogbookDokter.setJenisLogbook("FIXED_PAY");
|
||||
rekapLogbookDokter.setJenisRuangan(jenisRuangan);
|
||||
KelompokPasien kelompokPasien = new KelompokPasien();
|
||||
kelompokPasien.setId(idKelompokPasien);
|
||||
rekapLogbookDokter.setKelompokPasien(kelompokPasien);
|
||||
rekapLogbookDokter.setBulanPulangIbu(bulanIbuPulangRanap);
|
||||
rekapLogbookDokter.setBulan(date);
|
||||
rekapLogbookDokter.setJumlah(jumlah);
|
||||
rekapLogbookDokter.setCapaian(hargaJasa);
|
||||
models.add(rekapLogbookDokter);
|
||||
})));
|
||||
}
|
||||
});
|
||||
rekapLogbookDokterDao.save(models);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user