QUESTION #1

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Login Successful 0 JSON Data 2019-03-25 12:00:00

Code:

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

Which of the following will print the result as shown above?

A. log.SignIn(user, log.Action.LoginSuccessful(), r)
B. log.SignIn(user, uadmin.Action.LoginSuccessful(), r)
C. log.SignIn(user.Username, log.Action.LoginSuccessful(), r)
D. log.SignIn(user.Username, uadmin.Action.LoginSuccessful(), r)


QUESTION #2

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Login Denied 0 JSON Data 2019-03-25 12:00:00

Code:

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

Which of the following will print the result as shown above?

A. log.SignIn(user, log.Action.LoginDenied(), r)
B. log.SignIn(user.Username, log.Action.LoginDenied(), r)
C. log.SignIn(user, uadmin.Action.LoginDenied(), r)
D. log.SignIn(user.Username, uadmin.Action.LoginDenied(), r)


QUESTION #3

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Logout 0 JSON Data 2019-03-25 12:00:00

Code:

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

Which of the following will print the result as shown above?

A. log.SignIn(user.Username, uadmin.Action.Logout(), r)
B. log.SignIn(user.Username, log.Action.Logout(), r)
C. log.SignIn(user, uadmin.Action.Logout(), r)
D. log.SignIn(user, log.Action.Logout(), r)


QUESTION #4

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Password Reset Successful 0 JSON Data 2019-03-25 12:00:00

Code:

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

Which of the following will print the result as shown above?

A. log.PasswordReset(user.Username, log.Action.PasswordResetSuccessful(), r)/span>
B. log.PasswordReset(user, log.Action.PasswordResetSuccessful(), r)/span>
C. log.PasswordReset(user.Username, uadmin.Action.PasswordResetSuccessful(), r)/span>
D. log.PasswordReset(user, log.Action.PasswordResetSuccessful(), r)/span>


QUESTION #5

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Password Reset Request 0 JSON Data 2019-03-25 12:00:00

Code:

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

Which of the following will print the result as shown above?

A. log.PasswordReset(user.Username, uadmin.Action.PasswordResetRequest(), r)
B. log.PasswordReset(user, log.Action.PasswordResetRequest(), r)
C. log.PasswordReset(user, uadmin.Action.PasswordResetRequest(), r)
D. log.PasswordReset(user.Username, log.Action.PasswordResetRequest(), r)


QUESTION #6

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Password Reset Denied 0 JSON Data 2019-03-25 12:00:00

Code:

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

Which of the following will print the result as shown above?

A. log.PasswordReset(user, log.Action.PasswordResetDenied(), r)
B. log.PasswordReset(user.Username, uadmin.Action.PasswordResetDenied(), r)
C. log.PasswordReset(user, uadmin.Action.PasswordResetDenied(), r)
D. log.PasswordReset(user.Username, log.Action.PasswordResetDenied(), r)


QUESTION #7

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Read book 1 JSON Data 2019-03-25 12:00:00

Code:

session := uadmin.IsAuthenticated(r)
log := uadmin.Log{}
m, _ := uadmin.NewModel("book", true)
uadmin.Get(m.Interface(), "id = 1")

Condition: The ID of the Book model is 1.

Which of the following will print the result as shown above?

A. log.ParseRecord(m, "book", 1, &session.User, log.Action.Read(), r)
B. log.ParseRecord(m, "book", 1, &session.User, uadmin.Action.Read(), r)
C. log.ParseRecord(m, "book", 1, session.User, log.Action.Read(), r)
D. log.ParseRecord(m, "book", 1, session.User, uadmin.Action.Read(), r)


QUESTION #8

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Added restaurant 1 JSON Data 2019-03-25 12:00:00

Code:

session := uadmin.IsAuthenticated(r)
log := uadmin.Log{}
m, _ := uadmin.NewModel("restaurant", true)
uadmin.Get(m.Interface(), "id = 1")

Condition: The ID of the Restaurant model is 1.

Which of the following will print the result as shown above?

A. log.ParseRecord(m, "restaurant", 1, session.User, log.Action.Added(), r)
B. log.ParseRecord(m, "restaurant", 1, &session.User, log.Action.Added(), r)
C. log.ParseRecord(m, "restaurant", 1, session.User, uadmin.Action.Added(), r)
D. log.ParseRecord(m, "restaurant", 1, &session.User, uadmin.Action.Added(), r)


