Show / Hide Table of Contents

Interface IDocumentPluginTravel

Optional interface that Document Plugins can choose to implement. It is called when starting and stopping an offline (Travel) session, and is generally used to copy centrally-stored documents to local storage and back again.

Namespace: SuperOffice.CRM.Documents
Assembly: SuperOffice.Plugins.dll
Syntax
public interface IDocumentPluginTravel

Methods

GoTravel(Int32, String, ProgressEstimateCallback, ProgressStepCallback)

Start a Travel (offline) session. This method is called at a time when both the central and local storage systems are available, and should copy or otherwise prepare for an offline session.

Declaration
ReturnInfo GoTravel(int associateId, string localArchiveRoot, ProgressEstimateCallback estimate, ProgressStepCallback step)
Parameters
Type Name Description
Int32 associateId

ID of associate who is the document owner

String localArchiveRoot

ROot directory of local archive. This is a value that is only known to the Travel system in the Windows client, so it has to be passed in as a parameter

ProgressEstimateCallback estimate

Callback to set the expected number of items to copy, to scale the progress bar

ProgressStepCallback step

Callback to advance the progress bar by one step

Returns
Type Description
ReturnInfo
Remarks

While offline, the following document archive items need to be available:

  • All templates, in all language variants
  • All documents for the current user, in the current period
  • All documents for the current user, in the previous period
A period is half a year. In May this would mean the Jul-Dec + Jan-Jun. Since there may be many templates, caching them between travel sessions is highly recommended, almost mandatory; otherwise template/document copying may be the major time consumer when going on travel.

HomeComing(Int32, String, ProgressEstimateCallback, ProgressStepCallback)

End a Travel (offline) session. This method is called at a time when both the central and local storage systems are available, and should update any documents whose content has been changed locally, into the central storage. Templates cannot be changed locally and should not be copied back!

Declaration
ReturnInfo HomeComing(int associateId, string centralArchiveRoot, ProgressEstimateCallback estimate, ProgressStepCallback step)
Parameters
Type Name Description
Int32 associateId

ID of associate who is the document owner

String centralArchiveRoot

Root directory of central! archive. This is a value that is only known to the Travel system in the Windows client at this time, so it has to be passed in as a parameter (ArchivePath points to the local archive)

ProgressEstimateCallback estimate

Callback to set the expected number of items to copy, to scale the progress bar

ProgressStepCallback step

Callback to advance the progress bar by one step

Returns
Type Description
ReturnInfo

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