B2017-134 Creating a new enhanced section from EOP was using incorrect document type
This commit is contained in:
		| @@ -1590,10 +1590,13 @@ namespace VEPROMS.CSLA.Library | ||||
| 					if (edSource.Type == enhtype)  // found one to use: | ||||
| 					{ | ||||
| 						ItemInfo exEnh = ItemInfo.Get(edSource.ItemID); | ||||
| 						int enhType = (int)MyContent.Type; | ||||
| 						if (iiCur.MyContent.Type == MyContent.Type) // B2017-134 the enhanced section was being created with the wrong document type creating new enhanced section from EOP (bryon data) | ||||
| 							enhType = (int)exEnh.MyContent.Type; | ||||
| 						if (exEnh.IsStep) | ||||
| 							newEnh = exEnh.InsertEnhancedSteps(MyContent.Text, null, addtype, MyContent.Type, edSource.Type, this.ItemID); | ||||
| 							newEnh = exEnh.InsertEnhancedSteps(MyContent.Text, null, addtype,enhType, edSource.Type, this.ItemID); | ||||
| 						else | ||||
| 							newEnh = exEnh.InsertEnhancedItems(MyContent.Text, MyContent.Number, addtype, MyContent.Type, edSource.Type, this.ItemID); | ||||
| 							newEnh = exEnh.InsertEnhancedItems(MyContent.Text, MyContent.Number, addtype, enhType, edSource.Type, this.ItemID); | ||||
| 					} | ||||
| 				} | ||||
| 				iiCur = iiCur.MyPrevious; | ||||
| @@ -1609,10 +1612,13 @@ namespace VEPROMS.CSLA.Library | ||||
| 					if (edSource.Type == enhtype)  // found one to use: | ||||
| 					{ | ||||
| 						ItemInfo exEnh = ItemInfo.Get(edSource.ItemID); | ||||
| 						int enhType = (int)MyContent.Type; | ||||
| 						if (iiCur.MyContent.Type == MyContent.Type) // B2017-134 the enhanced section was being created with the wrong document type creating new enhanced section from EOP (byron data) | ||||
| 							enhType = (int)exEnh.MyContent.Type; | ||||
| 						if (exEnh.IsStep) | ||||
| 							newEnh = exEnh.InsertEnhancedSteps(MyContent.Text, null, addtype, MyContent.Type, edSource.Type, this.ItemID); | ||||
| 							newEnh = exEnh.InsertEnhancedSteps(MyContent.Text, null, addtype, enhType, edSource.Type, this.ItemID); | ||||
| 						else | ||||
| 							newEnh = exEnh.InsertEnhancedItems(MyContent.Text, MyContent.Number, addtype, MyContent.Type, edSource.Type, this.ItemID); | ||||
| 							newEnh = exEnh.InsertEnhancedItems(MyContent.Text, MyContent.Number, addtype, enhType, edSource.Type, this.ItemID); | ||||
| 					} | ||||
| 				} | ||||
| 				iiNxt = iiNxt.GetNextItem(); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user