QUESTION #1

user := uadmin.User{}
uadmin.Get(&user, "id = 1")

Which function will be used to get the active session of the user?

A. user.GetActiveSession()
B. user.ActiveSession
C. uadmin.GetActiveSession
D. uadmin.ActiveSession()


QUESTION #2

user := uadmin.User{}
uadmin.Get(&user, "id = 1")

Which function will be used to get the OTP of the user?

A. user.GetUserOTP
B. user.GetOTP
C. user.GetUserOTP()
D. user.GetOTP()


QUESTION #3

user := uadmin.User{}
uadmin.Get(&user, "id = 1")

Which function will be used to get the list of models in the dashboard menu?

A. user.DashboardMenu()
B. user.GetDashboardMenu()
C. user.DashboardMenu
D. user.GetDashboardMenu


QUESTION #4

user := uadmin.User{}
uadmin.Get(&user, "id = 1")

Which function will be used to return the first name and last name of the user?

A. user.FullName()
B. user.Name()
C. user.String()
D. user.Username()


QUESTION #5

user := uadmin.User{}
uadmin.Get(&user, "id = 1")

Which function will be used to validate the user?

A. user.Validate()
B. user.Validate
C. user.ValidateUser()
D. user.ValidateUser


QUESTION #6

Suppose you have this model as shown below:

USER PERMISSION DASHBOARD MENU USER READ ADD EDIT DELETE
1 Papers John Doe Check Check Error Error

Which uAdmin function will match the given statement above?

A. userpermission := uadmin.UserPermission {
                DashboardMenuID: 1,
                UserID: 1,
                Read: false,
                Add: false,
                Edit: true,
                Delete: true,
        }


B. userpermission := uadmin.UserPermission {
                DashboardMenuID: 1,
                UserID: 1,
                Read: true,
                Add: false,
                Edit: true,
                Delete: false,
        }


C. userpermission := uadmin.UserPermission {
                DashboardMenuID: 1,
                UserID: 1,
                Read: true,
                Add: true,
                Edit: false,
                Delete: false,
        }


D. userpermission := uadmin.UserPermission {
                DashboardMenuID: 1,
                UserID: 1,
                Read: false,
                Add: true,
                Edit: true,
                Delete: false,
        }



QUESTION #7

Suppose you have this model as shown below:

USER PERMISSION DASHBOARD MENU USER READ ADD EDIT DELETE
1 Headsets Allen Dale Check Error Error Check

Which uAdmin function will match the given statement above?

A. userpermission := uadmin.UserPermission {
                DashboardMenuID: 1,
                UserID: 1,
                Read: true,
                Add: false,
                Edit: false,
                Delete: true,
        }


B. userpermission := uadmin.UserPermission {
                DashboardMenuID: 1,
                UserID: 1,
                Read: false,
                Add: true,
                Edit: true,
                Delete: false,
        }


C. userpermission := uadmin.UserPermission {
                DashboardMenuID: 1,
                UserID: 1,
                Read: true,
                Add: false,
                Edit: true,
                Delete: false,
        }


D. userpermission := uadmin.UserPermission {
                DashboardMenuID: 1,
                UserID: 1,
                Read: false,
                Add: true,
                Edit: false,
                Delete: true,
        }



QUESTION #8

Suppose you have this model as shown below:

USER PERMISSION DASHBOARD MENU USER READ ADD EDIT DELETE
1 Flowers Jane Doe Error Check Error Check

Code:

flower := uadmin.DashboardMenu {
        MenuName: "Flowers",
}
user := uadmin.User {
        FirstName: "Jane",
        LastName: "Doe",
}

Which uAdmin function will match the given statement above?

A. userpermission := uadmin.UserPermission {
                DashboardMenu: flower,
                User: user,
                Read: true,
                Add: false,
                Edit: true,
                Delete: true,
        }


B. userpermission := uadmin.UserPermission {
                DashboardMenu: flower,
                User: user,
                Read: false,
                Add: false,
                Edit: true,
                Delete: true,
        }


C. userpermission := uadmin.UserPermission {
                DashboardMenu: flower,
                User: user,
                Read: false,
                Add: true,
                Edit: true,
                Delete: false,
        }


D. userpermission := uadmin.UserPermission {
                DashboardMenu: flower,
                User: user,
                Read: false,
                Add: true,
                Edit: false,
                Delete: true,
        }



QUESTION #9

Suppose you have this model as shown below:

USER PERMISSION DASHBOARD MENU USER READ ADD EDIT DELETE
1 Baskets Cierra Culler Check Error Check Error

Code:

basket := uadmin.DashboardMenu {
        MenuName: "Baskets",
}
user := uadmin.User {
        FirstName: "Cierra",
        LastName: "Culler",
}

Which uAdmin function will match the given statement above?

A. userpermission := uadmin.UserPermission {
                DashboardMenu: basket,
                User: user,
                Read: true,
                Add: false,
                Edit: false,
                Delete: true,
        }


B. userpermission := uadmin.UserPermission {
                DashboardMenu: basket,
                User: user,
                Read: true,
                Add: false,
                Edit: true,
                Delete: false,
        }


C. userpermission := uadmin.UserPermission {
                DashboardMenu: basket,
                User: user,
                Read: true,
                Add: false,
                Edit: true,
                Delete: true,
        }


D. userpermission := uadmin.UserPermission {
                DashboardMenu: basket,
                User: user,
                Read: true,
                Add: true,
                Edit: false,
                Delete: true,
        }



