Skip to content

Office.Cloud.Microsoft.Todo

apobekiaris edited this page Jun 27, 2020 · 20 revisions

GitHub issues GitHub close issues

About

This package provides a two way synchronization between XAF Bushiness objects that implement the ITask interface and the Office365 OutlookTask entities.

Details

This is a platform agnostic module. For each platform you need to create an Azure application following the public guides.

Authentication

The module does not replace XAF authentication and is a mandatory requirement. For both platform (Win,Web) an AzureAppCredentials.json must exit in the application directory and must look like:

{
  "MSClientId": "The_AzureAppId",
  "MSAppSecret": "The_AzureApp_Secret", //applicable only to web 
  "RedirectUri": "http://localhost:2064/login.aspx"
}

The module will use this json file to allow the XAF end user to authenticate/link it self with the Azure application. For authentication the end user must execute the AuthenticateMS action located in his profile details.

For both platforms once the user authenticated the RefreshToken and AccessToken are saved with the help of the MSAuthentication business object. When the AccessToken expires the module will use the RefreshToken to silently request a new AccessToken until the lifetime limit reached (6 months). If the MSAuthentication contains data for the current user and a new AccessToken cannot be acquired, a message will notify the end user to navigate to his/her profile for authentication.

Model configuration

  • The AuthenticateMS action styling respects the Microsoft branding guidelines and you can use as is. It is possible however to change the used images from the model.
  • The synchronization of ITask <-> OutlookTask takes place each time a pre-configured model view is shown.

Possible future improvements:

  1. Any other need you may have.

Let me know if you want me to implement them for you.


Examples

Bellow are a few examples of how we use the module in eXpandFramework.

![image](https://user-images.githubusercontent.com/159464/50846982-1709ce80-1379-11e9-877a-6a2e277867a7.png)

to derive a version with Remember Me support as below:

image

The next WorldCreatormodified version of PersistentMemberInfo:

image

is used to derive a version for the PersistentCoreTypeMemberInfo like:

image

and in addition one for the PersistentCollectionMemberInfo

image

Installation

  1. First you need the nuget package so issue this command to the VS Nuget package console

    Install-Package Xpand.XAF.Modules.Office.Cloud.Microsoft.Todo.

    The above only references the dependencies and nexts steps are mandatory.

  2. Ways to Register a Module or simply add the next call to your module constructor

    RequiredModuleTypes.Add(typeof(Xpand.XAF.Modules.Office.Cloud.Microsoft.TodoModule));

Versioning

The module is not bound to DevExpress versioning, which means you can use the latest version with your old DevExpress projects Read more.

The module follows the Nuget Version Basics.

Dependencies

.NetFramework: net461

DevExpress.ExpressApp Any
Fasterflect.Xpand 2.0.7
JetBrains.Annotations 2020.1.0
System.ValueTuple 4.5.0
Xpand.Extensions 2.201.34.5
Xpand.Extensions.XAF 2.201.35.8
Xpand.VersionConverter 2.201.7

Issues-Debugging-Troubleshooting

To Step in the source code you need to enable Source Server support in your Visual Studio/Tools/Options/Debugging/Enable Source Server Support. See also How to boost your DevExpress Debugging Experience.

If the package is installed in a way that you do not have access to uninstall it, then you can unload it with the next call at the constructor of your module.

Xpand.XAF.Modules.Reactive.ReactiveModuleBase.Unload(typeof(Xpand.XAF.Modules.Office.Cloud.Microsoft.Todo.Office.Cloud.Microsoft.TodoModule))

Tests

The module is tested on Azure for each build with these tests. All Tests run as per our Compatibility Matrix

image

image


Custom badge

Star the project if you think it deserves it.

GitHub stars

Fork the project to extend and contribute.

GitHub forks

Clone this wiki locally