Update service pelayanan pasien
Penyesuaian permintaan hak akses diskon paket untuk kelompok user tatarekening
This commit is contained in:
parent
81fc0c668c
commit
94f7897fce
@ -293,6 +293,8 @@ public class Master {
|
||||
public static final class LoginUser {
|
||||
public static final int GENERATED_NEW_LOGIN = 1;
|
||||
public static final int GENERATED_USED_LOGIN = 0;
|
||||
|
||||
public static final Integer TATA_REKENING = 52;
|
||||
}
|
||||
|
||||
public static final class MonitoringAbsensi {
|
||||
|
||||
@ -8,18 +8,15 @@ import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
import org.springframework.data.jpa.repository.Query;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import com.jasamedika.medifirst2000.entities.HistoryLoginModulAplikasi;
|
||||
|
||||
@Repository("historyLoginModulAplikasiDao")
|
||||
public interface HistoryLoginModulAplikasiDao extends JpaRepository<HistoryLoginModulAplikasi,Integer> {
|
||||
|
||||
@Query("Select m From HistoryLoginModulAplikasi m "
|
||||
+ "Where m.kdUser = :kdUser "
|
||||
public interface HistoryLoginModulAplikasiDao extends JpaRepository<HistoryLoginModulAplikasi, Integer> {
|
||||
@Query("Select m From HistoryLoginModulAplikasi m " + "Where m.kdUser = :kdUser "
|
||||
+ "And date(m.tglLogin) = date(:curDate) ")
|
||||
List<HistoryLoginModulAplikasi> findCurrentRuangan(@Param("kdUser")String kdUser, @Param("curDate") Date curDate);
|
||||
|
||||
List<HistoryLoginModulAplikasi> findCurrentRuangan(@Param("kdUser") String kdUser, @Param("curDate") Date curDate);
|
||||
|
||||
Page<HistoryLoginModulAplikasi> findByKdUser(String kdUser, Pageable pageable);
|
||||
|
||||
List<HistoryLoginModulAplikasi> findByKdUser(String kdUser);
|
||||
}
|
||||
|
||||
@ -1,7 +1,6 @@
|
||||
package com.jasamedika.medifirst2000.dao;
|
||||
|
||||
import org.springframework.data.repository.PagingAndSortingRepository;
|
||||
import org.springframework.stereotype.Repository;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
|
||||
import com.jasamedika.medifirst2000.entities.KelompokUser;
|
||||
|
||||
@ -10,7 +9,5 @@ import com.jasamedika.medifirst2000.entities.KelompokUser;
|
||||
*
|
||||
* @author Roberto
|
||||
*/
|
||||
@Repository("KelompokUserDao")
|
||||
public interface KelompokUserDao extends
|
||||
PagingAndSortingRepository<KelompokUser, Integer> {
|
||||
public interface KelompokUserDao extends JpaRepository<KelompokUser, Integer> {
|
||||
}
|
||||
|
||||
@ -39,6 +39,7 @@ import static com.jasamedika.medifirst2000.constants.Master.JenisProduk.OBAT_ALK
|
||||
import static com.jasamedika.medifirst2000.constants.Master.KONSUL_VISIT;
|
||||
import static com.jasamedika.medifirst2000.constants.Master.KategoryPegawai.DOKTER_LUAR;
|
||||
import static com.jasamedika.medifirst2000.constants.Master.KelompokPasien.KELOMPOK_BPJS;
|
||||
import static com.jasamedika.medifirst2000.constants.Master.LoginUser.TATA_REKENING;
|
||||
import static com.jasamedika.medifirst2000.constants.Master.Ruangan.*;
|
||||
import static com.jasamedika.medifirst2000.constants.Master.SubUnitKerja.*;
|
||||
import static com.jasamedika.medifirst2000.constants.Master.TipePegawai.PURNA_WAKTU;
|
||||
@ -2248,8 +2249,10 @@ public class PelayananPasienServiceImpl extends BaseVoServiceImpl implements Pel
|
||||
List<Integer> jabatanDiskonTarek = splitDataSettingDatafixed("jabatanDiskonTarek");
|
||||
List<Integer> listIdPegawai = mapPegawaiJabatanToUnitKerjaDao
|
||||
.findPegawaiIdByUnitKerjaIdAndJabatanId(unitKerjaDiskonTarek, jabatanDiskonTarek);
|
||||
boolean accessGranted = loginUserService.accessGranted(loginUserService.getLoginUser(), listIdPegawai);
|
||||
if (!accessGranted)
|
||||
LoginUser loginUser = loginUserService.getLoginUser();
|
||||
boolean accessGranted = loginUserService.accessGranted(loginUser, listIdPegawai);
|
||||
if (!accessGranted && kodeVoucher.isEmpty()
|
||||
|| !accessGranted && !loginUser.getKelompokUser().getId().equals(TATA_REKENING))
|
||||
throw new ServiceVOException("Tidak memiliki akses melakukan diskon");
|
||||
if (CommonUtil.isNotNullOrEmpty(kodeVoucher)) {
|
||||
diskonPaket(kodeVoucher, dtoList);
|
||||
|
||||
@ -1,224 +1,73 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.JoinColumn;
|
||||
import javax.persistence.ManyToOne;
|
||||
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 javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.util.Date;
|
||||
|
||||
import static javax.persistence.FetchType.LAZY;
|
||||
|
||||
/**
|
||||
* class HistoryLoginModulAplikasi
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "HistoryLoginModulAplikasi_S")
|
||||
@JsonIgnoreProperties({ "hibernateLazyInitializer", "handler" })
|
||||
public class HistoryLoginModulAplikasi extends BaseMaster {
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.historyloginmodulaplikasi_m_id_seq")
|
||||
@javax.persistence.SequenceGenerator(name = "public.historyloginmodulaplikasi_m_id_seq", sequenceName = "public.historyloginmodulaplikasi_m_id_seq", allocationSize = 1)
|
||||
@SequenceGenerator(name = "public.historyloginmodulaplikasi_m_id_seq", sequenceName = "public.historyloginmodulaplikasi_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@Caption(value = "Kode History Login")
|
||||
@NotNull(message = "Kd History Login tidak boleh kosong")
|
||||
@Column(name = "KdHistoryLogin", nullable = false)
|
||||
private Integer kdHistoryLogin;
|
||||
|
||||
public void setKdHistoryLogin(Integer kdHistoryLogin) {
|
||||
this.kdHistoryLogin = kdHistoryLogin;
|
||||
}
|
||||
|
||||
|
||||
public Integer getKdHistoryLogin() {
|
||||
return this.kdHistoryLogin;
|
||||
}
|
||||
|
||||
@NotNull(message = "Kd User tidak boleh kosong")
|
||||
@Caption(value = "Kode User")
|
||||
@Column(name = "KdUser", nullable = false, length = 5)
|
||||
@Column(name = "KdUser", nullable = false)
|
||||
private String kdUser;
|
||||
|
||||
public void setKdUser(String kdUser) {
|
||||
this.kdUser = kdUser;
|
||||
}
|
||||
|
||||
|
||||
public String getKdUser() {
|
||||
return this.kdUser;
|
||||
}
|
||||
|
||||
@Caption(value = "Id Pegawai")
|
||||
@Column(name = "IdPegawai")
|
||||
private Integer idPegawai;
|
||||
|
||||
public void setIdPegawai(Integer idPegawai) {
|
||||
this.idPegawai = idPegawai;
|
||||
}
|
||||
|
||||
|
||||
public Integer getIdPegawai() {
|
||||
return this.idPegawai;
|
||||
}
|
||||
|
||||
@Caption(value = "Nama Host")
|
||||
@NotNull(message = "Nama Host tidak boleh kosong")
|
||||
@Column(name = "NamaHost", nullable = false, length = 50)
|
||||
@Column(name = "NamaHost", nullable = false)
|
||||
private String namaHost;
|
||||
|
||||
public void setNamaHost(String namaHost) {
|
||||
this.namaHost = namaHost;
|
||||
}
|
||||
|
||||
public String getNamaHost() {
|
||||
return this.namaHost;
|
||||
}
|
||||
|
||||
@Caption(value = "Tanggal Login")
|
||||
@Column(name = "TglLogin", nullable = true)
|
||||
@Column(name = "TglLogin")
|
||||
private Date tglLogin;
|
||||
|
||||
public void setTglLogin(Date tglLogin) {
|
||||
this.tglLogin = tglLogin;
|
||||
}
|
||||
|
||||
|
||||
public Date getTglLogin() {
|
||||
return this.tglLogin;
|
||||
}
|
||||
|
||||
@Caption(value = "Tanggal Logout")
|
||||
@Column(name = "TglLogout", nullable = true)
|
||||
@Column(name = "TglLogout")
|
||||
private Date tglLogout;
|
||||
|
||||
public void setTglLogout(Date tglLogout) {
|
||||
this.tglLogout = tglLogout;
|
||||
}
|
||||
|
||||
public Date getTglLogout() {
|
||||
return this.tglLogout;
|
||||
}
|
||||
|
||||
//
|
||||
// Foreign Key
|
||||
//
|
||||
|
||||
|
||||
@Column(name = "ObjectModulAplikasiFk", insertable = false, updatable = false)
|
||||
private Integer modulAplikasiId;
|
||||
|
||||
public Integer getModulAplikasiId() {
|
||||
return modulAplikasiId;
|
||||
}
|
||||
|
||||
public void setModulAplikasiId(Integer modulAplikasiId) {
|
||||
this.modulAplikasiId = modulAplikasiId;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectModulAplikasiFk")
|
||||
@Caption(value = "Object Modul Aplikasi")
|
||||
private ModulAplikasi modulAplikasi;
|
||||
|
||||
public void setModulAplikasi(ModulAplikasi modulAplikasi) {
|
||||
this.modulAplikasi = modulAplikasi;
|
||||
}
|
||||
|
||||
public ModulAplikasi getModulAplikasi() {
|
||||
return this.modulAplikasi;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "ObjectRuanganUserFk", insertable = false, updatable = false)
|
||||
private Integer ruanganUserId;
|
||||
|
||||
public Integer getRuanganUserId() {
|
||||
return ruanganUserId;
|
||||
}
|
||||
|
||||
public void setRuanganUserId(Integer ruanganUserId) {
|
||||
this.ruanganUserId = ruanganUserId;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectRuanganUserFk")
|
||||
@NotNull(message = "Object Ruangan User Harus Diisi")
|
||||
@Caption(value = "Object Ruangan User")
|
||||
private Ruangan ruanganUser;
|
||||
|
||||
public void setRuanganUser(Ruangan ruanganUser) {
|
||||
this.ruanganUser = ruanganUser;
|
||||
}
|
||||
|
||||
@NotNull(message = "Kd Ruangan User tidak boleh kosong")
|
||||
public Ruangan getRuanganUser() {
|
||||
return this.ruanganUser;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy =
|
||||
* "kdhistorylogind") private Set<Anggaran> AnggaranDSet = new
|
||||
* HashSet<Anggaran>();
|
||||
*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy =
|
||||
* "kdhistorylogini") private Set<Anggaran> AnggaranISet = new
|
||||
* HashSet<Anggaran>();
|
||||
*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy =
|
||||
* "kdhistorylogins") private Set<Anggaran> AnggaranSSet = new
|
||||
* HashSet<Anggaran>();
|
||||
*
|
||||
* @JsonManagedReference
|
||||
*
|
||||
* @OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy =
|
||||
* "kdhistoryloginu") private Set<Anggaran> AnggaranUSet = new
|
||||
* HashSet<Anggaran>();
|
||||
*
|
||||
* public Set<Anggaran> getAnggaranUSet() { return AnggaranUSet; }
|
||||
*
|
||||
* public void setAnggaranUSet(Set<Anggaran> anggaranUSet) { AnggaranUSet =
|
||||
* anggaranUSet; }
|
||||
*
|
||||
* public Set<Anggaran> getAnggaranDSet() { return AnggaranDSet; }
|
||||
*
|
||||
* public void setAnggaranDSet(Set<Anggaran> anggaranDSet) { AnggaranDSet =
|
||||
* anggaranDSet; }
|
||||
*
|
||||
* public Set<Anggaran> getAnggaranISet() { return AnggaranISet; }
|
||||
*
|
||||
* public void setAnggaranISet(Set<Anggaran> anggaranISet) { AnggaranISet =
|
||||
* anggaranISet; }
|
||||
*
|
||||
* public Set<Anggaran> getAnggaranSSet() { return AnggaranSSet; }
|
||||
*
|
||||
* public void setAnggaranSSet(Set<Anggaran> anggaranSSet) { AnggaranSSet =
|
||||
* anggaranSSet; }
|
||||
*/
|
||||
|
||||
}
|
||||
@ -1,22 +1,21 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* class KelompokUser
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
@Entity // @Audited
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "KelompokUser_S")
|
||||
public class KelompokUser extends BaseMaster {
|
||||
|
||||
@ -25,39 +24,38 @@ public class KelompokUser extends BaseMaster {
|
||||
@Caption(value = "Kode Kelompok User")
|
||||
private Byte kdKelompokUser;
|
||||
|
||||
public void setKdKelompokUser(Byte kdKelompokUser) {
|
||||
this.kdKelompokUser = kdKelompokUser;
|
||||
}
|
||||
|
||||
public Byte getKdKelompokUser() {
|
||||
return this.kdKelompokUser;
|
||||
}
|
||||
|
||||
@NotNull(message = "Kelompok User tidak boleh kosong")
|
||||
@Column(name = "KelompokUser", nullable = false, length = 20)
|
||||
@Caption(value = "Kelompok User")
|
||||
private String kelompokUser;
|
||||
|
||||
public void setKelompokUser(String kelompokUser) {
|
||||
this.kelompokUser = kelompokUser;
|
||||
}
|
||||
@ManyToOne(fetch = FetchType.LAZY)
|
||||
@JoinColumn(name = "objecthistoryloginifk")
|
||||
@Caption(value = "History Login Modul Aplikasi I")
|
||||
private HistoryLoginModulAplikasi historyLoginModulAplikasiI;
|
||||
|
||||
public String getKelompokUser() {
|
||||
return this.kelompokUser;
|
||||
}
|
||||
@Column(name = "objecthistoryloginifk", insertable = false, updatable = false)
|
||||
private Integer historyLoginModulAplikasiIId;
|
||||
|
||||
@ManyToOne(fetch = FetchType.LAZY)
|
||||
@JoinColumn(name = "objecthistoryloginsfk")
|
||||
@Caption(value = "History Login Modul Aplikasi S")
|
||||
private HistoryLoginModulAplikasi historyLoginModulAplikasiS;
|
||||
|
||||
@Column(name = "objecthistoryloginsfk", insertable = false, updatable = false)
|
||||
private Integer historyLoginModulAplikasiSId;
|
||||
|
||||
@ManyToOne(fetch = FetchType.LAZY)
|
||||
@JoinColumn(name = "objecthistoryloginufk")
|
||||
@Caption(value = "History Login Modul Aplikasi U")
|
||||
private HistoryLoginModulAplikasi historyLoginModulAplikasiU;
|
||||
|
||||
@Column(name = "objecthistoryloginufk", insertable = false, updatable = false)
|
||||
private Integer historyLoginModulAplikasiUId;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.kelompokuser_m_id_seq")
|
||||
@javax.persistence.SequenceGenerator(name = "public.kelompokuser_m_id_seq", sequenceName = "public.kelompokuser_m_id_seq", allocationSize = 1)
|
||||
@SequenceGenerator(name = "public.kelompokuser_m_id_seq", sequenceName = "public.kelompokuser_m_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
public Integer getId() {
|
||||
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
}
|
||||
@ -1,33 +1,26 @@
|
||||
package com.jasamedika.medifirst2000.entities;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonBackReference;
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import javax.persistence.*;
|
||||
import javax.validation.constraints.NotNull;
|
||||
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.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.JoinColumn;
|
||||
import javax.persistence.ManyToOne;
|
||||
import javax.persistence.OneToMany;
|
||||
import javax.persistence.Table;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import static javax.persistence.FetchType.LAZY;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonBackReference;
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import com.jasamedika.medifirst2000.base.BaseMaster;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
|
||||
@SuppressWarnings("serial")
|
||||
@Getter
|
||||
@Setter
|
||||
@Entity
|
||||
@Table(name = "LoginUser_S")
|
||||
@JsonIgnoreProperties({ "hibernateLazyInitializer", "handler" })
|
||||
@Table(name = "loginuser_s")
|
||||
public class LoginUser extends BaseMaster {
|
||||
|
||||
public LoginUser() {}
|
||||
public LoginUser() {
|
||||
}
|
||||
|
||||
public LoginUser(String kataSandi, KelompokUser kelompokUser, String namaUser, String namaLengkap,
|
||||
String namaPanggilan, String nikIntern, String nipPns, String noIdentitas, String npwp, Integer id,
|
||||
@ -42,9 +35,8 @@ public class LoginUser extends BaseMaster {
|
||||
}
|
||||
|
||||
public LoginUser(Integer idLoginUser, String kataSandi, KelompokUser kelompokUser, String namaUser,
|
||||
String namaLengkap, String namaPanggilan, String nikIntern, String nipPns, String noIdentitas, String npwp,
|
||||
Integer id, String email, Integer ruanganId,
|
||||
String namaRuangan, String kdDepartemen, String namaDepartemen,
|
||||
String namaLengkap, String namaPanggilan, String nikIntern, String nipPns, String noIdentitas, String npwp,
|
||||
Integer id, String email, Integer ruanganId, String namaRuangan, String kdDepartemen, String namaDepartemen,
|
||||
Integer departemenId) {
|
||||
super();
|
||||
this.id = idLoginUser;
|
||||
@ -54,20 +46,6 @@ public class LoginUser extends BaseMaster {
|
||||
this.pegawai = new Pegawai(namaLengkap, namaPanggilan, nikIntern, nipPns, noIdentitas, npwp, id, email,
|
||||
ruanganId, namaRuangan, kdDepartemen, namaDepartemen, departemenId);
|
||||
}
|
||||
|
||||
// public LoginUser(Integer idLoginUser, String kataSandi, KelompokUser kelompokUser, String namaUser,
|
||||
// String namaLengkap, String namaPanggilan, String nikIntern, String nipPns, String noIdentitas, String npwp,
|
||||
// Integer unitKerjaId, String unitKerja, Integer id, String email, Integer ruanganId,
|
||||
// String namaRuangan, String kdDepartemen, String namaDepartemen,
|
||||
// Integer departemenId) {
|
||||
// super();
|
||||
// this.id = idLoginUser;
|
||||
// this.kataSandi = kataSandi;
|
||||
// this.kelompokUser = kelompokUser;
|
||||
// this.namaUser = namaUser;
|
||||
// this.pegawai = new Pegawai(namaLengkap, namaPanggilan, nikIntern, nipPns, noIdentitas, npwp,unitKerjaId,unitKerja, id, email,
|
||||
// ruanganId, namaRuangan, kdDepartemen, namaDepartemen, departemenId);
|
||||
// }
|
||||
|
||||
public LoginUser(Integer idLoginUser, KelompokUser kelompokUser, String namaUser, String namaLengkap,
|
||||
String namaPanggilan, String nikIntern, String nipPns, String noIdentitas, String npwp, Integer id,
|
||||
@ -80,14 +58,16 @@ public class LoginUser extends BaseMaster {
|
||||
this.pegawai = new Pegawai(namaLengkap, namaPanggilan, nikIntern, nipPns, noIdentitas, npwp, id, email,
|
||||
ruanganId, namaRuangan, kdDepartemen, namaDepartemen, departemenId);
|
||||
}
|
||||
public LoginUser(Integer idLoginUser,String namaUser){
|
||||
|
||||
public LoginUser(Integer idLoginUser, String namaUser) {
|
||||
super();
|
||||
this.id=idLoginUser;
|
||||
this.namaUser= namaUser;
|
||||
this.id = idLoginUser;
|
||||
this.namaUser = namaUser;
|
||||
}
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "public.LoginUser_S_id_seq")
|
||||
@javax.persistence.SequenceGenerator(name = "public.LoginUser_S_id_seq", sequenceName = "public.LoginUser_S_id_seq", allocationSize = 1)
|
||||
@SequenceGenerator(name = "public.LoginUser_S_id_seq", sequenceName = "public.LoginUser_S_id_seq", allocationSize = 1)
|
||||
@Column(name = "id")
|
||||
protected Integer id;
|
||||
|
||||
@ -96,16 +76,15 @@ public class LoginUser extends BaseMaster {
|
||||
@Caption(value = "Kata Sandi")
|
||||
private String kataSandi;
|
||||
|
||||
@ManyToOne
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectKelompokUserFk")
|
||||
@NotNull(message = "Kd Kelompok User tidak boleh kosong")
|
||||
@Caption(value = "Object Kelompok User")
|
||||
private KelompokUser kelompokUser;
|
||||
|
||||
@Column(name = "ObjectKelompokUserFk", insertable = false, updatable = false)
|
||||
private Integer kelompokUserId;
|
||||
|
||||
@ManyToOne
|
||||
@ManyToOne(fetch = LAZY)
|
||||
@JoinColumn(name = "ObjectPegawaiFk")
|
||||
@NotNull(message = "Kd Pegawai tidak boleh kosong")
|
||||
@Caption(value = "Object Pegawai")
|
||||
@ -123,81 +102,9 @@ public class LoginUser extends BaseMaster {
|
||||
@Column(name = "StatusLogin", nullable = false)
|
||||
@Caption(value = "Status Login")
|
||||
private Byte statusLogin;
|
||||
|
||||
|
||||
@JsonBackReference
|
||||
@OneToMany(cascade=CascadeType.ALL,fetch = FetchType.LAZY, mappedBy = "loginUser")
|
||||
@OneToMany(cascade = CascadeType.ALL, fetch = LAZY, mappedBy = "loginUser")
|
||||
private Set<MapLoginUserToRuangan> mapLoginUserToRuanganSet = new HashSet<>();
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getKataSandi() {
|
||||
return kataSandi;
|
||||
}
|
||||
|
||||
public void setKataSandi(String kataSandi) {
|
||||
this.kataSandi = kataSandi;
|
||||
}
|
||||
|
||||
public KelompokUser getKelompokUser() {
|
||||
return kelompokUser;
|
||||
}
|
||||
|
||||
public void setKelompokUser(KelompokUser kelompokUser) {
|
||||
this.kelompokUser = kelompokUser;
|
||||
}
|
||||
|
||||
public Integer getKelompokUserId() {
|
||||
return kelompokUserId;
|
||||
}
|
||||
|
||||
public void setKelompokUserId(Integer kelompokUserId) {
|
||||
this.kelompokUserId = kelompokUserId;
|
||||
}
|
||||
|
||||
public Pegawai getPegawai() {
|
||||
return pegawai;
|
||||
}
|
||||
|
||||
public void setPegawai(Pegawai pegawai) {
|
||||
this.pegawai = pegawai;
|
||||
}
|
||||
|
||||
public Integer getPegawaiId() {
|
||||
return pegawaiId;
|
||||
}
|
||||
|
||||
public void setPegawaiId(Integer pegawaiId) {
|
||||
this.pegawaiId = pegawaiId;
|
||||
}
|
||||
|
||||
public String getNamaUser() {
|
||||
return namaUser;
|
||||
}
|
||||
|
||||
public void setNamaUser(String namaUser) {
|
||||
this.namaUser = namaUser;
|
||||
}
|
||||
|
||||
public Byte getStatusLogin() {
|
||||
return statusLogin;
|
||||
}
|
||||
|
||||
public void setStatusLogin(Byte statusLogin) {
|
||||
this.statusLogin = statusLogin;
|
||||
}
|
||||
|
||||
public Set<MapLoginUserToRuangan> getMapLoginUserToRuanganSet() {
|
||||
return mapLoginUserToRuanganSet;
|
||||
}
|
||||
|
||||
public void setMapLoginUserToRuanganSet(Set<MapLoginUserToRuangan> mapLoginUserToRuanganSet) {
|
||||
this.mapLoginUserToRuanganSet = mapLoginUserToRuanganSet;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -2,104 +2,45 @@ package com.jasamedika.medifirst2000.vo;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||
import com.fasterxml.jackson.annotation.JsonInclude.Include;
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* class HistoryLoginModulAplikasi
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
|
||||
@JsonInclude(Include.ALWAYS)
|
||||
@Getter
|
||||
@Setter
|
||||
public class HistoryLoginModulAplikasiVO extends BaseMasterVO {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = 6745739408088584653L;
|
||||
|
||||
@Caption(value = "Kode Histori Login")
|
||||
private Integer kdHistoryLogin;
|
||||
|
||||
@Caption(value = "Kode User")
|
||||
private String kdUser;
|
||||
|
||||
@Caption(value = "Id Pegawai")
|
||||
private Integer idPegawai;
|
||||
|
||||
@Caption(value = "Nama Host")
|
||||
private String namaHost;
|
||||
|
||||
@Caption(value = "Tanggal Login")
|
||||
private Date tglLogin;
|
||||
private Date tglLogout;
|
||||
|
||||
@Caption(value = "Tanggal Logout")
|
||||
private Date tglLogout;
|
||||
|
||||
private Integer modulAplikasiId;
|
||||
|
||||
@Caption(value = "Modul Aplikasi")
|
||||
private ModulAplikasiVO modulAplikasi;
|
||||
|
||||
private Integer ruanganUserId;
|
||||
|
||||
@Caption(value = "Ruangan User")
|
||||
private RuanganVO ruanganUser;
|
||||
|
||||
public void setKdHistoryLogin(Integer kdHistoryLogin) {
|
||||
this.kdHistoryLogin = kdHistoryLogin;
|
||||
}
|
||||
|
||||
public Integer getKdHistoryLogin() {
|
||||
return this.kdHistoryLogin;
|
||||
}
|
||||
|
||||
public void setModulAplikasi(ModulAplikasiVO modulAplikasi) {
|
||||
this.modulAplikasi = modulAplikasi;
|
||||
}
|
||||
|
||||
public ModulAplikasiVO getModulAplikasi() {
|
||||
return this.modulAplikasi;
|
||||
}
|
||||
|
||||
public Integer getModulAplikasiId() {
|
||||
return modulAplikasiId;
|
||||
}
|
||||
|
||||
public void setModulAplikasiId(Integer modulAplikasiId) {
|
||||
this.modulAplikasiId = modulAplikasiId;
|
||||
}
|
||||
|
||||
public Integer getRuanganUserId() {
|
||||
return ruanganUserId;
|
||||
}
|
||||
|
||||
public void setRuanganUserId(Integer ruanganUserId) {
|
||||
this.ruanganUserId = ruanganUserId;
|
||||
}
|
||||
|
||||
public void setRuanganUser(RuanganVO ruanganUser) {
|
||||
this.ruanganUser = ruanganUser;
|
||||
}
|
||||
|
||||
public RuanganVO getRuanganUser() {
|
||||
return this.ruanganUser;
|
||||
}
|
||||
|
||||
public void setKdUser(String kdUser) {
|
||||
this.kdUser = kdUser;
|
||||
}
|
||||
|
||||
public String getKdUser() {
|
||||
return this.kdUser;
|
||||
}
|
||||
|
||||
public void setNamaHost(String namaHost) {
|
||||
this.namaHost = namaHost;
|
||||
}
|
||||
|
||||
public String getNamaHost() {
|
||||
return this.namaHost;
|
||||
}
|
||||
|
||||
public void setTglLogin(Date tglLogin) {
|
||||
this.tglLogin = tglLogin;
|
||||
}
|
||||
|
||||
public Date getTglLogin() {
|
||||
return this.tglLogin;
|
||||
}
|
||||
|
||||
public void setTglLogout(Date tglLogout) {
|
||||
this.tglLogout = tglLogout;
|
||||
}
|
||||
|
||||
public Date getTglLogout() {
|
||||
return this.tglLogout;
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,51 +1,36 @@
|
||||
package com.jasamedika.medifirst2000.vo;
|
||||
|
||||
import java.io.Serializable;
|
||||
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;
|
||||
|
||||
/**
|
||||
* class KelompokUser
|
||||
* class KelompokUser
|
||||
*
|
||||
* @author Generator
|
||||
*/
|
||||
//@Entity
|
||||
//@Table(name = "KelompokUser_S")
|
||||
@Getter
|
||||
@Setter
|
||||
public class KelompokUserVO extends BaseMasterVO {
|
||||
@Caption(value="Kode Kelompok User")
|
||||
@Caption(value = "Kode Kelompok User")
|
||||
private Byte kdKelompokUser;
|
||||
|
||||
public void setKdKelompokUser(Byte kdKelompokUser) {
|
||||
this.kdKelompokUser = kdKelompokUser;
|
||||
}
|
||||
|
||||
@Column(name = "KdKelompokUser", nullable = false )
|
||||
public Byte getKdKelompokUser(){
|
||||
return this.kdKelompokUser;
|
||||
}
|
||||
|
||||
@Caption(value="Kelompok User")
|
||||
@Caption(value = "Kelompok User")
|
||||
private String kelompokUser;
|
||||
|
||||
public void setKelompokUser(String kelompokUser) {
|
||||
this.kelompokUser = kelompokUser;
|
||||
}
|
||||
@Caption(value = "History Login Modul Aplikasi I")
|
||||
private HistoryLoginModulAplikasiVO historyLoginModulAplikasiI;
|
||||
|
||||
@Column(name = "KelompokUser", nullable = false , length = 20)
|
||||
public String getKelompokUser(){
|
||||
return this.kelompokUser;
|
||||
}
|
||||
private Integer historyLoginModulAplikasiIId;
|
||||
|
||||
@Caption(value = "History Login Modul Aplikasi S")
|
||||
private HistoryLoginModulAplikasiVO historyLoginModulAplikasiS;
|
||||
|
||||
private Integer historyLoginModulAplikasiSId;
|
||||
|
||||
@Caption(value = "History Login Modul Aplikasi U")
|
||||
private HistoryLoginModulAplikasiVO historyLoginModulAplikasiU;
|
||||
|
||||
private Integer historyLoginModulAplikasiUId;
|
||||
}
|
||||
|
||||
|
||||
@ -3,101 +3,43 @@ package com.jasamedika.medifirst2000.vo;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import javax.persistence.CascadeType;
|
||||
import javax.persistence.FetchType;
|
||||
import javax.persistence.ManyToOne;
|
||||
import javax.persistence.OneToMany;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
|
||||
import com.jasamedika.medifirst2000.helper.Caption;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
@SuppressWarnings("serial")
|
||||
@Getter
|
||||
@Setter
|
||||
public class LoginUserVO extends BaseMasterVO {
|
||||
|
||||
@NotNull(message="Kata Sandi tidak boleh kosong")
|
||||
@Caption(value="Kata Sandi")
|
||||
|
||||
@NotNull(message = "Kata Sandi tidak boleh kosong")
|
||||
@Caption(value = "Kata Sandi")
|
||||
private String kataSandi;
|
||||
|
||||
@ManyToOne
|
||||
@NotNull(message="Kd Kelompok User tidak boleh kosong")
|
||||
@Caption(value="Object Kelompok User")
|
||||
|
||||
@Caption(value = "Object Kelompok User")
|
||||
private KelompokUserVO kelompokUser;
|
||||
|
||||
@ManyToOne
|
||||
@NotNull(message="Kd Pegawai tidak boleh kosong")
|
||||
@Caption(value="Object Pegawai")
|
||||
private Integer kelompokUserId;
|
||||
|
||||
@NotNull(message = "Kd Pegawai tidak boleh kosong")
|
||||
@Caption(value = "Object Pegawai")
|
||||
private PegawaiVO pegawai;
|
||||
|
||||
@NotNull(message="Nama User tidak boleh kosong")
|
||||
@Caption(value="Nama User")
|
||||
private Integer pegawaiId;
|
||||
|
||||
@NotNull(message = "Nama User tidak boleh kosong")
|
||||
@Caption(value = "Nama User")
|
||||
private String namaUser;
|
||||
|
||||
@NotNull(message="Status Login tidak boleh kosong")
|
||||
@Caption(value="Status Login")
|
||||
@NotNull(message = "Status Login tidak boleh kosong")
|
||||
@Caption(value = "Status Login")
|
||||
private Byte statusLogin;
|
||||
|
||||
@OneToMany(cascade=CascadeType.ALL,fetch = FetchType.LAZY, mappedBy = "loginUser")
|
||||
|
||||
private Set<MapLoginUserToRuanganVO> mapLoginUserToRuanganSet = new HashSet<>();
|
||||
|
||||
|
||||
private Set<MapPegawaiToModulAplikasiVO> mapPegawaiToModulAplikasiSet = new HashSet<>();
|
||||
|
||||
public String getKataSandi() {
|
||||
return kataSandi;
|
||||
}
|
||||
|
||||
public void setKataSandi(String kataSandi) {
|
||||
this.kataSandi = kataSandi;
|
||||
}
|
||||
|
||||
public KelompokUserVO getKelompokUser() {
|
||||
return kelompokUser;
|
||||
}
|
||||
|
||||
public void setKelompokUser(KelompokUserVO kelompokUser) {
|
||||
this.kelompokUser = kelompokUser;
|
||||
}
|
||||
|
||||
public PegawaiVO getPegawai() {
|
||||
return pegawai;
|
||||
}
|
||||
|
||||
public void setPegawai(PegawaiVO pegawai) {
|
||||
this.pegawai = pegawai;
|
||||
}
|
||||
|
||||
public String getNamaUser() {
|
||||
return namaUser;
|
||||
}
|
||||
|
||||
public void setNamaUser(String namaUser) {
|
||||
this.namaUser = namaUser;
|
||||
}
|
||||
|
||||
public Byte getStatusLogin() {
|
||||
return statusLogin;
|
||||
}
|
||||
|
||||
public void setStatusLogin(Byte statusLogin) {
|
||||
this.statusLogin = statusLogin;
|
||||
}
|
||||
|
||||
public Set<MapLoginUserToRuanganVO> getMapLoginUserToRuanganSet() {
|
||||
return mapLoginUserToRuanganSet;
|
||||
}
|
||||
|
||||
public void setMapLoginUserToRuanganSet(Set<MapLoginUserToRuanganVO> mapLoginUserToRuanganSet) {
|
||||
this.mapLoginUserToRuanganSet = mapLoginUserToRuanganSet;
|
||||
}
|
||||
|
||||
public Set<MapPegawaiToModulAplikasiVO> getMapPegawaiToModulAplikasiSet() {
|
||||
return mapPegawaiToModulAplikasiSet;
|
||||
}
|
||||
|
||||
public void setMapPegawaiToModulAplikasiSet(Set<MapPegawaiToModulAplikasiVO> mapPegawaiToModulAplikasiSet) {
|
||||
this.mapPegawaiToModulAplikasiSet = mapPegawaiToModulAplikasiSet;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user