Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DbCollectionConstant = DbCollectionConstants{
DictionaryCollection: "dictionaries",
QuestionCollection: "questions",
OptionCollection: "options",
ArticleCollection: "articles",
CategoryCollection: "categories",
UserCollection: "users",
SavedCollection: "saved",
DIYCollection: "diy",
RewardCollection: "rewards",
BadgeCollection: "badges",
Badge_CollectionCollection: "badge_collections",
QuestionResultCollection: "question_results",
QuizResultCollection: "quiz_results",
ExchangedCollection: "exchanged",
QRCollection: "qrs",
}
Functions ¶
func ContainsElement ¶
func GetCurrentTime ¶
func GetDatabaseCollection ¶
func GetDatabaseCollection(name string, db *mongo.Client) *mongo.Collection
Types ¶
type DbCollectionConstants ¶
type DbCollectionConstants struct { DictionaryCollection string QuestionCollection string OptionCollection string ArticleCollection string CategoryCollection string UserCollection string SavedCollection string DIYCollection string RewardCollection string BadgeCollection string Badge_CollectionCollection string QuestionResultCollection string QuizResultCollection string ExchangedCollection string QRCollection string }
type Response ¶
type Response struct { Data interface{} `json:"data" bson:"data"` Message string `json:"message" bson:"message"` }
func FailedResponse ¶
func SuccessfulResponse ¶
type UserClaims ¶
type UserClaims struct { ISS string `json:"uuid"` AZP string `json:"azp"` AUD string `json:"aud"` SUB string `json:"sub"` Email string `json:"email"` EmailVerified bool `json:"email_verified"` Name string `json:"name"` Picture string `json:"picture"` GivenName string `json:"given_name"` FamilyName string `json:"family_name"` Locale string `json:"locale"` IAT int64 `json:"iat"` EXP int64 `json:"exp"` }
func CheckJwtIsValidateAndGetJwtDecoded ¶
func CheckJwtIsValidateAndGetJwtDecoded(jwt string) (UserClaims, bool)
Click to show internal directories.
Click to hide internal directories.