lixiaojun
2024-03-26 38b6c0f70c646d247e50083c4a09abce055e363a
版本大更新
已删除3个文件
已重命名27个文件
已复制2个文件
已修改17个文件
已添加17个文件
804 ■■■■■ 文件已修改
Yw.Application.DMA.Core/00-core/2-extensions/Extensions.cs 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/00-core/Mapper.cs 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/01-dma_area/DmaArea_Controller.cs 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/01-dma_area/DmaArea_StdController.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/02-dma_site/DmaSite_Controller.cs 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/02-dma_site/DmaSite_StdController.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/03-dma_site_binding/DmaSiteBinding_Controller.cs 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/04-dma_site_mapping/DmaSiteMapping_Controller.cs 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/GlobalUsings.cs 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/Properties/PublishProfiles/FolderProfile.pubxml.user 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/Yw.Application.DMA.Core.csproj 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.DMA.Core.sln 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/01-dma-area/AddDmaAreaInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/01-dma-area/DmaAreaDto.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/01-dma-area/DmaAreaStdDto.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/01-dma-area/UpdateDmaAreaInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/02-dma-site/AddDmaSiteInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/02-dma-site/DmaSiteDto.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/02-dma-site/DmaSiteStdDto.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/02-dma-site/UpdateDmaSiteInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/03-dma-site-binding/BindingDmaSiteInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/03-dma-site-binding/DmaSiteBindingDto.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/03-dma-site-binding/UnBindingDmaSiteInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/04-dma-site-mapping/AddDmaSiteMappingInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/04-dma-site-mapping/DmaSiteMappingDto.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/04-dma-site-mapping/UpdateDmaSiteMappingInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/99-model/areaid/AreaIDInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/99-model/direction/UpdateDirectionInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/99-model/siteid/SiteIDInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/99-model/siteid/SiteIdsInput.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/GlobalUsings.cs 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/Properties/PublishProfiles/FolderProfile.pubxml 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/Properties/PublishProfiles/FolderProfile.pubxml.user 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/Yw.Dto.DMA.Core.csproj 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Dto.DMA.Core/Yw.Dto.DMA.Core.csproj.user 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/00-core/ConfigHelper.cs 55 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/01-entity/DmaArea.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/01-entity/DmaSite.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/03-settings/helper/DMAFileHelper.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/03-settings/paras/Paras_DMA_DataBase.cs 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/03-settings/paras/Paras_DMA_DataBase_Factory.cs 18 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/03-settings/paras/Paras_DMA_DataBase_PostgreSql.cs 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/03-settings/paras/Paras_DMA_DataBase_SQLite.cs 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/01-interface/IDmaArea.cs 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/01-interface/IDmaSite.cs 18 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/01-interface/IDmaSiteBinding.cs 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/01-interface/IDmaSiteMapping.cs 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/02-postgresql/DmaArea.cs 35 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/02-postgresql/DmaSite.cs 34 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/02-postgresql/DmaSiteBinding.cs 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/02-postgresql/DmaSiteMapping.cs 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/03-sqlite/DmaArea.cs 35 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/03-sqlite/DmaSite.cs 34 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/03-sqlite/DmaSiteBinding.cs 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/03-sqlite/DmaSiteMapping.cs 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/DmaArea.cs 51 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/04-dal/DmaSite.cs 50 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/05-service/00-helper/DALCreateHelper.cs 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/05-service/01-dma_area/DmaArea.cs 44 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/05-service/02-dma_site/DmaSite.cs 44 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/05-service/03-dma_site_binding/DmaSiteBinding.cs 16 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/05-service/04-dma_site_mapping/DmaSiteMapping.cs 20 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/GlobalUsings.cs 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/Properties/PublishProfiles/FolderProfile.pubxml.user 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/Yw.Service.DMA.Core.csproj 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Service.DMA.Core/paras_dma_settings.json 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Yw.Application.DMA.Core/00-core/2-extensions/Extensions.cs
ÎļþÒÑɾ³ý
Yw.Application.DMA.Core/00-core/Mapper.cs
Yw.Application.DMA.Core/01-dma_area/DmaArea_Controller.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/01-dma_area/1-mgr/DmaArea_Controller.cs ÐÞ¸Ä
@@ -121,7 +121,7 @@
        [HttpPut]
        public bool UpdateSortCode([Required] UpdateSortCodeInput input)
        {
            var bol = _service.UpdateSortCode(input.ID, input.SortCode, UserManager.UserID, DateTime.Now, UserManager.UserName);
            var bol = _service.UpdateSortCode(input.ID, input.SortCode);
            return bol;
        }
@@ -132,7 +132,7 @@
        [HttpPut]
        public bool UpdateSorter([Required] List<UpdateSortCodeInput> input)
        {
            var list = input.Select(x => x.Adapt<UpdateSortCodeInput, Model.TraceSorter>()).ToList();
            var list = input.Select(x => x.Adapt<UpdateSortCodeInput, Model.Sorter>()).ToList();
            var bol = _service.UpdateSorter(list);
            return bol;
        }
@@ -144,7 +144,7 @@
        [HttpPut]
        public bool UpdateParas([Required] UpdateParasInput input)
        {
            var bol = _service.UpdateParas(input.ID, input.Paras, UserManager.UserID, DateTime.Now, UserManager.UserName);
            var bol = _service.UpdateParas(input.ID, input.Paras);
            return bol;
        }
@@ -155,7 +155,7 @@
        [HttpPut]
        public bool UpdateFlags([Required] UpdateFlagsInput input)
        {
            var bol = _service.UpdateFlags(input.ID, input.Flags, UserManager.UserID, DateTime.Now, UserManager.UserName);
            var bol = _service.UpdateFlags(input.ID, input.Flags);
            return bol;
        }
@@ -173,7 +173,7 @@
                    throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "标记已存在");
                }
            }
            var bol = _service.UpdateTagName(input.ID, input.TagName, UserManager.UserID, DateTime.Now, UserManager.UserName);
            var bol = _service.UpdateTagName(input.ID, input.TagName);
            return bol;
        }
Yw.Application.DMA.Core/01-dma_area/DmaArea_StdController.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/01-dma_area/2-std/DmaArea_StdController.cs ÐÞ¸Ä
@@ -24,7 +24,7 @@
                Yw.Service.DmaArea.PublishCache(cacheKey);
                var vmList = all?.Select(x => new DmaAreaStdDto(x)).ToList();
                return vmList;
            }, CacheHelper.CacheLevel5);
            }, Yw.Service.ConfigHelper.CacheLevel5);
            return vm_list;
        }
Yw.Application.DMA.Core/02-dma_site/DmaSite_Controller.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/02-dma_site/1-mgr/DmaSite_Controller.cs ÐÞ¸Ä
@@ -121,7 +121,7 @@
        [HttpPut]
        public bool UpdateSortCode([Required] UpdateSortCodeInput input)
        {
            var bol = _service.UpdateSortCode(input.ID, input.SortCode, UserManager.UserID, DateTime.Now, UserManager.UserName);
            var bol = _service.UpdateSortCode(input.ID, input.SortCode);
            return bol;
        }
