Documentation ¶
Index ¶
- func GetDataUserForAdmin(PublicKey, MongoEnv, dbname, colname string, r *http.Request) string
- func GetOneEmployee(PublicKey, MongoEnv, dbname, colname string, r *http.Request) string
- func InsertDataEmployee(MongoConn *mongo.Database, colname string, emp Employee) (InsertedID interface{})
- func InsertEmployee(MongoEnv, dbname, colname, publickey string, r *http.Request) string
- func IsAdmin(Tokenstr, PublicKey string) bool
- func IsHR(TokenStr, Publickey string) bool
- func Login(Privatekey, MongoEnv, dbname, Colname string, r *http.Request) string
- func Register(Mongoenv, dbname string, r *http.Request) string
- func UpdateDataEmployees(MongoEnv, dbname, publickey string, r *http.Request) string
- func UpdateEmployee(Mongoenv, dbname string, ctx context.Context, emp Employee) (UpdateId interface{})
- type Division
- type Employee
- type ResponseBack
- type ResponseEmployee
- type Updated
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetDataUserForAdmin ¶ added in v0.0.3
func GetOneEmployee ¶ added in v0.0.6
func InsertDataEmployee ¶ added in v0.0.6
func InsertEmployee ¶ added in v0.0.6
func UpdateDataEmployees ¶ added in v0.0.6
Types ¶
type Employee ¶ added in v0.0.6
type Employee struct { EmployeeId string `json:"employeeid" bson:"employeeid,omitempty"` Name string `json:"name" bson:"name,omitempty"` Email string `json:"email" bson:"email,omitempty"` Phone string `json:"phone" bson:"phone,omitempty"` Division Division `json:"division" bson:"division,omitempty"` Account pasproj.User `json:"account" bson:"account,omitempty"` }
type ResponseBack ¶
type ResponseEmployee ¶ added in v0.0.6
Click to show internal directories.
Click to hide internal directories.