Show / Hide Table of Contents

Class DiaryViewRecordDataExtensions

Extension methods to make it easy to fetch DiaryViewRecordData objects from the database, using the infrastructure

Inheritance
System.Object
DiaryViewRecordDataExtensions
Namespace: SuperOffice.CRM.Rows
Assembly: SoDataBase.dll
Syntax
public static class DiaryViewRecordDataExtensions : Object

Methods

FromRecord(TargetedDataRecord<DiaryViewTableInfo>)

From a TargetedDataRecord<DiaryViewTableInfo>, create and populate a DiaryViewRecordData POCO object

Declaration
public static DiaryViewRecordData FromRecord(this TargetedDataRecord<DiaryViewTableInfo> record)
Parameters
Type Name Description
TargetedDataRecord<DiaryViewTableInfo> record
Returns
Type Description
DiaryViewRecordData
Examples
            var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
            /* add joins, return fields etc. as you wish */
            s.ReturnFields.Add(s.Table.All);
            var result = s.Records().Select(r => new { DiaryViewItem = r.FromRecord(), /* fetch other fields here */ });

FromSelect(TargetedSelect<DiaryViewTableInfo>)

From a TargetedSelect<DiaryViewTableInfo>, execute it and return an IEnumerable<DiaryViewRecordData> with the results

Declaration
public static IEnumerable<DiaryViewRecordData> FromSelect(this TargetedSelect<DiaryViewTableInfo> select)
Parameters
Type Name Description
TargetedSelect<DiaryViewTableInfo> select
Returns
Type Description
System.Collections.Generic.IEnumerable<DiaryViewRecordData>
Examples
            var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
            var result = s.FromSelect();

ToInsert(DiaryViewRecordData)

Declaration
public static Insert ToInsert(this DiaryViewRecordData record)
Parameters
Type Name Description
DiaryViewRecordData record
Returns
Type Description
Insert

ToInserts(IEnumerable<DiaryViewRecordData>)

Declaration
public static IEnumerable<Insert> ToInserts(this IEnumerable<DiaryViewRecordData> records)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<DiaryViewRecordData> records
Returns
Type Description
System.Collections.Generic.IEnumerable<Insert>

ToRecordData(DiaryViewRow)

Declaration
public static DiaryViewRecordData ToRecordData(this DiaryViewRow row)
Parameters
Type Name Description
DiaryViewRow row
Returns
Type Description
DiaryViewRecordData
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top