Show / Hide Table of Contents

Class WorkflowSentry

WorkflowSentry guards Workflow entities. It is using visiblefor to make sure you can only see or modify what you should be able to.

Inheritance
object
Sentry
Sentry<WorkflowTableInfo>
WorkflowSentry
Implements
ICloneable
Inherited Members
Sentry<WorkflowTableInfo>.GetInterestingFieldsInTable(TableInfo)
Sentry<WorkflowTableInfo>.InterestedInAnyInstanceOf<T>()
Sentry<WorkflowTableInfo>.SuperComputeDerivedTableRights()
Sentry<WorkflowTableInfo>.ComputeDerivedTableRight(TableRight)
Sentry<WorkflowTableInfo>.SuperComputeTableRights()
Sentry<WorkflowTableInfo>.AddInterestingTables(params TableInfo[])
Sentry<WorkflowTableInfo>.ComputeLicenseExpiration()
Sentry<WorkflowTableInfo>.SuperComputeFieldRights()
Sentry<WorkflowTableInfo>.CanCoverTable(TableInfo)
Sentry<WorkflowTableInfo>.IsTableCovered(TableInfo)
Sentry<WorkflowTableInfo>.SetAllTableRights(ETableRight, string)
Sentry<WorkflowTableInfo>.GetOwnerFieldRight()
Sentry<WorkflowTableInfo>.AnalyzeQuery(PrivateSelect)
Sentry<WorkflowTableInfo>.ToString()
Sentry<WorkflowTableInfo>.InterestingFields
Sentry<WorkflowTableInfo>.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(params FieldInfo[])
Sentry.GetPersistedIntField(params FieldInfo[])
Sentry.GetIsGhostField(FieldInfo)
Sentry.GetDateTimeField(FieldInfo)
Sentry.GetStringField(FieldInfo)
Sentry.ClearRights()
Sentry.GetRecordOwnershipIndex()
Sentry.GetRecordOwnershipIndex(int, int)
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, bool)
Sentry.CanFieldDo(FieldInfo, EFieldRight, bool)
Sentry.IsFieldCovered(FieldInfo)
Sentry.GetGroupFromAssociate(int)
Sentry.IsContactDatabaseOwner(int)
Sentry.IsContactEmployeeUserOwner(int)
Sentry.IsContactSatelliteOwner(int)
Sentry.IsContactLicenseOwner(int)
Sentry.IsContactCurrentDatabaseOwner(int)
Sentry.IsPersonAssociate(int, bool)
Sentry.IsAssociatesOwnerContact(int, int)
Sentry.Lookups
Sentry.Parent
Sentry.Registered
Sentry.RegisteredAssociateId
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
Namespace: SuperOffice.CRM.Security
Assembly: SoDataBase.dll
Syntax
public class WorkflowSentry : Sentry<WorkflowTableInfo>, ICloneable

Constructors

WorkflowSentry(WorkflowTableInfo)

Create a Workflow sentry.

Declaration
public WorkflowSentry(WorkflowTableInfo tableInfo)
Parameters
Type Name Description
WorkflowTableInfo tableInfo

WorkflowSentry(WorkflowTableInfo, 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 WorkflowSentry(WorkflowTableInfo tableInfo, ISoDataLookup lookup)
Parameters
Type Name Description
WorkflowTableInfo tableInfo
ISoDataLookup lookup

Properties

AssociateId

Workflows associate id

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

GroupId

WorkflowTile's Group id

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

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
Sentry.IsGhostRow

IsNew

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

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

MainTable

Return table info.

Declaration
protected WorkflowTableInfo MainTable { get; }
Property Value
Type Description
WorkflowTableInfo

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

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

RowId

Should return a the primary key value

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

Status

WorkflowSentry guards Workflow entities. It is using visiblefor to make sure you can only see or modify what you should be able to.

Declaration
public WorkflowDefinitionStatus Status { get; }
Property Value
Type Description
WorkflowDefinitionStatus

Methods

ComputeDerivedTableRights()

Empty table copier function. Called after ComputeTableRights but before ComputeFieldRights. Default copy algorithm has been run, so the _tableRights array is fully populated. Gives sub-classes a chance to do their own funky thing. Publish and VisibleFor tables need to be handled

Declaration
protected override void ComputeDerivedTableRights()
Overrides
Sentry<WorkflowTableInfo>.ComputeDerivedTableRights()

ComputeFieldRights()

WorkflowSentry guards Workflow entities. It is using visiblefor to make sure you can only see or modify what you should be able to.

Declaration
protected override void ComputeFieldRights()
Overrides
Sentry<WorkflowTableInfo>.ComputeFieldRights()

ComputeTableRights()

Computes table rights for tables.

Declaration
protected override void ComputeTableRights()
Overrides
Sentry<WorkflowTableInfo>.ComputeTableRights()

GetMainRight()

Modify rights.

Declaration
public override ETableRight GetMainRight()
Returns
Type Description
ETableRight

Main TableRight.

Overrides
Sentry<WorkflowTableInfo>.GetMainRight()

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.

Overrides
Sentry.GetRowSentry()

GetTableInfoFromQuery<TargetTableInfo>()

Get tables of the given type from our query

Declaration
protected List<TargetTableInfo> GetTableInfoFromQuery<TargetTableInfo>() where TargetTableInfo : TableInfo
Returns
Type Description
List<TargetTableInfo>

List of tableinfos of the given type, from the query

Type Parameters
Name Description
TargetTableInfo

Type of table to look for

Implements

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