已删除5个文件
已重命名45个文件
已修改34个文件
已添加27个文件
| | |
| | | { |
| | | if (_service.IsExistCode(input.Code)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | } |
| | | } |
| | | if (!string.IsNullOrEmpty(input.TagName)) |
| | | { |
| | | if (_service.IsExistTagName(input.TagName)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | } |
| | | } |
| | | var model = input.Adapt<AddLogicPolicyInput, Model.LogicPolicy>(); |
| | |
| | | var model = _service.GetByID(input.ID); |
| | | if (model == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | } |
| | | if (!string.IsNullOrEmpty(input.Code)) |
| | | { |
| | | if (_service.IsExistCodeExceptID(input.Code, input.ID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | } |
| | | } |
| | | if (!string.IsNullOrEmpty(input.TagName)) |
| | | { |
| | | if (_service.IsExistTagNameExceptID(input.TagName, input.ID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | } |
| | | } |
| | | var rhs = new Model.LogicPolicy(model); |
| | |
| | | { |
| | | if (_service.IsExistTagNameExceptID(input.TagName, input.ID)) |
| | | { |
| | | throw Oops.Oh(ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°åç§°å·²åå¨"); |
| | | throw Oops.Oh(InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°åç§°å·²åå¨"); |
| | | } |
| | | } |
| | | var bol = _service.UpdateTagName(input.ID, input.TagName); |
| | |
| | | var bol = _service.DeleteByID(input.ID, out string Msg); |
| | | if (!bol) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, Msg); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, Msg); |
| | | } |
| | | return bol; |
| | | } |
| | |
| | | Service.LogicPolicy.PublishCache(cacheKey); |
| | | var vmList = all?.Select(x => new LogicPolicyStdDto(x)).ToList(); |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel1); |
| | | }, Yw.Service.ConfigHelper.CacheLevel1); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | var policy = new Service.LogicPolicy().GetByID(input.PolicyID); |
| | | if (policy == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"PolicyID:{input.PolicyID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"PolicyID:{input.PolicyID} æ°æ®ä¸åå¨"); |
| | | } |
| | | if (!string.IsNullOrEmpty(input.Code)) |
| | | { |
| | | if (_service.IsExistCode(input.Code)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | } |
| | | } |
| | | if (!string.IsNullOrEmpty(input.TagName)) |
| | | { |
| | | if (_service.IsExistTagName(input.TagName)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | } |
| | | } |
| | | var model = input.Adapt<AddLogicAreaInput, Model.LogicArea>(); |
| | |
| | | var model = _service.GetByID(input.ID); |
| | | if (model == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | } |
| | | if (!string.IsNullOrEmpty(input.Code)) |
| | | { |
| | | if (_service.IsExistCodeExceptID(input.Code, input.ID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | } |
| | | } |
| | | if (!string.IsNullOrEmpty(input.TagName)) |
| | | { |
| | | if (_service.IsExistTagNameExceptID(input.TagName, input.ID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | } |
| | | } |
| | | var rhs = new Model.LogicArea(model); |
| | |
| | | { |
| | | if (_service.IsExistTagNameExceptID(input.TagName, input.ID)) |
| | | { |
| | | throw Oops.Oh(ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°åç§°å·²åå¨"); |
| | | throw Oops.Oh(InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°åç§°å·²åå¨"); |
| | | } |
| | | } |
| | | var bol = _service.UpdateTagName(input.ID, input.TagName); |
| | |
| | | var bol = _service.DeleteByID(input.ID, out string Msg); |
| | | if (!bol) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, Msg); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, Msg); |
| | | } |
| | | return bol; |
| | | } |
| | |
| | | Service.LogicArea.PublishCache(cacheKey); |
| | | var vmList = all?.Select(x => new LogicAreaStdDto(x)).ToList(); |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel5); |
| | | }, Yw.Service.ConfigHelper.CacheLevel5); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | Service.LogicArea.PublishCache(cacheKey); |
| | | var vmList = all?.Select(x => new LogicAreaStdDto(x)).ToList(); |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel5); |
| | | }, Yw.Service.ConfigHelper.CacheLevel5); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | { |
| | | if (_service.IsExistCode(input.Code)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | } |
| | | } |
| | | if (!string.IsNullOrEmpty(input.TagName)) |
| | | { |
| | | if (_service.IsExistTagName(input.TagName)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | } |
| | | } |
| | | var model = input.Adapt<AddLogicSiteInput, Model.LogicSite>(); |
| | |
| | | var model = _service.GetByID(input.ID); |
| | | if (model == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | } |
| | | if (!string.IsNullOrEmpty(input.Code)) |
| | | { |
| | | if (_service.IsExistCodeExceptID(input.Code, input.ID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | } |
| | | } |
| | | if (!string.IsNullOrEmpty(input.TagName)) |
| | | { |
| | | if (_service.IsExistTagNameExceptID(input.TagName, input.ID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | } |
| | | } |
| | | var rhs = new Model.LogicSite(model); |
| | |
| | | { |
| | | if (_service.IsExistTagNameExceptID(input.TagName, input.ID)) |
| | | { |
| | | throw Oops.Oh(ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°åç§°å·²åå¨"); |
| | | throw Oops.Oh(InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°åç§°å·²åå¨"); |
| | | } |
| | | } |
| | | var bol = _service.UpdateTagName(input.ID, input.TagName); |
| | |
| | | var bol = _service.DeleteByID(input.ID, out string Msg); |
| | | if (!bol) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, Msg); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, Msg); |
| | | } |
| | | return bol; |
| | | } |
| | |
| | | Service.LogicSite.PublishCache(cacheKey); |
| | | var vmList = all?.Select(x => new LogicSiteStdDto(x)).ToList(); |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel1); |
| | | }, Yw.Service.ConfigHelper.CacheLevel1); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | var policy = new Service.LogicPolicy().GetByID(input.PolicyID); |
| | | if (policy == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"PolicyID:{input.PolicyID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"PolicyID:{input.PolicyID} æ°æ®ä¸åå¨"); |
| | | } |
| | | if (_service.IsExist(input.PolicyID, input.LogicType, input.LogicID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"LogicType:{input.LogicType}ï¼LogicID:{input.LogicID} å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"LogicType:{input.LogicType}ï¼LogicID:{input.LogicID} å·²åå¨"); |
| | | } |
| | | var parentIds = new List<long>(); |
| | | if (input.ParentID > 0) |
| | |
| | | var parent = _service.GetByID(input.ParentID); |
| | | if (parent == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ParentID:{input.ParentID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ParentID:{input.ParentID} æ°æ®ä¸åå¨"); |
| | | } |
| | | if (parent.PolicyID != input.PolicyID) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"ParentID:{input.ParentID} ä¸ PolicyID:{input.PolicyID} ä¸å¹é
"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"ParentID:{input.ParentID} ä¸ PolicyID:{input.PolicyID} ä¸å¹é
"); |
| | | } |
| | | parentIds = TreeParentIdsHelper.GetChildParentIds(parent.ID, parent.ParentIds); |
| | | } |
| | |
| | | var model = _service.GetByID(input.ID); |
| | | if (model == null) |
| | | { |
| | | throw Oops.Oh(ErrorCodes.D001, $"ID:{input.ID}"); |
| | | throw Oops.Oh(InternalErrorCodes.D001, $"ID:{input.ID}"); |
| | | } |
| | | var parentIds = new List<long>(); |
| | | if (input.ParentID > 0) |
| | |
| | | var parent = _service.GetByID(input.ParentID); |
| | | if (parent == null) |
| | | { |
| | | throw Oops.Oh(ErrorCodes.D001, $"ParentID:{input.ParentID}"); |
| | | throw Oops.Oh(InternalErrorCodes.D001, $"ParentID:{input.ParentID}"); |
| | | } |
| | | parentIds = TreeParentIdsHelper.GetChildParentIds(parent.ID, parent.ParentIds); |
| | | } |
| | |
| | | var bol = _service.DeleteByID(input.ID, out string Msg); |
| | | if (!bol) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, Msg); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, Msg); |
| | | } |
| | | return bol; |
| | | } |
| | |
| | | var policy = new Service.LogicPolicy().GetByID(input.PolicyID); |
| | | if (policy == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"PolicyID:{input.PolicyID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"PolicyID:{input.PolicyID} æ°æ®ä¸åå¨"); |
| | | } |
| | | if (input.TreeList != null && input.TreeList.Count > 0) |
| | | { |
| | |
| | | |
| | | if (tempList.Exists(x => x.LogicType == IStation.DataType.LogicSite && x.Children != null && x.Children.Count > 0)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"èç¹é»è¾å
³ç³»é误ï¼è¯·æ£æ¥åéè¯ï¼"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"èç¹é»è¾å
³ç³»é误ï¼è¯·æ£æ¥åéè¯ï¼"); |
| | | } |
| | | |
| | | var groupTreeList = tempList.GroupBy(x => new { x.LogicType, x.LogicID }).ToList(); |
| | | if (groupTreeList.Exists(x => x.Count() > 1)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"èç¹ä¸è½éå¤ï¼è¯·æ£æ¥åéè¯ï¼"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"èç¹ä¸è½éå¤ï¼è¯·æ£æ¥åéè¯ï¼"); |
| | | } |
| | | |
| | | } |
| | |
| | | Service.LogicTree.PublishCache(cacheKey); |
| | | var vmList = list?.Select(x => new LogicTreeItemDto(x)).ToList(); |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel5); |
| | | }, Yw.Service.ConfigHelper.CacheLevel5); |
| | | return vm_list; |
| | | |
| | | } |
| | |
| | | tempList.Add(vm); |
| | | } |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel5); |
| | | }, Yw.Service.ConfigHelper.CacheLevel5); |
| | | return vm_list; |
| | | |
| | | } |
| | |
| | | { |
| | | if (_service.IsExistCode(input.Code)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | } |
| | | } |
| | | if (!string.IsNullOrEmpty(input.TagName)) |
| | | { |
| | | if (_service.IsExistTagName(input.TagName)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | } |
| | | } |
| | | var model = input.Adapt<AddLogicDmaInput, Model.LogicDma>(); |
| | |
| | | var model = _service.GetByID(input.ID); |
| | | if (model == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | } |
| | | if (!string.IsNullOrEmpty(input.Code)) |
| | | { |
| | | if (_service.IsExistCodeExceptID(input.Code, input.ID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"Code:{input.Code}", "ç¼ç å·²åå¨"); |
| | | } |
| | | } |
| | | if (!string.IsNullOrEmpty(input.TagName)) |
| | | { |
| | | if (_service.IsExistTagNameExceptID(input.TagName, input.ID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°å·²åå¨"); |
| | | } |
| | | } |
| | | var rhs = new Model.LogicDma(model); |
| | |
| | | { |
| | | if (_service.IsExistTagNameExceptID(input.TagName, input.ID)) |
| | | { |
| | | throw Oops.Oh(ErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°åç§°å·²åå¨"); |
| | | throw Oops.Oh(InternalErrorCodes.V001, $"TagName:{input.TagName}", "æ è®°åç§°å·²åå¨"); |
| | | } |
| | | } |
| | | var bol = _service.UpdateTagName(input.ID, input.TagName); |
| | |
| | | var bol = _service.DeleteByID(input.ID, out string Msg); |
| | | if (!bol) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, Msg); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, Msg); |
| | | } |
| | | return bol; |
| | | } |
| | |
| | | Service.LogicDma.PublishCache(cacheKey); |
| | | var vmList = all?.Select(x => new LogicDmaStdDto(x)).ToList(); |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel1); |
| | | }, Yw.Service.ConfigHelper.CacheLevel1); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | } |
| | | } |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel5); |
| | | }, Yw.Service.ConfigHelper.CacheLevel5); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class MonitorFullLogicalTreeDto : Yw.Application.LogicalTreeDto |
| | | public class MonitorFullLogicalTreeDto : Yw.Dto.LogicalTreeDto |
| | | { |
| | | /// <summary> |
| | | /// |
| | |
| | | } |
| | | |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel5); |
| | | }, Yw.Service.ConfigHelper.CacheLevel5); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class EquipmentFullLogicalTreeDto : Yw.Application.LogicalTreeDto |
| | | public class EquipmentFullLogicalTreeDto : Yw.Dto.LogicalTreeDto |
| | | { |
| | | /// <summary> |
| | | /// |
| | |
| | | var model = new Yw.Service.DmaArea().GetByID(input.ID); |
| | | if (model == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | } |
| | | var vm = new DmaAnalyAreaDetailDto(model); |
| | | |
| | |
| | | var site = new Yw.Service.DmaSite().GetByID(input.ID); |
| | | if (site == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | } |
| | | var vm = new DmaAnalySiteDetailDto(site); |
| | | |
| | |
| | | var site = new Yw.Service.DmaSite().GetByID(input.ID); |
| | | if (site == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | } |
| | | var binding = new Yw.Service.DmaSiteBinding().GetValidBySiteID(site.ID); |
| | | if (binding == null) |
| | |
| | | var catalogList = new Yw.Service.SysCatalog().GetChildAndSelfByCode(IStation.Catalog.FlowMeter); |
| | | if (catalogList == null || catalogList.Count < 1) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, "æµé计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, "æµé计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | } |
| | | var catalogIds = catalogList.Select(x => x.ID).Distinct().ToList(); |
| | | |
| | |
| | | var catalogList = new Yw.Service.SysCatalog().GetChildAndSelfByCode(IStation.Catalog.PressMeter); |
| | | if (catalogList == null || catalogList.Count < 1) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, "åå计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, "åå计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | } |
| | | var catalogIds = catalogList.Select(x => x.ID).Distinct().ToList(); |
| | | |
| | |
| | | var catalogList = new Yw.Service.SysCatalog().GetChildAndSelfByCode(IStation.Catalog.FlowMeter); |
| | | if (catalogList == null || catalogList.Count < 1) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, "æµé计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, "æµé计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | } |
| | | var catalogIds = catalogList.Select(x => x.ID).Distinct().ToList(); |
| | | |
| | |
| | | var catalogList = new Yw.Service.SysCatalog().GetChildAndSelfByCode(IStation.Catalog.PressMeter); |
| | | if (catalogList == null || catalogList.Count < 1) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, "åå计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, "åå计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | } |
| | | var catalogIds = catalogList.Select(x => x.ID).Distinct().ToList(); |
| | | |
| | |
| | | |
| | | |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel1); |
| | | }, Yw.Service.ConfigHelper.CacheLevel1); |
| | | return vm_list; |
| | | |
| | | } |
| | |
| | | #endregion |
| | | |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel1); |
| | | }, Yw.Service.ConfigHelper.CacheLevel1); |
| | | return vm_list; |
| | | |
| | | } |
| | |
| | | } |
| | | return vmList; |
| | | |
| | | }, CacheHelper.CacheLevel3); |
| | | }, Yw.Service.ConfigHelper.CacheLevel3); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | var station = new Service.LogicSite().GetByID(input.StationID); |
| | | if (station == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"StationID:{input.StationID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"StationID:{input.StationID} æ°æ®ä¸åå¨"); |
| | | } |
| | | var vm = new StationMapMonitorKpiInfoMobileDto(station); |
| | | |
| | |
| | | Yw.Service.SysCatalog.PublishCache(cacheKey); |
| | | if (catalogList == null || catalogList.Count < 1) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, "æµé计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, "æµé计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | } |
| | | var catalogIds = catalogList.Select(x => x.ID).Distinct().ToList(); |
| | | |
| | |
| | | |
| | | return vmList; |
| | | |
| | | }, CacheHelper.CacheLevel3); |
| | | }, Yw.Service.ConfigHelper.CacheLevel3); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | var equipment = new Yw.Service.Equipment().GetByID(input.FlowMeterID); |
| | | if (equipment == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"FlowMeterID:{input.FlowMeterID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"FlowMeterID:{input.FlowMeterID} æ°æ®ä¸åå¨"); |
| | | } |
| | | var catalogList = new Yw.Service.SysCatalog().GetChildAndSelfByCode(IStation.Catalog.FlowMeter); |
| | | if (catalogList == null || catalogList.Count < 1) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, "æµé计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, "æµé计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | } |
| | | var catalogIds = catalogList.Select(x => x.ID).Distinct().ToList(); |
| | | if (!catalogIds.Contains(equipment.CatalogID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"FlowMeterID:{input.FlowMeterID} 请è¾å
¥æ£ç¡®æµé计id"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"FlowMeterID:{input.FlowMeterID} 请è¾å
¥æ£ç¡®æµé计id"); |
| | | } |
| | | |
| | | var vm = new FlowMeterMapMonitorKpiInfoMobileDto(); |
| | |
| | | Yw.Service.SysCatalog.PublishCache(cacheKey); |
| | | if (catalogList == null || catalogList.Count < 1) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, "åå计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, "åå计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | } |
| | | var catalogIds = catalogList.Select(x => x.ID).Distinct().ToList(); |
| | | |
| | |
| | | |
| | | return vmList; |
| | | |
| | | }, CacheHelper.CacheLevel3); |
| | | }, Yw.Service.ConfigHelper.CacheLevel3); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | var equipment = new Yw.Service.Equipment().GetByID(input.PressMeterID); |
| | | if (equipment == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"PressMeterID:{input.PressMeterID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"PressMeterID:{input.PressMeterID} æ°æ®ä¸åå¨"); |
| | | } |
| | | var catalogList = new Yw.Service.SysCatalog().GetChildAndSelfByCode(IStation.Catalog.PressMeter); |
| | | if (catalogList == null || catalogList.Count < 1) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, "åå计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, "åå计åç±»ç¼ç éªè¯å¤±è´¥"); |
| | | } |
| | | var catalogIds = catalogList.Select(x => x.ID).Distinct().ToList(); |
| | | if (!catalogIds.Contains(equipment.CatalogID)) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"PressMeterID:{input.PressMeterID} 请è¾å
¥æ£ç¡®åå计id"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"PressMeterID:{input.PressMeterID} 请è¾å
¥æ£ç¡®åå计id"); |
| | | } |
| | | |
| | | var vm = new PressMeterMapMonitorKpiInfoMobileDto(); |
| | |
| | | var request = new Yw.Service.RepairRequestForm().GetByID(FormID); |
| | | if (request == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"FormID:{FormID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"FormID:{FormID} æ°æ®ä¸åå¨"); |
| | | } |
| | | return new RepairMapStatusMobileDto(request); |
| | | } |
| | |
| | | var task = new Yw.Service.RepairTaskForm().GetByID(FormID); |
| | | if (task == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"FormID:{FormID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"FormID:{FormID} æ°æ®ä¸åå¨"); |
| | | } |
| | | return new RepairMapStatusMobileDto(task); |
| | | } |
| | | |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"FormType åæ°é误"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.V001, $"FormType åæ°é误"); |
| | | |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | return vm_list; |
| | | }, CacheHelper.CacheLevel3); |
| | | }, Yw.Service.ConfigHelper.CacheLevel3); |
| | | return vm_list; |
| | | } |
| | | |
| | |
| | | vmList.Add(vm); |
| | | } |
| | | return vmList; |
| | | }, CacheHelper.CacheLevel3); |
| | | }, Yw.Service.ConfigHelper.CacheLevel3); |
| | | |
| | | if (vm_list != null && vm_list.Count > 0) |
| | | { |
| | |
| | | var equipment = service_equipment.GetByID(input.ID); |
| | | if (equipment == null) |
| | | { |
| | | throw YOops.Oh(eResultCode.Alert, ErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | throw YOops.Oh(eResultCode.Alert, InternalErrorCodes.D001, $"ID:{input.ID} æ°æ®ä¸åå¨"); |
| | | } |
| | | var supplier = new Yw.Service.Supplier().GetByID(equipment.SupplierID); |
| | | |
| | |
| | | } |
| | | |
| | | return monthRecord; |
| | | }, CacheHelper.CacheLevel1); |
| | | }, Yw.Service.ConfigHelper.CacheLevel1); |
| | | |
| | | return vm_list; |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application |
| | | { |
| | | /// <summary> |
| | | /// BigScreen |
| | | /// </summary> |
| | | [Route("SZJT/Big/Screen/Logic")] |
| | | [ApiDescriptionSettings("SZJT", Name = "大å±(Logic)", Order = 1000)] |
| | | public class BigScreen_LogicController : IDynamicApiController |
| | | { |
| | | |
| | | #region ææ |
| | | |
| | | /// <summary> |
| | | /// è·åæææ³µç«kpiä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetAllStationKpiInfo@V1.0")] |
| | | [HttpGet] |
| | | public BigScreenAllStationKpiDto GetAllStationKpiInfo() |
| | | { |
| | | var vm = new BigScreenAllStationKpiDto(); |
| | | vm.Lws = new BigScreenAllStationKpiItemDto() |
| | | { |
| | | Name = "彿¥ç´¯è®¡ä¾æ°´é", |
| | | Value = "1120", |
| | | UnitName = "m³" |
| | | }; |
| | | vm.Lps = new BigScreenAllStationKpiItemDto() |
| | | { |
| | | Name = "彿¥ç´¯è®¡ç¨çµé", |
| | | Value = "2300", |
| | | UnitName = "kWâ§h" |
| | | }; |
| | | vm.Sws = new BigScreenAllStationKpiItemDto() |
| | | { |
| | | Name = "å½åç¬æ¶æ»æµé", |
| | | Value = "2300.2", |
| | | UnitName = "m³/h" |
| | | }; |
| | | vm.Sps = new BigScreenAllStationKpiItemDto() |
| | | { |
| | | Name = "å½åç¬æ¶æ»åç", |
| | | Value = "2600.2", |
| | | UnitName = "kW" |
| | | }; |
| | | vm.Tsc = new BigScreenAllStationKpiItemDto() |
| | | { |
| | | Name = "æ³µç«æ»æ°é", |
| | | Value = "13", |
| | | UnitName = "座" |
| | | }; |
| | | vm.Rsc = new BigScreenAllStationKpiItemDto() |
| | | { |
| | | Name = "è¿è¡æ³µç«æ°é", |
| | | Value = "10", |
| | | UnitName = "座" |
| | | }; |
| | | vm.Tpc = new BigScreenAllStationKpiItemDto() |
| | | { |
| | | Name = "æºç»æ»æ°", |
| | | Value = "50", |
| | | UnitName = "å°" |
| | | }; |
| | | vm.Rpc = new BigScreenAllStationKpiItemDto() |
| | | { |
| | | Name = "è¿è¡æºç»æ°é", |
| | | Value = "40", |
| | | UnitName = "å°" |
| | | }; |
| | | return vm; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæææ³µç«é¡¹å表 |
| | | /// </summary> |
| | | [Route("GetAllStationItemList@V1.0")] |
| | | [HttpGet] |
| | | public List<BigScreenAllStationListItemDto> GetAllStationItemList() |
| | | { |
| | | var allStationList = new Service.LogicSite().GetAll(); |
| | | if (allStationList == null || allStationList.Count < 1) |
| | | { |
| | | return default; |
| | | } |
| | | |
| | | var service_monitor = new Lazy<Yw.Service.MonitorPoint>(() => new Yw.Service.MonitorPoint()); |
| | | var service_monitor_record = new Lazy<Yw.Service.MonitorRealRecord>(() => new Yw.Service.MonitorRealRecord()); |
| | | |
| | | var vmList = new List<BigScreenAllStationListItemDto>(); |
| | | foreach (var station in allStationList) |
| | | { |
| | | var vm = new BigScreenAllStationListItemDto(); |
| | | vm.ID = station.ID; |
| | | vm.Name = station.Name; |
| | | vmList.Add(vm); |
| | | var allMonitorList = service_monitor.Value.GetExSignalWithSignalTypeByBelongTypeAndBelongID(IStation.DataType.LogicSite, station.ID, Yw.Monitor.eCronType.Real); |
| | | if (allMonitorList != null && allMonitorList.Count > 0) |
| | | { |
| | | var monitorQ = allMonitorList.Find(x => x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.ç¬æ¶æµé)); |
| | | if (monitorQ != null) |
| | | { |
| | | var signalQ = monitorQ.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.ç¬æ¶æµé); |
| | | vm.Qk = new BigScreenAllStationListKpiItemDto() |
| | | { |
| | | Name = "ç¬æ¶æµé", |
| | | Value = null, |
| | | UnitName = signalQ.GetDisplayUnitName() |
| | | }; |
| | | var recordQ = service_monitor_record.Value.GetLastRecord(signalQ.ID); |
| | | if (recordQ != null) |
| | | { |
| | | vm.Qk.Value = signalQ.GetDisplayValue(recordQ.DataValue); |
| | | } |
| | | } |
| | | |
| | | var monitorPr = allMonitorList.Find(x => x.Flags.Contains(Yw.Monitor.Flags.åºå£) && x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.åå)); |
| | | if (monitorPr != null) |
| | | { |
| | | var signalPr = monitorPr.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.åå); |
| | | vm.Prk = new BigScreenAllStationListKpiItemDto() |
| | | { |
| | | Name = "åºå£åå", |
| | | Value = null, |
| | | UnitName = signalPr.GetDisplayUnitName() |
| | | }; |
| | | var recordPr = service_monitor_record.Value.GetLastRecord(signalPr.ID); |
| | | if (recordPr != null) |
| | | { |
| | | vm.Prk.Value = signalPr.GetDisplayValue(recordPr.DataValue); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | return vmList; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæææ³µç«å·¥åKpiä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetAllStationRepairKpiInfo@V1.0")] |
| | | [HttpGet] |
| | | public BigScreenAllStationRepairKpiDto GetAllStationRepairKpiInfo() |
| | | { |
| | | var vm = new BigScreenAllStationRepairKpiDto(); |
| | | vm.Cd = 10; |
| | | vm.Cm = 235; |
| | | vm.Cy = 1230; |
| | | vm.Pending = 5; |
| | | vm.Accepted = 5; |
| | | vm.Progress = 35; |
| | | vm.Checked = 680; |
| | | return vm; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæææ³µç«å·¥åæ¥ç»è®¡ï¼æè¿ä¸æï¼ |
| | | /// </summary> |
| | | [Route("GetAllStationRepairDayStatisticsInfo@V1.0")] |
| | | [HttpGet] |
| | | public List<BigScreenAllStationRepairDayCountDto> GetAllStationRepairDayStatisticsInfo() |
| | | { |
| | | var dtEnd = DateTime.Now.Date; |
| | | var dtStart = dtEnd.AddMonths(-1); |
| | | var vmList = new List<BigScreenAllStationRepairDayCountDto>(); |
| | | for (DateTime dt = dtStart; dt <= dtEnd; dt = dt.AddDays(1)) |
| | | { |
| | | var vm = new BigScreenAllStationRepairDayCountDto(); |
| | | vm.Day = dt; |
| | | vm.Count = Yw.Untity.RandomHelper.Random(10, 100); |
| | | vmList.Add(vm); |
| | | } |
| | | return vmList; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæææ³µç«å·¥åæç»è®¡ï¼æè¿ä¸å¹´ï¼ |
| | | /// </summary> |
| | | [Route("GetAllStationRepairMonthStatisticsInfo@V1.0")] |
| | | [HttpGet] |
| | | public List<BigScreenAllStationRepairMonthCountDto> GetAllStationRepairMonthStatisticsInfo() |
| | | { |
| | | var dtNow = DateTime.Now; |
| | | var dtEnd = new DateTime(dtNow.Year, dtNow.Month, 1); |
| | | var dtStart = dtEnd.AddMonths(-11); |
| | | var vmList = new List<BigScreenAllStationRepairMonthCountDto>(); |
| | | for (DateTime dt = dtStart; dt <= dtEnd; dt = dt.AddMonths(1)) |
| | | { |
| | | var vm = new BigScreenAllStationRepairMonthCountDto(); |
| | | vm.Year = dt.Year; |
| | | vm.Month = dt.Month; |
| | | vm.Count = Yw.Untity.RandomHelper.Random(100, 1000); |
| | | vmList.Add(vm); |
| | | } |
| | | return vmList; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·åæææ³µç«æ¥è¦ä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetAllStationAlarmInfo@V1.0")] |
| | | [HttpGet] |
| | | public List<BigScreenAllStationAlarmItemDto> GetAllStationAlarmInfo() |
| | | { |
| | | var vmList = new List<BigScreenAllStationAlarmItemDto>(); |
| | | vmList.Add(new BigScreenAllStationAlarmItemDto() |
| | | { |
| | | ID = 1, |
| | | Name = "éåºä¸è
°æ³µç«", |
| | | Content = "1#æºç»åºå£ååè¿ä½ï¼è¯·å
³æ³¨ç¶æåå" |
| | | }); |
| | | vmList.Add(new BigScreenAllStationAlarmItemDto() |
| | | { |
| | | ID = 2, |
| | | Name = "坿³ä¸ä½åå åæ³µç«", |
| | | Content = "2#ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | vmList.Add(new BigScreenAllStationAlarmItemDto() |
| | | { |
| | | ID = 3, |
| | | Name = "坿³ä¸ä½åå åæ³µç«", |
| | | Content = "2#ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | vmList.Add(new BigScreenAllStationAlarmItemDto() |
| | | { |
| | | ID = 4, |
| | | Name = "坿³ä¸ä½åå åæ³µç«", |
| | | Content = "2#ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | vmList.Add(new BigScreenAllStationAlarmItemDto() |
| | | { |
| | | ID = 5, |
| | | Name = "坿³ä¸ä½åå åæ³µç«", |
| | | Content = "2#ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | vmList.Add(new BigScreenAllStationAlarmItemDto() |
| | | { |
| | | ID = 6, |
| | | Name = "坿³ä¸ä½åå åæ³µç«", |
| | | Content = "2#ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | return vmList; |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | |
| | | #region åç« |
| | | |
| | | /// <summary> |
| | | /// è·ååæ³µç«kpiä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetSingleStationKpiInfo@V1.0")] |
| | | [HttpGet] |
| | | public BigScreenSingleStationKpiDto GetSingleStationKpiInfo([FromQuery][Required] StationIDInput input) |
| | | { |
| | | var vm = new BigScreenSingleStationKpiDto(); |
| | | |
| | | var service_monitor = new Lazy<Yw.Service.MonitorPoint>(() => new Yw.Service.MonitorPoint()); |
| | | var service_monitor_record = new Lazy<Yw.Service.MonitorRealRecord>(() => new Yw.Service.MonitorRealRecord()); |
| | | var service_equipment = new Lazy<Yw.Service.Equipment>(() => new Yw.Service.Equipment()); |
| | | var service_run_record = new Lazy<Yw.Service.RunRealRecord>(() => new Yw.Service.RunRealRecord()); |
| | | |
| | | var allMonitorList = service_monitor.Value.GetExSignalWithSignalTypeByBelongTypeAndBelongID(IStation.DataType.LogicSite, input.StationID, Yw.Monitor.eCronType.Real); |
| | | if (allMonitorList != null && allMonitorList.Count > 0) |
| | | { |
| | | var monitorQ = allMonitorList.Find(x => x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.ç¬æ¶æµé)); |
| | | if (monitorQ != null) |
| | | { |
| | | var signalQ = monitorQ.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.ç¬æ¶æµé); |
| | | vm.Q = new BigScreenSingleStationKpiItemDto() |
| | | { |
| | | Name = "ç¬æ¶æµé", |
| | | Value = null, |
| | | UnitName = signalQ.GetDisplayUnitName() |
| | | }; |
| | | var recordQ = service_monitor_record.Value.GetLastRecord(signalQ.ID); |
| | | if (recordQ != null) |
| | | { |
| | | vm.Q.Value = signalQ.GetDisplayValue(recordQ.DataValue); |
| | | } |
| | | } |
| | | |
| | | var monitorPr = allMonitorList.Find(x => x.Flags.Contains(Yw.Monitor.Flags.åºå£) && x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.åå)); |
| | | if (monitorPr != null) |
| | | { |
| | | var signalPr = monitorPr.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.åå); |
| | | vm.Pr = new BigScreenSingleStationKpiItemDto() |
| | | { |
| | | Name = "åºå£åå", |
| | | Value = null, |
| | | UnitName = signalPr.GetDisplayUnitName() |
| | | }; |
| | | var recordPr = service_monitor_record.Value.GetLastRecord(signalPr.ID); |
| | | if (recordPr != null) |
| | | { |
| | | vm.Pr.Value = signalPr.GetDisplayValue(recordPr.DataValue); |
| | | } |
| | | } |
| | | |
| | | var monitorZD = allMonitorList.Find(x => x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.æµåº¦)); |
| | | if (monitorZD != null) |
| | | { |
| | | var signalZD = monitorZD.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.æµåº¦); |
| | | vm.ZD = new BigScreenSingleStationKpiItemDto() |
| | | { |
| | | Name = "æµåº¦", |
| | | Value = null, |
| | | UnitName = signalZD.GetDisplayUnitName() |
| | | }; |
| | | var recordZD = service_monitor_record.Value.GetLastRecord(signalZD.ID); |
| | | if (recordZD != null) |
| | | { |
| | | vm.ZD.Value = signalZD.GetDisplayValue(recordZD.DataValue); |
| | | } |
| | | } |
| | | |
| | | var monitorYL = allMonitorList.Find(x => x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.使°¯)); |
| | | if (monitorYL != null) |
| | | { |
| | | var signalYL = monitorYL.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.使°¯); |
| | | vm.YL = new BigScreenSingleStationKpiItemDto() |
| | | { |
| | | Name = "使°¯", |
| | | Value = null, |
| | | UnitName = signalYL.GetDisplayUnitName() |
| | | }; |
| | | var recordYL = service_monitor_record.Value.GetLastRecord(signalYL.ID); |
| | | if (recordYL != null) |
| | | { |
| | | vm.YL.Value = signalYL.GetDisplayValue(recordYL.DataValue); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | var allEquipmentList = service_equipment.Value.GetByBelongTypeAndBelongID(IStation.DataType.LogicSite, input.StationID); |
| | | allEquipmentList = allEquipmentList?.Where(x => x.Flags.Contains(IStation.Flags.æºç»)).ToList(); |
| | | if (allEquipmentList != null && allEquipmentList.Count > 0) |
| | | { |
| | | vm.RunList = new List<BigScreenSingleStationKpiRunItemDto>(); |
| | | foreach (var equipment in allEquipmentList) |
| | | { |
| | | var vm_run = new BigScreenSingleStationKpiRunItemDto() |
| | | { |
| | | Name = equipment.Name, |
| | | RunStatus = 0 |
| | | }; |
| | | var run_record = service_run_record.Value.GetLastRecord(Yw.Assets.DataType.Equipment, equipment.ID); |
| | | if (run_record != null) |
| | | { |
| | | vm_run.RunStatus = run_record.RSa; |
| | | } |
| | | vm.RunList.Add(vm_run); |
| | | } |
| | | } |
| | | |
| | | return vm; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·ååæ³µç«ææ ä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetSingleStationQuotaInfo@V1.0")] |
| | | [HttpGet] |
| | | public BigScreenSingleStationQuotaKpiDto GetSingleStationQuotaInfo([FromQuery][Required] StationIDInput input) |
| | | { |
| | | var vm = new BigScreenSingleStationQuotaKpiDto(); |
| | | vm.Ws = new List<BigScreenSingleStationQuotaItemDto>(); |
| | | vm.Ps = new List<BigScreenSingleStationQuotaItemDto>(); |
| | | |
| | | var dtEnd = DateTime.Now.Date; |
| | | var dtStart = dtEnd.AddMonths(-1); |
| | | for (DateTime dt = dtStart; dt <= dtEnd; dt = dt.AddDays(1)) |
| | | { |
| | | vm.Ws.Add(new BigScreenSingleStationQuotaItemDto() |
| | | { |
| | | Day = dt, |
| | | Value = RandomHelper.Random(1000, 10000).ToString(), |
| | | UnitName = "m³" |
| | | }); |
| | | vm.Ps.Add(new BigScreenSingleStationQuotaItemDto() |
| | | { |
| | | Day = dt, |
| | | Value = RandomHelper.Random(2000, 3000).ToString(), |
| | | UnitName = "kWâ§h" |
| | | }); |
| | | } |
| | | return vm; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·ååæ³µç«æºç»é¡¹å表 |
| | | /// </summary> |
| | | [Route("GetSingleStationEnginePumpItemList@V1.0")] |
| | | [HttpGet] |
| | | public List<BigScreenSingleStationEnginePumpListItemDto> GetSingleStationEnginePumpItemList([FromQuery][Required] StationIDInput input) |
| | | { |
| | | var service_equipment = new Yw.Service.Equipment(); |
| | | var allEnginePumpList = service_equipment.GetByBelongTypeAndBelongID(IStation.DataType.LogicSite, input.StationID); |
| | | allEnginePumpList = allEnginePumpList?.Where(x => x.Flags.Contains(IStation.Flags.æºç»)).ToList(); |
| | | if (allEnginePumpList == null || allEnginePumpList.Count < 1) |
| | | { |
| | | return default; |
| | | } |
| | | |
| | | var service_monitor_mapping = new Lazy<Yw.Service.EquipmentMonitorMapping>(() => new Yw.Service.EquipmentMonitorMapping()); |
| | | var service_monitor = new Lazy<Yw.Service.MonitorPoint>(() => new Yw.Service.MonitorPoint()); |
| | | var service_monitor_record = new Lazy<Yw.Service.MonitorRealRecord>(() => new Yw.Service.MonitorRealRecord()); |
| | | |
| | | var vmList = new List<BigScreenSingleStationEnginePumpListItemDto>(); |
| | | foreach (var enginePump in allEnginePumpList) |
| | | { |
| | | var vm = new BigScreenSingleStationEnginePumpListItemDto(); |
| | | vm.ID = enginePump.ID; |
| | | vm.Name = enginePump.Name; |
| | | vmList.Add(vm); |
| | | |
| | | var allChildEquipmentList = service_equipment.GetChildAndSelfByID(enginePump.ID); |
| | | if (allChildEquipmentList != null && allChildEquipmentList.Count > 0) |
| | | { |
| | | var allChildEquipmentIds = allChildEquipmentList.Select(x => x.ID).Distinct().ToList(); |
| | | var allMappingList = service_monitor_mapping.Value.GetByEquipmentIds(allChildEquipmentIds); |
| | | if (allMappingList != null && allMappingList.Count > 0) |
| | | { |
| | | var allMonitorIds = allMappingList.Select(x => x.MonitorPointID).Distinct().ToList(); |
| | | var allMonitorList = service_monitor.Value.GetExSignalWithSignalTypeByIds(allMonitorIds); |
| | | if (allMonitorList != null && allMonitorList.Count > 0) |
| | | { |
| | | var monitorRs = allMonitorList.Find(x => x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.è¿è¡ç¶æ)); |
| | | if (monitorRs != null) |
| | | { |
| | | var signalRs = monitorRs.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.è¿è¡ç¶æ); |
| | | vm.Rs = new BigScreenSingleStationEnginePumpListKpiItemDto() |
| | | { |
| | | Name = "ç¶æ", |
| | | Value = null, |
| | | UnitName = null |
| | | }; |
| | | var recordRs = service_monitor_record.Value.GetLastRecord(signalRs.ID); |
| | | if (recordRs != null) |
| | | { |
| | | vm.Rs.Value = recordRs.DataValue; |
| | | } |
| | | } |
| | | |
| | | var monitorHz = allMonitorList.Find(x => x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.é¢ç)); |
| | | if (monitorHz != null) |
| | | { |
| | | var signalHz = monitorHz.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.é¢ç); |
| | | vm.Hz = new BigScreenSingleStationEnginePumpListKpiItemDto() |
| | | { |
| | | Name = "é¢ç", |
| | | Value = null, |
| | | UnitName = signalHz.GetDisplayUnitName() |
| | | }; |
| | | var recordHz = service_monitor_record.Value.GetLastRecord(signalHz.ID); |
| | | if (recordHz != null) |
| | | { |
| | | vm.Hz.Value = signalHz.GetDisplayValue(recordHz.DataValue); |
| | | } |
| | | } |
| | | |
| | | var monitorP = allMonitorList.Find(x => x.SignalList.Exists(t => t.SignalType.Code == Yw.Monitor.SignalType.æååç)); |
| | | if (monitorP != null) |
| | | { |
| | | var signalP = monitorP.SignalList.Find(x => x.SignalType.Code == Yw.Monitor.SignalType.æååç); |
| | | vm.P = new BigScreenSingleStationEnginePumpListKpiItemDto() |
| | | { |
| | | Name = "åç", |
| | | Value = null, |
| | | UnitName = signalP.GetDisplayUnitName() |
| | | }; |
| | | var recordP = service_monitor_record.Value.GetLastRecord(signalP.ID); |
| | | if (recordP != null) |
| | | { |
| | | vm.P.Value = signalP.GetDisplayValue(recordP.DataValue); |
| | | } |
| | | } |
| | | |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | return vmList; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·ååæ³µç«å·¥åKpiä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetSingleStationRepairKpiInfo@V1.0")] |
| | | [HttpGet] |
| | | public BigScreenSingleStationRepairKpiDto GetSingleStationRepairKpiInfo([FromQuery][Required] StationIDInput input) |
| | | { |
| | | var vm = new BigScreenSingleStationRepairKpiDto(); |
| | | vm.Cd = 10; |
| | | vm.Cm = 235; |
| | | vm.Cy = 1230; |
| | | vm.Pending = 5; |
| | | vm.Accepted = 5; |
| | | vm.Progress = 35; |
| | | vm.Checked = 680; |
| | | return vm; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·ååæ³µç«å·¥åç»è®¡ä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetSingleStationRepairStatisticsInfo@V1.0")] |
| | | [HttpGet] |
| | | public BigScreenSingleStationRepairStatisticsInfoDto GetSingleStationRepairStatisticsInfo([FromQuery][Required] StationIDInput input) |
| | | { |
| | | var vm = new BigScreenSingleStationRepairStatisticsInfoDto(); |
| | | vm.LastMonth = new List<BigScreenSingleStationRepairDayCountDto>(); |
| | | |
| | | var dtEnd = DateTime.Now.Date; |
| | | var dtStart = dtEnd.AddMonths(-1); |
| | | for (DateTime dt = dtStart; dt <= dtEnd; dt = dt.AddDays(1)) |
| | | { |
| | | var vm_day = new BigScreenSingleStationRepairDayCountDto(); |
| | | vm_day.Day = dt; |
| | | vm_day.Count = Yw.Untity.RandomHelper.Random(10, 100); |
| | | vm.LastMonth.Add(vm_day); |
| | | } |
| | | |
| | | vm.LastYear = new List<BigScreenSingleStationRepairMonthCountDto>(); |
| | | var dtNow = DateTime.Now; |
| | | dtEnd = new DateTime(dtNow.Year, dtNow.Month, 1); |
| | | dtStart = dtEnd.AddMonths(-11); |
| | | for (DateTime dt = dtStart; dt <= dtEnd; dt = dt.AddMonths(1)) |
| | | { |
| | | var vm_month = new BigScreenSingleStationRepairMonthCountDto(); |
| | | vm_month.Year = dt.Year; |
| | | vm_month.Month = dt.Month; |
| | | vm_month.Count = Yw.Untity.RandomHelper.Random(100, 1000); |
| | | vm.LastYear.Add(vm_month); |
| | | } |
| | | return vm; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·ååæ³µç«æºç»å·¥åç»è®¡ä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetSingleStationRepairEnginePumpStatisticsInfo@V1.0")] |
| | | [HttpGet] |
| | | public BigScreenSingleStationRepairEnginePumpStatisticsInfoDto GetSingleStationRepairEnginePumpStatisticsInfo([FromQuery][Required] StationIDInput input) |
| | | { |
| | | var vm = new BigScreenSingleStationRepairEnginePumpStatisticsInfoDto(); |
| | | vm.Cd = new List<BigScreenSingleStationRepairEnginePumpCountDto>() |
| | | { |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="1#æºç»",Count=1}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="2#æºç»",Count=3}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="3#æºç»",Count=0}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="4#æºç»",Count=1} |
| | | }; |
| | | vm.Cm = new List<BigScreenSingleStationRepairEnginePumpCountDto>() |
| | | { |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="1#æºç»",Count=10}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="2#æºç»",Count=32}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="3#æºç»",Count=4}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="4#æºç»",Count=18} |
| | | }; |
| | | vm.Cm = new List<BigScreenSingleStationRepairEnginePumpCountDto>() |
| | | { |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="1#æºç»",Count=123}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="2#æºç»",Count=45}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="3#æºç»",Count=8}, |
| | | new BigScreenSingleStationRepairEnginePumpCountDto(){ Name="4#æºç»",Count=23} |
| | | }; |
| | | return vm; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// è·ååæ³µç«æ¥è¦ä¿¡æ¯ |
| | | /// </summary> |
| | | [Route("GetSingleStationAlarmInfo@V1.0")] |
| | | [HttpGet] |
| | | public List<BigScreenSingleStationAlarmItemDto> GetSingleStationAlarmInfo([FromQuery][Required] StationIDInput input) |
| | | { |
| | | var vmList = new List<BigScreenSingleStationAlarmItemDto>(); |
| | | vmList.Add(new BigScreenSingleStationAlarmItemDto() |
| | | { |
| | | ID = 1, |
| | | Name = "1#æºç»", |
| | | Content = "åºå£ååè¿ä½ï¼è¯·å
³æ³¨ç¶æåå" |
| | | }); |
| | | vmList.Add(new BigScreenSingleStationAlarmItemDto() |
| | | { |
| | | ID = 2, |
| | | Name = "2#æºç»", |
| | | Content = "ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | vmList.Add(new BigScreenSingleStationAlarmItemDto() |
| | | { |
| | | ID = 3, |
| | | Name = "2#æºç»", |
| | | Content = "ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | vmList.Add(new BigScreenSingleStationAlarmItemDto() |
| | | { |
| | | ID = 4, |
| | | Name = "2#æºç»", |
| | | Content = "ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | vmList.Add(new BigScreenSingleStationAlarmItemDto() |
| | | { |
| | | ID = 5, |
| | | Name = "2#æºç»", |
| | | Content = "ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | vmList.Add(new BigScreenSingleStationAlarmItemDto() |
| | | { |
| | | ID = 6, |
| | | Name = "2#æºç»", |
| | | Content = "ç¬æ¶æµéæ°æ®å¼å¸¸ï¼è¯·æ£ä¿®" |
| | | }); |
| | | return vmList; |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// æ³µç«æ¥è¦é¡¹ |
| | | /// </summary> |
| | | public class BigScreenAllStationAlarmItemDto |
| | | { |
| | | /// <summary> |
| | | /// id |
| | | /// </summary> |
| | | public long ID { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å
容 |
| | | /// </summary> |
| | | public string Content { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// æ³µç«å表项 |
| | | /// </summary> |
| | | public class BigScreenAllStationListItemDto |
| | | { |
| | | /// <summary> |
| | | /// id |
| | | /// </summary> |
| | | public long ID { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æµé |
| | | /// </summary> |
| | | public BigScreenAllStationListKpiItemDto Qk { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åå |
| | | /// </summary> |
| | | public BigScreenAllStationListKpiItemDto Prk { get; set; } |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenAllStationListKpiItemDto |
| | | { |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å¼ |
| | | /// </summary> |
| | | public string Value { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åä½ |
| | | /// </summary> |
| | | public string UnitName { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenAllStationRepairDayCountDto |
| | | { |
| | | /// <summary> |
| | | /// æ¥æ |
| | | /// </summary> |
| | | public DateTime Day { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ°é |
| | | /// </summary> |
| | | public int Count { get; set; } |
| | | |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenAllStationRepairMonthCountDto |
| | | { |
| | | /// <summary> |
| | | /// 年份 |
| | | /// </summary> |
| | | public int Year { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æä»½ |
| | | /// </summary> |
| | | public int Month { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ°é |
| | | /// </summary> |
| | | public int Count { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenAllStationRepairKpiDto |
| | | { |
| | | /// <summary> |
| | | /// 彿¥æ°é |
| | | /// </summary> |
| | | public int Cd { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 彿æ°é |
| | | /// </summary> |
| | | public int Cm { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å½å¹´æ°é |
| | | /// </summary> |
| | | public int Cy { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å¾
åç |
| | | /// </summary> |
| | | public int Pending { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å·²åç |
| | | /// </summary> |
| | | public int Accepted { get; set; } |
| | | |
| | | /// <summary> |
| | | /// è¿è¡ä¸ |
| | | /// </summary> |
| | | public int Progress { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å·²éªæ¶ |
| | | /// </summary> |
| | | public int Checked { get; set; } |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenAllStationKpiDto |
| | | { |
| | | /// <summary> |
| | | /// 彿¥ç´¯è®¡ä¾æ°´é |
| | | /// </summary> |
| | | public BigScreenAllStationKpiItemDto Lws { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 彿¥ç´¯è®¡ç¨çµé |
| | | /// </summary> |
| | | public BigScreenAllStationKpiItemDto Lps { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å½åç¬æ¶æ»æµé |
| | | /// </summary> |
| | | public BigScreenAllStationKpiItemDto Sws { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å½åç¬æ¶æ»åç |
| | | /// </summary> |
| | | public BigScreenAllStationKpiItemDto Sps { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ»æ³µç«æ°é |
| | | /// </summary> |
| | | public BigScreenAllStationKpiItemDto Tsc { get; set; } |
| | | |
| | | /// <summary> |
| | | /// è¿è¡æ³µç«æ°é |
| | | /// </summary> |
| | | public BigScreenAllStationKpiItemDto Rsc { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ»æºç»æ°é |
| | | /// </summary> |
| | | public BigScreenAllStationKpiItemDto Tpc { get; set; } |
| | | |
| | | /// <summary> |
| | | /// è¿è¡æºç»æ°é |
| | | /// </summary> |
| | | public BigScreenAllStationKpiItemDto Rpc { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// æææ³µç«kpi项 dto |
| | | /// </summary> |
| | | public class BigScreenAllStationKpiItemDto |
| | | { |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å¼ |
| | | /// </summary> |
| | | public string Value { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åä½ |
| | | /// </summary> |
| | | public string UnitName { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// æ³µç«æ¥è¦é¡¹ |
| | | /// </summary> |
| | | public class BigScreenSingleStationAlarmItemDto |
| | | { |
| | | /// <summary> |
| | | /// id |
| | | /// </summary> |
| | | public long ID { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å
容 |
| | | /// </summary> |
| | | public string Content { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// æ³µç«å表项 |
| | | /// </summary> |
| | | public class BigScreenSingleStationEnginePumpListItemDto |
| | | { |
| | | /// <summary> |
| | | /// id |
| | | /// </summary> |
| | | public long ID { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ç¶æ |
| | | /// </summary> |
| | | public BigScreenSingleStationEnginePumpListKpiItemDto Rs { get; set; } |
| | | |
| | | /// <summary> |
| | | /// é¢ç |
| | | /// </summary> |
| | | public BigScreenSingleStationEnginePumpListKpiItemDto Hz { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åç |
| | | /// </summary> |
| | | public BigScreenSingleStationEnginePumpListKpiItemDto P { get; set; } |
| | | |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationEnginePumpListKpiItemDto |
| | | { |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å¼ |
| | | /// </summary> |
| | | public string Value { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åä½ |
| | | /// </summary> |
| | | public string UnitName { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationQuotaItemDto |
| | | { |
| | | |
| | | /// <summary> |
| | | /// æ¥æ |
| | | /// </summary> |
| | | public DateTime Day { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ¥æ |
| | | /// </summary> |
| | | public string Value { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åä½ |
| | | /// </summary> |
| | | public string UnitName { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationQuotaKpiDto |
| | | { |
| | | /// <summary> |
| | | /// 便°´é |
| | | /// </summary> |
| | | public List<BigScreenSingleStationQuotaItemDto> Ws { get; set; } |
| | | |
| | | /// <summary> |
| | | /// ç¨çµé |
| | | /// </summary> |
| | | public List<BigScreenSingleStationQuotaItemDto> Ps { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationRepairDayCountDto |
| | | { |
| | | /// <summary> |
| | | /// æ¥æ |
| | | /// </summary> |
| | | public DateTime Day { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ°é |
| | | /// </summary> |
| | | public int Count { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationRepairEnginePumpCountDto |
| | | { |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ°é |
| | | /// </summary> |
| | | public int Count { get; set; } |
| | | |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationRepairEnginePumpStatisticsInfoDto |
| | | { |
| | | /// <summary> |
| | | /// 彿¥ |
| | | /// </summary> |
| | | public List<BigScreenSingleStationRepairEnginePumpCountDto> Cd { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 彿 |
| | | /// </summary> |
| | | public List<BigScreenSingleStationRepairEnginePumpCountDto> Cm { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å½å¹´ |
| | | /// </summary> |
| | | public List<BigScreenSingleStationRepairEnginePumpCountDto> Cy { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationRepairMonthCountDto |
| | | { |
| | | /// <summary> |
| | | /// 年份 |
| | | /// </summary> |
| | | public int Year { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æä»½ |
| | | /// </summary> |
| | | public int Month { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æ°é |
| | | /// </summary> |
| | | public int Count { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationRepairStatisticsInfoDto |
| | | { |
| | | /// <summary> |
| | | /// æè¿ä¸æ |
| | | /// </summary> |
| | | public List<BigScreenSingleStationRepairDayCountDto> LastMonth { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æè¿ä¸å¹´ |
| | | /// </summary> |
| | | public List<BigScreenSingleStationRepairMonthCountDto> LastYear { get; set; } |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationRepairKpiDto |
| | | { |
| | | /// <summary> |
| | | /// 彿¥æ°é |
| | | /// </summary> |
| | | public int Cd { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 彿æ°é |
| | | /// </summary> |
| | | public int Cm { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å½å¹´æ°é |
| | | /// </summary> |
| | | public int Cy { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å¾
åç |
| | | /// </summary> |
| | | public int Pending { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å·²åç |
| | | /// </summary> |
| | | public int Accepted { get; set; } |
| | | |
| | | /// <summary> |
| | | /// è¿è¡ä¸ |
| | | /// </summary> |
| | | public int Progress { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å·²éªæ¶ |
| | | /// </summary> |
| | | public int Checked { get; set; } |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationKpiDto |
| | | { |
| | | /// <summary> |
| | | /// ç¬æ¶æµé |
| | | /// </summary> |
| | | public BigScreenSingleStationKpiItemDto Q { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åºå£åå |
| | | /// </summary> |
| | | public BigScreenSingleStationKpiItemDto Pr { get; set; } |
| | | |
| | | /// <summary> |
| | | /// æµåº¦ |
| | | /// </summary> |
| | | public BigScreenSingleStationKpiItemDto ZD { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 使°¯ |
| | | /// </summary> |
| | | public BigScreenSingleStationKpiItemDto YL { get; set; } |
| | | |
| | | /// <summary> |
| | | /// è¿è¡å表 |
| | | /// </summary> |
| | | public List<BigScreenSingleStationKpiRunItemDto> RunList { get; set; } |
| | | |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// åæ³µç«kpi项 dto |
| | | /// </summary> |
| | | public class BigScreenSingleStationKpiItemDto |
| | | { |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// å¼ |
| | | /// </summary> |
| | | public string Value { get; set; } |
| | | |
| | | /// <summary> |
| | | /// åä½ |
| | | /// </summary> |
| | | public string UnitName { get; set; } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | namespace IStation.Application.SZJT |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public class BigScreenSingleStationKpiRunItemDto |
| | | { |
| | | /// <summary> |
| | | /// åç§° |
| | | /// </summary> |
| | | public string Name { get; set; } |
| | | |
| | | /// <summary> |
| | | /// è¿è¡ç¶æ 0-åæº 1-弿º |
| | | /// </summary> |
| | | public int RunStatus { get; set; } |
| | | } |
| | | } |
| | |
| | | global using Yw.Service.Monitor; |
| | | global using IStation.Application.SZJT; |
| | | global using Microsoft.AspNetCore.Authorization; |
| | | global using Yw.Dto; |
| | |
| | | </ItemGroup> |
| | | |
| | | <ItemGroup> |
| | | <PackageReference Include="Yw.Application.Core" Version="1.3.9" /> |
| | | <PackageReference Include="Yw.Service.Assets.Core" Version="1.2.9" /> |
| | | <PackageReference Include="Yw.Service.DMA.Core" Version="1.0.5" /> |
| | | <PackageReference Include="Yw.Service.Map.Core" Version="1.0.4" /> |
| | | <PackageReference Include="Yw.Service.Monitor.Core" Version="2.1.5" /> |
| | | <PackageReference Include="Yw.Service.Repair.Core" Version="1.0.2" /> |
| | | <PackageReference Include="Yw.Service.Run.Core" Version="1.0.4" /> |
| | | <PackageReference Include="Yw.Application.Core" Version="3.0.5" /> |
| | | <PackageReference Include="Yw.Service.DMA.Core" Version="3.0.1" /> |
| | | <PackageReference Include="Yw.Service.Map.Core" Version="3.0.3" /> |
| | | <PackageReference Include="Yw.Service.Repair.Core" Version="3.0.1" /> |
| | | <PackageReference Include="Yw.Service.Run.Core" Version="3.0.1" /> |
| | | </ItemGroup> |
| | | |
| | | <ItemGroup> |
| | |
| | | <ProjectExtensions><VisualStudio><UserProperties appsettings_1json__JsonSchema="" /></VisualStudio></ProjectExtensions> |
| | | |
| | | <ItemGroup> |
| | | <PackageReference Include="Yw.Application.ArtImage.Core" Version="1.1.4" /> |
| | | <PackageReference Include="Yw.Application.Assets.Core" Version="2.0.5" /> |
| | | <PackageReference Include="Yw.Application.Basic.Core" Version="1.2.8" /> |
| | | <PackageReference Include="Yw.Application.Bimface.Core" Version="1.0.5" /> |
| | | <PackageReference Include="Yw.Application.Dict.Core" Version="1.1.6" /> |
| | | <PackageReference Include="Yw.Application.DMA.Core" Version="1.0.6" /> |
| | | <PackageReference Include="Yw.Application.DOCS.Core" Version="1.0.2" /> |
| | | <PackageReference Include="Yw.Application.Map.Core" Version="1.0.5" /> |
| | | <PackageReference Include="Yw.Application.Monitor.Core" Version="2.2.3" /> |
| | | <PackageReference Include="Yw.Application.Repair.Core" Version="1.0.3" /> |
| | | <PackageReference Include="Yw.Application.Unit.Core" Version="1.1.7" /> |
| | | <PackageReference Include="Yw.Application.ArtImage.Core" Version="3.0.2" /> |
| | | <PackageReference Include="Yw.Application.Assets.Core" Version="3.0.5" /> |
| | | <PackageReference Include="Yw.Application.Basic.Core" Version="3.0.5" /> |
| | | <PackageReference Include="Yw.Application.Bimface.Core" Version="3.0.1" /> |
| | | <PackageReference Include="Yw.Application.Dict.Core" Version="3.0.1" /> |
| | | <PackageReference Include="Yw.Application.DMA.Core" Version="3.0.2" /> |
| | | <PackageReference Include="Yw.Application.DOCS.Core" Version="3.0.2" /> |
| | | <PackageReference Include="Yw.Application.Map.Core" Version="3.0.3" /> |
| | | <PackageReference Include="Yw.Application.Monitor.Core" Version="3.0.6" /> |
| | | <PackageReference Include="Yw.Application.Repair.Core" Version="3.0.1" /> |
| | | <PackageReference Include="Yw.Application.Unit.Core" Version="3.0.2" /> |
| | | </ItemGroup> |
| | | |
| | | <ItemGroup> |
| | |
| | | <Project> |
| | | <PropertyGroup> |
| | | <_PublishTargetUrl>D:\WorkData\git\istation\szjt\IStation.Entry.SZJT\bin\Release\net6.0\publish\</_PublishTargetUrl> |
| | | <History>True|2024-01-27T03:33:20.6165535Z;True|2024-01-18T15:02:34.3492480+08:00;True|2024-01-15T18:07:28.9717635+08:00;True|2024-01-13T18:33:12.9427731+08:00;True|2024-01-03T12:04:02.7753609+08:00;True|2024-01-03T11:08:38.0680764+08:00;True|2024-01-03T10:52:12.8371853+08:00;True|2024-01-03T10:03:29.0482464+08:00;True|2023-12-28T09:09:43.7988141+08:00;True|2023-12-26T11:51:52.4664582+08:00;True|2023-12-26T10:49:59.5124896+08:00;True|2023-12-26T10:10:53.5396234+08:00;True|2023-12-25T15:30:59.3409132+08:00;True|2023-12-25T15:26:43.1943347+08:00;True|2023-12-25T10:08:29.7964560+08:00;True|2023-12-21T10:30:55.0589855+08:00;True|2023-12-19T21:25:45.9098277+08:00;True|2023-12-16T12:52:46.7024463+08:00;True|2023-12-14T16:16:02.6188884+08:00;True|2023-12-14T16:03:53.1458158+08:00;True|2023-12-14T15:59:33.3947428+08:00;True|2023-12-14T15:53:09.8869780+08:00;True|2023-12-14T14:17:07.2707485+08:00;True|2023-12-14T11:49:15.9699053+08:00;False|2023-12-14T11:48:41.4121185+08:00;True|2023-12-13T17:28:38.2180193+08:00;True|2023-12-13T14:47:22.2493536+08:00;True|2023-12-13T14:31:45.6098784+08:00;True|2023-12-13T14:05:08.5014675+08:00;True|2023-12-13T14:01:37.7165974+08:00;True|2023-12-13T13:50:57.4832531+08:00;True|2023-12-13T13:20:55.2902900+08:00;True|2023-12-13T12:01:09.6397101+08:00;True|2023-12-13T11:53:51.3171154+08:00;True|2023-12-13T11:18:29.2505125+08:00;True|2023-12-13T09:48:22.2436154+08:00;True|2023-12-12T11:49:25.2723311+08:00;True|2023-12-11T14:05:58.1086840+08:00;True|2023-12-11T09:31:35.0365077+08:00;True|2023-12-05T18:00:29.7005601+08:00;True|2023-12-05T17:35:46.7846869+08:00;True|2023-12-05T17:29:36.5936716+08:00;True|2023-12-04T19:50:38.7216121+08:00;True|2023-12-02T14:06:28.8643257+08:00;True|2023-11-30T16:54:56.0879009+08:00;True|2023-11-30T15:49:27.5213126+08:00;True|2023-11-30T13:42:14.9061099+08:00;False|2023-11-30T13:41:50.2796105+08:00;False|2023-11-30T13:41:42.4700953+08:00;True|2023-11-30T10:23:50.6226599+08:00;True|2023-11-30T09:22:54.2133326+08:00;True|2023-11-29T16:32:53.3651373+08:00;True|2023-11-29T09:19:39.1127566+08:00;True|2023-11-28T17:25:14.9642204+08:00;True|2023-11-28T16:53:30.7550754+08:00;True|2023-11-28T09:57:02.3264015+08:00;True|2023-11-27T14:26:33.6153027+08:00;True|2023-11-27T13:33:46.1964012+08:00;True|2023-11-27T13:21:38.2133314+08:00;True|2023-11-24T14:12:06.2053905+08:00;True|2023-11-23T15:38:30.0872291+08:00;True|2023-11-15T19:27:36.4861114+08:00;True|2023-11-15T14:16:33.6004541+08:00;True|2023-11-15T14:02:06.1224051+08:00;True|2023-11-15T09:35:35.1770813+08:00;True|2023-11-10T14:06:46.1528992+08:00;True|2023-11-08T14:07:13.3792249+08:00;True|2023-11-08T13:58:21.2455396+08:00;True|2023-11-08T13:34:05.8131818+08:00;True|2023-11-08T11:58:01.9187650+08:00;True|2023-11-07T14:11:15.6278203+08:00;True|2023-11-07T14:05:43.3330586+08:00;True|2023-10-27T08:30:17.2959726+08:00;True|2023-10-27T08:23:59.8360129+08:00;True|2023-10-25T20:36:54.7517897+08:00;True|2023-10-24T23:27:01.1980187+08:00;True|2023-10-24T22:57:21.3872591+08:00;True|2023-10-17T09:26:15.4157626+08:00;True|2023-10-16T16:44:05.1411215+08:00;True|2023-10-10T14:24:00.3649304+08:00;True|2023-10-10T14:12:16.4050462+08:00;True|2023-10-10T13:43:17.4397783+08:00;True|2023-10-08T16:16:16.4721892+08:00;True|2023-10-08T14:27:40.6092129+08:00;True|2023-10-08T13:36:44.2969175+08:00;True|2023-10-08T13:21:21.1105671+08:00;True|2023-10-08T11:41:25.6876188+08:00;True|2023-10-08T09:39:46.1146411+08:00;True|2023-09-26T14:26:57.6168193+08:00;True|2023-09-21T13:54:19.1780900+08:00;True|2023-09-21T13:16:00.2957740+08:00;True|2023-09-21T11:28:36.3091944+08:00;True|2023-09-21T11:18:20.1060798+08:00;True|2023-09-13T16:00:49.4080881+08:00;True|2023-09-11T13:53:38.8582724+08:00;True|2023-09-01T10:32:37.4923361+08:00;True|2023-08-30T16:52:43.1952609+08:00;True|2023-08-30T13:41:35.0430741+08:00;True|2023-08-28T14:53:24.2454140+08:00;True|2023-08-28T13:50:55.9362462+08:00;True|2023-08-28T10:00:17.0366755+08:00;True|2023-08-25T15:41:23.8727088+08:00;True|2023-08-24T16:47:54.1391198+08:00;True|2023-08-24T16:40:29.0473991+08:00;True|2023-08-22T15:02:27.5312918+08:00;True|2023-08-22T11:18:43.6918732+08:00;True|2023-08-21T15:10:42.9223597+08:00;True|2023-08-21T14:21:08.1887373+08:00;True|2023-08-21T11:56:07.5304445+08:00;True|2023-08-18T16:57:57.0506312+08:00;True|2023-08-18T13:51:54.9145260+08:00;True|2023-08-17T14:52:44.6557301+08:00;True|2023-08-17T14:15:19.8255432+08:00;True|2023-08-17T14:03:01.1586247+08:00;True|2023-08-17T11:46:51.6685579+08:00;True|2023-08-16T11:12:27.1684542+08:00;True|2023-08-15T16:59:09.4901359+08:00;True|2023-08-10T14:08:04.8032876+08:00;True|2023-08-10T13:55:01.9698355+08:00;True|2023-08-10T10:43:44.0440039+08:00;True|2023-08-10T10:12:03.9359243+08:00;True|2023-08-09T15:07:46.6906781+08:00;True|2023-08-09T13:12:06.7912004+08:00;True|2023-08-09T10:23:24.5864225+08:00;True|2023-08-08T17:38:10.4753030+08:00;True|2023-08-08T12:56:08.9783211+08:00;True|2023-08-06T09:18:33.3703637+08:00;True|2023-08-03T11:01:58.9814864+08:00;True|2023-08-03T10:26:08.4681748+08:00;True|2023-08-02T20:33:35.0425049+08:00;True|2023-08-02T17:31:18.4675932+08:00;True|2023-08-02T16:04:16.8761862+08:00;True|2023-08-02T13:48:38.9129192+08:00;True|2023-08-02T13:45:00.6546267+08:00;True|2023-08-01T15:26:25.0389689+08:00;True|2023-08-01T14:08:10.9121758+08:00;True|2023-07-31T13:35:10.1220213+08:00;True|2023-07-31T09:20:11.2607880+08:00;True|2023-07-28T13:44:35.4317136+08:00;True|2023-07-27T10:40:46.5453757+08:00;True|2023-07-27T09:16:57.7421426+08:00;True|2023-07-26T17:10:56.0976913+08:00;True|2023-07-26T12:01:33.5766311+08:00;True|2023-07-25T18:07:38.5726960+08:00;True|2023-07-25T17:42:39.3625959+08:00;True|2023-07-25T17:04:09.8723273+08:00;True|2023-07-25T16:28:14.1819137+08:00;True|2023-07-24T14:11:28.2113907+08:00;True|2023-07-24T12:05:09.0376032+08:00;True|2023-07-24T09:36:39.6541522+08:00;True|2023-07-19T12:25:56.9887829+08:00;True|2023-07-17T13:00:04.0123733+08:00;True|2023-07-13T12:13:14.7927242+08:00;True|2023-07-13T11:46:24.1368807+08:00;True|2023-07-13T10:24:33.1684712+08:00;True|2023-06-26T11:38:29.6648988+08:00;True|2023-06-21T16:17:40.6226554+08:00;True|2023-06-21T13:30:18.8163322+08:00;True|2023-06-21T13:19:43.9290154+08:00;True|2023-06-21T11:35:28.3376504+08:00;</History> |
| | | <History>True|2024-04-04T03:28:14.8768964Z;True|2024-04-04T09:39:21.6552156+08:00;True|2024-03-11T16:36:41.1901368+08:00;True|2024-01-27T11:33:20.6165535+08:00;True|2024-01-18T15:02:34.3492480+08:00;True|2024-01-15T18:07:28.9717635+08:00;True|2024-01-13T18:33:12.9427731+08:00;True|2024-01-03T12:04:02.7753609+08:00;True|2024-01-03T11:08:38.0680764+08:00;True|2024-01-03T10:52:12.8371853+08:00;True|2024-01-03T10:03:29.0482464+08:00;True|2023-12-28T09:09:43.7988141+08:00;True|2023-12-26T11:51:52.4664582+08:00;True|2023-12-26T10:49:59.5124896+08:00;True|2023-12-26T10:10:53.5396234+08:00;True|2023-12-25T15:30:59.3409132+08:00;True|2023-12-25T15:26:43.1943347+08:00;True|2023-12-25T10:08:29.7964560+08:00;True|2023-12-21T10:30:55.0589855+08:00;True|2023-12-19T21:25:45.9098277+08:00;True|2023-12-16T12:52:46.7024463+08:00;True|2023-12-14T16:16:02.6188884+08:00;True|2023-12-14T16:03:53.1458158+08:00;True|2023-12-14T15:59:33.3947428+08:00;True|2023-12-14T15:53:09.8869780+08:00;True|2023-12-14T14:17:07.2707485+08:00;True|2023-12-14T11:49:15.9699053+08:00;False|2023-12-14T11:48:41.4121185+08:00;True|2023-12-13T17:28:38.2180193+08:00;True|2023-12-13T14:47:22.2493536+08:00;True|2023-12-13T14:31:45.6098784+08:00;True|2023-12-13T14:05:08.5014675+08:00;True|2023-12-13T14:01:37.7165974+08:00;True|2023-12-13T13:50:57.4832531+08:00;True|2023-12-13T13:20:55.2902900+08:00;True|2023-12-13T12:01:09.6397101+08:00;True|2023-12-13T11:53:51.3171154+08:00;True|2023-12-13T11:18:29.2505125+08:00;True|2023-12-13T09:48:22.2436154+08:00;True|2023-12-12T11:49:25.2723311+08:00;True|2023-12-11T14:05:58.1086840+08:00;True|2023-12-11T09:31:35.0365077+08:00;True|2023-12-05T18:00:29.7005601+08:00;True|2023-12-05T17:35:46.7846869+08:00;True|2023-12-05T17:29:36.5936716+08:00;True|2023-12-04T19:50:38.7216121+08:00;True|2023-12-02T14:06:28.8643257+08:00;True|2023-11-30T16:54:56.0879009+08:00;True|2023-11-30T15:49:27.5213126+08:00;True|2023-11-30T13:42:14.9061099+08:00;False|2023-11-30T13:41:50.2796105+08:00;False|2023-11-30T13:41:42.4700953+08:00;True|2023-11-30T10:23:50.6226599+08:00;True|2023-11-30T09:22:54.2133326+08:00;True|2023-11-29T16:32:53.3651373+08:00;True|2023-11-29T09:19:39.1127566+08:00;True|2023-11-28T17:25:14.9642204+08:00;True|2023-11-28T16:53:30.7550754+08:00;True|2023-11-28T09:57:02.3264015+08:00;True|2023-11-27T14:26:33.6153027+08:00;True|2023-11-27T13:33:46.1964012+08:00;True|2023-11-27T13:21:38.2133314+08:00;True|2023-11-24T14:12:06.2053905+08:00;True|2023-11-23T15:38:30.0872291+08:00;True|2023-11-15T19:27:36.4861114+08:00;True|2023-11-15T14:16:33.6004541+08:00;True|2023-11-15T14:02:06.1224051+08:00;True|2023-11-15T09:35:35.1770813+08:00;True|2023-11-10T14:06:46.1528992+08:00;True|2023-11-08T14:07:13.3792249+08:00;True|2023-11-08T13:58:21.2455396+08:00;True|2023-11-08T13:34:05.8131818+08:00;True|2023-11-08T11:58:01.9187650+08:00;True|2023-11-07T14:11:15.6278203+08:00;True|2023-11-07T14:05:43.3330586+08:00;True|2023-10-27T08:30:17.2959726+08:00;True|2023-10-27T08:23:59.8360129+08:00;True|2023-10-25T20:36:54.7517897+08:00;True|2023-10-24T23:27:01.1980187+08:00;True|2023-10-24T22:57:21.3872591+08:00;True|2023-10-17T09:26:15.4157626+08:00;True|2023-10-16T16:44:05.1411215+08:00;True|2023-10-10T14:24:00.3649304+08:00;True|2023-10-10T14:12:16.4050462+08:00;True|2023-10-10T13:43:17.4397783+08:00;True|2023-10-08T16:16:16.4721892+08:00;True|2023-10-08T14:27:40.6092129+08:00;True|2023-10-08T13:36:44.2969175+08:00;True|2023-10-08T13:21:21.1105671+08:00;True|2023-10-08T11:41:25.6876188+08:00;True|2023-10-08T09:39:46.1146411+08:00;True|2023-09-26T14:26:57.6168193+08:00;True|2023-09-21T13:54:19.1780900+08:00;True|2023-09-21T13:16:00.2957740+08:00;True|2023-09-21T11:28:36.3091944+08:00;True|2023-09-21T11:18:20.1060798+08:00;True|2023-09-13T16:00:49.4080881+08:00;True|2023-09-11T13:53:38.8582724+08:00;True|2023-09-01T10:32:37.4923361+08:00;True|2023-08-30T16:52:43.1952609+08:00;True|2023-08-30T13:41:35.0430741+08:00;True|2023-08-28T14:53:24.2454140+08:00;True|2023-08-28T13:50:55.9362462+08:00;True|2023-08-28T10:00:17.0366755+08:00;True|2023-08-25T15:41:23.8727088+08:00;True|2023-08-24T16:47:54.1391198+08:00;True|2023-08-24T16:40:29.0473991+08:00;True|2023-08-22T15:02:27.5312918+08:00;True|2023-08-22T11:18:43.6918732+08:00;True|2023-08-21T15:10:42.9223597+08:00;True|2023-08-21T14:21:08.1887373+08:00;True|2023-08-21T11:56:07.5304445+08:00;True|2023-08-18T16:57:57.0506312+08:00;True|2023-08-18T13:51:54.9145260+08:00;True|2023-08-17T14:52:44.6557301+08:00;True|2023-08-17T14:15:19.8255432+08:00;True|2023-08-17T14:03:01.1586247+08:00;True|2023-08-17T11:46:51.6685579+08:00;True|2023-08-16T11:12:27.1684542+08:00;True|2023-08-15T16:59:09.4901359+08:00;True|2023-08-10T14:08:04.8032876+08:00;True|2023-08-10T13:55:01.9698355+08:00;True|2023-08-10T10:43:44.0440039+08:00;True|2023-08-10T10:12:03.9359243+08:00;True|2023-08-09T15:07:46.6906781+08:00;True|2023-08-09T13:12:06.7912004+08:00;True|2023-08-09T10:23:24.5864225+08:00;True|2023-08-08T17:38:10.4753030+08:00;True|2023-08-08T12:56:08.9783211+08:00;True|2023-08-06T09:18:33.3703637+08:00;True|2023-08-03T11:01:58.9814864+08:00;True|2023-08-03T10:26:08.4681748+08:00;True|2023-08-02T20:33:35.0425049+08:00;True|2023-08-02T17:31:18.4675932+08:00;True|2023-08-02T16:04:16.8761862+08:00;True|2023-08-02T13:48:38.9129192+08:00;True|2023-08-02T13:45:00.6546267+08:00;True|2023-08-01T15:26:25.0389689+08:00;True|2023-08-01T14:08:10.9121758+08:00;True|2023-07-31T13:35:10.1220213+08:00;True|2023-07-31T09:20:11.2607880+08:00;True|2023-07-28T13:44:35.4317136+08:00;True|2023-07-27T10:40:46.5453757+08:00;True|2023-07-27T09:16:57.7421426+08:00;True|2023-07-26T17:10:56.0976913+08:00;True|2023-07-26T12:01:33.5766311+08:00;True|2023-07-25T18:07:38.5726960+08:00;True|2023-07-25T17:42:39.3625959+08:00;True|2023-07-25T17:04:09.8723273+08:00;True|2023-07-25T16:28:14.1819137+08:00;True|2023-07-24T14:11:28.2113907+08:00;True|2023-07-24T12:05:09.0376032+08:00;True|2023-07-24T09:36:39.6541522+08:00;True|2023-07-19T12:25:56.9887829+08:00;True|2023-07-17T13:00:04.0123733+08:00;True|2023-07-13T12:13:14.7927242+08:00;True|2023-07-13T11:46:24.1368807+08:00;True|2023-07-13T10:24:33.1684712+08:00;True|2023-06-26T11:38:29.6648988+08:00;True|2023-06-21T16:17:40.6226554+08:00;True|2023-06-21T13:30:18.8163322+08:00;True|2023-06-21T13:19:43.9290154+08:00;True|2023-06-21T11:35:28.3376504+08:00;</History> |
| | | </PropertyGroup> |
| | | </Project> |
| | |
| | | </PropertyGroup> |
| | | |
| | | <ItemGroup> |
| | | <PackageReference Include="Yw.Log4Net.Core" Version="1.0.0" /> |
| | | <PackageReference Include="Yw.Quartz.Core" Version="1.0.0" /> |
| | | <PackageReference Include="Yw.Service.Assets.Core" Version="1.1.5" /> |
| | | <PackageReference Include="Yw.Service.Monitor.Core" Version="1.4.0" /> |
| | | <PackageReference Include="Yw.Service.Run.Core" Version="1.0.2" /> |
| | | <PackageReference Include="Yw.Quartz.Core" Version="3.0.0" /> |
| | | <PackageReference Include="Yw.Service.Run.Core" Version="3.0.1" /> |
| | | </ItemGroup> |
| | | |
| | | <ItemGroup> |
ÎļþÃû´Ó IStation.Service.SZJT/1-entity/1-policy/LogicPolicy.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Entity |
| | | using Yw.Entity; |
| | | namespace IStation.Entity |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡çç¥ |
| | | /// </summary> |
| | | [SugarTable("logic_policy")] |
| | | public class LogicPolicy : Yw.Entity.BaseEntity, Yw.Entity.ICode, Yw.Entity.ISorter, Yw.Entity.IParas, Yw.Entity.IFlags, Yw.Entity.IUseStatus, Yw.Entity.ITagName, System.ICloneable |
| | | public class LogicPolicy : BaseEntity, ICode, IParas, IFlags, ITagName, ISorter, IUseStatus, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/1-entity/2-area/LogicArea.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Entity |
| | | using Yw.Entity; |
| | | namespace IStation.Entity |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡åºå |
| | | /// </summary> |
| | | [SugarTable("logic_area")] |
| | | public class LogicArea : Yw.Entity.BaseEntity, Yw.Entity.ISorter, Yw.Entity.ICode, Yw.Entity.IParas, Yw.Entity.IFlags, Yw.Entity.ITagName, Yw.Entity.IUseStatus, System.ICloneable |
| | | public class LogicArea : BaseEntity, ICode, IParas, IFlags, ITagName, ISorter, IUseStatus, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/1-entity/3-site/LogicSite.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Entity |
| | | using Yw.Entity; |
| | | namespace IStation.Entity |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡ç« |
| | | /// </summary> |
| | | [SugarTable("logic_site")] |
| | | public class LogicSite : Yw.Entity.BaseEntity, Yw.Entity.ICode, Yw.Entity.ISorter, Yw.Entity.IFlags, Yw.Entity.IParas, Yw.Entity.ITagName, Yw.Entity.IUseStatus, System.ICloneable |
| | | public class LogicSite : BaseEntity, ICode, IParas, IFlags, ITagName, ISorter, IUseStatus, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/1-entity/4-tree/LogicTree.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Entity |
| | | using Yw.Entity; |
| | | namespace IStation.Entity |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡æ¸
å |
| | | /// </summary> |
| | | [SugarTable("logic_tree")] |
| | | public class LogicTree : Yw.Entity.BaseEntity, Yw.Entity.ITreeSorter, System.ICloneable |
| | | public class LogicTree : BaseEntity, ITreeSorter, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/1-entity/5-dma/LogicDma.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Entity |
| | | using Yw.Entity; |
| | | namespace IStation.Entity |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡dma |
| | | /// </summary> |
| | | [SugarTable("logic_dma")] |
| | | public class LogicDma : Yw.Entity.BaseEntity, Yw.Entity.ICode, Yw.Entity.ISorter, Yw.Entity.IFlags, Yw.Entity.IParas, Yw.Entity.ITagName, Yw.Entity.IUseStatus, System.ICloneable |
| | | public class LogicDma : BaseEntity, ICode, IParas, IFlags, ITagName, ISorter, IUseStatus, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/2-model/1-policy/LogicPolicy.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Model |
| | | using Yw.Model; |
| | | namespace IStation.Model |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡çç¥ |
| | | /// </summary> |
| | | public class LogicPolicy : Yw.Model.BaseModel, System.ICloneable |
| | | public class LogicPolicy : BaseModel, ICode, IParas, IFlags, ITagName, ISorter, IUseStatus, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/2-model/2-area/LogicArea.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Model |
| | | using Yw.Model; |
| | | namespace IStation.Model |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡åºå |
| | | /// </summary> |
| | | public class LogicArea : Yw.Model.BaseModel, System.ICloneable |
| | | public class LogicArea : BaseModel, ICode, IParas, IFlags, ITagName, ISorter, IUseStatus, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/2-model/3-site/LogicSite.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Model |
| | | using Yw.Model; |
| | | namespace IStation.Model |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡ç« |
| | | /// </summary> |
| | | public partial class LogicSite : Yw.Model.BaseModel, System.ICloneable |
| | | public partial class LogicSite : BaseModel, ICode, IParas, IFlags, ITagName, ISorter, IUseStatus, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/2-model/4-tree/LogicTree.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Model |
| | | using Yw.Model; |
| | | namespace IStation.Model |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡æ¸
å |
| | | /// </summary> |
| | | public class LogicTree : Yw.Model.BaseModel, System.ICloneable |
| | | public class LogicTree : BaseModel, ITreeSorter, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/2-model/4-tree/LogicTreeEx.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Model |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Linq; |
| | | using System.Text; |
| | | using System.Threading.Tasks; |
| | | |
| | | namespace IStation.Model |
| | | { |
| | | /// <summary> |
| | | /// |
ÎļþÃû´Ó IStation.Service.SZJT/2-model/5-dma/LogicDma.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.Model |
| | | using Yw.Model; |
| | | namespace IStation.Model |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡dma |
| | | /// </summary> |
| | | public partial class LogicDma : Yw.Model.BaseModel, System.ICloneable |
| | | public partial class LogicDma : BaseModel, ICode, IParas, IFlags, ITagName, ISorter, IUseStatus, System.ICloneable |
| | | { |
| | | /// <summary> |
| | | /// |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Yw.DAL.PostgreSql; |
| | | namespace IStation.DAL |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public partial class LogicPolicy : BaseDAL_Code_Paras_Flags_TagName_Sorter_UseStatus<Entity.LogicPolicy> |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public override ConnectionConfig ConnectionConfig |
| | | { |
| | | get { return ConfigHelper.DefaultConnectionConfig; } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Yw.DAL.PostgreSql; |
| | | namespace IStation.DAL |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public partial class LogicArea : BaseDAL_Code_Paras_Flags_TagName_Sorter_UseStatus<Entity.LogicArea> |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public override ConnectionConfig ConnectionConfig |
| | | { |
| | | get { return ConfigHelper.DefaultConnectionConfig; } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// éè¿ PolicyID è·å |
| | | /// </summary> |
| | | public List<Entity.LogicArea> GetByPolicyID(long PolicyID) |
| | | { |
| | | using (var db = new SqlSugarClient(ConnectionConfig)) |
| | | { |
| | | return db.Queryable<Entity.LogicArea>() |
| | | .Where(x => x.PolicyID == PolicyID) |
| | | .OrderBy(x => x.SortCode).ToList(); |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Yw.DAL.PostgreSql; |
| | | namespace IStation.DAL |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public partial class LogicSite : BaseDAL_Code_Paras_Flags_TagName_Sorter_UseStatus<Entity.LogicSite> |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public override ConnectionConfig ConnectionConfig |
| | | { |
| | | get { return ConfigHelper.DefaultConnectionConfig; } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | } |
ÎļþÃû´Ó IStation.Service.SZJT/4-dal/4-tree/LogicTree.cs ÐÞ¸Ä |
| | |
| | | namespace IStation.DAL |
| | | using Yw.DAL.PostgreSql; |
| | | namespace IStation.DAL |
| | | { |
| | | /// <summary> |
| | | /// ä¸å¡æ¸
å |
| | | /// </summary> |
| | | public partial class LogicTree : Yw.DAL.BaseDAL_TreeSorter<Entity.LogicTree> |
| | | public partial class LogicTree : BaseDAL_TreeSorter<Entity.LogicTree> |
| | | { |
| | | /// <summary> |
| | | /// |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Yw.DAL.PostgreSql; |
| | | namespace IStation.DAL |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public partial class LogicDma : BaseDAL_Code_Paras_Flags_TagName_Sorter_UseStatus<Entity.LogicDma> |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public override ConnectionConfig ConnectionConfig |
| | | { |
| | | get { return ConfigHelper.DefaultConnectionConfig; } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | } |
ÎļþÃû´Ó IStation.Service.SZJT/5-service/0-helper/CacheHelper.cs ÐÞ¸Ä |
| | |
| | | /// </summary> |
| | | internal class CacheHelper |
| | | { |
| | | private const string _cacheKeyPrefix = "Phm";//ç¼åé®åç¼ |
| | | private const string _cacheKeyPrefix = "szjt";//ç¼åé®åç¼ |
| | | |
| | | /// <summary> |
| | | /// è·åç¼åé® |
| | |
| | | global using System.Collections; |
| | | global using SqlSugar; |
| | | global using AutoMapper; |
| | | global using Yw.Newtonsoft; |
| | | global using Yw.Settings; |
| | | global using Yw.Untity; |
| | | global using Yw; |
| | |
| | | </ItemGroup> |
| | | |
| | | <ItemGroup> |
| | | <PackageReference Include="Yw.Service.Basic.Core" Version="1.3.3" /> |
| | | <PackageReference Include="Yw.Service.Assets.Core" Version="3.0.5" /> |
| | | <PackageReference Include="Yw.Service.Basic.Core" Version="3.0.3" /> |
| | | <PackageReference Include="Yw.Service.Monitor.Core" Version="3.0.5" /> |
| | | </ItemGroup> |
| | | |
| | | </Project> |
| | |
| | | </PropertyGroup> |
| | | |
| | | <ItemGroup> |
| | | <PackageReference Include="Yw.TopShelf" Version="1.0.0" /> |
| | | <PackageReference Include="Yw.TopShelf" Version="3.0.0" /> |
| | | </ItemGroup> |
| | | |
| | | <ItemGroup> |
| | |
| | | --> |
| | | <Project> |
| | | <PropertyGroup> |
| | | <History>True|2023-12-26T02:39:19.5076776Z;True|2023-12-15T09:43:55.2219318+08:00;True|2023-11-29T15:11:51.9151157+08:00;True|2023-11-29T14:58:05.0127775+08:00;</History> |
| | | <History>True|2024-04-04T01:42:40.4553718Z;True|2023-12-26T10:39:19.5076776+08:00;True|2023-12-15T09:43:55.2219318+08:00;True|2023-11-29T15:11:51.9151157+08:00;True|2023-11-29T14:58:05.0127775+08:00;</History> |
| | | </PropertyGroup> |
| | | </Project> |
| | |
| | | using Furion.Authorization; |
| | | using Furion.DataEncryption; |
| | | using Microsoft.AspNetCore.Authorization; |
| | | using Microsoft.AspNetCore.Http; |
| | | |
| | | |
| | | namespace IStation.WebApi |
| | | { |
| | |
| | | public class JwtHandler : AppAuthorizeHandler |
| | | { |
| | | /// <summary> |
| | | /// èªå¨å·æ°Token |
| | | /// </summary> |
| | | /// <param name="context"></param> |
| | | /// <returns></returns> |
| | | public override async Task HandleAsync(AuthorizationHandlerContext context) |
| | | { |
| | | var accessTokenExpire = Yw.Settings.AuthParasHelper.Auth.JWT.AccessTokenExpire; |
| | | var refreshTokenExpire = Yw.Settings.AuthParasHelper.Auth.JWT.RefreshTokenExpire; |
| | | |
| | | if (JWTEncryption.AutoRefreshToken(context, context.GetCurrentHttpContext(), accessTokenExpire, refreshTokenExpire)) |
| | | { |
| | | await AuthorizeHandleAsync(context); |
| | | } |
| | | else |
| | | { |
| | | context.Fail(); // ææå¤±è´¥ |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 请æ±ç®¡é |
| | | /// </summary> |
| | | /// <param name="context"></param> |
| | |
| | | </ItemGroup> |
| | | |
| | | <ItemGroup> |
| | | <PackageReference Include="Yw.Knife4jUI.Core" Version="1.0.0" /> |
| | | <PackageReference Include="Yw.Knife4jUI.Core" Version="3.0.0" /> |
| | | <PackageReference Include="Yw.Service.Auth.Core" Version="3.0.2" /> |
| | | </ItemGroup> |
| | | |
| | | <ItemGroup> |
| | |
| | | using System.Net; |
| | | using Yw.Untity; |
| | | using Yw.Application; |
| | | using Yw.Dto; |
| | | |
| | | namespace IStation.WebApi |
| | | { |
| | | /// <summary> |
| | | /// è§èåRESTful飿 ¼è¿åå¼ |
| | | /// </summary> |
| | | [SuppressSniffer, UnifyModel(typeof(XnRestfulResult<>))] |
| | | [SuppressSniffer, UnifyModel(typeof(Result<>))] |
| | | public class XnRestfulResultProvider : IUnifyResultProvider |
| | | { |
| | | |
| | | /// <summary> |
| | | /// å¼å¸¸ |
| | | /// </summary> |
| | |
| | | // è§£æå¼å¸¸ä¿¡æ¯ |
| | | //var exceptionMetadata = UnifyContext.GetExceptionMetadata(context); |
| | | |
| | | XnRestfulResult<object> result = null; |
| | | Result<object> result = null; |
| | | |
| | | //furionå¼å¸¸ |
| | | if (context.Exception is AppFriendlyException friendException) |
| | | { |
| | | result = new XnRestfulResult<object> |
| | | result = new Result<object> |
| | | { |
| | | Code = (int)eResultCode.Alert, |
| | | Code = eResultCode.Alert, |
| | | Error = friendException.ErrorCode, |
| | | Message = friendException.ErrorMessage, |
| | | Data = null, |
| | |
| | | } |
| | | |
| | | //apiå¼å¸¸ |
| | | else if (context.Exception is ApiException apiException) |
| | | else if (context.Exception is InternalException apiException) |
| | | { |
| | | result = new XnRestfulResult<object> |
| | | result = new Result<object> |
| | | { |
| | | Code = apiException.ResultCode, |
| | | Error = apiException.ErrorCode, |
| | |
| | | |
| | | else |
| | | { |
| | | result = new XnRestfulResult<object> |
| | | result = new Result<object> |
| | | { |
| | | Code = (int)eResultCode.Error, |
| | | Code = eResultCode.Error, |
| | | Error = "ç³»ç»å¼å¸¸", |
| | | Message = context.Exception.StackTrace, |
| | | Data = null, |
| | |
| | | }; |
| | | } |
| | | |
| | | if (result.Code == (int)eResultCode.Error) |
| | | if (result.Code == eResultCode.Error) |
| | | { |
| | | LogHelper.Error($"é误ç ï¼{result.Error}ï¼é误信æ¯ï¼{result.Message}"); |
| | | Yw.LogHelper.Error($"é误ç ï¼{result.Error}ï¼é误信æ¯ï¼{result.Message}"); |
| | | } |
| | | |
| | | return new JsonResult(result); |
| | |
| | | return null; |
| | | } |
| | | |
| | | return new JsonResult(new XnRestfulResult<object> |
| | | return new JsonResult(new Result<object> |
| | | { |
| | | Code = (int)eResultCode.Success, |
| | | Code = eResultCode.Success, |
| | | Error = null, |
| | | Message = "è¯·æ±æå", |
| | | Data = data, |
| | |
| | | /// </summary> |
| | | public IActionResult OnValidateFailed(ActionExecutingContext context, ValidationMetadata metadata) |
| | | { |
| | | return new JsonResult(new XnRestfulResult<object> |
| | | return new JsonResult(new Result<object> |
| | | { |
| | | Code = (int)eResultCode.Prompt, |
| | | Error = ErrorCodes.V001.ToString(), |
| | | Code = eResultCode.Prompt, |
| | | Error = InternalErrorCodes.V001.ToString(), |
| | | Message = metadata.Message, |
| | | Data = null, |
| | | Extras = UnifyContext.Take(), |
| | |
| | | |
| | | if (Enum.IsDefined(typeof(HttpStatusCode), (HttpStatusCode)statusCode)) |
| | | { |
| | | await context.Response.WriteAsJsonAsync(new XnRestfulResult<object> |
| | | await context.Response.WriteAsJsonAsync(new Result<object> |
| | | { |
| | | Code = (int)eResultCode.Confirm, |
| | | Error = ErrorCodes.A099.ToString(), |
| | | Code = eResultCode.Confirm, |
| | | Error = InternalErrorCodes.A099.ToString(), |
| | | Message = "æééªè¯å¤±è´¥", |
| | | Data = null, |
| | | Extras = UnifyContext.Take(), |