M171 Training Verkoop

M171 Training Verkoop

De werknemer in opleiding wenst te oefenen op de verkoop van 2 artikels en betaling met Cash

  • 2 Perrier
  • 1 Burger of the Chef
C#
        
        //Create the correct action according to the example
        var newSalesAction = new PosSalesAction(
            FpsFinancesModels.Company,
            _myFpsPos,
            FpsFinancesModels.TerminalTer1Bar,
            FpsFinancesModels.EmployeeJohn)
        {
            TicketMedium = TicketMedium.NONE,
            SalesActionNumber = 1016,
            BookingDate = DateTime.Now,
            BookingPeriodId = Guid.Parse("dffcd829-a0e5-41ca-a0ae-9eb887f95637"),
            TransactionLines =
            [
                new SaleLine(TransactionLineType.SINGLE_PRODUCT, 2, FpsFinancesModels.ProdPerrier),
                new SaleLine(TransactionLineType.SINGLE_PRODUCT, 1, FpsFinancesModels.ProdBurgerOfTheChef)
            ],
            Payments = [
                new Payment
                {
                    Id = "1",
                    Name = "CONTANT",
                    Type = PaymentType.CASH,
                    InputMethod = InputMethod.MANUAL,
                    Amount = 33,
                    AmountType = PaymentLineType.PAYMENT
                }
            ]
        };

        //Sign the action
        var result = await checkboxService.SignPosAction(newSalesAction, true, null, cancellationToken);

        //Handle the result accordingly
        Console.WriteLine($"Result with Signature {result.SignResult?.DigitalSignature}");