Exemplo n.º 1
0
        public System.Drawing.Color GetLineColor(string serviceType)
        {
            var serviceClass = ServiceClassDataAccess.GetServiceClassModelFromString(serviceType, GraphModel.ServiceClassList);

            if (serviceClass == null)
            {
                return(Color.Magenta);
            }
            return(System.Drawing.Color.FromName(serviceClass.Color));
        }
Exemplo n.º 2
0
 public void EditServiceTemplate()
 {
     ServiceTemplateName         = SelectedServiceTemplate.ServiceTemplateName;
     ServiceTemplateAbbreviation = SelectedServiceTemplate.ServiceTemplateAbbreviation;
     SelectedServiceClass        = ServiceClassDataAccess.GetServiceClassModelFromString(SelectedServiceTemplate.ServiceType, ServiceClassList);
     ServiceTemplateDescription  = SelectedServiceTemplate.ServiceTemplateDescription;
     CalculatedDuration          = SelectedServiceTemplate.CalculatedDuration;
     ServiceDirectionId          = SelectedServiceTemplate.ServiceDirectionId;
     SelectedServiceDirection    = ServiceDirectionDataAccess.GetServiceDirectionById(ServiceDirectionId);
     ServiceDirectionName        = SelectedServiceDirection.ServiceDirectionName;
     ServiceTemplateId           = SelectedServiceTemplate.Id;
     FullTimeEventsList          = new BindableCollection <FullTimeEventModel>(FullTimeEventDataAccess.GetAllFullTimeEventsPerServiceTemplate(SelectedServiceTemplate.Id));
     NotifyOfPropertyChange(() => CanLoadTimeEvents);
     NotifyOfPropertyChange(() => CanEditServiceTemplate);
     NotifyOfPropertyChange(() => CanDeleteServiceTemplate);
     NotifyOfPropertyChange(() => SelectedServiceClass);
 }