Skip to main content
Question

Removing "Create Payment" buttton


SergioSP
How can we remove the “Create Payment” button for Sales users while still allowing our users (Salespeople) to create pre-payments?
 

 

 
Our goal is to allow prepayments, but prevent the team from using the standard payment processing flow.

Thanks!

7 replies

Forum|alt.badge.img+2
  • Pro I
  • 64 replies
  • April 11, 2025

It depends, you can remove it by going into a customization project and making it disabled. However, this can be an issue if you use any sales order types where you can’t use prepayments, such as mixed orders. In my case, I conditionally disabled it by creating a custom field that checks the order type and spits out true for order types that it needs to be enabled and spits out false for the others.

If that doesn’t matter to you, then just set the Enabled field to false instead of worrying about the DependOnGrid and StateColumn. It’s the second button from the top on the Adjustments grid.

// Acuminator disable once PX1016 ExtensionDoesNotDeclareIsActiveMethod extension should be constantly active
// Acuminator disable once PX1011 InheritanceFromPXCacheExtension [Justification]
public class SO_SOOrder_ExistingColumn : PXCacheExtension<PX.Objects.SO.SOOrder>
{
    #region UsrPaymentVisibleCondition
    [PXBool]
    [PXUIField(DisplayName = "PaymentVisibleCondition")]
    [PXUIEnabled(typeof(False))]
    [PXDefault(PersistingCheck = PXPersistingCheck.Nothing)]
    [PXFormula(typeof(IIf<SOOrder.behavior.IsEqual<SOOrderConstants.orderTypeMO>
        .And<SOOrder.curyUnpaidBalance
        .IsNotEqual<SOOrderConstants.decimalZero>>, True, False>), 
        Persistent = true)]
    public virtual bool? UsrPaymentVisibleCondition { get; set; }
    public abstract class usrPaymentVisibleCondition : 
    PX.Data.BQL.BqlBool.Field<usrPaymentVisibleCondition> { }
    #endregion
}

public class SOOrderConstants
{
    public const string OrderTypeMO = "MO";
    public class orderTypeMO : BqlType<IBqlString, string>.Constant<orderTypeMO> 
        { public orderTypeMO() : base(OrderTypeMO) { } }
}

 


Naveen Boga
Captain II
Forum|alt.badge.img+19
  • Captain II
  • 3417 replies
  • April 12, 2025

@SergioSP  Instead of customizing, you can simply create a role for your team that restricts access to the 'Create Payment' feature by configuring the appropriate access rights.


valentynbeznosiuk
Jr Varsity I
Forum|alt.badge.img

@Naveen Boga ​@SergioSP It’s actually a good advice. I’ve tried the following and it works as expected.

 


ricoybanez
Jr Varsity III
Forum|alt.badge.img+1
  • Jr Varsity III
  • 60 replies
  • April 14, 2025

@SergioSP 

  • Go to your Access Rights by Role (SM201025)
  • Select the Role Name
  • Change Access Rights to REVOKE

 

 

 

 


Forum|alt.badge.img+2
  • Pro I
  • 64 replies
  • April 14, 2025
Naveen Boga wrote:

@SergioSP  Instead of customizing, you can simply create a role for your team that restricts access to the 'Create Payment' feature by configuring the appropriate access rights.

@Naveen Boga Hmm, I never even thought about doing it that way. Can you do it per sales order type that way as well?


valentynbeznosiuk
Jr Varsity I
Forum|alt.badge.img

@DrewNisley Access Rights works for the screen generally and cannot apply it only for specific SOTypes, so in this case, your method steps in as the best way to do it


Forum|alt.badge.img+2
  • Pro I
  • 64 replies
  • April 14, 2025

@valentynbeznosiuk Gotcha, appreciate it.


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