Acumatica:如何在注销余额和贷方上添加额外过滤器 (AR505000)
Acumatica: how to add a extra filter on Write Off Balances and Credits(AR505000)
我需要在 Write Off Balances and Credits (AR505000) 上添加新过滤器。通常你必须复制
PXFilteredProcessingJoin 或 PXProcessingJoin 字段到扩展 class 和它附带的 IEnumerable 函数。但是在 Write Off Balances and Credits 页面中没有 IEnumerable。
一种方法如何添加更多过滤器?
我正在考虑自己添加 IEnumerable:
public class ARCreateWriteOff_Extension : PXGraphExtension<ARCreateWriteOff>
{
#region Event Handlers
//THis is copied form the Graph
[PXFilterable]
// [PX.SM.PXViewDetailsButton(typeof(ARRegisterEx.refNbr), WindowMode = PXRedirectHelper.WindowMode.NewWindow)]
public PXFilteredProcessingJoin<ARRegisterEx, ARWriteOffFilter,
InnerJoin<Customer,
On<Customer.bAccountID, Equal<ARRegisterEx.customerID>,
And<Customer.smallBalanceAllow, Equal<True>>>,
LeftJoin<ARAdjust,
On<ARAdjust.adjdDocType, Equal<ARRegisterEx.docType>,
And<ARAdjust.adjdRefNbr, Equal<ARRegisterEx.refNbr>,
And<ARAdjust.released, Equal<False>,
And<ARAdjust.voided, Equal<False>>>>>,
LeftJoin<ARAdjust2,
On<ARAdjust2.adjgDocType, Equal<ARRegisterEx.docType>,
And<ARAdjust2.adjgRefNbr, Equal<ARRegisterEx.refNbr>,
And<ARAdjust2.released, Equal<False>,
And<ARAdjust2.voided, Equal<False>>>>>>>>,
Where<
Where2< MatchWithBranch<ARRegisterEx.branchID>,
And2<Match<Current<AccessInfo.userName>>,
And<ARRegisterEx.released, Equal<True>,
And<ARRegisterEx.hold, NotEqual<True>,
And<ARRegisterEx.openDoc, Equal<True>,
And<ARRegisterEx.pendingPPD, NotEqual<True>,
And2<
Where< ARRegisterEx.docBal, Greater<decimal0>,
Or<ARRegisterEx.curyDocBal, Greater<decimal0>>>,
And<ARRegisterEx.docBal, LessEqual<Current<ARWriteOffFilter.wOLimit>>,
And2< Where< Current2<ARWriteOffFilter.branchID>, IsNull,
Or<ARRegisterEx.branchID, Equal<Current<ARWriteOffFilter.branchID>>>>,
And2< Where<Current<ARWriteOffFilter.woType>, Equal<ARDocType.smallBalanceWO>,
And2< Where< ARRegisterEx.docType, Equal<ARDocType.invoice>,
Or<ARRegisterEx.docType, Equal<ARDocType.debitMemo>,
Or<ARRegisterEx.docType, Equal<ARDocType.finCharge>>>>,
And< ARAdjust.adjgRefNbr, IsNull,
Or<Current<ARWriteOffFilter.woType>, Equal<ARDocType.smallCreditWO>,
And2< Where< ARRegisterEx.docType, Equal<ARDocType.payment>,
Or<ARRegisterEx.docType, Equal<ARDocType.creditMemo>,
Or<ARRegisterEx.docType, Equal<ARDocType.prepayment>>>>,
And<ARAdjust2.adjdRefNbr, IsNull>>>>>>,
And<Where< Current<ARWriteOffFilter.customerID>, IsNull,
Or<Current<ARWriteOffFilter.customerID>, Equal<ARRegisterEx.customerID>>>>>>>>>>>>>>>>
ARDocumentList;
protected virtual IEnumerable aRDocumentList()
{
ARWriteOffFilter aRWriteOffFilter = Base.Filter.Current;
ARWriteOffFilterExt aRWriteOffFilterExt = aRWriteOffFilter.GetExtension<ARWriteOffFilterExt>();
foreach (ARRegisterEx item in ARDocumentList.Select())
{
if (1==1)//removed my customer filter to removed cluter
{
yield return item;
}
else
{
yield return item;
}
}
}
#endregion
}
}
要修改数据视图,您必须在图表扩展中重新定义数据视图class。
在 BLC 扩展中重新定义的数据视图 完全替换了图形实例的视图集合中的基础数据视图 ,包括附加到基础图形中声明的数据视图的所有属性。您可以将同一组属性附加到数据视图或完全重新声明属性。
数据视图必须具有完全相同的标识符(相同的名称),该标识符在 ASPX 页面的相应容器中引用。
或者,您可以通过在图形构造函数中添加新的 filters/joins 来更改现有数据视图(在扩展中,您可以通过覆盖图形扩展中的 Initialize
来实现)
public override void Initialize()
{
base.Initialize();
this.Base.ARDocumentList.WhereNew< your new Where filter here >();
//or WhereAnd< ... >(); to append contitions to existing one
//you can also add this.Base.ARDocumentList.Join< _join a new table here >();
}
我需要在 Write Off Balances and Credits (AR505000) 上添加新过滤器。通常你必须复制 PXFilteredProcessingJoin 或 PXProcessingJoin 字段到扩展 class 和它附带的 IEnumerable 函数。但是在 Write Off Balances and Credits 页面中没有 IEnumerable。 一种方法如何添加更多过滤器?
我正在考虑自己添加 IEnumerable:
public class ARCreateWriteOff_Extension : PXGraphExtension<ARCreateWriteOff>
{
#region Event Handlers
//THis is copied form the Graph
[PXFilterable]
// [PX.SM.PXViewDetailsButton(typeof(ARRegisterEx.refNbr), WindowMode = PXRedirectHelper.WindowMode.NewWindow)]
public PXFilteredProcessingJoin<ARRegisterEx, ARWriteOffFilter,
InnerJoin<Customer,
On<Customer.bAccountID, Equal<ARRegisterEx.customerID>,
And<Customer.smallBalanceAllow, Equal<True>>>,
LeftJoin<ARAdjust,
On<ARAdjust.adjdDocType, Equal<ARRegisterEx.docType>,
And<ARAdjust.adjdRefNbr, Equal<ARRegisterEx.refNbr>,
And<ARAdjust.released, Equal<False>,
And<ARAdjust.voided, Equal<False>>>>>,
LeftJoin<ARAdjust2,
On<ARAdjust2.adjgDocType, Equal<ARRegisterEx.docType>,
And<ARAdjust2.adjgRefNbr, Equal<ARRegisterEx.refNbr>,
And<ARAdjust2.released, Equal<False>,
And<ARAdjust2.voided, Equal<False>>>>>>>>,
Where<
Where2< MatchWithBranch<ARRegisterEx.branchID>,
And2<Match<Current<AccessInfo.userName>>,
And<ARRegisterEx.released, Equal<True>,
And<ARRegisterEx.hold, NotEqual<True>,
And<ARRegisterEx.openDoc, Equal<True>,
And<ARRegisterEx.pendingPPD, NotEqual<True>,
And2<
Where< ARRegisterEx.docBal, Greater<decimal0>,
Or<ARRegisterEx.curyDocBal, Greater<decimal0>>>,
And<ARRegisterEx.docBal, LessEqual<Current<ARWriteOffFilter.wOLimit>>,
And2< Where< Current2<ARWriteOffFilter.branchID>, IsNull,
Or<ARRegisterEx.branchID, Equal<Current<ARWriteOffFilter.branchID>>>>,
And2< Where<Current<ARWriteOffFilter.woType>, Equal<ARDocType.smallBalanceWO>,
And2< Where< ARRegisterEx.docType, Equal<ARDocType.invoice>,
Or<ARRegisterEx.docType, Equal<ARDocType.debitMemo>,
Or<ARRegisterEx.docType, Equal<ARDocType.finCharge>>>>,
And< ARAdjust.adjgRefNbr, IsNull,
Or<Current<ARWriteOffFilter.woType>, Equal<ARDocType.smallCreditWO>,
And2< Where< ARRegisterEx.docType, Equal<ARDocType.payment>,
Or<ARRegisterEx.docType, Equal<ARDocType.creditMemo>,
Or<ARRegisterEx.docType, Equal<ARDocType.prepayment>>>>,
And<ARAdjust2.adjdRefNbr, IsNull>>>>>>,
And<Where< Current<ARWriteOffFilter.customerID>, IsNull,
Or<Current<ARWriteOffFilter.customerID>, Equal<ARRegisterEx.customerID>>>>>>>>>>>>>>>>
ARDocumentList;
protected virtual IEnumerable aRDocumentList()
{
ARWriteOffFilter aRWriteOffFilter = Base.Filter.Current;
ARWriteOffFilterExt aRWriteOffFilterExt = aRWriteOffFilter.GetExtension<ARWriteOffFilterExt>();
foreach (ARRegisterEx item in ARDocumentList.Select())
{
if (1==1)//removed my customer filter to removed cluter
{
yield return item;
}
else
{
yield return item;
}
}
}
#endregion
}
}
要修改数据视图,您必须在图表扩展中重新定义数据视图class。 在 BLC 扩展中重新定义的数据视图 完全替换了图形实例的视图集合中的基础数据视图 ,包括附加到基础图形中声明的数据视图的所有属性。您可以将同一组属性附加到数据视图或完全重新声明属性。 数据视图必须具有完全相同的标识符(相同的名称),该标识符在 ASPX 页面的相应容器中引用。
或者,您可以通过在图形构造函数中添加新的 filters/joins 来更改现有数据视图(在扩展中,您可以通过覆盖图形扩展中的 Initialize
来实现)
public override void Initialize()
{
base.Initialize();
this.Base.ARDocumentList.WhereNew< your new Where filter here >();
//or WhereAnd< ... >(); to append contitions to existing one
//you can also add this.Base.ARDocumentList.Join< _join a new table here >();
}