add new relational table requests
This commit is contained in:
@@ -38,6 +38,11 @@ func GetCurrentDay(loc *time.Location) string {
|
||||
return fmt.Sprint(time.Now().In(loc).Weekday())
|
||||
}
|
||||
|
||||
func GetDayFromDate(dateTime string) (string, error) {
|
||||
t, err := time.Parse("2006-01-02 15:04:05", dateTime)
|
||||
return fmt.Sprint(t.Weekday()), err
|
||||
}
|
||||
|
||||
func HashField(field string, token []byte) string {
|
||||
h := hmac.New(sha256.New, token)
|
||||
h.Write([]byte(field))
|
||||
|
||||
Reference in New Issue
Block a user