コード例 #1
0
 private VmDescription CreateDescription(string language, string value, VmGeneralDescriptionBase vModel, DescriptionTypeEnum typeEnum, bool isEmpty = false)
 {
     return(new VmDescription
     {
         Description = isEmpty ? null : value,
         TypeId = typesCache.Get <DescriptionType>(typeEnum.ToString()),
         OwnerReferenceId = vModel.Id,
         LocalizationId = languageCache.Get(language)
     });
 }
コード例 #2
0
 private VmDescription CreateDescription(string language, string value, VmServiceChannel vModel, DescriptionTypeEnum typeEnum)
 {
     return(new VmDescription
     {
         Description = value,
         TypeId = typesCache.Get <DescriptionType>(typeEnum.ToString()),
         OwnerReferenceId = vModel.Id,
         LocalizationId = languageCache.Get(language)
     });
 }
コード例 #3
0
 private VmDescription CreateDescription(string language, string value, VmConnectionInput vModel, DescriptionTypeEnum typeEnum, bool isEmpty = false)
 {
     return(new VmDescription
     {
         Description = isEmpty ? null : value,
         TypeId = typesCache.Get <DescriptionType>(typeEnum.ToString()),
         OwnerReferenceId = vModel.MainEntityId,
         OwnerReferenceId2 = vModel.ConnectedEntityId,
         LocalizationId = languageCache.Get(language)
     });
 }
コード例 #4
0
        private IEnumerable <VmDescription> GetDescription(IEnumerable <JsonLanguageLabel> descriptions, DescriptionTypeEnum type, StatutoryServiceGeneralDescriptionVersioned generalDescription)
        {
            var typeId = typesCache.Get <DescriptionType>(type.ToString());

            return(descriptions?.Select(
                       x =>
                       new VmDescription
            {
                Description = x.Label,
                TypeId = typeId,
                OwnerReferenceId = generalDescription.Id,
                LocalizationId = languageCache.Get(x.Lang)
            })
                   ?? new List <VmDescription>());
        }
コード例 #5
0
 private IEnumerable <IDescription> GetDescription(ServiceChannelVersioned serviceChannelVersioned, DescriptionTypeEnum type)
 {
     return(serviceChannelVersioned.ServiceChannelDescriptions.Where(x => typesCache.Compare <DescriptionType>(x.TypeId, type.ToString())));
 }
コード例 #6
0
 private IEnumerable <IDescription> GetDescription(StatutoryServiceGeneralDescriptionVersioned generalDescriptionVersioned, DescriptionTypeEnum type)
 {
     return(generalDescriptionVersioned.Descriptions.Where(x => typesCache.Compare <DescriptionType>(x.TypeId, type.ToString())));
 }
コード例 #7
0
 private IEnumerable <IDescription> GetDescription(OrganizationVersioned organizationVersioned, DescriptionTypeEnum type)
 {
     return(organizationVersioned.OrganizationDescriptions.Where(x => x.TypeId == typesCache.Get <DescriptionType>(type.ToString())));
 }
コード例 #8
0
 private ICollection <ServiceDescription> GetDescription(ServiceVersioned serviceVersioned, DescriptionTypeEnum type)
 {
     return(serviceVersioned.ServiceDescriptions.Where(x => x.TypeId == typesCache.Get <DescriptionType>(type.ToString())).ToList());
 }
コード例 #9
0
 private IEnumerable <IDescription> GetDescription(GeneralDescriptionServiceChannel generalDescriptionServiceChannel, DescriptionTypeEnum type)
 {
     return(generalDescriptionServiceChannel.GeneralDescriptionServiceChannelDescriptions.Where(x => typesCache.Compare <DescriptionType>(x.TypeId, type.ToString())));
 }
コード例 #10
0
 private ICollection <StatutoryServiceDescription> GetDescription(StatutoryServiceGeneralDescriptionVersioned gdVersioned, DescriptionTypeEnum type)
 {
     return(gdVersioned.Descriptions.Where(x => x.TypeId == typesCache.Get <DescriptionType>(type.ToString())).ToList());
 }