public override void CreateLiveBrewCommands(string fieldName, string fieldValue, Brew brew, string fieldSection) { switch (fieldName) { case "Start Heating(Boiling) - Finish": liveBrewCommand = new StartWortCopperHeatingCommand(brew.StartDate, brew.StartTime, brew.BrandName, brew.BrewNumber, fieldName, fieldValue, fieldSection); AddToLiveBrewCommands(liveBrewCommand); break; // from whirlpool case "Start Casting - Finish": liveBrewCommand = new StartWortCopperCastingCommand(brew.StartTime, brew.BrandName, brew.BrewNumber, fieldName, fieldValue, fieldSection); AddToLiveBrewCommands(liveBrewCommand); break; case "Heating Time (Boiling) - Finish": case "Wort Boiling - Finish": case "Extra Boiling Time - Finish": case "Casting to Whirpool - Finish": case "Wort Copper Finish(No cip) - Finish": case "Daily Cleaning - Finish": case "Wort Copper Finish(with cip) - Finish": liveBrewCommand = new CompleteWortCopperProcessStepCommand(brew.BrandName, brew.BrewNumber, fieldName, fieldValue, fieldSection); AddToLiveBrewCommands(liveBrewCommand); break; } }
public override void CreateLiveBrewCommands(string fieldName, string fieldValue, Brew brew, string fieldSection) { this.liveBrewCommands = new BlockingCollection <LiveBrewCommand>(); switch (fieldName) { case "Start Casting - Finish": liveBrewCommand = new StartWortCopperCastingCommand(brew.StartTime, brew.BrandName, brew.BrewNumber, fieldName, fieldValue, fieldSection); AddToLiveBrewCommands(liveBrewCommand); liveBrewCommand = new StartWhirlpoolCastingCommand(brew.StartTime, brew.BrandName, brew.BrewNumber, fieldName, fieldValue, fieldSection); AddToLiveBrewCommands(liveBrewCommand); break; case "Casting Time - Finish": liveBrewCommand = new CompleteWortCopperProcessStepCommand(brew.BrandName, brew.BrewNumber, fieldName, fieldValue, fieldSection); AddToLiveBrewCommands(liveBrewCommand); liveBrewCommand = new CompleteWhirlpoolProcessStepCommand(brew.BrandName, brew.BrewNumber, fieldName, fieldValue, fieldSection); AddToLiveBrewCommands(liveBrewCommand); break; case "Rest Time - Finish": case "Wort Cooling - Finish": case "Trub Removal - Finish": case "Whirlpool Ready at - Finish": liveBrewCommand = new CompleteWhirlpoolProcessStepCommand(brew.BrandName, brew.BrewNumber, fieldName, fieldValue, fieldSection); AddToLiveBrewCommands(liveBrewCommand); break; } }