Пример #1
0
        /// <summary>
        /// 离开滚筒
        /// </summary>
        /// <param name="runningProduct"></param>
        private void RunningRoller_Out(RunningProductVo runningProduct)
        {
            var currentRoller = _runningRollers.FirstOrDefault(a => a.RollerKey == runningProduct.CurrentRollerKey)?.Roller;

            if (currentRoller == null)
            {
                return;
            }

            string targetNode = currentRoller.InTrigger?.GetTargetNode(runningProduct);

            if (false == string.IsNullOrWhiteSpace(targetNode))
            {
                runningProduct.TargetNode = targetNode;
            }
        }
Пример #2
0
        /// <summary>
        /// 开始入板
        /// </summary>
        /// <param name="currentRoller"></param>
        private void start(RollerDesignerItemViewModel currentRoller)
        {
            var product = getReadyProduct();

            if (product == null)
            {
                return;
            }
            RunningProductVo runningProduct = new RunningProductVo {
                Product = product
            };

            _runningProducts.Add(runningProduct);
            var beginRoller = _runningRollers.FirstOrDefault(a => a.RollerKey == currentRoller.Key);

            if (beginRoller == null)
            {
                throw new Exception($"起点({currentRoller.Key})不在运行时中");
            }
            beginRoller.BandProduct = runningProduct;
        }