QuellCode/CentronERP war nur als Gitlink (Submodul-Referenz auf 79c1142) getrackt, ohne .gitmodules und ohne erreichbares Remote. Der Untersuchungsgegenstand der Versuchsreihe war damit nicht reproduzierbar gesichert: Ein Klon haette ein leeres Verzeichnis erhalten, und die Belege der 3.287 Anforderungen waeren nicht ueberpruefbar gewesen. Umstellung: - Historie nach c:\DEV\CentronERP_git_snapshot_79c1142 ausgelagert (vollstaendig lesbar, enthaelt 79c1142 und Vorgaenger 89ccfd6) - Gitlink aus dem Index entfernt - Dateiinhalt aufgenommen: 24.557 Dateien, rund 333 MB Die verschachtelte .gitignore der Codebasis gilt weiter, Build-Artefakte bleiben ausgeschlossen. Details in Versuche/Versuch_01/_Codebasis-Nachweis.md
45 lines
1.7 KiB
C#
45 lines
1.7 KiB
C#
using System.Collections.Generic;
|
|
using Centron.BusinessLogic;
|
|
using Centron.BusinessLogic.Sales.Receipts;
|
|
using Centron.BusinessLogic.WebServices.Sales.Receipts;
|
|
using Centron.Interfaces;
|
|
using Centron.Tests.EndToEnd.Infrastructure;
|
|
using CentronSoftware.Centron.WebServices.Entities.Sales.CustomerAssets.TimerBilling;
|
|
using Xunit.Abstractions;
|
|
|
|
namespace Centron.Tests.EndToEnd.TicketTests.Ticket130840;
|
|
|
|
public class Ticket130840Test : EndToEndTest
|
|
{
|
|
public Ticket130840Test(ITestOutputHelper testOutputHelper)
|
|
: base(testOutputHelper)
|
|
{
|
|
}
|
|
|
|
private const int HelpdeskTimerI3D = 10520;
|
|
|
|
public override void Execute()
|
|
{
|
|
// In this ticket, there was an issue when billing timers that:
|
|
// - have a special article (Anfahrts- oder Remoteartikel)
|
|
// - that don't have a contract
|
|
// - you wanna group the special articles together
|
|
this.PrepareDatabase();
|
|
|
|
using var session = new BLSession();
|
|
var timerBillingSettingsDto = new TimerBillingSettingsDTO
|
|
{
|
|
ReceiptKind = CentronObjectKindNumeric.DeliveryListClass,
|
|
GroupEqualSpecialArticles = true //Important
|
|
};
|
|
var result = session.GetBL<ReceiptWebServiceBL>().CreateNewReceiptForHelpdekTimers(new List<int> { 10520 }, timerBillingSettingsDto, this.GetLoggedInUser().User);
|
|
this.Verifier.Verify("Result", result);
|
|
}
|
|
|
|
private void PrepareDatabase()
|
|
{
|
|
// The timer 10520 already has a special-article, but also has a contract
|
|
// Remove the contract to force the issue from this ticket
|
|
this.Sql($"UPDATE dbo.hlpdsk_timer SET ContractI3D = NULL WHERE I3D = {HelpdeskTimerI3D}");
|
|
}
|
|
} |