@@ -132,7 +132,7 @@
        [HttpPut]
        public bool UpdateSorter([Required] List<UpdateSortCodeInput> input)
        {
            var list = input.Select(x => x.Adapt<UpdateSortCodeInput, Model.TraceSorter>()).ToList();
            var list = input.Select(x => x.Adapt<UpdateSortCodeInput, Model.Sorter>()).ToList();
            var bol = _service.UpdateSorter(list);
            return bol;
        }
@@ -144,7 +144,7 @@
        [HttpPut]
        public bool UpdateParas([Required] UpdateParasInput input)
        {
            var bol = _service.UpdateParas(input.ID, input.Paras, UserManager.UserID, DateTime.Now, UserManager.UserName);
            var bol = _service.UpdateParas(input.ID, input.Paras);
            return bol;
        }
@@ -155,7 +155,7 @@
        [HttpPut]
        public bool UpdateFlags([Required] UpdateFlagsInput input)
        {
            var bol = _service.UpdateFlags(input.ID, input.Flags, UserManager.UserID, DateTime.Now, UserManager.UserName);
            var bol = _service.UpdateFlags(input.ID, input.Flags);
            return bol;
        }
@@ -173,7 +173,7 @@
                    throw YOops.Oh(eResultCode.Alert, ErrorCodes.V001, $"TagName:{input.TagName}", "标记已存在");
                }
            }
            var bol = _service.UpdateTagName(input.ID, input.TagName, UserManager.UserID, DateTime.Now, UserManager.UserName);
            var bol = _service.UpdateTagName(input.ID, input.TagName);
            return bol;
        }
Yw.Application.DMA.Core/02-dma_site/DmaSite_StdController.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/02-dma_site/2-std/DmaSite_StdController.cs ÐÞ¸Ä
@@ -24,7 +24,7 @@
                Yw.Service.DmaSite.PublishCache(cacheKey);
                var vmList = all?.Select(x => new DmaSiteStdDto(x)).ToList();
                return vmList;
            }, CacheHelper.CacheLevel5);
            }, Yw.Service.ConfigHelper.CacheLevel5);
            return vm_list;
        }
Yw.Application.DMA.Core/03-dma_site_binding/DmaSiteBinding_Controller.cs
Yw.Application.DMA.Core/04-dma_site_mapping/DmaSiteMapping_Controller.cs
Yw.Application.DMA.Core/GlobalUsings.cs
@@ -4,7 +4,10 @@
global using Microsoft.AspNetCore.Mvc;
global using System.ComponentModel.DataAnnotations;
global using System.Text;
global using Yw.DMA;
global using Yw.Untity;
global using Yw.Application.DMA;
global using Yw.JWT;
global using Yw.Dto;
global using Yw.Dto.DMA;
global using Yw.Service.DMA;
global using Yw.DMA;
Yw.Application.DMA.Core/Properties/PublishProfiles/FolderProfile.pubxml.user
@@ -4,6 +4,6 @@
-->
<Project>
  <PropertyGroup>
    <History>True|2024-03-08T08:18:57.0565373Z;True|2024-01-27T11:12:36.5624841+08:00;True|2024-01-21T15:11:49.7807954+08:00;True|2023-12-14T16:15:09.1175216+08:00;True|2023-12-14T16:03:02.7254674+08:00;True|2023-12-14T11:25:21.0608059+08:00;True|2023-12-14T09:22:56.3156463+08:00;True|2023-12-05T17:05:07.9898436+08:00;True|2023-12-05T17:04:51.8319435+08:00;True|2023-07-13T12:10:11.2591498+08:00;True|2023-05-25T18:02:16.3580168+08:00;True|2023-05-25T15:44:32.4909866+08:00;</History>
    <History>True|2024-03-26T07:12:13.3294744Z;True|2024-03-08T16:18:57.0565373+08:00;True|2024-01-27T11:12:36.5624841+08:00;True|2024-01-21T15:11:49.7807954+08:00;True|2023-12-14T16:15:09.1175216+08:00;True|2023-12-14T16:03:02.7254674+08:00;True|2023-12-14T11:25:21.0608059+08:00;True|2023-12-14T09:22:56.3156463+08:00;True|2023-12-05T17:05:07.9898436+08:00;True|2023-12-05T17:04:51.8319435+08:00;True|2023-07-13T12:10:11.2591498+08:00;True|2023-05-25T18:02:16.3580168+08:00;True|2023-05-25T15:44:32.4909866+08:00;</History>
  </PropertyGroup>
</Project>
Yw.Application.DMA.Core/Yw.Application.DMA.Core.csproj
@@ -7,7 +7,7 @@
    <RootNamespace>Yw.Application</RootNamespace>
    <GenerateDocumentationFile>True</GenerateDocumentationFile>
    <GeneratePackageOnBuild>True</GeneratePackageOnBuild>
    <Version>1.0.7</Version>
    <Version>3.0.0</Version>
  </PropertyGroup>
  <ItemGroup>
@@ -32,13 +32,8 @@
  </ItemGroup>
  <ItemGroup>
    <PackageReference Include="Yw.Application.Core" Version="1.4.2" />
    <PackageReference Include="Yw.Service.DMA.Core" Version="1.0.6" />
  </ItemGroup>
  <ItemGroup>
    <Folder Include="03-dma_site_binding\2-std\dto\" />
    <Folder Include="04-dma_site_mapping\2-std\dto\" />
    <PackageReference Include="Yw.Application.Core" Version="3.0.1" />
    <PackageReference Include="Yw.Dto.DMA.Core" Version="3.0.0" />
  </ItemGroup>
</Project>
Yw.DMA.Core.sln
@@ -11,6 +11,8 @@
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Yw.Entry.DMA.Core", "Yw.Entry.DMA.Core\Yw.Entry.DMA.Core.csproj", "{825A8A98-0F00-45D9-810B-C6D2E3B3C366}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Yw.Dto.DMA.Core", "Yw.Dto.DMA.Core\Yw.Dto.DMA.Core.csproj", "{F4CFCD1F-83A6-425E-A7BC-09B299676679}"
EndProject
Global
    GlobalSection(SolutionConfigurationPlatforms) = preSolution
        Debug|Any CPU = Debug|Any CPU
@@ -33,6 +35,10 @@
        {825A8A98-0F00-45D9-810B-C6D2E3B3C366}.Debug|Any CPU.Build.0 = Debug|Any CPU
        {825A8A98-0F00-45D9-810B-C6D2E3B3C366}.Release|Any CPU.ActiveCfg = Release|Any CPU
        {825A8A98-0F00-45D9-810B-C6D2E3B3C366}.Release|Any CPU.Build.0 = Release|Any CPU
        {F4CFCD1F-83A6-425E-A7BC-09B299676679}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
        {F4CFCD1F-83A6-425E-A7BC-09B299676679}.Debug|Any CPU.Build.0 = Debug|Any CPU
        {F4CFCD1F-83A6-425E-A7BC-09B299676679}.Release|Any CPU.ActiveCfg = Release|Any CPU
        {F4CFCD1F-83A6-425E-A7BC-09B299676679}.Release|Any CPU.Build.0 = Release|Any CPU
    EndGlobalSection
    GlobalSection(SolutionProperties) = preSolution
        HideSolutionNode = FALSE
