Class DashboardSentry
DashboardSentry guards Dashboard entities. It is using datarights and visiblefor to make sure you can only see or modify what you should be able to.
Inheritance
Implements
Inherited Members
Namespace: SuperOffice.CRM.Security
Assembly: SoDataBase.dll
Syntax
public class DashboardSentry : RoleRightsSentry<DashboardTableInfo>, ICloneable
Constructors
DashboardSentry(DashboardTableInfo)
Create a DashboardTile sentry.
Declaration
public DashboardSentry(DashboardTableInfo tableInfo)
Parameters
Type | Name | Description |
---|---|---|
DashboardTableInfo | tableInfo |
DashboardSentry(DashboardTableInfo, ISoDataLookup)
Create a sentry for a particular row. The row's associate_id will control the user's permissions with respect to this row.
Declaration
public DashboardSentry(DashboardTableInfo tableInfo, ISoDataLookup lookup)
Parameters
Type | Name | Description |
---|---|---|
DashboardTableInfo | tableInfo | |
ISoDataLookup | lookup |
Properties
AssociateId
Dashboards associate id
Declaration
public override int AssociateId { get; }
Property Value
Type | Description |
---|---|
int |
Overrides
GroupId
DashboardTile's Group id
Declaration
public override int GroupId { get; }
Property Value
Type | Description |
---|---|
int |
Overrides
IsGhostRow
Returns whether the primary key is a ghost field (i.e., we're looking at a nonexistent record, as opposed to just looking at a new one)
Declaration
public override bool IsGhostRow { get; }
Property Value
Type | Description |
---|---|
bool |
Overrides
IsNew
Is the row saved to teh database (persisted primary key == 0)
Declaration
public override bool IsNew { get; }
Property Value
Type | Description |
---|---|
bool |
Overrides
MainTable
Return table info.
Declaration
protected DashboardTableInfo MainTable { get; }
Property Value
Type | Description |
---|---|
DashboardTableInfo |
RegisteredAssociateIdField
The field that holds the associate id of the user first creating the item.
Declaration
public override FieldInfo RegisteredAssociateIdField { get; }
Property Value
Type | Description |
---|---|
FieldInfo |
Overrides
RegisteredField
The field that holds information about when the item was first created.
Declaration
public override FieldInfo RegisteredField { get; }
Property Value
Type | Description |
---|---|
FieldInfo |
Overrides
RowId
Should return a the primary key value
Declaration
public override int RowId { get; }
Property Value
Type | Description |
---|---|
int |
Overrides
Methods
ComputeFieldRights()
DashboardSentry guards Dashboard entities. It is using datarights and visiblefor to make sure you can only see or modify what you should be able to.
Declaration
protected override void ComputeFieldRights()
Overrides
ComputeTableRights()
Computes table rights for tables.
Declaration
protected override void ComputeTableRights()
Overrides
GetMainRight()
Modify rights.
Declaration
public override ETableRight GetMainRight()
Returns
Type | Description |
---|---|
ETableRight | Main TableRight. |
Overrides
GetRowSentry()
Create a copy of the Sentry holding the right instances of table and field infos.
Declaration
public override Sentry GetRowSentry()
Returns
Type | Description |
---|---|
Sentry | New instance of the Sentry. |