Skip to main content
Solved

Changing filter does not clear selected entries in custom Processing Form


Forum|alt.badge.img

Hi, all. I’m currently working on custom processing form which uses a filter. However whenever I select entries and change the filter, the entries I selected remain selected. Is there an event handler needed to clear the selected fields or should it automatically clear all selected fields when the filter is updated?

 

Here are some screenshots and initialization of the view.

 

 

public SelectFrom<ARPayment>.
            Where<ARPayment.docType.IsEqual<ARDocType.payment>
                    .And<ARPayment.status.IsEqual<ARDocStatus.balanced>.Or<ARPayment.status.IsEqual<ARDocStatus.closed>>.Or<ARPayment.status.IsEqual<ARDocStatus.open>>>
                    .And<ARPayment.status.IsLessEqual<GiroCheckToProcessFilter.action.FromCurrent>>
                    .And<ARPayment.voided.IsNotEqual<True>>
                    .And<ARPayment.paymentMethodID.IsEqual<PaymentMethodConstant.check>.Or<ARPayment.paymentMethodID.IsEqual<PaymentMethodConstant.giro>>>
                    .And<ARPayment.paymentMethodID.IsEqual<GiroCheckToProcessFilter.paymentMethod.FromCurrent>.Or<GiroCheckToProcessFilter.paymentMethod.FromCurrent.IsNull>>
                    .And<ARPayment.customerID.IsEqual<GiroCheckToProcessFilter.customerID.FromCurrent>.Or<GiroCheckToProcessFilter.customerID.FromCurrent.IsNull>>
                    .And<ARPayment.docDate.IsGreaterEqual<GiroCheckToProcessFilter.startDate.FromCurrent>.Or<GiroCheckToProcessFilter.startDate.FromCurrent.IsNull>>
                .And<ARPayment.docDate.IsLessEqual<GiroCheckToProcessFilter.endDate.FromCurrent>.Or<GiroCheckToProcessFilter.endDate.FromCurrent.IsNull>>
                >.
           OrderBy<ARPayment.docDate.Desc,
               ARPayment.refNbr.Desc>.
           ProcessingView.
           FilteredBy<GiroCheckToProcessFilter> GiroChecksList;

 

This is problematic because pressing process will process unwanted selected entries. So, any insight on this and suggestions will be invaluable. TIA!

Best answer by Dmitrii Naumov

If you want to reset ‘Selected’ for all records when you change the filter, you can use something like GiroChecksList.Cache.Clear(); on Filter_RowUpdated event

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

2 replies

Dmitrii Naumov
Acumatica Moderator
Forum|alt.badge.img+7
  • Acumatica Moderator
  • 633 replies
  • Answer
  • February 2, 2023

If you want to reset ‘Selected’ for all records when you change the filter, you can use something like GiroChecksList.Cache.Clear(); on Filter_RowUpdated event


Forum|alt.badge.img
  • Author
  • Jr Varsity II
  • 18 replies
  • February 7, 2023

Thanks, Dmitrii! Worked like a charm.

 


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