Xavier LARTEM
Xavier LARTEM

Reputation: 139

remove a check on a duplication of the tarif

I would like to know if it is possible via code to remove this control?

enter image description here

Upvotes: 0

Views: 42

Answers (1)

Hugues Beauséjour
Hugues Beauséjour

Reputation: 8278

This validation is executed in CheckForDuplicateDetails method. You can override the method. Make sure there is no bad side effects down the line if you remove this validation.

namespace PX.Objects.AP
{
  public class APPriceWorksheetMaint_Extension : PXGraphExtension<APPriceWorksheetMaint>
  {
    public delegate void CheckForDuplicateDetailsDelegate();

    [PXOverride]
    public void CheckForDuplicateDetails(CheckForDuplicateDetailsDelegate baseMethod)
    {
      // To skip validation, don't call base method
      // baseMethod();
    }
  }
}

Upvotes: 1

Related Questions