I got the next problem. I got report in which i have two field ProjectCD and TaskCD. TaskCD is not required and if it not selected it should show all task that project have.
I i run it only using subreport everything look good
Without task selected
With task selected
But for main report if i don’t select Task it alway will show first one.
But if i will select task it will show selected task
There are my params for main report for Task
Collection that i send to subreport
And params for subreport
And the view that i use for calculation values
[Serializable]
[PXCacheName(CAMSPMProjectDetailsTransactionsTaskIDViewCacheName)]
public class CAMSPMProjectDetailsTransactionsTaskIDView : IBqlTable
{
private const string CAMSPMProjectDetailsTransactionsTaskIDViewCacheName = "Project Details Transactions Task View";
#region ProjectID
[PXDBInt(IsKey = true)]
public virtual int? ProjectID { get; set; }
public abstract class projectID : BqlInt.Field<projectID> { }
#endregion
#region TaskID
[PXDBInt(IsKey = true)]
public virtual int? TaskID { get; set; }
public abstract class taskID : BqlInt.Field<taskID> { }
#endregion
#region TaskCD
[PXDBString(IsUnicode = true, /*IsKey = true,*/ InputMask = "")]
[PXSelector(typeof(Search<PMTask.taskCD>),
typeof(PMTask.taskCD), typeof(PMTask.description), typeof(PMTask.isActive),
SubstituteKey = typeof(PMTask.taskCD), DescriptionField = typeof(PMTask.description))]
public virtual string TaskCD { get; set; }
public abstract class taskCD : BqlString.Field<taskCD> { }
#endregion
#region GroupCD
[PXDBString(IsUnicode = true, IsKey = true, InputMask = "")]
[PXDimensionSelector(AccountGroupAttribute.DimensionName,
typeof(Search<PMAccountGroup.groupCD>),
typeof(PMAccountGroup.groupCD),
typeof(PMAccountGroup.groupCD), typeof(PMAccountGroup.description), typeof(PMAccountGroup.type), typeof(PMAccountGroup.isActive), DescriptionField = typeof(PMTask.description))]
public virtual string GroupCD { get; set; }
public abstract class groupCD : BqlString.Field<groupCD> { }
#endregion
#region GroupID
[PXDBInt]
public virtual int? GroupID { get; set; }
public abstract class groupID : BqlInt.Field<groupID> { }
#endregion
#region Type
[PXDBString(IsKey = true)]
[PMAccountType.List]
public virtual string Type { get; set; }
public abstract class type : BqlString.Field<type> { }
#endregion
#region MTD
[PXDBDecimal]
[PXDefault(TypeCode.Decimal, "0.00", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual decimal? MTD { get; set; }
public abstract class mTD : BqlDecimal.Field<mTD> { }
#endregion
#region PTD
[PXDBDecimal]
[PXDefault(TypeCode.Decimal, "0.00", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual decimal? PTD { get; set; }
public abstract class pTD : BqlDecimal.Field<pTD> { }
#endregion
#region Commitment
[PXDBDecimal]
[PXDefault(TypeCode.Decimal, "0.00", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual decimal? Commitment { get; set; }
public abstract class commitment : BqlDecimal.Field<commitment> { }
#endregion
#region PDTPlusCommitment
[PXDBDecimal]
[PXDefault(TypeCode.Decimal, "0.00", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual decimal? PDTPlusCommitment { get; set; }
public abstract class pDTPlusCommitment : BqlDecimal.Field<pDTPlusCommitment> { }
#endregion
#region Budget
[PXDBDecimal]
[PXDefault(TypeCode.Decimal, "0.00", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual decimal? Budget { get; set; }
public abstract class budget : BqlDecimal.Field<budget> { }
#endregion
#region Variance
[PXDBDecimal]
[PXDefault(TypeCode.Decimal, "0.00", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual decimal? Variance { get; set; }
public abstract class variance : BqlDecimal.Field<variance> { }
#endregion
#region CreditGroup
[PXDBDecimal]
[PXDefault(TypeCode.Decimal, "0.00", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual decimal? CreditGroup { get; set; }
public abstract class creditGroup : BqlDecimal.Field<creditGroup> { }
#endregion
#region CreditGroupMTD
[PXDBDecimal]
[PXDefault(TypeCode.Decimal, "0.00", PersistingCheck = PXPersistingCheck.Nothing)]
public virtual decimal? CreditGroupMTD { get; set; }
public abstract class creditGroupMTD : BqlDecimal.Field<creditGroupMTD> { }
#endregion
}