Skip to main content
Solved

PXSelector for custom table

  • January 28, 2022
  • 2 replies
  • 421 views

Forum|alt.badge.img

We are writing a custom integration between Salesforce and Acumatica as the customer requirements are outside of the built-in integration provided by Acumatica.  To establish a synchronization between SF Users and Acumatica Salesperson we have created a custom table SFUsers with two fields SFUserID and SFFullName.  Both are string fields.  What we want to do is to add a custom field to the Acumatica Salesperson screen called UsrSFUser that does a PXSelector on the SFUsers table.  Here is the code that is not working:

using PX.Data.EP;
using PX.Data.ReferentialIntegrity.Attributes;
using PX.Data;
using PX.Objects.AR;
using PX.Objects;
using System.Collections.Generic;
using System;

namespace SenteSFIntegration
{
  public class SalesPersonExt : PXCacheExtension<PX.Objects.AR.SalesPerson>
  {
    #region UsrSFUser
    [PXDBString(20)]
    [PXUIField(DisplayName="SF User")]
    [PXSelector(typeof(Search<SFUsers.sFUserID>),
     DescriptionField = typeof(SFUsers.sFFullName),
     CacheGlobal = true)]
    public virtual string UsrSFUser { get; set; }
    public abstract class usrSFUser : PX.Data.BQL.BqlString.Field<usrSFUser> { }
    #endregion
  }
}

The error is:  The type name 'sFUserID' does not exist in the type 'SFUsers'

 

Best answer by johnw51

Thank you.  I hadn’t noticed that it lower cased sfuserid.  It publishes now.

View original
Did this topic help you find an answer to your question?

jinin
Pro I
Forum|alt.badge.img+11
  • Pro I
  • January 28, 2022

Hi @johnw51 

The selector looks fine for me. Can you please share the 'SFUsers' DAC?


Forum|alt.badge.img
  • Varsity I
  • January 28, 2022

Thank you.  I hadn’t noticed that it lower cased sfuserid.  It publishes now.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings