This commit is contained in:
@@ -31,7 +31,6 @@ type UserSecret struct {
|
|||||||
GroupId int `db:"GroupId" json:"groupId"`
|
GroupId int `db:"GroupId" json:"groupId"`
|
||||||
Group
|
Group
|
||||||
Permission
|
Permission
|
||||||
SafeName string `db:"SafeName"`
|
|
||||||
Secret
|
Secret
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -103,7 +102,7 @@ func SecretsGetAllowed(s *Secret, userId int) ([]UserSecret, error) {
|
|||||||
|
|
||||||
// Query for group access
|
// Query for group access
|
||||||
queryArgs := []interface{}{}
|
queryArgs := []interface{}{}
|
||||||
query := `SELECT users.UserId, users.GroupId, permissions.ReadOnly,
|
query := `SELECT users.UserId, users.GroupId, permissions.ReadOnly, permissions.SafeId AS PermSafeId,
|
||||||
secrets.SecretId, secrets.SafeId, secrets.DeviceName, secrets.DeviceCategory, secrets.UserName, secrets.Secret
|
secrets.SecretId, secrets.SafeId, secrets.DeviceName, secrets.DeviceCategory, secrets.UserName, secrets.Secret
|
||||||
FROM users
|
FROM users
|
||||||
INNER JOIN groups ON users.GroupId = groups.GroupId
|
INNER JOIN groups ON users.GroupId = groups.GroupId
|
||||||
|
Reference in New Issue
Block a user