Show / Hide Table of Contents

Class SelectionSentry

SelectionSentry guards Selection entities and their component rows. The SelectionSentry applies to the following classes: Selection, SelectionRow, TextRow, SelectionMemberRow

Inheritance
Object
Sentry
Sentry<SelectionTableInfo>
RoleRightsSentry<SelectionTableInfo>
SelectionSentry
Implements
ICloneable
Inherited Members
RoleRightsSentry<SelectionTableInfo>.RoleTableRights
RoleRightsSentry<SelectionTableInfo>.VisibleForRights
Sentry<SelectionTableInfo>.GetInterestingFieldsInTable(TableInfo)
Sentry<SelectionTableInfo>.InterestedInAnyInstanceOf<T>()
Sentry<SelectionTableInfo>.ComputeDerivedTableRights()
Sentry<SelectionTableInfo>.SuperComputeDerivedTableRights()
Sentry<SelectionTableInfo>.ComputeDerivedTableRight(TableRight)
Sentry<SelectionTableInfo>.SuperComputeTableRights()
Sentry<SelectionTableInfo>.AddInterestingTables(TableInfo[])
Sentry<SelectionTableInfo>.ComputeLicenseExpiration()
Sentry<SelectionTableInfo>.SuperComputeFieldRights()
Sentry<SelectionTableInfo>.CanCoverTable(TableInfo)
Sentry<SelectionTableInfo>.IsTableCovered(TableInfo)
Sentry<SelectionTableInfo>.SetAllTableRights(ETableRight, String)
Sentry<SelectionTableInfo>.GetOwnerFieldRight()
Sentry<SelectionTableInfo>.AnalyzeQuery(PrivateSelect)
Sentry<SelectionTableInfo>.ToString()
Sentry<SelectionTableInfo>.InterestingFields
Sentry<SelectionTableInfo>.SentryQueryInfo
Sentry.kTableRights
Sentry.kFieldRights
Sentry._tableRights
Sentry._fieldRights
Sentry._lookups
Sentry.DemandPlugins()
Sentry.CreateSentry(TableInfo)
Sentry.CreateSentries(Select)
Sentry.BeginIgnoreSentry()
Sentry.BeginIgnoreRowSentry()
Sentry.IgnoreRowSentry()
Sentry.IgnoreSentry()
Sentry.IterateLookups(LookupCollection)
Sentry.GetIntField(FieldInfo[])
Sentry.GetPersistedIntField(FieldInfo[])
Sentry.GetIsGhostField(FieldInfo)
Sentry.GetDateTimeField(FieldInfo)
Sentry.GetStringField(FieldInfo)
Sentry.ClearRights()
Sentry.GetRecordOwnershipIndex()
Sentry.GetRecordOwnershipIndex(Int32, Int32)
Sentry.MapTableToFieldRights(TableInfo, TableRight, FieldInfo[])
Sentry.MakeFieldFromTableRight(TableRight)
Sentry.MakeFieldFromTableRight(TableRight, ETableRight)
Sentry.MakeFieldFromTableRight(ETableRight)
Sentry.GetTableRight(TableInfo)
Sentry.GetFieldRight(FieldInfo)
Sentry.CanTableDo(TableInfo, ETableRight, Boolean)
Sentry.CanFieldDo(FieldInfo, EFieldRight, Boolean)
Sentry.IsFieldCovered(FieldInfo)
Sentry.GetGroupFromAssociate(Int32)
Sentry.IsContactDatabaseOwner(Int32)
Sentry.IsContactEmployeeUserOwner(Int32)
Sentry.IsContactSatelliteOwner(Int32)
Sentry.IsContactLicenseOwner(Int32)
Sentry.IsContactCurrentDatabaseOwner(Int32)
Sentry.IsPersonAssociate(Int32, Boolean)
Sentry.IsAssociatesOwnerContact(Int32, Int32)
Sentry.Lookups
Sentry.Parent
Sentry.Registered
Sentry.RegisteredAssociateId
Namespace: SuperOffice.CRM.Security
Assembly: SoDataBase.dll
Syntax
public class SelectionSentry : RoleRightsSentry<SelectionTableInfo>, ICloneable
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

