forked from ddrilling/AsbCloudServer
Merge branch 'dev' into feature/refactoring_api_route
This commit is contained in:
commit
2f415bc027
@ -105,7 +105,7 @@ namespace AsbCloudInfrastructure.Services
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (limitingLast.IdFeedRegulator != idLimiting)
|
if (limitingLast.IdFeedRegulator != idLimiting || limitingLast.DepthStart < wellDepth)
|
||||||
{
|
{
|
||||||
limitingParameters.Add(new LimitingParameter {
|
limitingParameters.Add(new LimitingParameter {
|
||||||
IdTelemetry = idTelemetry,
|
IdTelemetry = idTelemetry,
|
||||||
@ -114,7 +114,7 @@ namespace AsbCloudInfrastructure.Services
|
|||||||
DateEnd = date,
|
DateEnd = date,
|
||||||
DepthStart = limitingLast.DepthStart,
|
DepthStart = limitingLast.DepthStart,
|
||||||
DepthEnd = wellDepth
|
DepthEnd = wellDepth
|
||||||
});
|
});
|
||||||
|
|
||||||
limitingLast = new LimitingParameter
|
limitingLast = new LimitingParameter
|
||||||
{
|
{
|
||||||
|
@ -45,13 +45,8 @@ namespace AsbCloudInfrastructure.Services
|
|||||||
{
|
{
|
||||||
var trimData = TrimLimitingParameters(item, request).ToArray();
|
var trimData = TrimLimitingParameters(item, request).ToArray();
|
||||||
|
|
||||||
//TODO: временный фикс, нужно избежать отрицательных значений в ограничивающих параметрах.
|
var allItemDepths = trimData.Sum(x => x.DepthEnd - x.DepthStart);
|
||||||
//Проблема возникает при при формировании LimitingParameter в LimitingParameterCalcWorkFactory.
|
var allItemDates = trimData.Sum(x => (x.DateEnd - x.DateStart).TotalMinutes);
|
||||||
//Начальная глубина ограничивающего параметра не может быть больше конечной.
|
|
||||||
var allItemDepths = trimData.Where(x => x.DepthStart < x.DepthEnd)
|
|
||||||
.Sum(x => x.DepthEnd - x.DepthStart);
|
|
||||||
var allItemDates = trimData.Where(x => x.DepthStart < x.DepthEnd)
|
|
||||||
.Sum(x => (x.DateEnd - x.DateStart).TotalMinutes);
|
|
||||||
|
|
||||||
result.Add(new LimitingParameterDto
|
result.Add(new LimitingParameterDto
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user