From 9573bb4b7bb1b30a90af3bf236b5254945818d2c Mon Sep 17 00:00:00 2001 From: Rich Date: Mon, 14 Apr 2014 20:57:06 +0000 Subject: [PATCH] Logic fixed to handle transition updates when printing a P/C PC child where the first step is not applicable and the second step is applicable. --- PROMS/VEPROMS.CSLA.Library/Extension/TransitionExt.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/TransitionExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/TransitionExt.cs index ba7018b4..e374464f 100644 --- a/PROMS/VEPROMS.CSLA.Library/Extension/TransitionExt.cs +++ b/PROMS/VEPROMS.CSLA.Library/Extension/TransitionExt.cs @@ -876,7 +876,14 @@ namespace VEPROMS.CSLA.Library tb.AppendPrefix(); } if (tb._ToItem.PreviousID == null && tb._ToItem.ItemPartCount == 0 && tb._ToItem.ItemDocVersionCount == 0) + { + // Logic added for handling applicability. If the first item is not applicable, then the second item will effectively become + // the first item but it's itempartcount will be zero + if(tb._ToItem.ActiveParent is ItemInfo && (tb._ToItem.ActiveParent as ItemInfo).Steps[0].ItemID == tb._ToItem.ItemID) + tb.ReplaceToken(Tab(tb._ToItem, true)); + else tb.Append("?"); + } else tb.ReplaceToken(Tab(tb._ToItem, true)); return true;