Constructors

SelectionSentry(SelectionTableInfo)

Create a Selection sentry.

Declaration
public SelectionSentry(SelectionTableInfo selectionTableInfo)
Parameters
Type Name Description
SelectionTableInfo selectionTableInfo
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

SelectionSentry(SelectionTableInfo, ISoDataLookup)

Create a Selection sentry for a particular Selection row. The row's associate_id will control the user's permissions with respect to this row.

Declaration
public SelectionSentry(SelectionTableInfo selectionTableInfo, ISoDataLookup lookup)
Parameters
Type Name Description
SelectionTableInfo selectionTableInfo
ISoDataLookup lookup
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

Properties

AssociateId

Selection's associate id

Declaration
public override int AssociateId { get; }
Property Value
Type Description
Int32
Overrides
Sentry.AssociateId
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

GroupId

Selection's Group id

Declaration
public override int GroupId { get; }
Property Value
Type Description
Int32
Overrides
Sentry.GroupId
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

IsFindOrDashboardSelection

SelectionSentry guards Selection entities and their component rows. The SelectionSentry applies to the following classes: Selection, SelectionRow, TextRow, SelectionMemberRow

Declaration
public bool IsFindOrDashboardSelection { get; }
Property Value
Type Description
Boolean
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

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
Boolean
Overrides
Sentry.IsGhostRow
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

IsNew

Is the row saved to teh database (persisted primary key == 0)

Declaration
public override bool IsNew { get; }
Property Value
Type Description
Boolean
Overrides
Sentry.IsNew
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

MainTable

Return Selection table info.

Declaration
protected SelectionTableInfo MainTable { get; }
Property Value
Type Description
SelectionTableInfo
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

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
Sentry.RegisteredAssociateIdField
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

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
Sentry.RegisteredField
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

RowId

Should return a Selection.Selection_id

Declaration
public override int RowId { get; }
Property Value
Type Description
Int32
Overrides
Sentry.RowId
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

Visibility

Selection's Visibility flag

Declaration
public int Visibility { get; }
Property Value
Type Description
Int32
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

Methods

ComputeFieldRights()

Disable the selection kind field if it is 'static', since a static selection cannot be converted to a dynamic one

Declaration
protected override void ComputeFieldRights()
Overrides
SuperOffice.CRM.Security.Sentry<SuperOffice.CRM.Data.SelectionTableInfo>.ComputeFieldRights()
Remarks

In SIX.win, this is GUI logic in GUI/SelectionCardView, ::HandleEnableDisableEdit, line 195...

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

ComputeTableRights()

Computes table rights for Selection tables. Deny delete and update to Selections which belong to other associates. If the current is an user or general admin, full rights are granted.

Declaration
protected override void ComputeTableRights()
Overrides
SuperOffice.CRM.Security.Sentry<SuperOffice.CRM.Data.SelectionTableInfo>.ComputeTableRights()
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

GetMainRight()

Modify rights so persons that can administer users can see and delete their selections.

Declaration
public override ETableRight GetMainRight()
Returns
Type Description
ETableRight

Main TableRight for Selection.

Overrides
SuperOffice.CRM.Security.RoleRightsSentry<SuperOffice.CRM.Data.SelectionTableInfo>.GetMainRight()
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

GetRowSentry()

SelectionSentry guards Selection entities and their component rows. The SelectionSentry applies to the following classes: Selection, SelectionRow, TextRow, SelectionMemberRow

Declaration
public override Sentry GetRowSentry()
Returns
Type Description
Sentry
Overrides
Sentry.GetRowSentry()
Remarks

The Selection row automatically creates a sentry, because Selection is also an RDB Entity. The text row does not create a sentry because it does not know which entity it belongs to, so we have to give it a sentry to use. The text row will ask the Selection sentry about its permissions.

Examples

SelectionRow p = new SelectionRow.IdxSelectionId(1234); TextRow t = new TextRow.IdxTextId( c.TextId ); t.Sentries.Add( p.Sentries );

Implements

System.ICloneable

Extension Methods

EnumUtil.MapEnums<From, To>(From)
Converters.MapEnums<From, To>(From)
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top