/// <summary> /// Создать системного контрагента для рассылки нескольким адресатам. /// </summary> public static void CreateDistributionListCounterparty() { var needLink = false; var guid = Parties.Constants.Counterparty.DistributionListCounterpartyGuid; var name = Parties.Resources.DistributionListCounterpartyName; var company = Parties.PublicFunctions.Counterparty.Remote.GetDistributionListCounterparty(); if (company == null) { company = Companies.Create(); needLink = true; } company.Name = name; company.State.IsEnabled = false; company.Save(); if (needLink) { Docflow.PublicFunctions.Module.CreateExternalLink(company, guid); } }
public static ICompany CreateCompany() { return(Companies.Create()); }