missing files
This commit is contained in:
parent
1db418e708
commit
747ce5f064
@ -25,10 +25,10 @@ namespace Manager.Interfaces.DTO
|
|||||||
public List<string> sectionIds { get; set; }
|
public List<string> sectionIds { get; set; }
|
||||||
public string loaderImageId { get; set; } // == ResourceId
|
public string loaderImageId { get; set; } // == ResourceId
|
||||||
public string loaderImageUrl { get; set; } // == Image url
|
public string loaderImageUrl { get; set; } // == Image url
|
||||||
public string weatherCity { get; set; } // Weather City
|
public string weatherCity { get; set; } // Weather City // TODO REMOVE
|
||||||
public DateTimeOffset? weatherUpdatedDate { get; set; } // Weather date update (to only refresh)
|
public DateTimeOffset? weatherUpdatedDate { get; set; } // Weather date update (to only refresh) // TODO REMOVE
|
||||||
public string weatherResult { get; set; } // Weather result
|
public string weatherResult { get; set; } // Weather result // TODO REMOVE
|
||||||
public bool isWeather
|
public bool isWeather // TODO REMOVE
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
@ -38,5 +38,8 @@ namespace Manager.Interfaces.DTO
|
|||||||
public bool isDate { get; set; }
|
public bool isDate { get; set; }
|
||||||
public bool isHour { get; set; }
|
public bool isHour { get; set; }
|
||||||
|
|
||||||
|
public bool isSectionImageBackground { get; set; } // Use to display background for section main image (or not)
|
||||||
|
public int? roundedValue { get; set; } // Use to set rounded decoration value
|
||||||
|
public int? screenPercentageSectionsMainPage { get; set; } // Use to set percentage of screen will be used to show sections (base on center)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -26,6 +26,12 @@ namespace Manager.Interfaces.DTO
|
|||||||
public CategorieDTO categorie { get; set; }
|
public CategorieDTO categorie { get; set; }
|
||||||
public string latitude { get; set; }
|
public string latitude { get; set; }
|
||||||
public string longitude { get; set; }
|
public string longitude { get; set; }
|
||||||
|
|
||||||
|
public List<TranslationDTO> schedules { get; set; }
|
||||||
|
public List<TranslationDTO> prices { get; set; }
|
||||||
|
public List<TranslationDTO> phone { get; set; }
|
||||||
|
public List<TranslationDTO> email { get; set; }
|
||||||
|
public List<TranslationDTO> site { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public class CategorieDTO
|
public class CategorieDTO
|
||||||
|
|||||||
13
Manager.Interfaces/DTO/SubSection/WeatherDTO.cs
Normal file
13
Manager.Interfaces/DTO/SubSection/WeatherDTO.cs
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace Manager.Interfaces.DTO
|
||||||
|
{
|
||||||
|
public class WeatherDTO
|
||||||
|
{
|
||||||
|
public string city { get; set; } // Weather City
|
||||||
|
public DateTimeOffset? updatedDate { get; set; } // Weather date update (to only refresh)
|
||||||
|
public string result { get; set; } // Weather result
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -76,6 +76,15 @@ namespace Manager.Interfaces.Models
|
|||||||
[BsonElement("IsHour")]
|
[BsonElement("IsHour")]
|
||||||
public bool IsHour { get; set; }
|
public bool IsHour { get; set; }
|
||||||
|
|
||||||
|
[BsonElement("IsSectionImageBackground")]
|
||||||
|
public bool IsSectionImageBackground { get; set; }
|
||||||
|
|
||||||
|
[BsonElement("RoundedValue")]
|
||||||
|
public int? RoundedValue { get; set; }
|
||||||
|
|
||||||
|
[BsonElement("ScreenPercentageSectionsMainPage")]
|
||||||
|
public int? ScreenPercentageSectionsMainPage { get; set; }
|
||||||
|
|
||||||
public ConfigurationDTO ToDTO(List<string> sectionIds)
|
public ConfigurationDTO ToDTO(List<string> sectionIds)
|
||||||
{
|
{
|
||||||
return new ConfigurationDTO()
|
return new ConfigurationDTO()
|
||||||
@ -100,6 +109,9 @@ namespace Manager.Interfaces.Models
|
|||||||
instanceId = InstanceId,
|
instanceId = InstanceId,
|
||||||
isDate = IsDate,
|
isDate = IsDate,
|
||||||
isHour = IsHour,
|
isHour = IsHour,
|
||||||
|
isSectionImageBackground = IsSectionImageBackground,
|
||||||
|
roundedValue = RoundedValue,
|
||||||
|
screenPercentageSectionsMainPage = ScreenPercentageSectionsMainPage,
|
||||||
sectionIds = sectionIds
|
sectionIds = sectionIds
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@ -126,7 +138,9 @@ namespace Manager.Interfaces.Models
|
|||||||
resources = resources,
|
resources = resources,
|
||||||
instanceId = InstanceId,
|
instanceId = InstanceId,
|
||||||
isDate = IsDate,
|
isDate = IsDate,
|
||||||
isHour = IsHour,
|
isSectionImageBackground = IsSectionImageBackground,
|
||||||
|
roundedValue = RoundedValue,
|
||||||
|
screenPercentageSectionsMainPage = ScreenPercentageSectionsMainPage,
|
||||||
sectionIds = sections.Select(s => s.id).ToList()
|
sectionIds = sections.Select(s => s.id).ToList()
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -223,6 +223,9 @@ namespace ManagerService.Controllers
|
|||||||
configuration.WeatherResult = null;
|
configuration.WeatherResult = null;
|
||||||
configuration.IsDate = newConfiguration.isDate;
|
configuration.IsDate = newConfiguration.isDate;
|
||||||
configuration.IsHour = newConfiguration.isHour;
|
configuration.IsHour = newConfiguration.isHour;
|
||||||
|
configuration.IsSectionImageBackground = newConfiguration.isSectionImageBackground;
|
||||||
|
configuration.RoundedValue = newConfiguration.roundedValue;
|
||||||
|
configuration.ScreenPercentageSectionsMainPage = newConfiguration.screenPercentageSectionsMainPage;
|
||||||
|
|
||||||
configuration.Languages = _configuration.GetSection("SupportedLanguages").Get<List<string>>();
|
configuration.Languages = _configuration.GetSection("SupportedLanguages").Get<List<string>>();
|
||||||
|
|
||||||
@ -296,6 +299,9 @@ namespace ManagerService.Controllers
|
|||||||
}
|
}
|
||||||
configuration.IsDate = updatedConfiguration.isDate;
|
configuration.IsDate = updatedConfiguration.isDate;
|
||||||
configuration.IsHour = updatedConfiguration.isHour;
|
configuration.IsHour = updatedConfiguration.isHour;
|
||||||
|
configuration.IsSectionImageBackground = updatedConfiguration.isSectionImageBackground;
|
||||||
|
configuration.RoundedValue = updatedConfiguration.roundedValue;
|
||||||
|
configuration.ScreenPercentageSectionsMainPage = updatedConfiguration.screenPercentageSectionsMainPage;
|
||||||
|
|
||||||
Configuration configurationModified = _configurationService.Update(updatedConfiguration.id, configuration);
|
Configuration configurationModified = _configurationService.Update(updatedConfiguration.id, configuration);
|
||||||
|
|
||||||
@ -430,6 +436,8 @@ namespace ManagerService.Controllers
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (mapDTO.categories != null && mapDTO.categories.Count > 0)
|
||||||
|
{
|
||||||
foreach (var categorie in mapDTO.categories)
|
foreach (var categorie in mapDTO.categories)
|
||||||
{
|
{
|
||||||
if (categorie.iconResourceId != null)
|
if (categorie.iconResourceId != null)
|
||||||
@ -437,6 +445,7 @@ namespace ManagerService.Controllers
|
|||||||
addResourceToList(resourceDTOs, categorie.iconResourceId);
|
addResourceToList(resourceDTOs, categorie.iconResourceId);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
case SectionType.Slider:
|
case SectionType.Slider:
|
||||||
@ -560,6 +569,7 @@ namespace ManagerService.Controllers
|
|||||||
case SectionType.Menu:
|
case SectionType.Menu:
|
||||||
case SectionType.Web:
|
case SectionType.Web:
|
||||||
case SectionType.Video:
|
case SectionType.Video:
|
||||||
|
case SectionType.Weather:
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -643,6 +653,9 @@ namespace ManagerService.Controllers
|
|||||||
configuration.WeatherCity = exportConfiguration.weatherCity;
|
configuration.WeatherCity = exportConfiguration.weatherCity;
|
||||||
configuration.IsDate = exportConfiguration.isDate;
|
configuration.IsDate = exportConfiguration.isDate;
|
||||||
configuration.IsHour = exportConfiguration.isHour;
|
configuration.IsHour = exportConfiguration.isHour;
|
||||||
|
configuration.IsSectionImageBackground = exportConfiguration.isSectionImageBackground;
|
||||||
|
configuration.RoundedValue = exportConfiguration.roundedValue;
|
||||||
|
configuration.ScreenPercentageSectionsMainPage = exportConfiguration.screenPercentageSectionsMainPage;
|
||||||
|
|
||||||
_configurationService.Create(configuration);
|
_configurationService.Create(configuration);
|
||||||
|
|
||||||
@ -795,6 +808,7 @@ namespace ManagerService.Controllers
|
|||||||
case SectionType.Menu:
|
case SectionType.Menu:
|
||||||
case SectionType.Web:
|
case SectionType.Web:
|
||||||
case SectionType.Video:
|
case SectionType.Video:
|
||||||
|
case SectionType.Weather:
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user