forked from turbot/steampipe-plugin-salesforce
-
Notifications
You must be signed in to change notification settings - Fork 1
/
table_salesforce_permission_set_assignment.go
31 lines (28 loc) · 1.46 KB
/
table_salesforce_permission_set_assignment.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package salesforce
import (
"context"
"github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto"
"github.com/turbot/steampipe-plugin-sdk/v5/plugin"
)
func SalesforcePermissionSetAssignment(ctx context.Context, dm dynamicMap, config salesforceConfig) *plugin.Table {
tableName := "PermissionSetAssignment"
return &plugin.Table{
Name: "salesforce_permission_set_assignment",
Description: "Represents the association between a User and a PermissionSet.",
List: &plugin.ListConfig{
Hydrate: listSalesforceObjectsByTable(tableName, dm.salesforceColumns),
KeyColumns: dm.keyColumns,
},
Get: &plugin.GetConfig{
Hydrate: getSalesforceObjectbyID(tableName),
KeyColumns: plugin.SingleColumn(checkNameScheme(config, dm.cols)),
},
Columns: mergeTableColumns(ctx, config, dm.cols, []*plugin.Column{
{Name: "assignee_id", Type: proto.ColumnType_STRING, Description: "ID of the User to assign the permission set specified in PermissionSetId."},
{Name: "id", Type: proto.ColumnType_STRING, Description: "The Permission Set Assignment ID."},
{Name: "permission_set_group_id", Type: proto.ColumnType_STRING, Description: "If associated with a permission set group, this is the ID of that group."},
{Name: "permission_set_id", Type: proto.ColumnType_STRING, Description: "ID of the PermissionSet to assign to the user specified in AssigneeId."},
{Name: "system_modstamp", Type: proto.ColumnType_TIMESTAMP, Description: "The Date Assigned."},
}),
}
}