module

package
v0.0.0-...-2eccd6b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 14, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var MongoInfo = atdb.DBInfo{
	DBString: MongoString,
	DBName:   "tesdb2024",
}
View Source
var MongoString string = os.Getenv("MONGOSTRING")

Functions

func DeletePresensiByID

func DeletePresensiByID(_id primitive.ObjectID, db *mongo.Database, col string) error

func GetAllPresensi

func GetAllPresensi(db *mongo.Database, col string) (data []model.Presensi)

func GetKaryawanFromPhoneNumber

func GetKaryawanFromPhoneNumber(phone_number string, db *mongo.Database, col string) (staf model.Presensi, errs error)

func GetPresensiFromID

func GetPresensiFromID(_id primitive.ObjectID, db *mongo.Database, col string) (presensi model.Presensi, errs error)

func InsertOneDoc

func InsertOneDoc(db string, collection string, doc interface{}) (insertedID interface{})

func InsertPresensi

func InsertPresensi(db *mongo.Database, col string, long float64, lat float64, lokasi string, phonenumber string, checkin string, biodata model.Karyawan) (insertedID primitive.ObjectID, err error)

func MongoConnect

func MongoConnect(dbname string) (db *mongo.Database)

func UpdatePresensi

func UpdatePresensi(db *mongo.Database, col string, id primitive.ObjectID, long float64, lat float64, lokasi string, phonenumber string, checkin string, biodata model.Karyawan) (err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL