We have to implement the Nowegian requirements for POS registers - and I am looking into the sample projects:
Runtime.Extensions.SalesPaymentTransExt
We have to start with the legacy connector - since we are not on the new commerce sdk. (know they are deprecated and update is needed. )
In one the files we have:
ParameterSet parameters = new ParameterSet();
parameters[DatabaseAccessor.ChannelIdVariableName] = request.RequestContext.GetPrincipal().ChannelId;
parameters[sourceTableNamePrm] = sourceTable;
int errorCode;
using (var databaseContext = new DatabaseContext(request.RequestContext))
{
errorCode = await databaseContext.ExecuteStoredProcedureNonQueryAsync(insertProcName, parameters, resultSettings: null).ConfigureAwait(false);
}
if (errorCode != (int)DatabaseErrorCodes.Success)
{
throw new StorageException(StorageErrors.Microsoft_Dynamics_Commerce_Runtime_CriticalStorageError, errorCode);
}
Where DatabaseAccessor is marked as obsolete. So I guess it will not work any more.
any hints of how to work-around this.