public void Locale() { var englishGreatBritain = new Locales(this.DatabaseSession).EnglishGreatBritain; var dutchBelgium = new Locales(this.DatabaseSession).DutchBelgium; new C1Builder(this.DatabaseSession).WithC1AllorsString("c1A").WithC1AllorsDecimal(10.5M).Build(); new C1Builder(this.DatabaseSession).WithC1AllorsString("c1B").WithC1AllorsDecimal(11.5M).Build(); this.DatabaseSession.Derive(true); var column1 = new CsvExportPath(C1s.Meta.C1AllorsString); var column2 = new CsvExportPath(C1s.Meta.C1AllorsDecimal); var export = new CsvExport("Test"); export.Columns.Add(column1); export.Columns.Add(column2); var extent = this.DatabaseSession.Extent(C1s.Meta.ObjectType).AddSort(C1s.Meta.C1AllorsString); var user = new Users(this.DatabaseSession).GetCurrentUser(); var acls = new AccessControlListCache(user); var csvEn = export.Write(extent, englishGreatBritain, acls); var csvNl = export.Write(extent, dutchBelgium, acls); Assert.AreNotEqual(csvEn, csvNl); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(MaleId, v => { v.Name = "Male"; localisedName.Set(v, dutchLocale, "Mannelijk"); v.IsActive = true; }); merge(FemaleId, v => { v.Name = "Female"; localisedName.Set(v, dutchLocale, "Vrouwelijk"); v.IsActive = true; }); merge(OtherId, v => { v.Name = "Other"; localisedName.Set(v, dutchLocale, "Anders"); v.IsActive = true; }); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(ProjectPlanId, v => { v.Name = "Project Plan"; localisedName.Set(v, dutchLocale, "Projectplan"); v.IsActive = true; }); merge(PresentationId, v => { v.Name = "Presentation"; localisedName.Set(v, dutchLocale, "Presentatie"); v.IsActive = true; }); merge(ReportId, v => { v.Name = "Report"; localisedName.Set(v, dutchLocale, "Rapport"); v.IsActive = true; }); merge(MarketAnalysisId, v => { v.Name = "Market Analysis"; localisedName.Set(v, dutchLocale, "Markt analyse"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new VatTariffBuilder(this.Session) .WithName("Standard") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Standard").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Hoog").WithLocale(dutchLocale).Build()) .WithUniqueId(StandardId).Build(); new VatTariffBuilder(this.Session) .WithName("Reduced rate") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Reduced rate").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Laag").WithLocale(dutchLocale).Build()) .WithUniqueId(ReducedRateId).Build(); new VatTariffBuilder(this.Session) .WithName("Zero rate") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Zero rate").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("nul tarief").WithLocale(dutchLocale).Build()) .WithUniqueId(ZeroRateId).Build(); }
public void One2Many() { var dutchBelgium = new Locales(this.Session).DutchBelgium; new C1Builder(this.Session) .WithC1AllorsString("c1A") .WithC1C2One2Many(new C2Builder(this.Session).WithC2AllorsString("c2A").Build()) .Build(); new C1Builder(this.Session) .WithC1AllorsString("c1B") .WithC1C2One2Many(new C2Builder(this.Session).WithC2AllorsString("c2B").Build()) .WithC1C2One2Many(new C2Builder(this.Session).WithC2AllorsString("c2C").Build()) .Build(); this.Session.Derive(true); var export = new CsvExport("Test"); export.Columns.Add(new CsvExportPath(C1s.Meta.C1AllorsString)); export.Columns.Add(new CsvExportPath(new Path(C1s.Meta.C1C2One2Manies, C2s.Meta.C2AllorsString))); var extent = this.Session.Extent(C1s.Meta.ObjectType).AddSort(C1s.Meta.C1AllorsString); var aclMock = new Mock<IAccessControlList>(); aclMock.Setup(acl => acl.CanRead(It.IsAny<PropertyType>())).Returns(true); var acls = new AccessControlListCache(null, (allorsObject, user) => aclMock.Object); var csv = export.Write(extent, dutchBelgium, acls); Assert.AreEqual( @"""C1AllorsString"";""C2AllorsString"" ""c1A"";""c2A"" ""c1B"";""c2B;c2C""".Replace("\r\n", "\n"), csv.Replace("\r\n", "\n")); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new EmploymentApplicationSourceBuilder(this.Session) .WithName("NewsPaper") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Krant").WithLocale(dutchLocale).Build()) .WithUniqueId(NewsPaperId) .WithIsActive(true) .Build(); new EmploymentApplicationSourceBuilder(this.Session) .WithName("PersonallReferal") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Persoonlijk doorverwezen").WithLocale(dutchLocale).Build()) .WithUniqueId(PersonallReferalId) .WithIsActive(true) .Build(); new EmploymentApplicationSourceBuilder(this.Session) .WithName("Internet") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Internet").WithLocale(dutchLocale).Build()) .WithUniqueId(InternetId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new RatingTypeBuilder(this.Session) .WithName("Poor") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Poor").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Laag").WithLocale(dutchLocale).Build()) .WithUniqueId(PoorId) .Build(); new RatingTypeBuilder(this.Session) .WithName("Fair") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Fair").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Redelijk").WithLocale(dutchLocale).Build()) .WithUniqueId(FairId) .Build(); new RatingTypeBuilder(this.Session) .WithName("Good") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Good").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goed").WithLocale(dutchLocale).Build()) .WithUniqueId(GoodId) .Build(); new RatingTypeBuilder(this.Session) .WithName("Outstanding") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Outstanding").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Uitstekend").WithLocale(dutchLocale).Build()) .WithUniqueId(OutstandingId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englischLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new PickListObjectStateBuilder(Session) .WithUniqueId(CreatedId) .WithName("Created") .Build(); new PickListObjectStateBuilder(Session) .WithUniqueId(PickedId) .WithName("Picked") .Build(); new PickListObjectStateBuilder(Session) .WithUniqueId(CancelledId) .WithName("Cancelled") .Build(); new PickListObjectStateBuilder(Session) .WithUniqueId(OnHoldId) .WithName("On Hold") .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new SalutationBuilder(this.Session) .WithName("Mr.") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Mr.").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Mr.").WithLocale(dutchLocale).Build()) .WithUniqueId(MrId) .Build(); new SalutationBuilder(this.Session) .WithName("Mrs.") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Mrs.").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Mvr.").WithLocale(dutchLocale).Build()) .WithUniqueId(MrsId) .Build(); new SalutationBuilder(this.Session) .WithName("Dr.") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Dr.").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Dr.").WithLocale(dutchLocale).Build()) .WithUniqueId(DrId) .Build(); new SalutationBuilder(this.Session) .WithName("Ms.") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Ms.").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Juff.").WithLocale(dutchLocale).Build()) .WithUniqueId(MsId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new OrganisationRoleBuilder(this.Session) .WithName("Customer") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Klant").WithLocale(dutchLocale).Build()) .WithUniqueId(CustomerId) .WithIsActive(true) .Build(); new OrganisationRoleBuilder(this.Session) .WithName("Supplier") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Leverancier").WithLocale(dutchLocale).Build()) .WithUniqueId(SupplierId) .WithIsActive(true) .Build(); new OrganisationRoleBuilder(this.Session) .WithName("Manufacturer") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Fabrikant").WithLocale(dutchLocale).Build()) .WithUniqueId(ManufacturerId) .WithIsActive(true) .Build(); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(PurchaseId, v => { v.Name = "Purchase"; localisedName.Set(v, dutchLocale, "Inkoop"); v.IsActive = true; }); merge(SalesId, v => { v.Name = "Sales"; localisedName.Set(v, dutchLocale, "Verkoop"); v.IsActive = true; }); merge(PurchaseAndSalesId, v => { v.Name = "Purchase & sales"; localisedName.Set(v, dutchLocale, "Inkoop & verkoop"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new DeliverableTypeBuilder(this.Session) .WithName("Project Plan") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Project Plan").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Projectplan").WithLocale(dutchLocale).Build()) .WithUniqueId(ProjectPlanId) .Build(); new DeliverableTypeBuilder(this.Session) .WithName("Presentation") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Presentation").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Presentatie").WithLocale(dutchLocale).Build()) .WithUniqueId(PresentationId) .Build(); new DeliverableTypeBuilder(this.Session) .WithName("Report") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Report").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Rapport").WithLocale(dutchLocale).Build()) .WithUniqueId(ReportId) .Build(); new DeliverableTypeBuilder(this.Session) .WithName("Market Analysis") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Market Analysis").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Markt analyse").WithLocale(dutchLocale).Build()) .WithUniqueId(MarketAnalysisId) .Build(); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(OwnId, v => { v.Name = "Own"; localisedName.Set(v, dutchLocale, "Eigen"); v.IsActive = true; }); merge(TradingId, v => { v.Name = "Trading"; localisedName.Set(v, dutchLocale, "Handel"); v.IsActive = true; }); merge(ThirdPartyId, v => { v.Name = "Third party"; localisedName.Set(v, dutchLocale, "Derde partij"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new EmploymentTerminationReasonBuilder(this.Session) .WithName("Insubordination") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Insubordination").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Weigering van bevel").WithLocale(dutchLocale).Build()) .WithUniqueId(InsubordinationId) .Build(); new EmploymentTerminationReasonBuilder(this.Session) .WithName("Accepted New Job") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Accepted New Job").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Nieuwe job aangenomen").WithLocale(dutchLocale).Build()) .WithUniqueId(AcceptedNewJobId) .Build(); new EmploymentTerminationReasonBuilder(this.Session) .WithName("Non Performance") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Non Performance").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Slechte performantie").WithLocale(dutchLocale).Build()) .WithUniqueId(NonPerformanceId) .Build(); new EmploymentTerminationReasonBuilder(this.Session) .WithName("Moved") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Moved").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Verhuis").WithLocale(dutchLocale).Build()) .WithUniqueId(MovedId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new OrganisationUnitBuilder(this.Session) .WithName("Department") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Department").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Departement").WithLocale(dutchLocale).Build()) .WithUniqueId(DepartmentId) .Build(); new OrganisationUnitBuilder(this.Session) .WithName("Division") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Division").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Divisie").WithLocale(dutchLocale).Build()) .WithUniqueId(DivisionId) .Build(); new OrganisationUnitBuilder(this.Session) .WithName("Subsidiary") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Subsidiary").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Dochtermaatschappij").WithLocale(dutchLocale).Build()) .WithUniqueId(SubsidiaryId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new OrdinalBuilder(this.Session) .WithName("First") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("First").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Eerste").WithLocale(dutchLocale).Build()) .WithUniqueId(FirstId) .Build(); new OrdinalBuilder(this.Session) .WithName("Second") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Second").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Tweede").WithLocale(dutchLocale).Build()) .WithUniqueId(SecondId) .Build(); new OrdinalBuilder(this.Session) .WithName("Third") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Third").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Derde").WithLocale(dutchLocale).Build()) .WithUniqueId(ThirdId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new SkillRatingBuilder(this.Session) .WithName("Poor") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Poor").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Slecht").WithLocale(dutchLocale).Build()) .WithUniqueId(PoorId) .Build(); new SkillRatingBuilder(this.Session) .WithName("Fair") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Fair").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Matig").WithLocale(dutchLocale).Build()) .WithUniqueId(FairId) .Build(); new SkillRatingBuilder(this.Session) .WithName("Good") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Good").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goed").WithLocale(dutchLocale).Build()) .WithUniqueId(GoodId) .Build(); new SkillRatingBuilder(this.Session) .WithName("Excellent") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Excellent").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Uitstekend").WithLocale(dutchLocale).Build()) .WithUniqueId(ExcellentId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new VatRatePurchaseKindBuilder(this.Session) .WithName("Goods") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goods").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goederen").WithLocale(dutchLocale).Build()) .WithUniqueId(GoodsId).Build(); new VatRatePurchaseKindBuilder(this.Session) .WithName("Services") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Services").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Diensten").WithLocale(dutchLocale).Build()) .WithUniqueId(ServicesId).Build(); new VatRatePurchaseKindBuilder(this.Session) .WithName("Investments") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Investments").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Investeringen").WithLocale(dutchLocale).Build()) .WithUniqueId(InvestmentsId).Build(); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(InternalRateId, v => { v.Name = "Internal Rate"; localisedName.Set(v, dutchLocale, "Internal tarief"); v.IsActive = true; }); merge(StandardRateId, v => { v.Name = "Standard Rate"; localisedName.Set(v, dutchLocale, "Standaard tarief"); v.IsActive = true; }); merge(OvertimeRateId, v => { v.Name = "Overtime Rate"; localisedName.Set(v, dutchLocale, "Overuren tarief"); v.IsActive = true; }); merge(WeekendRateId, v => { v.Name = "Weekend Rate"; localisedName.Set(v, dutchLocale, "Weekend tarief"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new VatRateUsageBuilder(this.Session) .WithName("Purchase") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("inkoop").WithLocale(dutchLocale).Build()) .WithUniqueId(PurchaseId) .WithIsActive(true) .Build(); new VatRateUsageBuilder(this.Session) .WithName("Sales") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Verkoop").WithLocale(dutchLocale).Build()) .WithUniqueId(SalesId) .WithIsActive(true) .Build(); new VatRateUsageBuilder(this.Session) .WithName("Purchase & sales") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Inkoop & verkoop").WithLocale(dutchLocale).Build()) .WithUniqueId(PurchaseAndSalesId) .WithIsActive(true) .Build(); }
public void GivenOrder_WhenDeriving_ThenLocaleMustExist() { var englischLocale = new Locales(this.DatabaseSession).EnglishGreatBritain; var supplier = new OrganisationBuilder(this.DatabaseSession).WithName("supplier").Build(); var internalOrganisation = new InternalOrganisations(this.DatabaseSession).FindBy(InternalOrganisations.Meta.Name, "internalOrganisation"); new SupplierRelationshipBuilder(this.DatabaseSession).WithSupplier(supplier).WithInternalOrganisation(internalOrganisation).Build(); var mechelen = new CityBuilder(this.DatabaseSession).WithName("Mechelen").Build(); ContactMechanism takenViaContactMechanism = new PostalAddressBuilder(this.DatabaseSession).WithGeographicBoundary(mechelen).WithAddress1("Haverwerf 15").Build(); var supplierContactMechanism = new PartyContactMechanismBuilder(this.DatabaseSession) .WithContactMechanism(takenViaContactMechanism) .WithUseAsDefault(true) .WithContactPurpose(new ContactMechanismPurposes(this.DatabaseSession).OrderAddress) .Build(); supplier.AddPartyContactMechanism(supplierContactMechanism); var order = new PurchaseOrderBuilder(this.DatabaseSession) .WithTakenViaSupplier(supplier) .WithShipToBuyer(internalOrganisation) .Build(); this.DatabaseSession.Derive(true); Assert.AreEqual(englischLocale, order.Locale); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var dutchBelgium = new Locales(this.Session).DutchBelgium; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); var localisedClause = new LocalisedTextAccessor(this.Meta.LocalisedClauses); merge(ServiceB2BId, v => { v.Name = "Rent goods"; localisedName.Set(v, dutchBelgium, "Verhuur goederen"); localisedClause.Set(v, dutchBelgium, "Dienstverrichting niet onderworpen aan Belgische btw art. 21, § 2 van het Wbtw / Art. 44 /EG."); v.IsActive = true; }); merge(IntracommunautairId, v => { v.Name = "Intracommunautair"; localisedName.Set(v, dutchBelgium, "Intracommunautair"); localisedClause.Set(v, dutchBelgium, "Vrijstelling van BTW art. 39bis, eerste lid, 1° van het WBTW / Vrijgesteld || Artikel 138, lid 1 - Richtlijn 2006/112."); v.IsActive = true; }); merge(BeArt39Par1Item1Id, v => { v.Name = "Export goods, transport responsible is you, destination customer"; localisedName.Set(v, dutchBelgium, "Verkoop buiten EU, transport verantwoordelijk bent u, bestemming klant"); localisedClause.Set(v, dutchBelgium, "Vrijstelling van BTW art. 39 § 1, 1° van het WBTW / Vrijgesteld || artikel 146, lid 1, onder a) – richtlijn 2006/112."); v.IsActive = true; }); merge(BeArt15Par2Id, v => { v.Name = "Export goods, transport responsible is you, destination internal organisation"; localisedName.Set(v, dutchBelgium, "Verkoop buiten EU, transport verantwoordelijk bent u, bestemming interne organisatie"); localisedClause.Set(v, dutchBelgium, "Levering van goederen niet onderworpen aan Belgische BTW. art. 15, § 2, van het WBTW / Artikel 33, lid 1, onder a) en b) - Richtlijn 2006/112."); v.IsActive = true; }); merge(BeArt39Par1Item2Id, v => { v.Name = "Export goods, transport responsible is customer, destination customer"; localisedName.Set(v, dutchBelgium, "Verkoop buiten EU, transport verantwoordelijk is klant, bestemming klant"); localisedClause.Set(v, dutchBelgium, "Vrijstelling van BTW art. 39 § 1, 2° van het WBTW / Vrijgesteld || artikel 146, lid 1, onder a) – richtlijn 2006/112."); v.IsActive = true; }); merge(BeArt14Par2Id, v => { v.Name = "Export goods, transport responsible is customer, destination internal organisation"; localisedName.Set(v, dutchBelgium, "Verkoop buiten EU, transport verantwoordelijk is klant, bestemming internal organisation"); localisedClause.Set(v, dutchBelgium, @" Levering van goederen niet onderworpen aan Belgische BTW. art. 14, § 2 van het WBTW / Artikel 32, eerste alinea - Richtlijn 2006/112 Extra vermeldingen: De goederen worden niet geïnstalleerd. / The goods are not installed. Koper vervoert van België naar {shipToCountry}. / The buyer transports from Belgium to {shipToCountry}"); v.IsActive = true; }); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(BeginnerId, v => { v.Name = "Beginner"; localisedName.Set(v, dutchLocale, "Starter"); v.IsActive = true; }); merge(IntermediateId, v => { v.Name = "Intermediate"; localisedName.Set(v, dutchLocale, "Intermediate"); v.IsActive = true; }); merge(AdvancedId, v => { v.Name = "Advanced"; localisedName.Set(v, dutchLocale, "Ervaren"); v.IsActive = true; }); merge(ExpertId, v => { v.Name = "Expert"; localisedName.Set(v, dutchLocale, "Expert"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new BillingProcessBuilder(this.Session) .WithName("Billing for Order Items") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Billing for Order Items").WithLocale(dutchLocale).Build()) .WithUniqueId(BillingForOrderItemsId) .WithIsActive(true) .Build(); new BillingProcessBuilder(this.Session) .WithName("Billing for Shipment Items") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Billing for Shipment Items").WithLocale(dutchLocale).Build()) .WithUniqueId(BillingForShipmentItemsId) .WithIsActive(true) .Build(); new BillingProcessBuilder(this.Session) .WithName("Billing for Work Efforts") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Billing for Shipment Items").WithLocale(dutchLocale).Build()) .WithUniqueId(BillingForWorkEffortsId) .WithIsActive(true) .Build(); new BillingProcessBuilder(this.Session) .WithName("Billing for Time Entries") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Billing for Shipment Items").WithLocale(dutchLocale).Build()) .WithUniqueId(BillingForTimeEntriesId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new VatTariffBuilder(this.Session) .WithName("Standard") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Hoog").WithLocale(dutchLocale).Build()) .WithUniqueId(StandardId) .WithIsActive(true) .Build(); new VatTariffBuilder(this.Session) .WithName("Reduced rate") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Laag").WithLocale(dutchLocale).Build()) .WithUniqueId(ReducedRateId) .WithIsActive(true) .Build(); new VatTariffBuilder(this.Session) .WithName("Zero rate") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("nul tarief").WithLocale(dutchLocale).Build()) .WithUniqueId(ZeroRateId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var durchLocale = new Locales(this.Session).DutchNetherlands; new CommunicationEventObjectStateBuilder(this.Session) .WithName("Scheduled") .WithUniqueId(ScheduledId) .Build(); new CommunicationEventObjectStateBuilder(this.Session) .WithName("In Progress") .WithUniqueId(InProgressId) .Build(); new CommunicationEventObjectStateBuilder(this.Session) .WithName("Completed") .WithUniqueId(CompletedId) .Build(); new CommunicationEventObjectStateBuilder(this.Session) .WithName("Cancelled") .WithUniqueId(CancelledId) .Build(); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(NewsPaperId, v => { v.Name = "NewsPaper"; localisedName.Set(v, dutchLocale, "Krant"); v.IsActive = true; }); merge(PersonallReferalId, v => { v.Name = "PersonallReferal"; localisedName.Set(v, dutchLocale, "Persoonlijk doorverwezen"); v.IsActive = true; }); merge(InternetId, v => { v.Name = "Internet"; localisedName.Set(v, dutchLocale, "Internet"); v.IsActive = true; }); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(ResignationId, v => { v.Name = "Resignation"; localisedName.Set(v, dutchLocale, "Ontslag genomen"); v.IsActive = true; }); merge(FiredId, v => { v.Name = "Fired"; localisedName.Set(v, dutchLocale, "Ontslagen"); v.IsActive = true; }); merge(RetirenmentId, v => { v.Name = "Retirement"; localisedName.Set(v, dutchLocale, "Pensioen"); v.IsActive = true; }); merge(DeceasedId, v => { v.Name = "Deceased"; localisedName.Set(v, dutchLocale, "Overleden"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new PurchaseInvoiceTypeBuilder(this.Session) .WithName("Purchase invoice") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Aankoop factuur").WithLocale(dutchLocale).Build()) .WithUniqueId(PurchaseInvoiceId) .WithIsActive(true) .Build(); new PurchaseInvoiceTypeBuilder(this.Session) .WithName("Customer return") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Crediet nota retour").WithLocale(dutchLocale).Build()) .WithUniqueId(CustomerReturnId) .WithIsActive(true) .Build(); new PurchaseInvoiceTypeBuilder(this.Session) .WithName("Commission") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Commissie").WithLocale(dutchLocale).Build()) .WithUniqueId(CommissionId) .WithIsActive(true) .Build(); new PurchaseInvoiceTypeBuilder(this.Session) .WithName("Payroll") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Salaris").WithLocale(dutchLocale).Build()) .WithUniqueId(PayrollId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new VatRatePurchaseKindBuilder(this.Session) .WithName("Goods") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goederen").WithLocale(dutchLocale).Build()) .WithUniqueId(GoodsId) .WithIsActive(true) .Build(); new VatRatePurchaseKindBuilder(this.Session) .WithName("Services") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Diensten").WithLocale(dutchLocale).Build()) .WithUniqueId(ServicesId) .WithIsActive(true) .Build(); new VatRatePurchaseKindBuilder(this.Session) .WithName("Investments") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Investeringen").WithLocale(dutchLocale).Build()) .WithUniqueId(InvestmentsId).WithIsActive(true) .Build(); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(PhoneId, v => { v.Name = "Phone"; localisedName.Set(v, dutchLocale, "Telefoon"); v.IsActive = true; }); merge(MobilePhoneId, v => { v.Name = "Mobile Phone"; localisedName.Set(v, dutchLocale, "Mobiel"); v.IsActive = true; }); merge(MobilePhoneId, v => { v.Name = "FaxId"; localisedName.Set(v, dutchLocale, "Fax"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new EuSalesListTypeBuilder(this.Session) .WithName("Goods") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goods").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goederen").WithLocale(dutchLocale).Build()) .WithUniqueId(GoodsId).Build(); new EuSalesListTypeBuilder(this.Session) .WithName("Services") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Services").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Diensten").WithLocale(dutchLocale).Build()) .WithUniqueId(ServicesId).Build(); new EuSalesListTypeBuilder(this.Session) .WithName("Triangular trade") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Triangular trade").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("ABC-transactie").WithLocale(dutchLocale).Build()) .WithUniqueId(TriangularTradeId).Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new SalesInvoiceTypeBuilder(this.Session) .WithName("Sales invoice") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Verkoop factuur").WithLocale(dutchLocale).Build()) .WithUniqueId(SalesInvoiceId) .WithIsActive(true) .Build(); new SalesInvoiceTypeBuilder(this.Session) .WithName("Credit Note") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Credit Nota").WithLocale(dutchLocale).Build()) .WithUniqueId(CreditNoteId) .WithIsActive(true) .Build(); new SalesInvoiceTypeBuilder(this.Session) .WithName("Interest") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Interest").WithLocale(dutchLocale).Build()) .WithUniqueId(InterestId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new SkillLevelBuilder(this.Session) .WithName("Beginner") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Beginner").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Starter").WithLocale(dutchLocale).Build()) .WithUniqueId(BeginnerId) .Build(); new SkillLevelBuilder(this.Session) .WithName("Intermediate") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Intermediate").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Intermediate").WithLocale(dutchLocale).Build()) .WithUniqueId(IntermediateId) .Build(); new SkillLevelBuilder(this.Session) .WithName("Advanced") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Advanced").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Ervaren").WithLocale(dutchLocale).Build()) .WithUniqueId(AdvancedId) .Build(); new SkillLevelBuilder(this.Session) .WithName("Expert") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Expert").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Expert").WithLocale(dutchLocale).Build()) .WithUniqueId(ExpertId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new EmploymentTerminationReasonBuilder(this.Session) .WithName("Insubordination") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Weigering van bevel").WithLocale(dutchLocale).Build()) .WithUniqueId(InsubordinationId) .WithIsActive(true) .Build(); new EmploymentTerminationReasonBuilder(this.Session) .WithName("Accepted New Job") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Nieuwe job aangenomen").WithLocale(dutchLocale).Build()) .WithUniqueId(AcceptedNewJobId) .WithIsActive(true) .Build(); new EmploymentTerminationReasonBuilder(this.Session) .WithName("Non Performance") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Slechte performantie").WithLocale(dutchLocale).Build()) .WithUniqueId(NonPerformanceId) .WithIsActive(true) .Build(); new EmploymentTerminationReasonBuilder(this.Session) .WithName("Moved") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Verhuis").WithLocale(dutchLocale).Build()) .WithUniqueId(MovedId) .WithIsActive(true) .Build(); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(FiFoId, v => { v.Name = "FiFo"; localisedName.Set(v, dutchLocale, "FiFo"); v.IsActive = true; }); merge(LiFoId, v => { v.Name = "LiFo"; localisedName.Set(v, dutchLocale, "LiFo"); v.IsActive = true; }); merge(AverageId, v => { v.Name = "Average price"; localisedName.Set(v, dutchLocale, "Gemiddelde prijs"); v.IsActive = true; }); }
public void Constructor() { var dutchBelgium = new Locales(this.DatabaseSession).DutchBelgium; new C1Builder(this.DatabaseSession).WithC1AllorsString("c1A").WithC1C2One2One(new C2Builder(this.DatabaseSession).WithC2AllorsString("c2A").Build()).Build(); new C1Builder(this.DatabaseSession).WithC1AllorsString("c1B").WithC1C2One2One(new C2Builder(this.DatabaseSession).WithC2AllorsString("c2B").Build()).Build(); this.DatabaseSession.Derive(true); var aclMock = new Mock<IAccessControlList>(); aclMock.Setup(acl => acl.CanRead(It.IsAny<PropertyType>())).Returns(true); var acls = new AccessControlListCache(null, (allorsObject, user) => aclMock.Object); var export = new CsvExport("Test"); export.Columns.Add(new CsvExportPath(C1s.Meta.C1AllorsString)); export.Columns.Add(new CsvExportFunction<C1>("Function", (c1, aclFactory) => CsvExport.Escape("Hello " + c1.C1AllorsString))); var extent = this.DatabaseSession.Extent(C1s.Meta.ObjectType).AddSort(C1s.Meta.C1AllorsString); var csv = export.Write(extent, dutchBelgium, acls); Assert.AreEqual( @"""C1AllorsString"";""Function"" ""c1A"";""Hello c1A"" ""c1B"";""Hello c1B""".Replace("\r\n", "\n"), csv.Replace("\r\n", "\n")); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new RatingTypeBuilder(this.Session) .WithName("Poor") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Laag").WithLocale(dutchLocale).Build()) .WithUniqueId(PoorId) .WithIsActive(true) .Build(); new RatingTypeBuilder(this.Session) .WithName("Fair") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Redelijk").WithLocale(dutchLocale).Build()) .WithUniqueId(FairId) .WithIsActive(true) .Build(); new RatingTypeBuilder(this.Session) .WithName("Good") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goed").WithLocale(dutchLocale).Build()) .WithUniqueId(GoodId) .WithIsActive(true) .Build(); new RatingTypeBuilder(this.Session) .WithName("Outstanding") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Uitstekend").WithLocale(dutchLocale).Build()) .WithUniqueId(OutstandingId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new WorkEffortTypeKindBuilder(this.Session) .WithName("Production Run") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Production Run").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Productie run").WithLocale(dutchLocale).Build()) .WithUniqueId(ProductionRunId) .Build(); new WorkEffortTypeKindBuilder(this.Session) .WithName("Process") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Process").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Verwerking").WithLocale(dutchLocale).Build()) .WithUniqueId(ProcessId) .Build(); new WorkEffortTypeKindBuilder(this.Session) .WithName("Process Step") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Process Step").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Proces stap").WithLocale(dutchLocale).Build()) .WithUniqueId(ProcessStepId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new SkillRatingBuilder(this.Session) .WithName("Poor") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Slecht").WithLocale(dutchLocale).Build()) .WithUniqueId(PoorId) .WithIsActive(true) .Build(); new SkillRatingBuilder(this.Session) .WithName("Fair") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Matig").WithLocale(dutchLocale).Build()) .WithUniqueId(FairId) .WithIsActive(true) .Build(); new SkillRatingBuilder(this.Session) .WithName("Good") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goed").WithLocale(dutchLocale).Build()) .WithUniqueId(GoodId) .WithIsActive(true) .Build(); new SkillRatingBuilder(this.Session) .WithName("Excellent") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Uitstekend").WithLocale(dutchLocale).Build()) .WithUniqueId(ExcellentId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new DebitCreditConstantBuilder(this.Session) .WithName("FiFo") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("FiFo").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("FiFo").WithLocale(dutchLocale).Build()) .WithUniqueId(FiFoId).Build(); new DebitCreditConstantBuilder(this.Session) .WithName("LiFo") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("LiFo").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("LiFo").WithLocale(dutchLocale).Build()) .WithUniqueId(LiFoId) .Build(); new DebitCreditConstantBuilder(this.Session) .WithName("Average price") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Average price").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Gemiddelde prijs").WithLocale(dutchLocale).Build()) .WithUniqueId(AverageId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new MaritalStatusBuilder(this.Session) .WithName("Single") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Single").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Alleenstaand").WithLocale(dutchLocale).Build()) .WithUniqueId(SingleId) .Build(); new MaritalStatusBuilder(this.Session) .WithName("Married") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Married").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Gehuwd").WithLocale(dutchLocale).Build()) .WithUniqueId(MarriedId) .Build(); new MaritalStatusBuilder(this.Session) .WithName("Divorced") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Divorced").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Gescheiden").WithLocale(dutchLocale).Build()) .WithUniqueId(DivorcedId) .Build(); new MaritalStatusBuilder(this.Session) .WithName("Widowed") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Widowed").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Weduw(e)(naar)").WithLocale(dutchLocale).Build()) .WithUniqueId(WidowedId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new PersonRoleBuilder(this.Session) .WithName("Employee") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Werknemer").WithLocale(dutchLocale).Build()) .WithUniqueId(EmployeeId) .WithIsActive(true) .Build(); new PersonRoleBuilder(this.Session) .WithName("Sales Rep") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Verkoper").WithLocale(dutchLocale).Build()) .WithUniqueId(EmployeeId) .WithIsActive(true) .Build(); new PersonRoleBuilder(this.Session) .WithName("Organisation Contact") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Contact").WithLocale(dutchLocale).Build()) .WithUniqueId(ContactId) .WithIsActive(true) .Build(); new PersonRoleBuilder(this.Session) .WithName("Customer") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Klant").WithLocale(dutchLocale).Build()) .WithUniqueId(CustomerId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new EuSalesListTypeBuilder(this.Session) .WithName("Goods") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Goederen").WithLocale(dutchLocale).Build()) .WithIsActive(true) .WithUniqueId(GoodsId).Build(); new EuSalesListTypeBuilder(this.Session) .WithName("Services") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Diensten").WithLocale(dutchLocale).Build()) .WithIsActive(true) .WithUniqueId(ServicesId).Build(); new EuSalesListTypeBuilder(this.Session) .WithName("Triangular trade") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("ABC-transactie").WithLocale(dutchLocale).Build()) .WithIsActive(true) .WithUniqueId(TriangularTradeId).Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new EmploymentApplicationSourceBuilder(this.Session) .WithName("NewsPaper") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("NewsPaper").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Krant").WithLocale(dutchLocale).Build()) .WithUniqueId(NewsPaperId) .Build(); new EmploymentApplicationSourceBuilder(this.Session) .WithName("PersonallReferal") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("PersonallReferal").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Persoonlijk doorverwezen").WithLocale(dutchLocale).Build()) .WithUniqueId(PersonallReferalId).Build(); new EmploymentApplicationSourceBuilder(this.Session) .WithName("Internet") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Internet").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Internet").WithLocale(dutchLocale).Build()) .WithUniqueId(InternetId) .Build(); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(InsubordinationId, v => { v.Name = "Insubordination"; localisedName.Set(v, dutchLocale, "Weigering van bevel"); v.IsActive = true; }); merge(AcceptedNewJobId, v => { v.Name = "Accepted New Job"; localisedName.Set(v, dutchLocale, "Nieuwe job aangenomen"); v.IsActive = true; }); merge(NonPerformanceId, v => { v.Name = "Non Performance"; localisedName.Set(v, dutchLocale, "Slechte performantie"); v.IsActive = true; }); merge(MovedId, v => { v.Name = "Moved"; localisedName.Set(v, dutchLocale, "Verhuis"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new OrdinalBuilder(this.Session) .WithName("First") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Eerste").WithLocale(dutchLocale).Build()) .WithUniqueId(FirstId) .WithIsActive(true) .Build(); new OrdinalBuilder(this.Session) .WithName("Second") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Tweede").WithLocale(dutchLocale).Build()) .WithUniqueId(SecondId) .WithIsActive(true) .Build(); new OrdinalBuilder(this.Session) .WithName("Third") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Derde").WithLocale(dutchLocale).Build()) .WithUniqueId(ThirdId) .WithIsActive(true) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var dutchLocale = new Locales(this.Session).DutchNetherlands; new EmploymentTerminationBuilder(this.Session) .WithName("Resignation") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Ontslag genomen").WithLocale(dutchLocale).Build()) .WithUniqueId(ResignationId) .WithIsActive(true) .Build(); new EmploymentTerminationBuilder(this.Session) .WithName("Fired") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Ontslagen").WithLocale(dutchLocale).Build()) .WithUniqueId(FiredId) .WithIsActive(true) .Build(); new EmploymentTerminationBuilder(this.Session) .WithName("Retirement") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Pensioen").WithLocale(dutchLocale).Build()) .WithUniqueId(RetirenmentId) .WithIsActive(true) .Build(); new EmploymentTerminationBuilder(this.Session) .WithName("Deceased") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Overleden").WithLocale(dutchLocale).Build()) .WithUniqueId(DeceasedId) .WithIsActive(true) .Build(); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(Assessable15Id, v => { v.Name = "IRPF Assessable 15%"; localisedName.Set(v, dutchLocale, "IRPF-plichtig 15%"); v.IsActive = true; }); var irpfregime = new IrpfRegimes(this.Session).FindBy(M.VatRegime.UniqueId, Assessable15Id); irpfregime.AddIrpfRate(new IrpfRates(this.Session).fifteen); merge(Assessable19Id, v => { v.Name = "IRPF Assessable 19%"; localisedName.Set(v, dutchLocale, "IRPF-plichtig 19%"); v.IsActive = true; }); irpfregime = new IrpfRegimes(this.Session).FindBy(M.VatRegime.UniqueId, Assessable19Id); irpfregime.AddIrpfRate(new IrpfRates(this.Session).nineteen); merge(ExemptId, v => { v.Name = "Exempt"; localisedName.Set(v, dutchLocale, "Vrijgesteld"); v.IsActive = true; }); irpfregime = new IrpfRegimes(this.Session).FindBy(M.VatRegime.UniqueId, ExemptId); irpfregime.AddIrpfRate(new IrpfRates(this.Session).Zero); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(RequiredId, v => { v.Name = "Required"; localisedName.Set(v, dutchLocale, "Verplicht"); v.IsActive = true; }); merge(RequiredId, v => { v.Name = "Standard"; localisedName.Set(v, dutchLocale, "Standaard"); v.IsActive = true; }); merge(OptionalId, v => { v.Name = "Optional"; localisedName.Set(v, dutchLocale, "Optioneel"); v.IsActive = true; }); merge(OptionalId, v => { v.Name = "Selectable"; localisedName.Set(v, dutchLocale, "Selecteerbaar"); v.IsActive = true; }); }
protected override void BaseSetup(Setup setup) { var dutchLocale = new Locales(this.Session).DutchNetherlands; var merge = this.Cache.Merger().Action(); var localisedName = new LocalisedTextAccessor(this.Meta.LocalisedNames); merge(CustomerId, v => { v.Name = "Customer"; localisedName.Set(v, dutchLocale, "Klant"); v.IsActive = true; }); merge(SupplierId, v => { v.Name = "Supplier"; localisedName.Set(v, dutchLocale, "Leverancier"); v.IsActive = true; }); merge(ManufacturerId, v => { v.Name = "Manufacturer"; localisedName.Set(v, dutchLocale, "Fabrikant"); v.IsActive = true; }); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new PurchaseInvoiceTypeBuilder(this.Session) .WithName("Purchase invoice") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Purchase invoice").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Aankoop factuur").WithLocale(dutchLocale).Build()) .WithUniqueId(PurchaseInvoiceId) .Build(); new PurchaseInvoiceTypeBuilder(this.Session) .WithName("Customer return") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Customer return").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Crediet nota retour").WithLocale(dutchLocale).Build()) .WithUniqueId(CustomerReturnId) .Build(); new PurchaseInvoiceTypeBuilder(this.Session) .WithName("Commission") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Commission").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Commissie").WithLocale(dutchLocale).Build()) .WithUniqueId(CommissionId) .Build(); new PurchaseInvoiceTypeBuilder(this.Session) .WithName("Payroll") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Payroll").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Salaris").WithLocale(dutchLocale).Build()) .WithUniqueId(PayrollId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new SalesInvoiceTypeBuilder(this.Session) .WithName("Sales invoice") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Sales invoice").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Verkoop factuur").WithLocale(dutchLocale).Build()) .WithUniqueId(SalesInvoiceId) .Build(); new SalesInvoiceTypeBuilder(this.Session) .WithName("Purchase return") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Purchase return").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Inkoop retour").WithLocale(dutchLocale).Build()) .WithUniqueId(PurchaseReturnId) .Build(); new SalesInvoiceTypeBuilder(this.Session) .WithName("Interest") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Interest").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Interest").WithLocale(dutchLocale).Build()) .WithUniqueId(InterestId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new SkillBuilder(this.Session) .WithName("Project Management") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Project Management").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Project Management").WithLocale(dutchLocale).Build()) .WithUniqueId(ProjectManagementId) .Build(); }
protected override void AppsSetup(Setup setup) { var englishLocale = new Locales(Session).EnglishGreatBritain; var dutchLocale = new Locales(Session).DutchNetherlands; new DropShipmentObjectStateBuilder(Session) .WithUniqueId(CreatedId) .WithName("Created") .Build(); new DropShipmentObjectStateBuilder(Session) .WithUniqueId(CancelledId) .WithName("Cancelled") .Build(); }
public void Locale() { var englishGreatBritain = new Locales(this.DatabaseSession).EnglishGreatBritain; var dutchBelgium = new Locales(this.DatabaseSession).DutchBelgium; new C1Builder(this.DatabaseSession).WithC1AllorsString("c1A").WithC1AllorsDecimal(10.5M).Build(); new C1Builder(this.DatabaseSession).WithC1AllorsString("c1B").WithC1AllorsDecimal(11.5M).Build(); this.DatabaseSession.Derive(true); var csvFile = new CsvExport("Test"); csvFile.Columns.Add(new CsvExportPath(C1s.Meta.C1AllorsString)); csvFile.Columns.Add(new CsvExportFunction<C1>( "Function", (c1, acl, cultureInfo) => { if (c1.C1AllorsDecimal.HasValue) { return CsvExport.Escape(c1.C1AllorsDecimal.Value.ToString(cultureInfo)); } return string.Empty; })); var extent = this.DatabaseSession.Extent(C1s.Meta.ObjectType).AddSort(C1s.Meta.C1AllorsString); var aclMock = new Mock<IAccessControlList>(); aclMock.Setup(acl => acl.CanRead(It.IsAny<PropertyType>())).Returns(true); var acls = new AccessControlListCache(null, (allorsObject, user) => aclMock.Object); var csvEn = csvFile.Write(extent, englishGreatBritain, acls); var csvNl = csvFile.Write(extent, dutchBelgium, acls); Assert.AreNotEqual(csvEn, csvNl); Assert.AreEqual( @"""C1AllorsString"";""Function"" ""c1A"";""10,5"" ""c1B"";""11,5""".Replace("\r\n", "\n"), csvNl.Replace("\r\n", "\n")); Assert.AreEqual( @"""C1AllorsString"",""Function"" ""c1A"",""10.5"" ""c1B"",""11.5""".Replace("\r\n", "\n"), csvEn.Replace("\r\n", "\n")); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(Session).EnglishGreatBritain; var dutchLocale = new Locales(Session).DutchNetherlands; new PurchaseShipmentObjectStateBuilder(Session) .WithUniqueId(CreatedId) .WithName("Created") .Build(); new PurchaseShipmentObjectStateBuilder(Session) .WithUniqueId(CompletedId) .WithName("Completed") .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new VatCalculationMethodBuilder(this.Session) .WithName("Cash management scheme") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Cash management scheme").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Kasstelsel").WithLocale(dutchLocale).Build()) .WithUniqueId(CashId).Build(); new VatCalculationMethodBuilder(this.Session) .WithName("Incoice management scheme") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Incoice management scheme").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Factuurstelsel").WithLocale(dutchLocale).Build()) .WithUniqueId(InvoiceId).Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new DebitCreditConstantBuilder(this.Session) .WithName("Use top level´s cost center GL-account") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Use top level´s cost center GL-account").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Gebruik grootboekrekening van kostenplaats van hoogste niveau").WithLocale(dutchLocale).Build()) .WithUniqueId(Topid).Build(); new DebitCreditConstantBuilder(this.Session) .WithName("Use bottom level´s cost center GL-account") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Use bottom level´s cost center GL-account").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Gebruik grootboekrekening van kostenplaats van laagste niveau").WithLocale(dutchLocale).Build()) .WithUniqueId(BottomId) .Build(); }
protected override void AppsSetup(Setup setup) { base.AppsSetup(setup); var englishLocale = new Locales(this.Session).EnglishGreatBritain; var dutchLocale = new Locales(this.Session).DutchNetherlands; new DebitCreditConstantBuilder(this.Session) .WithName("Debit") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Debit").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Debet").WithLocale(dutchLocale).Build()) .WithUniqueId(DebitId).Build(); new DebitCreditConstantBuilder(this.Session) .WithName("Credit") .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Credit").WithLocale(englishLocale).Build()) .WithLocalisedName(new LocalisedTextBuilder(this.Session).WithText("Credit").WithLocale(dutchLocale).Build()) .WithUniqueId(CreditId) .Build(); }