QUESTION #9

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Modified animal 1 JSON Data RollBack 2019-03-25 12:00:00

Code:

session := uadmin.IsAuthenticated(r)
log := uadmin.Log{}
m, _ := uadmin.NewModel("animal", true)
uadmin.Get(m.Interface(), "id = 1")

Condition: The ID of the Animal model is 1.

Which of the following will print the result as shown above?

A. log.ParseRecord(m, "animal", 1, session.User, uadmin.Action.Modified(), r)
B. log.ParseRecord(m, "animal", 1, session.User, log.Action.Modified(), r)
C. log.ParseRecord(m, "animal", 1, &session.User, log.Action.Modified(), r)
D. log.ParseRecord(m, "animal", 1, &session.User, uadmin.Action.Modified(), r)


QUESTION #10

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Deleted patient 1 JSON Data RollBack 2019-03-25 12:00:00

Code:

session := uadmin.IsAuthenticated(r)
log := uadmin.Log{}
m, _ := uadmin.NewModel("patient", true)
uadmin.Get(m.Interface(), "id = 1")

Condition: The ID of the Patient model is 1.

Which of the following will print the result as shown above?

A. log.ParseRecord(m, "patient", 1, session.User, log.Action.Deleted(), r)
B. log.ParseRecord(m, "patient", 1, &session.User, uadmin.Action.Deleted(), r)
C. log.ParseRecord(m, "patient", 1, &session.User, log.Action.Deleted(), r)
D. log.ParseRecord(m, "patient", 1, session.User, uadmin.Action.Deleted(), r)


QUESTION #11

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Custom account 1 JSON Data 2019-03-25 12:00:00

Which of the following will print the result as shown above?

A. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Custom,
                TableName: "account",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


B. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Custom(),
                TableName: "account",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


C. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action(0).Custom(),
                TableName: "account",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


D. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Custom()[0],
                TableName: "account",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }



QUESTION #12

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Read category 1 JSON Data 2019-03-25 12:00:00

Which of the following will print the result as shown above?

A. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Read(),
                TableName: "category",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


B. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Read()[0],
                TableName: "category",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


C. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Read,
                TableName: "category",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


D. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action(0).Read(),
                TableName: "category",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }



QUESTION #13

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Added movie 1 JSON Data 2019-03-25 12:00:00

Which of the following will print the result as shown above?

A. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action(0).Added(),
                TableName: "movie",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


B. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Added()[0],
                TableName: "movie",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


C. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Added,
                TableName: "movie",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }


D. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Added(),
                TableName: "movie",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "",
                CreatedAt: time.Now(),
        }



QUESTION #14

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Modified game 1 JSON Data RollBack 2019-03-25 12:00:00

Which of the following will print the result as shown above?

A. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Modified(),
                TableName: "game",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "/admin/revertHandler/?log_id=1",
                CreatedAt: time.Now(),
        }


B. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action(0).Modified(),
                TableName: "game",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "/admin/revertHandler/?log_id=1",
                CreatedAt: time.Now(),
        }


C. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Modified,
                TableName: "game",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "/admin/revertHandler/?log_id=1",
                CreatedAt: time.Now(),
        }


D. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Modified()[0],
                TableName: "game",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "/admin/revertHandler/?log_id=1",
                CreatedAt: time.Now(),
        }



QUESTION #15

Suppose you have this record as shown below:

LOG USERNAME ACTION TABLE NAME TABLE ACTIVITY ROLL BACK CREATED AT
1 admin Deleted duplicate 1 JSON Data RollBack 2019-03-25 12:00:00

Which of the following will print the result as shown above?

A. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Deleted,
                TableName: "duplicate",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "/admin/revertHandler/?log_id=1",
                CreatedAt: time.Now(),
        }


B. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Deleted()[0],
                TableName: "duplicate",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "/admin/revertHandler/?log_id=1",
                CreatedAt: time.Now(),
        }


C. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action.Deleted(),
                TableName: "duplicate",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "/admin/revertHandler/?log_id=1",
                CreatedAt: time.Now(),
        }


D. log := uadmin.Log{
                Username: "admin",
                Action: uadmin.Action(0).Deleted(),
                TableName: "duplicate",
                TableID: 1,
                Activity: "JSON Data",
                RollBack: "/admin/revertHandler/?log_id=1",
                CreatedAt: time.Now(),
        }