Exemplo n.º 1
0
		public void T()
		{
			var ecr = new Dp25("COM3");
			ecr.OpenFiscalReceipt("1", "1");
//			ecr.RegisterProgrammedItemSale);
			ecr.Total();
			ecr.CloseFiscalReceipt();
			ecr.Dispose();
		}
Exemplo n.º 2
0
        public void T()
        {
            var ecr = new Dp25("COM3");

            ecr.OpenFiscalReceipt("1", "1");
//			ecr.RegisterProgrammedItemSale);
            ecr.Total();
            ecr.CloseFiscalReceipt();
            ecr.Dispose();
        }
Exemplo n.º 3
0
        public void ExecuteCommands()
        {
            try
            {
                var response1 = _ecr.OpenFiscalReceipt();
                _messenger.Publish(new EcrRespondedEvent(response1));

                foreach (var item in Items.Where(x => x.HasValues()))
                {
                    var res = _ecr.RegisterSale(item.Name, item.Price, item.Quantity);
                    _messenger.Publish(new EcrRespondedEvent(res));
                }

                var response3 = _ecr.Total();
                _messenger.Publish(new EcrRespondedEvent(response3));

                var response4 = _ecr.CloseFiscalReceipt();
                _messenger.Publish(new EcrRespondedEvent(response4));
            }
            catch (Exception ex)
            {
                _messenger.Publish(new EcrThrewExceptionEvent(ex));
            }
        }