Yw.Dto.DMA.Core/01-dma-area/AddDmaAreaInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/01-dma_area/1-mgr/dto/AddDmaAreaInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/01-dma-area/DmaAreaDto.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/01-dma_area/1-mgr/dto/DmaAreaDto.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/01-dma-area/DmaAreaStdDto.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/01-dma_area/2-std/dto/DmaAreaStdDto.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/01-dma-area/UpdateDmaAreaInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/01-dma_area/1-mgr/dto/UpdateDmaAreaInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/02-dma-site/AddDmaSiteInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/02-dma_site/1-mgr/dto/AddDmaSiteInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/02-dma-site/DmaSiteDto.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/02-dma_site/1-mgr/dto/DmaSiteDto.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/02-dma-site/DmaSiteStdDto.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/02-dma_site/2-std/dto/DmaSiteStdDto.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/02-dma-site/UpdateDmaSiteInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/02-dma_site/1-mgr/dto/UpdateDmaSiteInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/03-dma-site-binding/BindingDmaSiteInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/03-dma_site_binding/1-mgr/dto/BindingDmaSiteInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// ç»‘定
Yw.Dto.DMA.Core/03-dma-site-binding/DmaSiteBindingDto.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/03-dma_site_binding/1-mgr/dto/DmaSiteBindingDto.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/03-dma-site-binding/UnBindingDmaSiteInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/03-dma_site_binding/1-mgr/dto/UnBindingDmaSiteInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// è§£ç»‘Dma点位
Yw.Dto.DMA.Core/04-dma-site-mapping/AddDmaSiteMappingInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/04-dma_site_mapping/1-mgr/dto/AddDmaSiteMappingInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// æ·»åŠ Dma点位映射
Yw.Dto.DMA.Core/04-dma-site-mapping/DmaSiteMappingDto.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/04-dma_site_mapping/1-mgr/dto/DmaSiteMappingDto.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/04-dma-site-mapping/UpdateDmaSiteMappingInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/04-dma_site_mapping/1-mgr/dto/UpdateDmaSiteMappingInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application
namespace Yw.Dto
{
    /// <summary>
    /// æ›´æ–°Dma点位映射
Yw.Dto.DMA.Core/99-model/areaid/AreaIDInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/00-core/3-dto/areaid/AreaIDInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application.DMA
namespace Yw.Dto.DMA
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/99-model/direction/UpdateDirectionInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/00-core/3-dto/direction/UpdateDirectionInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application.DMA
namespace Yw.Dto.DMA
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/99-model/siteid/SiteIDInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/00-core/3-dto/siteid/SiteIDInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application.DMA
namespace Yw.Dto.DMA
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/99-model/siteid/SiteIdsInput.cs
ÎļþÃû´Ó Yw.Application.DMA.Core/00-core/3-dto/siteid/SiteIdsInput.cs ÐÞ¸Ä
@@ -1,4 +1,4 @@
namespace Yw.Application.DMA
namespace Yw.Dto.DMA
{
    /// <summary>
    /// 
Yw.Dto.DMA.Core/GlobalUsings.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,5 @@
global using System.ComponentModel.DataAnnotations;
global using System.Text;
global using Yw.Untity;
global using Yw.DMA;
global using Yw.Service.DMA;
Yw.Dto.DMA.Core/Properties/PublishProfiles/FolderProfile.pubxml
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
https://go.microsoft.com/fwlink/?LinkID=208121.
-->
<Project>
  <PropertyGroup>
    <Configuration>Release</Configuration>
    <Platform>Any CPU</Platform>
    <PublishDir>bin\Release\net6.0\publish\</PublishDir>
    <PublishProtocol>FileSystem</PublishProtocol>
  </PropertyGroup>
</Project>
Yw.Dto.DMA.Core/Properties/PublishProfiles/FolderProfile.pubxml.user
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
https://go.microsoft.com/fwlink/?LinkID=208121.
-->
<Project>
  <PropertyGroup>
    <History>True|2024-03-26T07:05:50.1066628Z;</History>
  </PropertyGroup>
</Project>
Yw.Dto.DMA.Core/Yw.Dto.DMA.Core.csproj
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">
  <PropertyGroup>
    <TargetFramework>net6.0</TargetFramework>
    <ImplicitUsings>enable</ImplicitUsings>
    <Nullable>disable</Nullable>
    <Version>3.0.0</Version>
  </PropertyGroup>
  <ItemGroup>
    <PackageReference Include="Yw.Dto.Core" Version="3.0.1" />
    <PackageReference Include="Yw.Service.DMA.Core" Version="3.0.0" />
  </ItemGroup>
</Project>
Yw.Dto.DMA.Core/Yw.Dto.DMA.Core.csproj.user
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <_LastSelectedProfileId>D:\WorkData\模块\Code\DMA\Yw.Dto.DMA.Core\Properties\PublishProfiles\FolderProfile.pubxml</_LastSelectedProfileId>
  </PropertyGroup>
</Project>
Yw.Service.DMA.Core/00-core/ConfigHelper.cs
@@ -3,7 +3,6 @@
    internal class ConfigHelper
    {
        /// <summary>
        /// é»˜è®¤è¿žæŽ¥é…ç½®
        /// </summary>
@@ -15,7 +14,7 @@
                return new ConnectionConfig()
                {
                    DbType = SqlSugar.DbType.PostgreSQL,//数据库类型
                    ConnectionString = DMAParasHelper.DMA.DataBase.ConnectString,
                    ConnectionString = DMAParasHelper.DMA.DataBase.PostgreSql.ConnectString,
                    IsAutoCloseConnection = true,//是否自动关闭
                    MoreSettings = new ConnMoreSettings()
                    {
@@ -34,29 +33,65 @@
            }
        }
        /// <summary>
        /// ç¼“存保持时间 ï¼ˆåˆ†é’Ÿï¼‰
        /// PostgreSql连接配置
        /// </summary>
        public static int CacheKeepTime
        internal static ConnectionConfig PostgreSqlConnectionConfig
        {
            get
            {
                return MemoryCacheParasHelper.MemoryCache.KeepTime;
                //SnowFlakeSingle.WorkId = Settings.SqlSugar.SnowFlakeWorkId; ä¸åŒæœºå™¨é…ç½®çš„唯一数字; // å•服务器不需要指定
                return new ConnectionConfig()
                {
                    DbType = SqlSugar.DbType.PostgreSQL,//数据库类型
                    ConnectionString = DMAParasHelper.DMA.DataBase.PostgreSql.ConnectString,
                    IsAutoCloseConnection = true,//是否自动关闭
                    MoreSettings = new ConnMoreSettings()
                    {
                        //PgSqlIsAutoToLower = false //数据库存在大写字段的 ï¼Œéœ€è¦æŠŠè¿™ä¸ªè®¾ä¸ºfalse ï¼Œå¹¶ä¸”实体和字段名称要一样
                    },
                    AopEvents = new AopEvents
                    {
                        OnLogExecuting = (sql, p) =>
                        {
                            // var sqlString = UtilMethods.GetNativeSql(sql, p);
                            //LogHelper.Debug(sqlString);
                            // Console.WriteLine(sql);
                        }
                    }
                };
            }
        }
        /// <summary>
        /// ç¼“存随机时间 ï¼ˆç§’)
        /// SQLite连接配置
        /// </summary>
        public static int CacheRandomTime
        internal static ConnectionConfig SQLiteConnectionConfig
        {
            get
            {
                return RandomHelper.Random(0, MemoryCacheParasHelper.MemoryCache.RandomTime);
                //SnowFlakeSingle.WorkId = Settings.SqlSugar.SnowFlakeWorkId; ä¸åŒæœºå™¨é…ç½®çš„唯一数字; // å•服务器不需要指定
                return new ConnectionConfig()
                {
                    DbType = SqlSugar.DbType.Sqlite,//数据库类型
                    ConnectionString = DMAParasHelper.DMA.DataBase.SQLite.ConnectString,
                    IsAutoCloseConnection = true,//是否自动关闭
                    MoreSettings = new ConnMoreSettings()
                    {
                        //PgSqlIsAutoToLower = false //数据库存在大写字段的 ï¼Œéœ€è¦æŠŠè¿™ä¸ªè®¾ä¸ºfalse ï¼Œå¹¶ä¸”实体和字段名称要一样
                    },
                    AopEvents = new AopEvents
                    {
                        OnLogExecuting = (sql, p) =>
                        {
                            // var sqlString = UtilMethods.GetNativeSql(sql, p);
                            //LogHelper.Debug(sqlString);
                            // Console.WriteLine(sql);
                        }
                    }
                };
            }
        }
Yw.Service.DMA.Core/01-entity/DmaArea.cs
@@ -4,7 +4,7 @@
    /// Dma分区
    /// </summary>
    [SugarTable("dma_area")]
    public class DmaArea : BaseTraceEntity, System.ICloneable, ISorter, IParas, IFlags, ITagName
    public class DmaArea : BaseTraceEntity, ICode, IParas, IFlags, ITagName, ISorter, System.ICloneable
    {
        /// <summary>
        /// 
Yw.Service.DMA.Core/01-entity/DmaSite.cs
@@ -4,7 +4,7 @@
    /// Dma点位
    /// </summary>
    [SugarTable("dma_site")]
    public class DmaSite : BaseTraceEntity, System.ICloneable, ISorter, IParas, IFlags, ITagName
    public class DmaSite : BaseTraceEntity, ICode, IParas, IFlags, ITagName, ISorter, System.ICloneable
    {
        /// <summary>
        /// 
Yw.Service.DMA.Core/03-settings/helper/DMAFileHelper.cs
@@ -50,7 +50,9 @@
        internal static bool Save()
        {
            if (_appparas == null)
            {
                return default;
            }
            var json = JsonHelper.Object2FormatJson(_appparas);
            File.WriteAllText(JsonFileName, json, Encoding.UTF8);
            return true;
Yw.Service.DMA.Core/03-settings/paras/Paras_DMA_DataBase.cs
@@ -6,9 +6,24 @@
    public class Paras_DMA_DataBase
    {
        /// <summary>
        /// è¿žæŽ¥å­—符串
        /// æ•°æ®åº“类型
        /// </summary>
        public string ConnectString { get; set; }
        public string DbType { get; set; }
        /// <summary>
        /// å·¥åŽ‚
        /// </summary>
        public Paras_DMA_DataBase_Factory Factory { get; set; }
        /// <summary>
        /// PostgreSql
        /// </summary>
        public Paras_DMA_DataBase_PostgreSql PostgreSql { get; set; }
        /// <summary>
        /// SQLite
        /// </summary>
        public Paras_DMA_DataBase_SQLite SQLite { get; set; }
    }
Yw.Service.DMA.Core/03-settings/paras/Paras_DMA_DataBase_Factory.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,18 @@
namespace Yw.Settings
{
    /// <summary>
    ///
    /// </summary>
    public class Paras_DMA_DataBase_Factory
    {
        /// <summary>
        /// æ˜¯å¦å¼€å¯ç¼“å­˜
        /// </summary>
        public bool EnableCache { get; set; }
        /// <summary>
        /// ç¼“存时间(秒)
        /// </summary>
        public int CacheTime { get; set; }
    }
}
Yw.Service.DMA.Core/03-settings/paras/Paras_DMA_DataBase_PostgreSql.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,14 @@
namespace Yw.Settings
{
    /// <summary>
    ///
    /// </summary>
    public class Paras_DMA_DataBase_PostgreSql
    {
        /// <summary>
        /// è¿žæŽ¥å­—符串
        /// </summary>
        public string ConnectString { get; set; }
    }
}
Yw.Service.DMA.Core/03-settings/paras/Paras_DMA_DataBase_SQLite.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,14 @@
namespace Yw.Settings
{
    /// <summary>
    ///
    /// </summary>
    public class Paras_DMA_DataBase_SQLite
    {
        /// <summary>
        /// è¿žæŽ¥å­—符串
        /// </summary>
        public string ConnectString { get; set; }
    }
}
Yw.Service.DMA.Core/04-dal/01-interface/IDmaArea.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,19 @@
namespace Yw.DAL
{
    /// <summary>
    /// Dma分区
    /// </summary>
    public interface IDmaArea : IBaseTraceDAL<Entity.DmaArea>, IUpdateCode, IUpdateParas, IUpdateFlags, IUpdateTagName, IUpdateSorter
    {
        /// <summary>
        /// é€šè¿‡ BelongType å’Œ BelongID èŽ·å–
        /// </summary>
        List<Entity.DmaArea> GetByBelongTypeAndBelongID(string BelongType, long BelongID);
    }
}
Yw.Service.DMA.Core/04-dal/01-interface/IDmaSite.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,18 @@
namespace Yw.DAL
{
    /// <summary>
    /// Dma点位
    /// </summary>
    public interface IDmaSite : IBaseTraceDAL<Entity.DmaSite>, IUpdateCode, IUpdateParas, IUpdateFlags, IUpdateTagName, IUpdateSorter
    {
        /// <summary>
        /// é€šè¿‡ BelongType å’Œ BelongID èŽ·å–
        /// </summary>
        List<Entity.DmaSite> GetByBelongTypeAndBelongID(string BelongType, long BelongID);
    }
}
Yw.Service.DMA.Core/04-dal/01-interface/IDmaSiteBinding.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,22 @@
namespace Yw.DAL
{
    /// <summary>
    /// Dma点位映射
    /// </summary>
    public interface IDmaSiteBinding : IBaseDAL<Entity.DmaSiteBinding>
    {
        /// <summary>
        /// é€šè¿‡ SiteID èŽ·å–
        /// </summary>
        List<Entity.DmaSiteBinding> GetBySiteID(long SiteID);
        /// <summary>
        /// é€šè¿‡ MeterID èŽ·å–
        /// </summary>
        List<Entity.DmaSiteBinding> GetByMeterID(long MeterID);
    }
}
Yw.Service.DMA.Core/04-dal/01-interface/IDmaSiteMapping.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,25 @@
namespace Yw.DAL
{
    /// <summary>
    /// Dma点位映射关系
    /// </summary>
    public interface IDmaSiteMapping : IBaseDAL<Entity.DmaSiteMapping>
    {
        /// <summary>
        /// é€šè¿‡ AreaID èŽ·å–
        /// </summary>
        List<Entity.DmaSiteMapping> GetByAreaID(long AreaID);
        /// <summary>
        /// é€šè¿‡ SiteID èŽ·å–
        /// </summary>
        List<Entity.DmaSiteMapping> GetBySiteID(long SiteID);
        /// <summary>
        /// æ›´æ–°æ–¹å‘
        /// </summary>
        bool UpdateDirection(long ID, int Direction);
    }
}
Yw.Service.DMA.Core/04-dal/02-postgresql/DmaArea.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,35 @@
namespace Yw.DAL.PostgreSql
{
    /// <summary>
    /// Dma分区
    /// </summary>
    public partial class DmaArea : BaseTraceDAL_Code_Paras_Flags_TagName_Sorter<Entity.DmaArea>, IDmaArea
    {
        /// <summary>
        ///
        /// </summary>
        public override ConnectionConfig ConnectionConfig
        {
            get { return ConfigHelper.PostgreSqlConnectionConfig; }
        }
        /// <summary>
        /// é€šè¿‡ BelongType å’Œ BelongID èŽ·å–
        /// </summary>
        public List<Entity.DmaArea> GetByBelongTypeAndBelongID(string BelongType, long BelongID)
        {
            using (var db = new SqlSugarClient(ConnectionConfig))
            {
                return db.Queryable<Entity.DmaArea>()
                    .Where(x => x.BelongType == BelongType && x.BelongID == BelongID)
                    .OrderBy(x => x.SortCode).ToList();
            }
        }
    }
}
Yw.Service.DMA.Core/04-dal/02-postgresql/DmaSite.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,34 @@
namespace Yw.DAL.PostgreSql
{
    /// <summary>
    /// Dma点位
    /// </summary>
    public partial class DmaSite : BaseTraceDAL_Code_Paras_Flags_TagName_Sorter<Entity.DmaSite>, IDmaSite
    {
        /// <summary>
        ///
        /// </summary>
        public override ConnectionConfig ConnectionConfig
        {
            get { return ConfigHelper.PostgreSqlConnectionConfig; }
        }
        /// <summary>
        /// é€šè¿‡ BelongType å’Œ BelongID èŽ·å–
        /// </summary>
        public List<Entity.DmaSite> GetByBelongTypeAndBelongID(string BelongType, long BelongID)
        {
            using (var db = new SqlSugarClient(ConnectionConfig))
            {
                return db.Queryable<Entity.DmaSite>()
                    .Where(x => x.BelongType == BelongType && x.BelongID == BelongID)
                    .OrderBy(x => x.SortCode).ToList();
            }
        }
    }
}
Yw.Service.DMA.Core/04-dal/02-postgresql/DmaSiteBinding.cs
ÎļþÃû´Ó Yw.Service.DMA.Core/04-dal/DmaSiteBinding.cs ÐÞ¸Ä
@@ -1,23 +1,16 @@
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using SqlSugar;
namespace Yw.DAL
namespace Yw.DAL.PostgreSql
{
    /// <summary>
    /// Dma点位映射
    /// </summary>
    public partial class DmaSiteBinding : BaseDAL<Entity.DmaSiteBinding>
    public partial class DmaSiteBinding : BaseDAL<Entity.DmaSiteBinding>, IDmaSiteBinding
    {
        /// <summary>
        /// 
        /// </summary>
        public override ConnectionConfig ConnectionConfig
        {
            get { return ConfigHelper.DefaultConnectionConfig; }
            get { return ConfigHelper.PostgreSqlConnectionConfig; }
        }
Yw.Service.DMA.Core/04-dal/02-postgresql/DmaSiteMapping.cs
ÎļþÃû´Ó Yw.Service.DMA.Core/04-dal/DmaSiteMapping.cs ÐÞ¸Ä
@@ -1,16 +1,16 @@
namespace Yw.DAL
namespace Yw.DAL.PostgreSql
{
    /// <summary>
    /// Dma点位映射关系
    /// </summary>
    public partial class DmaSiteMapping : BaseDAL<Entity.DmaSiteMapping>
    public partial class DmaSiteMapping : BaseDAL<Entity.DmaSiteMapping>, IDmaSiteMapping
    {
        /// <summary>
        /// 
        /// </summary>
        public override ConnectionConfig ConnectionConfig
        {
            get { return ConfigHelper.DefaultConnectionConfig; }
            get { return ConfigHelper.PostgreSqlConnectionConfig; }
        }
Yw.Service.DMA.Core/04-dal/03-sqlite/DmaArea.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,35 @@
namespace Yw.DAL.SQLite
{
    /// <summary>
    /// Dma分区
    /// </summary>
    public partial class DmaArea : BaseTraceDAL_Code_Paras_Flags_TagName_Sorter<Entity.DmaArea>, IDmaArea
    {
        /// <summary>
        ///
        /// </summary>
        public override ConnectionConfig ConnectionConfig
        {
            get { return ConfigHelper.SQLiteConnectionConfig; }
        }
        /// <summary>
        /// é€šè¿‡ BelongType å’Œ BelongID èŽ·å–
        /// </summary>
        public List<Entity.DmaArea> GetByBelongTypeAndBelongID(string BelongType, long BelongID)
        {
            using (var db = new SqlSugarClient(ConnectionConfig))
            {
                return db.Queryable<Entity.DmaArea>()
                    .Where(x => x.BelongType == BelongType && x.BelongID == BelongID)
                    .OrderBy(x => x.SortCode).ToList();
            }
        }
    }
}
Yw.Service.DMA.Core/04-dal/03-sqlite/DmaSite.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,34 @@
namespace Yw.DAL.SQLite
{
    /// <summary>
    /// Dma点位
    /// </summary>
    public partial class DmaSite : BaseTraceDAL_Code_Paras_Flags_TagName_Sorter<Entity.DmaSite>, IDmaSite
    {
        /// <summary>
        ///
        /// </summary>
        public override ConnectionConfig ConnectionConfig
        {
            get { return ConfigHelper.SQLiteConnectionConfig; }
        }
        /// <summary>
        /// é€šè¿‡ BelongType å’Œ BelongID èŽ·å–
        /// </summary>
        public List<Entity.DmaSite> GetByBelongTypeAndBelongID(string BelongType, long BelongID)
        {
            using (var db = new SqlSugarClient(ConnectionConfig))
            {
                return db.Queryable<Entity.DmaSite>()
                    .Where(x => x.BelongType == BelongType && x.BelongID == BelongID)
                    .OrderBy(x => x.SortCode).ToList();
            }
        }
    }
}
Yw.Service.DMA.Core/04-dal/03-sqlite/DmaSiteBinding.cs
copy from Yw.Service.DMA.Core/04-dal/DmaSiteBinding.cs copy to Yw.Service.DMA.Core/04-dal/03-sqlite/DmaSiteBinding.cs
Îļþ´Ó Yw.Service.DMA.Core/04-dal/DmaSiteBinding.cs ¸´ÖÆ
@@ -1,23 +1,16 @@
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using SqlSugar;
namespace Yw.DAL
namespace Yw.DAL.SQLite
{
    /// <summary>
    /// Dma点位映射
    /// </summary>
    public partial class DmaSiteBinding : BaseDAL<Entity.DmaSiteBinding>
    public partial class DmaSiteBinding : BaseDAL<Entity.DmaSiteBinding>, IDmaSiteBinding
    {
        /// <summary>
        /// 
        /// </summary>
        public override ConnectionConfig ConnectionConfig
        {
            get { return ConfigHelper.DefaultConnectionConfig; }
            get { return ConfigHelper.SQLiteConnectionConfig; }
        }
Yw.Service.DMA.Core/04-dal/03-sqlite/DmaSiteMapping.cs
copy from Yw.Service.DMA.Core/04-dal/DmaSiteMapping.cs copy to Yw.Service.DMA.Core/04-dal/03-sqlite/DmaSiteMapping.cs
Îļþ´Ó Yw.Service.DMA.Core/04-dal/DmaSiteMapping.cs ¸´ÖÆ
@@ -1,16 +1,16 @@
namespace Yw.DAL
namespace Yw.DAL.SQLite
{
    /// <summary>
    /// Dma点位映射关系
    /// </summary>
    public partial class DmaSiteMapping : BaseDAL<Entity.DmaSiteMapping>
    public partial class DmaSiteMapping : BaseDAL<Entity.DmaSiteMapping>, IDmaSiteMapping
    {
        /// <summary>
        /// 
        /// </summary>
        public override ConnectionConfig ConnectionConfig
        {
            get { return ConfigHelper.DefaultConnectionConfig; }
            get { return ConfigHelper.SQLiteConnectionConfig; }
        }
Yw.Service.DMA.Core/04-dal/DmaArea.cs
ÎļþÒÑɾ³ý
Yw.Service.DMA.Core/04-dal/DmaSite.cs
ÎļþÒÑɾ³ý
Yw.Service.DMA.Core/05-service/00-helper/DALCreateHelper.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,23 @@
namespace Yw.Service.DMA
{
    /// <summary>
    /// DAL辅助类
    /// </summary>
    internal class DALCreateHelper
    {
        /// <summary>
        /// åˆ›å»ºDAL
        /// </summary>
        /// <typeparam name="T"></typeparam>
        /// <returns></returns>
        public static T CreateDAL<T>()
        {
            var dbType = Settings.DMAParasHelper.DMA.DataBase.DbType;
            var enableCache = Settings.DMAParasHelper.DMA.DataBase.Factory.EnableCache;
            var cacheTime = Settings.DMAParasHelper.DMA.DataBase.Factory.CacheTime;
            return Yw.DALFactory.CreateDAL<T>(dbType, enableCache, cacheTime);
        }
    }
}
Yw.Service.DMA.Core/05-service/01-dma_area/DmaArea.cs
@@ -12,7 +12,7 @@
        {
            var all = DmaAreaCacheHelper.GetSet(() =>
            {
                var dal = new DAL.DmaArea();
                var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
                var entityList = dal.GetAll();
                var modelList = Entity2Models(entityList);
                if (modelList == null)
@@ -27,7 +27,7 @@
        //通过 ID æ›´æ–°ç¼“å­˜
        private static void UpdateCache(long ID)
        {
            var dal = new DAL.DmaArea();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var entityDb = dal.GetByID(ID);
            var modelDb = Entity2Model(entityDb);
            var all = GetCache();
@@ -48,7 +48,7 @@
        {
            if (Ids == null || Ids.Count < 1)
                return;
            var dal = new DAL.DmaArea();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var entityList = dal.GetByIds(Ids);
            var modelList = Entity2Models(entityList);
            var all = GetCache();
@@ -150,7 +150,7 @@
                return default;
            }
            var entity = Model2Entity(model);
            var dal = new DAL.DmaArea();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var id = dal.Insert(entity);
            if (id > 0)
            {
@@ -168,7 +168,7 @@
            {
                return false;
            }
            var dal = new DAL.DmaArea();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var entity_list = Model2Entities(list);
            var ids = dal.InsertsR(entity_list);
            if (ids != null && ids.Count > 0)
@@ -193,7 +193,7 @@
                return false;
            }
            var entity = Model2Entity(model);
            var dal = new DAL.DmaArea();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var bol = dal.Update(entity);
            if (bol)
            {
@@ -212,7 +212,7 @@
                return false;
            }
            var entity_list = Model2Entities(list.ToList());
            var dal = new DAL.DmaArea();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var bol = dal.Updates(entity_list);
            if (bol)
            {
@@ -224,14 +224,14 @@
        /// <summary>
        /// æ›´æ–°æŽ’序码
        /// </summary>
        public bool UpdateSortCode(long ID, int SortCode, long UpdateUserID, DateTime UpdateTime, string UpdateUserName)
        public bool UpdateSortCode(long ID, int SortCode)
        {
            if (ID < 1)
            {
                return default;
            }
            var dal = new DAL.DmaArea();
            var bol = dal.UpdateSortCode(ID, SortCode, UpdateUserID, UpdateTime, UpdateUserName);
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var bol = dal.UpdateSortCode(ID, SortCode);
            if (bol)
            {
                UpdateCache(ID);
@@ -242,13 +242,13 @@
        /// <summary>
        /// æ›´æ–°æŽ’序
        /// </summary>
        public bool UpdateSorter(List<Model.TraceSorter> sorters)
        public bool UpdateSorter(List<Model.Sorter> sorters)
        {
            if (sorters == null || sorters.Count < 1)
            {
                return default;
            }
            var dal = new DAL.DmaArea();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var bol = dal.UpdateSorter(sorters.ToEntityList());
            if (bol)
            {
@@ -260,10 +260,10 @@
        /// <summary>
        /// æ›´æ–° Paras
        /// </summary>
        public bool UpdateParas(long ID, Dictionary<string, string> Paras, long UpdateUserID, DateTime UpdateTime, string UpdateUserName)
        public bool UpdateParas(long ID, Dictionary<string, string> Paras)
        {
            var dal = new DAL.DmaArea();
            var bol = dal.UpdateParas(ID, ParasHelper.ToString(Paras), UpdateUserID, UpdateTime, UpdateUserName);
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var bol = dal.UpdateParas(ID, ParasHelper.ToString(Paras));
            if (bol)
            {
                UpdateCache(ID);
@@ -274,10 +274,10 @@
        /// <summary>
        /// æ›´æ–° Flags
        /// </summary>
        public bool UpdateFlags(long ID, List<string> Flags, long UpdateUserID, DateTime UpdateTime, string UpdateUserName)
        public bool UpdateFlags(long ID, List<string> Flags)
        {
            var dal = new DAL.DmaArea();
            var bol = dal.UpdateFlags(ID, FlagsHelper.ToString(Flags), UpdateUserID, UpdateTime, UpdateUserName);
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var bol = dal.UpdateFlags(ID, FlagsHelper.ToString(Flags));
            if (bol)
            {
                UpdateCache(ID);
@@ -288,10 +288,10 @@
        /// <summary>
        /// æ›´æ–° TagName
        /// </summary>
        public bool UpdateTagName(long ID, string TagName, long UpdateUserID, DateTime UpdateTime, string UpdateUserName)
        public bool UpdateTagName(long ID, string TagName)
        {
            var dal = new DAL.DmaArea();
            var bol = dal.UpdateTagName(ID, TagName, UpdateUserID, UpdateTime, UpdateUserName);
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var bol = dal.UpdateTagName(ID, TagName);
            if (bol)
            {
                UpdateCache(ID);
@@ -377,7 +377,7 @@
                Msg = "存在点位映射关系";
                return false;
            }
            var dal = new DAL.DmaArea();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaArea>();
            var bol = dal.DeleteByID(ID);
            if (bol)
            {
Yw.Service.DMA.Core/05-service/02-dma_site/DmaSite.cs
@@ -12,7 +12,7 @@
        {
            var all = DmaSiteCacheHelper.GetSet(() =>
            {
                var dal = new DAL.DmaSite();
                var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
                var entityList = dal.GetAll();
                var modelList = Entity2Models(entityList);
                if (modelList == null)
@@ -27,7 +27,7 @@
        //通过 ID æ›´æ–°ç¼“å­˜
        private static void UpdateCache(long ID)
        {
            var dal = new DAL.DmaSite();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var entityDb = dal.GetByID(ID);
            var modelDb = Entity2Model(entityDb);
            var all = GetCache();
@@ -48,7 +48,7 @@
        {
            if (Ids == null || Ids.Count < 1)
                return;
            var dal = new DAL.DmaSite();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var entityList = dal.GetByIds(Ids);
            var modelList = Entity2Models(entityList);
            var all = GetCache();
@@ -147,7 +147,7 @@
                return default;
            }
            var entity = Model2Entity(model);
            var dal = new DAL.DmaSite();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var id = dal.Insert(entity);
            if (id > 0)
            {
@@ -165,7 +165,7 @@
            {
                return false;
            }
            var dal = new DAL.DmaSite();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var entity_list = Model2Entities(list);
            var ids = dal.InsertsR(entity_list);
            if (ids != null && ids.Count > 0)
@@ -190,7 +190,7 @@
                return false;
            }
            var entity = Model2Entity(model);
            var dal = new DAL.DmaSite();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var bol = dal.Update(entity);
            if (bol)
            {
@@ -209,7 +209,7 @@
                return false;
            }
            var entity_list = Model2Entities(list.ToList());
            var dal = new DAL.DmaSite();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var bol = dal.Updates(entity_list);
            if (bol)
            {
@@ -221,14 +221,14 @@
        /// <summary>
        /// æ›´æ–°æŽ’序码
        /// </summary>
        public bool UpdateSortCode(long ID, int SortCode, long UpdateUserID, DateTime UpdateTime, string UpdateUserName)
        public bool UpdateSortCode(long ID, int SortCode)
        {
            if (ID < 1)
            {
                return default;
            }
            var dal = new DAL.DmaSite();
            var bol = dal.UpdateSortCode(ID, SortCode, UpdateUserID, UpdateTime, UpdateUserName);
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var bol = dal.UpdateSortCode(ID, SortCode);
            if (bol)
            {
                UpdateCache(ID);
@@ -239,13 +239,13 @@
        /// <summary>
        /// æ›´æ–°æŽ’序
        /// </summary>
        public bool UpdateSorter(List<Model.TraceSorter> sorters)
        public bool UpdateSorter(List<Model.Sorter> sorters)
        {
            if (sorters == null || sorters.Count < 1)
            {
                return default;
            }
            var dal = new DAL.DmaSite();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var bol = dal.UpdateSorter(sorters.ToEntityList());
            if (bol)
            {
@@ -257,10 +257,10 @@
        /// <summary>
        /// æ›´æ–° Paras
        /// </summary>
        public bool UpdateParas(long ID, Dictionary<string, string> Paras, long UpdateUserID, DateTime UpdateTime, string UpdateUserName)
        public bool UpdateParas(long ID, Dictionary<string, string> Paras)
        {
            var dal = new DAL.DmaSite();
            var bol = dal.UpdateParas(ID, ParasHelper.ToString(Paras), UpdateUserID, UpdateTime, UpdateUserName);
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var bol = dal.UpdateParas(ID, ParasHelper.ToString(Paras));
            if (bol)
            {
                UpdateCache(ID);
@@ -271,10 +271,10 @@
        /// <summary>
        /// æ›´æ–° Flags
        /// </summary>
        public bool UpdateFlags(long ID, List<string> Flags, long UpdateUserID, DateTime UpdateTime, string UpdateUserName)
        public bool UpdateFlags(long ID, List<string> Flags)
        {
            var dal = new DAL.DmaSite();
            var bol = dal.UpdateFlags(ID, FlagsHelper.ToString(Flags), UpdateUserID, UpdateTime, UpdateUserName);
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var bol = dal.UpdateFlags(ID, FlagsHelper.ToString(Flags));
            if (bol)
            {
                UpdateCache(ID);
@@ -285,10 +285,10 @@
        /// <summary>
        /// æ›´æ–° TagName
        /// </summary>
        public bool UpdateTagName(long ID, string TagName, long UpdateUserID, DateTime UpdateTime, string UpdateUserName)
        public bool UpdateTagName(long ID, string TagName)
        {
            var dal = new DAL.DmaSite();
            var bol = dal.UpdateTagName(ID, TagName, UpdateUserID, UpdateTime, UpdateUserName);
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var bol = dal.UpdateTagName(ID, TagName);
            if (bol)
            {
                UpdateCache(ID);
@@ -379,7 +379,7 @@
                Msg = "存在映射关系";
                return false;
            }
            var dal = new DAL.DmaSite();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSite>();
            var bol = dal.DeleteByID(ID);
            if (bol)
            {
Yw.Service.DMA.Core/05-service/03-dma_site_binding/DmaSiteBinding.cs
@@ -12,7 +12,7 @@
        {
            var all = DmaSiteBindingCacheHelper.GetSet(() =>
            {
                var dal = new DAL.DmaSiteBinding();
                var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteBinding>();
                var entityList = dal.GetAll();
                var modelList = Entity2Models(entityList);
                if (modelList == null)
@@ -27,7 +27,7 @@
        //通过 ID æ›´æ–°ç¼“å­˜
        private static void UpdateCache(long ID)
        {
            var dal = new DAL.DmaSiteBinding();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteBinding>();
            var entityDb = dal.GetByID(ID);
            var modelDb = Entity2Model(entityDb);
            var all = GetCache();
@@ -50,7 +50,7 @@
            {
                return;
            }
            var dal = new DAL.DmaSiteBinding();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteBinding>();
            var entityList = dal.GetByIds(Ids);
            var modelList = Entity2Models(entityList);
            var all = GetCache();
@@ -261,7 +261,7 @@
                return default;
            }
            var entity = Model2Entity(model);
            var dal = new DAL.DmaSiteBinding();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteBinding>();
            var id = dal.Insert(entity);
            if (id > 0)
            {
@@ -279,7 +279,7 @@
            {
                return false;
            }
            var dal = new DAL.DmaSiteBinding();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteBinding>();
            var entity_list = Model2Entities(list);
            var ids = dal.InsertsR(entity_list);
            if (ids != null && ids.Count > 0)
@@ -304,7 +304,7 @@
                return false;
            }
            var entity = Model2Entity(model);
            var dal = new DAL.DmaSiteBinding();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteBinding>();
            var bol = dal.Update(entity);
            if (bol)
            {
@@ -323,7 +323,7 @@
                return false;
            }
            var entity_list = Model2Entities(list.ToList());
            var dal = new DAL.DmaSiteBinding();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteBinding>();
            var bol = dal.Updates(entity_list);
            if (bol)
            {
@@ -382,7 +382,7 @@
        public bool DeleteByID(long ID, out string Msg)
        {
            Msg = string.Empty;
            var dal = new DAL.DmaSiteBinding();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteBinding>();
            var bol = dal.DeleteByID(ID);
            if (bol)
            {
Yw.Service.DMA.Core/05-service/04-dma_site_mapping/DmaSiteMapping.cs
@@ -12,7 +12,7 @@
        {
            return DmaSiteMappingCacheHelper.GetSet(() =>
            {
                var dal = new DAL.DmaSiteMapping();
                var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
                var entity_list = dal.GetAll();
                var model_list = Entity2Models(entity_list);
                if (model_list == null)
@@ -26,7 +26,7 @@
        //通过 ID æ›´æ–°ç¼“å­˜
        private static void UpdateCache(long ID)
        {
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var entity_ds = dal.GetByID(ID);
            var model_ds = Entity2Model(entity_ds);
            var all = GetCache();
@@ -49,7 +49,7 @@
            {
                return;
            }
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var entity_list = dal.GetByIds(Ids);
            var model_list = Entity2Models(entity_list);
            var all = GetCache();
@@ -64,7 +64,7 @@
        //通过 SiteID æ›´æ–°ç¼“å­˜
        private static void UpdateCacheBySiteID(long SiteID)
        {
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var entity_list = dal.GetBySiteID(SiteID);
            var model_list = Entity2Models(entity_list);
            var all = GetCache();
@@ -185,7 +185,7 @@
                return default;
            }
            var entity = Model2Entity(model);
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var id = dal.Insert(entity);
            if (id > 0)
            {
@@ -203,7 +203,7 @@
            {
                return false;
            }
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var entity_list = Model2Entities(list);
            var ids = dal.InsertsR(entity_list);
            if (ids != null && ids.Count > 0)
@@ -228,7 +228,7 @@
                return false;
            }
            var entity = Model2Entity(model);
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var bol = dal.Update(entity);
            if (bol)
            {
@@ -247,7 +247,7 @@
                return false;
            }
            var entity_list = Model2Entities(list.ToList());
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var bol = dal.Updates(entity_list);
            if (bol)
            {
@@ -261,7 +261,7 @@
        /// </summary>
        public bool UpdateDirection(long ID, eDirection Direction)
        {
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var bol = dal.UpdateDirection(ID, (int)Direction);
            if (bol)
            {
@@ -302,7 +302,7 @@
        public bool DeleteByID(long ID, out string Msg)
        {
            Msg = string.Empty;
            var dal = new DAL.DmaSiteMapping();
            var dal = DALCreateHelper.CreateDAL<Yw.DAL.IDmaSiteMapping>();
            var bol = dal.DeleteByID(ID);
            if (bol)
            {
Yw.Service.DMA.Core/GlobalUsings.cs
@@ -7,7 +7,6 @@
global using System.Collections;
global using SqlSugar;
global using AutoMapper;
global using Yw.Newtonsoft;
global using Yw.DMA;
global using Yw.Settings;
global using Yw.Untity;
Yw.Service.DMA.Core/Properties/PublishProfiles/FolderProfile.pubxml.user
@@ -4,6 +4,6 @@
-->
<Project>
  <PropertyGroup>
    <History>True|2024-03-08T08:18:18.3780160Z;True|2024-01-21T15:08:21.6456363+08:00;True|2023-12-14T16:14:15.6493020+08:00;True|2023-12-14T16:02:00.2140184+08:00;True|2023-12-14T16:01:54.5715660+08:00;True|2023-12-14T11:24:08.6483638+08:00;True|2023-12-14T09:18:59.7684854+08:00;True|2023-12-05T17:01:08.6045358+08:00;True|2023-12-05T17:00:59.6449800+08:00;True|2023-07-13T11:54:33.7989040+08:00;True|2023-07-13T11:54:23.3967174+08:00;True|2023-07-06T09:49:52.7407983+08:00;True|2023-05-25T15:37:23.5406830+08:00;False|2023-05-25T15:36:09.3589239+08:00;</History>
    <History>True|2024-03-26T06:58:52.6917193Z;True|2024-03-08T16:18:18.3780160+08:00;True|2024-01-21T15:08:21.6456363+08:00;True|2023-12-14T16:14:15.6493020+08:00;True|2023-12-14T16:02:00.2140184+08:00;True|2023-12-14T16:01:54.5715660+08:00;True|2023-12-14T11:24:08.6483638+08:00;True|2023-12-14T09:18:59.7684854+08:00;True|2023-12-05T17:01:08.6045358+08:00;True|2023-12-05T17:00:59.6449800+08:00;True|2023-07-13T11:54:33.7989040+08:00;True|2023-07-13T11:54:23.3967174+08:00;True|2023-07-06T09:49:52.7407983+08:00;True|2023-05-25T15:37:23.5406830+08:00;False|2023-05-25T15:36:09.3589239+08:00;</History>
  </PropertyGroup>
</Project>
Yw.Service.DMA.Core/Yw.Service.DMA.Core.csproj
@@ -7,7 +7,7 @@
        <RootNamespace>Yw</RootNamespace>
        <GenerateDocumentationFile>True</GenerateDocumentationFile>
        <GeneratePackageOnBuild>True</GeneratePackageOnBuild>
        <Version>1.0.6</Version>
        <Version>3.0.0</Version>
        <Description>引用升级</Description>
    </PropertyGroup>
@@ -27,7 +27,11 @@
    </ItemGroup>
    <ItemGroup>
      <PackageReference Include="Yw.Service.Core" Version="1.1.7" />
      <PackageReference Include="Yw.DAL.PostgreSql.Core" Version="3.0.0" />
      <PackageReference Include="Yw.DAL.SQLite.Core" Version="3.0.0" />
      <PackageReference Include="Yw.DALFactory.Core" Version="3.0.0" />
      <PackageReference Include="Yw.IDAL.Core" Version="3.0.0" />
      <PackageReference Include="Yw.Service.Core" Version="3.0.0" />
    </ItemGroup>
    <ItemGroup>
Yw.Service.DMA.Core/paras_dma_settings.json
@@ -4,7 +4,17 @@
  "DMA": {
    "DataBase": {
      "ConnectString": "PORT=5432;DATABASE=yw_dma;HOST=localhost;PASSWORD=123456;USER ID=postgres;"
      "DbType": "PostgreSql", //PostgreSql、SQLite
      "Factory": {
        "EnableCache": true,
        "CacheTime": 10
      },
      "PostgreSql": {
        "ConnectString": "PORT=5432;DATABASE=yw_dma;HOST=localhost;PASSWORD=123456;USER ID=postgres;"
      },
      "SQLite": {
        "ConnectString": "Data Source=yw_dma.db;"
      }
    }
  }