QUESTION #10

Suppose you have this model as shown below:

USER PERMISSION DASHBOARD MENU USER READ ADD EDIT DELETE
1 Chocolates Caroline Stoltenberg Check Check Error Check

Code:

chocolate := uadmin.DashboardMenu {
        MenuName: "Chocolates",
}
user := uadmin.User {
        FirstName: "Caroline",
        LastName: "Stoltenberg",
}

Which uAdmin function will match the given statement above?

A. userpermission := uadmin.UserPermission {
                DashboardMenu: chocolate,
                User: user,
                Read: true,
                Add: false,
                Edit: true,
                Delete: true,
        }


B. userpermission := uadmin.UserPermission {
                DashboardMenu: chocolate,
                User: user,
                Read: true,
                Add: true,
                Edit: true,
                Delete: false,
        }


C. userpermission := uadmin.UserPermission {
                DashboardMenu: chocolate,
                User: user,
                Read: true,
                Add: true,
                Edit: false,
                Delete: false,
        }


D. userpermission := uadmin.UserPermission {
                DashboardMenu: chocolate,
                User: user,
                Read: true,
                Add: true,
                Edit: false,
                Delete: true,
        }



QUESTION #11

Suppose you have this model as shown below:

USER USERNAME FIRST NAME LAST NAME EMAIL ACTIVE ADMIN REMOTE ACCESS USER GROUP PHOTO LAST LOGIN EXPIRES ON OTP REQUIRED
Lizette Diez lizette Lizette Diez lizette.diez@gmail.com Check Check Error 2019-05-02 12:14:18 Error

Which uAdmin function will match the given statement above?

A. now := time.Now()
        user := uadmin.User {
                Username: "lizette",
                FirstName: "Lizette",
                LastName: "Diez",
                Email: "lizette.diez@gmail.com",
                Active: true,
                Admin: true,
                RemoteAccess: false,
                LastLogin: now,
                OTPRequired: false,
        }


B. now := time.Now()
        user := uadmin.User {
                Username: "lizette",
                FirstName: "Lizette",
                LastName: "Diez",
                Email: "lizette.diez@gmail.com",
                Active: true,
                Admin: true,
                RemoteAccess: false,
                LastLogin: &now,
                OTPRequired: false,
        }


C. now := time.Now()
        user := uadmin.User {
                Username: "lizette",
                FirstName: "Lizette",
                LastName: "Diez",
                Email: "lizette.diez@gmail.com",
                Active: true,
                Admin: false,
                RemoteAccess: false,
                LastLogin: &now,
                OTPRequired: false,
        }


D. now := time.Now()
        user := uadmin.User {
                Username: "lizzete",
                FirstName: "Lizzete",
                LastName: "Diez",
                Email: "lizzete.diez@gmail.com",
                Active: true,
                Admin: true,
                RemoteAccess: false,
                LastLogin: &now,
                OTPRequired: false,
        }



QUESTION #12

Suppose you have this model as shown below:

USER USERNAME FIRST NAME LAST NAME EMAIL ACTIVE ADMIN REMOTE ACCESS USER GROUP PHOTO LAST LOGIN EXPIRES ON OTP REQUIRED
Elaina Nanez elaina Elaina Nanez elaina.nanez@gmail.com Check Error Check Girls of the Galaxy Girl 2019-06-14 08:06:19 2019-06-24 08:06:19 Check

Which uAdmin function will match the given statement above?

A. now := time.Now()
        expire := now.Local().Add(time.Hour * 24 * 10)
        user := uadmin.User {
                Username: "elaina",
                FirstName: "Elaina",
                LastName: "Nanez",
                Email: "elaina.nanez@gmail.com",
                Active: true,
                Admin: false,
                RemoteAccess: true,
                UserGroup: "Girls of the Galaxy",
                Photo: "girl.png",
                LastLogin: &now,
                ExpiresOn: &expire,
                OTPRequired: true
        }


B. now := time.Now()
        expire := now.Local().Add(time.Hour * 24 * 10)
        user := uadmin.User {
                Username: "elaina",
                FirstName: "Elaina",
                LastName: "Nanez",
                Email: "elaina.nanez@gmail.com",
                Active: true,
                Admin: false,
                RemoteAccess: true,
                UserGroup: "Girls of the Galaxy",
                Photo: "girl.png",
                LastLogin: now,
                ExpiresOn: expire,
                OTPRequired: true,
        }


C. now := time.Now()
        expire := now.Local().Add(time.Hour * 24 * 10)
        user := uadmin.User {
                Username: "elaina",
                FirstName: "Elaina",
                LastName: "Nanez",
                Email: "elaina.nanez@gmail.com",
                Active: true,
                Admin: false,
                RemoteAccess: true,
                UserGroup: "Girls of the Galaxy",
                Photo: "girl.png",
                LastLogin: &now,
                ExpiresOn: &expire,
                OTPRequired: true,
        }


D. now := time.Now()
        expire := now.Local().Add(time.Hour * 24 * 10)
        user := uadmin.User {
                Username: "elaina",
                FirstName: "Elaina",
                LastName: "Nanez",
                Email: "elaina.nanez@gmail.com",
                Active: true,
                Admin: false,
                RemoteAccess: false,
                UserGroup: "Girls of the Galaxy",
                Photo: "girl.png",
                LastLogin: &now,
                ExpiresOn: &expire,
                OTPRequired: true,
        }