fix get dokter

This commit is contained in:
2024-09-26 07:53:33 +07:00
parent d5b06ff328
commit 7a508c6691
5 changed files with 24 additions and 10 deletions

View File

@@ -21,7 +21,7 @@ func GetJadwalDokterByDate(hari string) ([]string, error) {
func GetJadwalDokterBySpesialis(hari string, spesialis string) ([]string, error) {
var listDokter []string
errSelect := config.SatuDataDB.Debug().Raw(`select "Dokter" from "daftar_jadwal_dokter" where "Nama_hari" = ? and Spesialis = ? order by "Spesialis"`, hari, spesialis).Scan(&listDokter).Error
errSelect := config.SatuDataDB.Debug().Raw(`select "Dokter" from "daftar_jadwal_dokter" where "Nama_hari" = ? and "Spesialis" = ? order by "Spesialis"`, hari, spesialis).Scan(&listDokter).Error
if errSelect != nil {
log.Printf("Failed get data : %v", errSelect)
return nil, errSelect