Yes, you can write your own data provider. Here’s some boilerplate code to help you get started; Acumatica will automatically detect your provider. This is from an existing provider that I wrote, I just removed everything that is specific and provided just a base template for you.
InternalImport/InternalExport are the functions you need to implement and where the actual work happens.
using PX.Api;
using PX.Data;
using PX.DataSync;
using PX.Objects.AP;
using PX.SM;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml;
using System.Xml.Linq;
using System.Xml.Schema;
namespace Velixo.Sample
{
publicclass SampleProvider : PXSYBaseEncodedFileProvider, IPXSYProvider
{
protectedconststring MsgId = "MsgId";
publicstring DefaultFileExtension => ".xml";
publicoverridestring ProviderName => "My Provider";
publicoverridestring Extensiton => DefaultFileExtension;
publicoverride PXFieldState[] GetSchemaFields(string objectName)
{
List<PXFieldState> ret = new List<PXFieldState>(base.GetSchemaFields(objectName));
//TODO: Add the fields your provider will be exposing
ret.Add(CreateFieldState(new SchemaFieldInfo(-1, MsgId)));
return ret.ToArray();
}
protectedoverride List<PXStringState> FillParameters()
{
List<PXStringState> ret = base.FillParameters();
//TODO: Add the parameters your provider will be exposingreturn ret;
}
protectedoverridebyte[] InternalExport(string objectName, PXSYTable table)
{
thrownew NotImplementedException();
}
protectedoverridevoidInternalImport(PXSYTable table)
{
thrownew NotImplementedException();
}
}
}
Yes, you can write your own data provider. Here’s some boilerplate code to help you get started; Acumatica will automatically detect your provider. This is from an existing provider that I wrote, I just removed everything that is specific and provided just a base template for you.
InternalImport/InternalExport are the functions you need to implement and where the actual work happens.
using PX.Api;
using PX.Data;
using PX.DataSync;
using PX.Objects.AP;
using PX.SM;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml;
using System.Xml.Linq;
using System.Xml.Schema;
namespace Velixo.Sample
{
publicclass SampleProvider : PXSYBaseEncodedFileProvider, IPXSYProvider
{
protectedconststring MsgId = "MsgId";
publicstring DefaultFileExtension => ".xml";
publicoverridestring ProviderName => "My Provider";
publicoverridestring Extensiton => DefaultFileExtension;
publicoverride PXFieldState[] GetSchemaFields(string objectName)
{
List<PXFieldState> ret = new List<PXFieldState>(base.GetSchemaFields(objectName));
//TODO: Add the fields your provider will be exposing
ret.Add(CreateFieldState(new SchemaFieldInfo(-1, MsgId)));
return ret.ToArray();
}
protectedoverride List<PXStringState> FillParameters()
{
List<PXStringState> ret = base.FillParameters();
//TODO: Add the parameters your provider will be exposingreturn ret;
}
protectedoverridebyte[] InternalExport(string objectName, PXSYTable table)
{
thrownew NotImplementedException();
}
protectedoverridevoidInternalImport(PXSYTable table)
{
thrownew NotImplementedException();
}
}
}
Thnk u :) where can i find this code to modify it ? thnx
It depends on what type of data provider you want to create. Is it a B2B data provider designed specifically for sales? You will need to understand the main features of B2B data providers and see how other data providers work. Here are some examples of good B2B data providers on the market:
OneMoreLead
PureB2
Globaldatabase
Salesify
Leadspace
All of them offer the following services: data accuracy, CRM management, pipeline prediction, and more sales. In conclusion, you better do some research and choose the best data provider as a prototype.
Hi, I see there was a link associated with this posting, its not a valid link , can you provide a better updated link or even some documentation on building a custom specific data provider.
We use 3 different kinds of cookies. You can choose which cookies you want to accept. We need basic cookies to make this site work, therefore these are the minimum you can select. Learn more about our cookies.