From 374ce4ffd0c459bb4067e8d5765f972668aff9b1 Mon Sep 17 00:00:00 2001 From: wzp <2040239371@qq.com> Date: 星期四, 02 三月 2023 14:56:23 +0800 Subject: [PATCH] 变更oracle访问组件 --- web/Dao/GwRmDao.cs | 2 web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.uninstall.xdt | 64 web/Common/App.config | 28 web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.uninstall.xdt | 64 web/Dao/GwOrderAuditDao.cs | 2 web/Dao/GwAlarmDao.cs | 2 web/.vs/Web/FileContentIndex/8f696eb1-6627-4ae6-821d-6d56c98f9654.vsidx | 0 web/Dao/GwSpDao.cs | 2 web/.vs/Web/FileContentIndex/79694cf4-4ab6-42a5-9a88-3040eca22d51.vsidx | 0 web/web/Bin/Common.dll | 0 web/Dao/GwClientPayMentDao.cs | 2 web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.install.xdt | 115 + web/.vs/Web/config/applicationhost.config | 2 web/Dao/GwClientCertificationDao.cs | 2 web/Dao/GwSmDao.cs | 2 web/.vs/Web/v17/fileList.bin | 0 web/Dao/GwOrderDao.cs | 2 web/App_Code/bin/Debug/App_Code.pdb | 0 web/Dao/GwDmDao.cs | 2 web/web/Bin/Common.pdb | 0 web/Web.sln | 20 web/Common/SegmentHelper.cs | 52 web/packages/Oracle.ManagedDataAccess.19.18.0/PerfCounters/register_odpm_perfmon_counters.ps1 | 41 web/packages/Oracle.ManagedDataAccess.19.18.0/lib/net40/Oracle.ManagedDataAccess.dll | 0 web/Dao/GwOpGroupDao.cs | 2 web/Lib/Dao.dll | 0 web/Dao/SysDictDataDao.cs | 2 web/App_Code/bin/Debug/App_Code.dll | 0 web/Dao/GwSettingDao.cs | 2 web/Dao/GwProductDao.cs | 2 web/Common/OracleHelper.cs | 5 web/Dao/SysXhDao.cs | 2 web/Lib/Dao.pdb | 0 web/Dao/GwMobileAreaDao.cs | 2 web/.vs/Web/v17/.suo | 0 web/Dao/GwStatisProfitDao.cs | 2 web/Dao/GwStatisDao.cs | 2 web/Dao/GwApDao.cs | 4 web/packages/Oracle.ManagedDataAccess.19.18.0/info.txt | 296 ++++ web/packages/Oracle.ManagedDataAccess.19.18.0/readme.txt | 208 +++ web/Lib/Model.dll | 0 web/web/GwClientSub.aspx.cs | 287 ++++ web/Dao/SysFlowDao.cs | 2 web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.install.xdt | 114 + web/Common/Common.csproj | 12 web/web/GwClientSub.aspx | 1072 ++++++++++++++++ web/UMCLib/bin/Debug/UMCLib.pdb | 0 web/web/Bin/UMCLib.pdb | 0 web/Lib/Common.dll | 0 web/Lib/Ionic.Zip.dll | 0 web/Lib/Model.pdb | 0 web/Lib/Aspose.Cells.dll | 0 web/Dao/GwClientDao.cs | 2 web/web/Index.aspx | 2 web/Dao/GwRmResendDao.cs | 2 web/Dao/packages.config | 4 web/Lib/Common.pdb | 0 web/packages/Oracle.ManagedDataAccess.19.18.0/.signature.p7s | 0 web/Dao/GwSpPrePatternDao.cs | 2 web/web/Bin/UMCLib.dll | 0 web/UMCLib/bin/Debug/UMCLib.dll | 0 web/Dao/UserDao.cs | 2 web/.vs/Web/FileContentIndex/7104b6c1-743e-4aa0-bd68-82beb31cfe6d.vsidx | 0 web/web/GwBlackMobile.ashx | 835 ++++++------ web/Dao/SysFlowNodeDao.cs | 2 web/web/gwdiverter.ashx | 350 ++-- web/Lib/Oracle.ManagedDataAccess.dll | 0 web/Dao/SysDictTypeDao.cs | 2 web/Dao/App.config | 28 web/packages/Oracle.ManagedDataAccess.19.18.0/LICENSE.txt | 42 web/Dao/GwMoRouteDao.cs | 2 web/Dao/SysRoleMenuDao.cs | 2 web/UMCLib/UMCLib.csproj | 4 web/Dao/GwRptCodeDao.cs | 2 web/.vs/Web/v16/.suo | 0 web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.transform | 4 web/Lib/Dao.dll.config | 28 web/Lib/App_Code.dll | 0 web/Dao/GwAuditCacheDao.cs | 2 web/Dao/GwStatisRefundDao.cs | 2 web/web/Bin/Dao.dll | 0 web/.vs/Web/FileContentIndex/0419d2ad-ced8-4447-bad9-7b5701b335d8.vsidx | 0 web/Dao/GwChargeLogDao.cs | 2 web/Dao/GwEventLogDao.cs | 2 web/web/GwTransfer.ashx | 2 web/Dao/Dao.csproj | 9 web/App_Code/App_Code.csproj | 7 web/App_Code/RegexHelper.cs | 13 web/web/Bin/App_Code.pdb | 0 web/web/Bin/Dao.pdb | 0 web/Dao/GwClientPayLogDao.cs | 2 web/Dao/SysOperationLogDao.cs | 2 web/packages/Oracle.ManagedDataAccess.19.18.0/PerfCounters/unregister_odpm_perfmon_counters.ps1 | 12 web/web/Bin/App_Code.dll | 0 web/Dao/GwStatisV3Dao.cs | 2 web/Dao/GwOpDao.cs | 2 web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.transform | 4 /dev/null | 0 web/Common/OracleReaderWrapper.cs | 2 web/Dao/GwBlackPoolDao.cs | 2 web/Lib/Common.dll.config | 28 web/Dao/GwStrategyDao.cs | 2 web/web/Bin/Model.pdb | 0 web/Dao/GwTransferDao.cs | 2 web/Common/packages.config | 4 web/Dao/GwDiverterDao.cs | 2 web/web/Bin/Model.dll | 0 web/Dao/GwClientProductDao.cs | 2 108 files changed, 3,175 insertions(+), 667 deletions(-) diff --git a/web/.vs/Web/FileContentIndex/0419d2ad-ced8-4447-bad9-7b5701b335d8.vsidx b/web/.vs/Web/FileContentIndex/0419d2ad-ced8-4447-bad9-7b5701b335d8.vsidx new file mode 100644 index 0000000..b2e5031 --- /dev/null +++ b/web/.vs/Web/FileContentIndex/0419d2ad-ced8-4447-bad9-7b5701b335d8.vsidx Binary files differ diff --git a/web/.vs/Web/FileContentIndex/1bc43914-da5e-4a96-8aec-a027603c8eb5.vsidx b/web/.vs/Web/FileContentIndex/1bc43914-da5e-4a96-8aec-a027603c8eb5.vsidx deleted file mode 100644 index e4e6ec9..0000000 --- a/web/.vs/Web/FileContentIndex/1bc43914-da5e-4a96-8aec-a027603c8eb5.vsidx +++ /dev/null Binary files differ diff --git a/web/.vs/Web/FileContentIndex/54ad995a-69de-48b5-8633-7a86a3b5b0e5.vsidx b/web/.vs/Web/FileContentIndex/54ad995a-69de-48b5-8633-7a86a3b5b0e5.vsidx deleted file mode 100644 index 0df3968..0000000 --- a/web/.vs/Web/FileContentIndex/54ad995a-69de-48b5-8633-7a86a3b5b0e5.vsidx +++ /dev/null Binary files differ diff --git a/web/.vs/Web/FileContentIndex/54d13018-9b98-4cb8-82e4-60d957fd21bd.vsidx b/web/.vs/Web/FileContentIndex/54d13018-9b98-4cb8-82e4-60d957fd21bd.vsidx deleted file mode 100644 index 4510951..0000000 --- a/web/.vs/Web/FileContentIndex/54d13018-9b98-4cb8-82e4-60d957fd21bd.vsidx +++ /dev/null Binary files differ diff --git a/web/.vs/Web/FileContentIndex/7104b6c1-743e-4aa0-bd68-82beb31cfe6d.vsidx b/web/.vs/Web/FileContentIndex/7104b6c1-743e-4aa0-bd68-82beb31cfe6d.vsidx new file mode 100644 index 0000000..4607b64 --- /dev/null +++ b/web/.vs/Web/FileContentIndex/7104b6c1-743e-4aa0-bd68-82beb31cfe6d.vsidx Binary files differ diff --git a/web/.vs/Web/FileContentIndex/79694cf4-4ab6-42a5-9a88-3040eca22d51.vsidx b/web/.vs/Web/FileContentIndex/79694cf4-4ab6-42a5-9a88-3040eca22d51.vsidx new file mode 100644 index 0000000..8b81979 --- /dev/null +++ b/web/.vs/Web/FileContentIndex/79694cf4-4ab6-42a5-9a88-3040eca22d51.vsidx Binary files differ diff --git a/web/.vs/Web/FileContentIndex/8f696eb1-6627-4ae6-821d-6d56c98f9654.vsidx b/web/.vs/Web/FileContentIndex/8f696eb1-6627-4ae6-821d-6d56c98f9654.vsidx new file mode 100644 index 0000000..ee3d074 --- /dev/null +++ b/web/.vs/Web/FileContentIndex/8f696eb1-6627-4ae6-821d-6d56c98f9654.vsidx Binary files differ diff --git a/web/.vs/Web/config/applicationhost.config b/web/.vs/Web/config/applicationhost.config index 88fe2ce..2e2a7ca 100644 --- a/web/.vs/Web/config/applicationhost.config +++ b/web/.vs/Web/config/applicationhost.config @@ -162,7 +162,7 @@ </site> <site name="web" id="2"> <application path="/" applicationPool="Clr4IntegratedAppPool"> - <virtualDirectory path="/" physicalPath="C:\Users\mac\Desktop\Work-Archives\SMGW\SMGW_NewWeb\web\web" /> + <virtualDirectory path="/" physicalPath="C:\Users\mac\Desktop\RDream\SMGW_NewWeb\web\web" /> </application> <bindings> <binding protocol="http" bindingInformation="*:60960:localhost" /> diff --git a/web/.vs/Web/v16/.suo b/web/.vs/Web/v16/.suo index 0521d24..d084a18 100644 --- a/web/.vs/Web/v16/.suo +++ b/web/.vs/Web/v16/.suo Binary files differ diff --git a/web/.vs/Web/v17/.suo b/web/.vs/Web/v17/.suo index 931cce9..d10b0cf 100644 --- a/web/.vs/Web/v17/.suo +++ b/web/.vs/Web/v17/.suo Binary files differ diff --git a/web/.vs/Web/v17/fileList.bin b/web/.vs/Web/v17/fileList.bin index d579fa4..2a9cf36 100644 --- a/web/.vs/Web/v17/fileList.bin +++ b/web/.vs/Web/v17/fileList.bin Binary files differ diff --git a/web/App_Code/App_Code.csproj b/web/App_Code/App_Code.csproj index bbef05b..0b40a65 100644 --- a/web/App_Code/App_Code.csproj +++ b/web/App_Code/App_Code.csproj @@ -13,11 +13,11 @@ <FileAlignment>512</FileAlignment> </PropertyGroup> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> - <PlatformTarget>x86</PlatformTarget> + <PlatformTarget>AnyCPU</PlatformTarget> <DebugSymbols>true</DebugSymbols> <DebugType>full</DebugType> <Optimize>false</Optimize> - <OutputPath>bin\Debug\</OutputPath> + <OutputPath>..\Lib\</OutputPath> <DefineConstants>DEBUG;TRACE</DefineConstants> <ErrorReport>prompt</ErrorReport> <WarningLevel>4</WarningLevel> @@ -55,8 +55,7 @@ <Compile Include="Const.cs" /> <Compile Include="WebTool.cs" /> <Compile Include="ZipUtils.cs" /> - <Compile Include="com\softwee\smgw\common\RegexHelper.cs" /> - <Compile Include="com\softwee\smgw\common\SegmentHelper.cs" /> + <Compile Include="RegexHelper.cs" /> <Compile Include="AssemblyInfo.cs" /> </ItemGroup> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> diff --git a/web/App_Code/com/softwee/smgw/common/RegexHelper.cs b/web/App_Code/RegexHelper.cs similarity index 93% rename from web/App_Code/com/softwee/smgw/common/RegexHelper.cs rename to web/App_Code/RegexHelper.cs index c5ed55e..7b609a8 100644 --- a/web/App_Code/com/softwee/smgw/common/RegexHelper.cs +++ b/web/App_Code/RegexHelper.cs @@ -1,10 +1,11 @@ -锘縩amespace com.softwee.smgw.common -{ - using System; - using System.Collections.Generic; - using System.Runtime.InteropServices; - using System.Text.RegularExpressions; +锘縰sing System; +using System.Collections.Generic; +using System.Runtime.InteropServices; +using System.Text.RegularExpressions; + +namespace App_Code +{ public abstract class RegexHelper { protected RegexHelper() diff --git a/web/App_Code/bin/Debug/App_Code.dll b/web/App_Code/bin/Debug/App_Code.dll index 3fe27c7..0002c93 100644 --- a/web/App_Code/bin/Debug/App_Code.dll +++ b/web/App_Code/bin/Debug/App_Code.dll Binary files differ diff --git a/web/App_Code/bin/Debug/App_Code.pdb b/web/App_Code/bin/Debug/App_Code.pdb index 251ff8e..16c946e 100644 --- a/web/App_Code/bin/Debug/App_Code.pdb +++ b/web/App_Code/bin/Debug/App_Code.pdb Binary files differ diff --git a/web/App_Code/com/softwee/smgw/common/SegmentHelper.cs b/web/App_Code/com/softwee/smgw/common/SegmentHelper.cs deleted file mode 100644 index fe84da3..0000000 --- a/web/App_Code/com/softwee/smgw/common/SegmentHelper.cs +++ /dev/null @@ -1,57 +0,0 @@ -锘�// Decompiled with JetBrains decompiler -// Type: com.softwee.smgw.common.SegmentHelper -// Assembly: App_Code, Version=0.0.0.0, Culture=neutral, PublicKeyToken=c1a16487c920c3dc -// MVID: 787A2D4B-0A31-4F54-A952-652B33850A5A -// Assembly location: C:\Users\Administrator\Desktop\ssss\bin\App_Code.dll - -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; - -namespace com.softwee.smgw.common -{ - public class SegmentHelper - { - public static string Filrate(string srcText) - { - if (string.IsNullOrEmpty(srcText)) - return string.Empty; - List<string> srcList = new List<string>(Enumerable.Distinct<string>((IEnumerable<string>) srcText.Split(Enumerable.ToArray<char>((IEnumerable<char>) "\r\n;,|"), StringSplitOptions.RemoveEmptyEntries))); - List<string> destList; - for (destList = new List<string>(); SegmentHelper.Merge(srcList, destList); destList = new List<string>()) - srcList = destList; - StringBuilder stringBuilder = new StringBuilder(); - foreach (string str in destList) - stringBuilder.AppendLine(str); - return stringBuilder.ToString(); - } - - private static bool Merge(List<string> srcList, List<string> destList) - { - foreach (string str in srcList.ToArray()) - { - if (str.Length > 5) - { - string s = str.Substring(0, str.Length - 1); - if (SegmentHelper.Remove(srcList, s)) - destList.Add(s); - } - } - destList.AddRange((IEnumerable<string>) srcList); - return srcList.Count != destList.Count; - } - - private static bool Remove(List<string> srcList, string s) - { - for (int index = 0; index < 10; ++index) - { - if (!srcList.Contains(s + (object) index)) - return false; - } - for (int index = 0; index < 10; ++index) - srcList.Remove(s + (object) index); - return true; - } - } -} diff --git a/web/Common/App.config b/web/Common/App.config new file mode 100644 index 0000000..9b01c9d --- /dev/null +++ b/web/Common/App.config @@ -0,0 +1,28 @@ +锘�<?xml version="1.0" encoding="utf-8"?> +<configuration> + <configSections> + <section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </configSections> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" /> + <add name="ODP.NET, Managed Driver" invariant="Oracle.ManagedDataAccess.Client" description="Oracle Data Provider for .NET, Managed Driver" type="Oracle.ManagedDataAccess.Client.OracleClientFactory, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </DbProviderFactories> + </system.data> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly> + <publisherPolicy apply="no" /> + <assemblyIdentity name="Oracle.ManagedDataAccess" publicKeyToken="89b483f429c47342" culture="neutral" /> + <bindingRedirect oldVersion="4.121.0.0 - 4.65535.65535.65535" newVersion="4.122.19.1" /> + </dependentAssembly> + </assemblyBinding> + </runtime> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " /> + </dataSources> + </version> + </oracle.manageddataaccess.client> +</configuration> \ No newline at end of file diff --git a/web/Common/Common.csproj b/web/Common/Common.csproj index 23e60fe..623a046 100644 --- a/web/Common/Common.csproj +++ b/web/Common/Common.csproj @@ -14,6 +14,8 @@ <OldToolsVersion>3.5</OldToolsVersion> <UpgradeBackupLocation> </UpgradeBackupLocation> + <NuGetPackageImportStamp> + </NuGetPackageImportStamp> </PropertyGroup> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> <PlatformTarget>AnyCPU</PlatformTarget> @@ -39,9 +41,8 @@ <SpecificVersion>False</SpecificVersion> <HintPath>..\web\Bin\Newtonsoft.Json.dll</HintPath> </Reference> - <Reference Include="Oracle.DataAccess, Version=2.112.1.0, Culture=neutral, PublicKeyToken=89b483f429c47342, processorArchitecture=x86"> - <SpecificVersion>False</SpecificVersion> - <HintPath>lib\Oracle.DataAccess.dll</HintPath> + <Reference Include="Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342, processorArchitecture=MSIL"> + <HintPath>..\packages\Oracle.ManagedDataAccess.19.18.0\lib\net40\Oracle.ManagedDataAccess.dll</HintPath> </Reference> <Reference Include="System.Data" /> <Reference Include="System" /> @@ -65,6 +66,7 @@ <Compile Include="OracleHelper.cs" /> <Compile Include="DESEncrypt.cs" /> <Compile Include="DataValidate.cs" /> + <Compile Include="SegmentHelper.cs" /> <Compile Include="XmlHelper.cs" /> <Compile Include="Utils.cs" /> <Compile Include="DataHelper.cs" /> @@ -78,5 +80,9 @@ <Compile Include="MyPage.cs" /> <Compile Include="AssemblyInfo.cs" /> </ItemGroup> + <ItemGroup> + <None Include="App.config" /> + <None Include="packages.config" /> + </ItemGroup> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> </Project> \ No newline at end of file diff --git a/web/Common/OracleHelper.cs b/web/Common/OracleHelper.cs index cc85e35..17bfde2 100644 --- a/web/Common/OracleHelper.cs +++ b/web/Common/OracleHelper.cs @@ -1,5 +1,6 @@ 锘� -using Oracle.DataAccess.Client; +//using Oracle.ManagedDataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections; using System.Collections.Generic; @@ -375,7 +376,7 @@ //鑰佺殑 -//using Oracle.DataAccess.Client; +//using Oracle.ManagedDataAccess.Client; //using System; //using System.Collections; //using System.Collections.Generic; diff --git a/web/Common/OracleReaderWrapper.cs b/web/Common/OracleReaderWrapper.cs index 6a74f6d..d83f513 100644 --- a/web/Common/OracleReaderWrapper.cs +++ b/web/Common/OracleReaderWrapper.cs @@ -1,5 +1,5 @@ 锘� -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Data.Common; diff --git a/web/Common/SegmentHelper.cs b/web/Common/SegmentHelper.cs new file mode 100644 index 0000000..2f11962 --- /dev/null +++ b/web/Common/SegmentHelper.cs @@ -0,0 +1,52 @@ +锘� +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace Common +{ + public class SegmentHelper + { + public static string Filrate(string srcText) + { + if (string.IsNullOrEmpty(srcText)) + return string.Empty; + List<string> srcList = new List<string>(Enumerable.Distinct<string>((IEnumerable<string>)srcText.Split(Enumerable.ToArray<char>((IEnumerable<char>)"\r\n;,|"), StringSplitOptions.RemoveEmptyEntries))); + List<string> destList; + for (destList = new List<string>(); SegmentHelper.Merge(srcList, destList); destList = new List<string>()) + srcList = destList; + StringBuilder stringBuilder = new StringBuilder(); + foreach (string str in destList) + stringBuilder.AppendLine(str); + return stringBuilder.ToString(); + } + + private static bool Merge(List<string> srcList, List<string> destList) + { + foreach (string str in srcList.ToArray()) + { + if (str.Length > 5) + { + string s = str.Substring(0, str.Length - 1); + if (SegmentHelper.Remove(srcList, s)) + destList.Add(s); + } + } + destList.AddRange((IEnumerable<string>)srcList); + return srcList.Count != destList.Count; + } + + private static bool Remove(List<string> srcList, string s) + { + for (int index = 0; index < 10; ++index) + { + if (!srcList.Contains(s + (object)index)) + return false; + } + for (int index = 0; index < 10; ++index) + srcList.Remove(s + (object)index); + return true; + } + } +} diff --git a/web/Common/packages.config b/web/Common/packages.config new file mode 100644 index 0000000..ea448cc --- /dev/null +++ b/web/Common/packages.config @@ -0,0 +1,4 @@ +锘�<?xml version="1.0" encoding="utf-8"?> +<packages> + <package id="Oracle.ManagedDataAccess" version="19.18.0" targetFramework="net40" /> +</packages> \ No newline at end of file diff --git a/web/Dao/App.config b/web/Dao/App.config new file mode 100644 index 0000000..9b01c9d --- /dev/null +++ b/web/Dao/App.config @@ -0,0 +1,28 @@ +锘�<?xml version="1.0" encoding="utf-8"?> +<configuration> + <configSections> + <section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </configSections> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" /> + <add name="ODP.NET, Managed Driver" invariant="Oracle.ManagedDataAccess.Client" description="Oracle Data Provider for .NET, Managed Driver" type="Oracle.ManagedDataAccess.Client.OracleClientFactory, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </DbProviderFactories> + </system.data> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly> + <publisherPolicy apply="no" /> + <assemblyIdentity name="Oracle.ManagedDataAccess" publicKeyToken="89b483f429c47342" culture="neutral" /> + <bindingRedirect oldVersion="4.121.0.0 - 4.65535.65535.65535" newVersion="4.122.19.1" /> + </dependentAssembly> + </assemblyBinding> + </runtime> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " /> + </dataSources> + </version> + </oracle.manageddataaccess.client> +</configuration> \ No newline at end of file diff --git a/web/Dao/Dao.csproj b/web/Dao/Dao.csproj index 110d560..1e706b6 100644 --- a/web/Dao/Dao.csproj +++ b/web/Dao/Dao.csproj @@ -54,9 +54,8 @@ <Reference Include="Common"> <HintPath>..\Lib\Common.dll</HintPath> </Reference> - <Reference Include="Oracle.DataAccess, Version=2.112.1.0, Culture=neutral, PublicKeyToken=89b483f429c47342, processorArchitecture=x86"> - <SpecificVersion>False</SpecificVersion> - <HintPath>..\Common\lib\Oracle.DataAccess.dll</HintPath> + <Reference Include="Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342, processorArchitecture=MSIL"> + <HintPath>..\packages\Oracle.ManagedDataAccess.19.18.0\lib\net40\Oracle.ManagedDataAccess.dll</HintPath> </Reference> <Reference Include="System.configuration" /> <Reference Include="System.Core"> @@ -164,5 +163,9 @@ <Name>Model</Name> </ProjectReference> </ItemGroup> + <ItemGroup> + <None Include="App.config" /> + <None Include="packages.config" /> + </ItemGroup> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> </Project> \ No newline at end of file diff --git a/web/Dao/GwAlarmDao.cs b/web/Dao/GwAlarmDao.cs index f9348cb..d9ea924 100644 --- a/web/Dao/GwAlarmDao.cs +++ b/web/Dao/GwAlarmDao.cs @@ -1,7 +1,7 @@ 锘� using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Data; using System.Data.Common; diff --git a/web/Dao/GwApDao.cs b/web/Dao/GwApDao.cs index b4d3ff1..655ea93 100644 --- a/web/Dao/GwApDao.cs +++ b/web/Dao/GwApDao.cs @@ -2,7 +2,7 @@ { using Common; using Model; - using Oracle.DataAccess.Client; + using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Runtime.InteropServices; @@ -217,7 +217,7 @@ /* using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwAuditCacheDao.cs b/web/Dao/GwAuditCacheDao.cs index c143d56..f3b2388 100644 --- a/web/Dao/GwAuditCacheDao.cs +++ b/web/Dao/GwAuditCacheDao.cs @@ -3,7 +3,7 @@ { using Common; using Model; - using Oracle.DataAccess.Client; + using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwBlackPoolDao.cs b/web/Dao/GwBlackPoolDao.cs index 32ec808..997ee95 100644 --- a/web/Dao/GwBlackPoolDao.cs +++ b/web/Dao/GwBlackPoolDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwChargeLogDao.cs b/web/Dao/GwChargeLogDao.cs index 3705ee7..421ccf1 100644 --- a/web/Dao/GwChargeLogDao.cs +++ b/web/Dao/GwChargeLogDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwClientCertificationDao.cs b/web/Dao/GwClientCertificationDao.cs index 650010f..ef249e6 100644 --- a/web/Dao/GwClientCertificationDao.cs +++ b/web/Dao/GwClientCertificationDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; namespace Dao { diff --git a/web/Dao/GwClientDao.cs b/web/Dao/GwClientDao.cs index 5414c9e..4b8cc89 100644 --- a/web/Dao/GwClientDao.cs +++ b/web/Dao/GwClientDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwClientPayLogDao.cs b/web/Dao/GwClientPayLogDao.cs index b0ae26c..570fa61 100644 --- a/web/Dao/GwClientPayLogDao.cs +++ b/web/Dao/GwClientPayLogDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwClientPayMentDao.cs b/web/Dao/GwClientPayMentDao.cs index 97db9ac..5d770c6 100644 --- a/web/Dao/GwClientPayMentDao.cs +++ b/web/Dao/GwClientPayMentDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwClientProductDao.cs b/web/Dao/GwClientProductDao.cs index 443b4b8..4bb2434 100644 --- a/web/Dao/GwClientProductDao.cs +++ b/web/Dao/GwClientProductDao.cs @@ -5,7 +5,7 @@ using System.Text; using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; namespace Dao { diff --git a/web/Dao/GwDiverterDao.cs b/web/Dao/GwDiverterDao.cs index a1862b0..9bb6fc6 100644 --- a/web/Dao/GwDiverterDao.cs +++ b/web/Dao/GwDiverterDao.cs @@ -1,7 +1,7 @@ 锘� using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwDmDao.cs b/web/Dao/GwDmDao.cs index 9e717d9..11c7df2 100644 --- a/web/Dao/GwDmDao.cs +++ b/web/Dao/GwDmDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwEventLogDao.cs b/web/Dao/GwEventLogDao.cs index 6ca777b..6cd6d20 100644 --- a/web/Dao/GwEventLogDao.cs +++ b/web/Dao/GwEventLogDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/GwMoRouteDao.cs b/web/Dao/GwMoRouteDao.cs index c7827d5..70ddcd8 100644 --- a/web/Dao/GwMoRouteDao.cs +++ b/web/Dao/GwMoRouteDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwMobileAreaDao.cs b/web/Dao/GwMobileAreaDao.cs index 6006c7b..63e232f 100644 --- a/web/Dao/GwMobileAreaDao.cs +++ b/web/Dao/GwMobileAreaDao.cs @@ -2,7 +2,7 @@ using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwOpDao.cs b/web/Dao/GwOpDao.cs index 0ec876f..7a1c08f 100644 --- a/web/Dao/GwOpDao.cs +++ b/web/Dao/GwOpDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwOpGroupDao.cs b/web/Dao/GwOpGroupDao.cs index fd6fc52..5bd2bf6 100644 --- a/web/Dao/GwOpGroupDao.cs +++ b/web/Dao/GwOpGroupDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwOrderAuditDao.cs b/web/Dao/GwOrderAuditDao.cs index 80e1014..f538d78 100644 --- a/web/Dao/GwOrderAuditDao.cs +++ b/web/Dao/GwOrderAuditDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/GwOrderDao.cs b/web/Dao/GwOrderDao.cs index 0614adc..7dcdcd4 100644 --- a/web/Dao/GwOrderDao.cs +++ b/web/Dao/GwOrderDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/GwProductDao.cs b/web/Dao/GwProductDao.cs index 4e0cc18..8b1dc00 100644 --- a/web/Dao/GwProductDao.cs +++ b/web/Dao/GwProductDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/GwRmDao.cs b/web/Dao/GwRmDao.cs index c123b54..f7df8ab 100644 --- a/web/Dao/GwRmDao.cs +++ b/web/Dao/GwRmDao.cs @@ -3,7 +3,7 @@ { using Common; using Model; - using Oracle.DataAccess.Client; + using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwRmResendDao.cs b/web/Dao/GwRmResendDao.cs index 15ee42f..b734ea4 100644 --- a/web/Dao/GwRmResendDao.cs +++ b/web/Dao/GwRmResendDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwRptCodeDao.cs b/web/Dao/GwRptCodeDao.cs index 43e834e..26d80b5 100644 --- a/web/Dao/GwRptCodeDao.cs +++ b/web/Dao/GwRptCodeDao.cs @@ -1,6 +1,6 @@ 锘� using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwSettingDao.cs b/web/Dao/GwSettingDao.cs index ba797b3..5823994 100644 --- a/web/Dao/GwSettingDao.cs +++ b/web/Dao/GwSettingDao.cs @@ -1,6 +1,6 @@ 锘� using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Data.Common; diff --git a/web/Dao/GwSmDao.cs b/web/Dao/GwSmDao.cs index b71aaef..e073abb 100644 --- a/web/Dao/GwSmDao.cs +++ b/web/Dao/GwSmDao.cs @@ -1,7 +1,7 @@ 锘�//鍖哄煙鏆傛椂娌℃湁鍐欏叆鏁版嵁搴� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwSpDao.cs b/web/Dao/GwSpDao.cs index afb0514..482c169 100644 --- a/web/Dao/GwSpDao.cs +++ b/web/Dao/GwSpDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwSpPrePatternDao.cs b/web/Dao/GwSpPrePatternDao.cs index d55dcc7..71f4f5a 100644 --- a/web/Dao/GwSpPrePatternDao.cs +++ b/web/Dao/GwSpPrePatternDao.cs @@ -1,6 +1,6 @@ 锘� using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwStatisDao.cs b/web/Dao/GwStatisDao.cs index f4ea2fa..42fa0b5 100644 --- a/web/Dao/GwStatisDao.cs +++ b/web/Dao/GwStatisDao.cs @@ -1,6 +1,6 @@ 锘� using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwStatisProfitDao.cs b/web/Dao/GwStatisProfitDao.cs index cda43c6..5cc1e11 100644 --- a/web/Dao/GwStatisProfitDao.cs +++ b/web/Dao/GwStatisProfitDao.cs @@ -1,6 +1,6 @@ 锘�//add鏂板姞2017-10-23 鍒╂鼎缁熻 using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data.Common; diff --git a/web/Dao/GwStatisRefundDao.cs b/web/Dao/GwStatisRefundDao.cs index 655e07f..4795390 100644 --- a/web/Dao/GwStatisRefundDao.cs +++ b/web/Dao/GwStatisRefundDao.cs @@ -1,6 +1,6 @@ 锘� using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwStatisV3Dao.cs b/web/Dao/GwStatisV3Dao.cs index dbedbcf..d06e0e8 100644 --- a/web/Dao/GwStatisV3Dao.cs +++ b/web/Dao/GwStatisV3Dao.cs @@ -3,7 +3,7 @@ using Model; using Newtonsoft.Json; using Newtonsoft.Json.Linq; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwStrategyDao.cs b/web/Dao/GwStrategyDao.cs index a88e4f5..71340b8 100644 --- a/web/Dao/GwStrategyDao.cs +++ b/web/Dao/GwStrategyDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/GwTransferDao.cs b/web/Dao/GwTransferDao.cs index f322fbe..d935996 100644 --- a/web/Dao/GwTransferDao.cs +++ b/web/Dao/GwTransferDao.cs @@ -4,7 +4,7 @@ using System.Text; using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data; using System.Data.Common; diff --git a/web/Dao/SysDictDataDao.cs b/web/Dao/SysDictDataDao.cs index 0451a85..84df31b 100644 --- a/web/Dao/SysDictDataDao.cs +++ b/web/Dao/SysDictDataDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/SysDictTypeDao.cs b/web/Dao/SysDictTypeDao.cs index 7a08eb2..a696822 100644 --- a/web/Dao/SysDictTypeDao.cs +++ b/web/Dao/SysDictTypeDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/SysFlowDao.cs b/web/Dao/SysFlowDao.cs index d6c127c..bac203c 100644 --- a/web/Dao/SysFlowDao.cs +++ b/web/Dao/SysFlowDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/SysFlowNodeDao.cs b/web/Dao/SysFlowNodeDao.cs index 767778d..c15abc8 100644 --- a/web/Dao/SysFlowNodeDao.cs +++ b/web/Dao/SysFlowNodeDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/SysOperationLogDao.cs b/web/Dao/SysOperationLogDao.cs index 1433c53..44cd9f8 100644 --- a/web/Dao/SysOperationLogDao.cs +++ b/web/Dao/SysOperationLogDao.cs @@ -1,7 +1,7 @@ 锘�//鐧婚檰鏃ュ織绋嬪簭 using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Data; using System.Data.Common; diff --git a/web/Dao/SysRoleMenuDao.cs b/web/Dao/SysRoleMenuDao.cs index 670f473..429946f 100644 --- a/web/Dao/SysRoleMenuDao.cs +++ b/web/Dao/SysRoleMenuDao.cs @@ -4,7 +4,7 @@ using System.Text; using Model; using Common; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System.Data.Common; namespace Dao diff --git a/web/Dao/SysXhDao.cs b/web/Dao/SysXhDao.cs index 64caa3a..8f95bf2 100644 --- a/web/Dao/SysXhDao.cs +++ b/web/Dao/SysXhDao.cs @@ -7,7 +7,7 @@ using Common; using Newtonsoft.Json; using Newtonsoft.Json.Linq; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Data; diff --git a/web/Dao/UserDao.cs b/web/Dao/UserDao.cs index 77aa6bb..5e39672 100644 --- a/web/Dao/UserDao.cs +++ b/web/Dao/UserDao.cs @@ -1,7 +1,7 @@ 锘� using Common; using Model; -using Oracle.DataAccess.Client; +using Oracle.ManagedDataAccess.Client; using System; using System.Collections.Generic; using System.Configuration; diff --git a/web/Dao/packages.config b/web/Dao/packages.config new file mode 100644 index 0000000..ea448cc --- /dev/null +++ b/web/Dao/packages.config @@ -0,0 +1,4 @@ +锘�<?xml version="1.0" encoding="utf-8"?> +<packages> + <package id="Oracle.ManagedDataAccess" version="19.18.0" targetFramework="net40" /> +</packages> \ No newline at end of file diff --git a/web/Lib/App_Code.dll b/web/Lib/App_Code.dll new file mode 100644 index 0000000..815ff01 --- /dev/null +++ b/web/Lib/App_Code.dll Binary files differ diff --git a/web/Lib/Aspose.Cells.dll b/web/Lib/Aspose.Cells.dll new file mode 100644 index 0000000..13cbd9d --- /dev/null +++ b/web/Lib/Aspose.Cells.dll Binary files differ diff --git a/web/Lib/Common.dll b/web/Lib/Common.dll index debaf88..38094bf 100644 --- a/web/Lib/Common.dll +++ b/web/Lib/Common.dll Binary files differ diff --git a/web/Lib/Common.dll.config b/web/Lib/Common.dll.config new file mode 100644 index 0000000..9b01c9d --- /dev/null +++ b/web/Lib/Common.dll.config @@ -0,0 +1,28 @@ +锘�<?xml version="1.0" encoding="utf-8"?> +<configuration> + <configSections> + <section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </configSections> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" /> + <add name="ODP.NET, Managed Driver" invariant="Oracle.ManagedDataAccess.Client" description="Oracle Data Provider for .NET, Managed Driver" type="Oracle.ManagedDataAccess.Client.OracleClientFactory, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </DbProviderFactories> + </system.data> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly> + <publisherPolicy apply="no" /> + <assemblyIdentity name="Oracle.ManagedDataAccess" publicKeyToken="89b483f429c47342" culture="neutral" /> + <bindingRedirect oldVersion="4.121.0.0 - 4.65535.65535.65535" newVersion="4.122.19.1" /> + </dependentAssembly> + </assemblyBinding> + </runtime> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " /> + </dataSources> + </version> + </oracle.manageddataaccess.client> +</configuration> \ No newline at end of file diff --git a/web/Lib/Common.pdb b/web/Lib/Common.pdb index be293b9..97663e8 100644 --- a/web/Lib/Common.pdb +++ b/web/Lib/Common.pdb Binary files differ diff --git a/web/Lib/Dao.dll b/web/Lib/Dao.dll index 0370d65..1c149ac 100644 --- a/web/Lib/Dao.dll +++ b/web/Lib/Dao.dll Binary files differ diff --git a/web/Lib/Dao.dll.config b/web/Lib/Dao.dll.config new file mode 100644 index 0000000..9b01c9d --- /dev/null +++ b/web/Lib/Dao.dll.config @@ -0,0 +1,28 @@ +锘�<?xml version="1.0" encoding="utf-8"?> +<configuration> + <configSections> + <section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </configSections> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" /> + <add name="ODP.NET, Managed Driver" invariant="Oracle.ManagedDataAccess.Client" description="Oracle Data Provider for .NET, Managed Driver" type="Oracle.ManagedDataAccess.Client.OracleClientFactory, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </DbProviderFactories> + </system.data> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly> + <publisherPolicy apply="no" /> + <assemblyIdentity name="Oracle.ManagedDataAccess" publicKeyToken="89b483f429c47342" culture="neutral" /> + <bindingRedirect oldVersion="4.121.0.0 - 4.65535.65535.65535" newVersion="4.122.19.1" /> + </dependentAssembly> + </assemblyBinding> + </runtime> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " /> + </dataSources> + </version> + </oracle.manageddataaccess.client> +</configuration> \ No newline at end of file diff --git a/web/Lib/Dao.pdb b/web/Lib/Dao.pdb index 8693fc8..b283ec3 100644 --- a/web/Lib/Dao.pdb +++ b/web/Lib/Dao.pdb Binary files differ diff --git a/web/Lib/Ionic.Zip.dll b/web/Lib/Ionic.Zip.dll new file mode 100644 index 0000000..95fa928 --- /dev/null +++ b/web/Lib/Ionic.Zip.dll Binary files differ diff --git a/web/Lib/Model.dll b/web/Lib/Model.dll index dc67266..d380f8b 100644 --- a/web/Lib/Model.dll +++ b/web/Lib/Model.dll Binary files differ diff --git a/web/Lib/Model.pdb b/web/Lib/Model.pdb index 61d8d0d..088ca1c 100644 --- a/web/Lib/Model.pdb +++ b/web/Lib/Model.pdb Binary files differ diff --git a/web/Lib/Oracle.ManagedDataAccess.dll b/web/Lib/Oracle.ManagedDataAccess.dll new file mode 100644 index 0000000..993f911 --- /dev/null +++ b/web/Lib/Oracle.ManagedDataAccess.dll Binary files differ diff --git a/web/UMCLib/UMCLib.csproj b/web/UMCLib/UMCLib.csproj index e46c516..e12e526 100644 --- a/web/UMCLib/UMCLib.csproj +++ b/web/UMCLib/UMCLib.csproj @@ -16,11 +16,11 @@ </UpgradeBackupLocation> </PropertyGroup> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> - <PlatformTarget>x86</PlatformTarget> + <PlatformTarget>AnyCPU</PlatformTarget> <DebugSymbols>true</DebugSymbols> <DebugType>full</DebugType> <Optimize>false</Optimize> - <OutputPath>bin\Debug\</OutputPath> + <OutputPath>..\Lib\</OutputPath> <DefineConstants>DEBUG;TRACE</DefineConstants> <ErrorReport>prompt</ErrorReport> <WarningLevel>4</WarningLevel> diff --git a/web/UMCLib/bin/Debug/UMCLib.dll b/web/UMCLib/bin/Debug/UMCLib.dll index 7b4e055..0c278f0 100644 --- a/web/UMCLib/bin/Debug/UMCLib.dll +++ b/web/UMCLib/bin/Debug/UMCLib.dll Binary files differ diff --git a/web/UMCLib/bin/Debug/UMCLib.pdb b/web/UMCLib/bin/Debug/UMCLib.pdb index dec77ed..d690289 100644 --- a/web/UMCLib/bin/Debug/UMCLib.pdb +++ b/web/UMCLib/bin/Debug/UMCLib.pdb Binary files differ diff --git a/web/Web.sln b/web/Web.sln index 1e8c964..db24bb6 100644 --- a/web/Web.sln +++ b/web/Web.sln @@ -1,12 +1,19 @@ 锘� Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 16 -VisualStudioVersion = 16.0.30503.244 +# Visual Studio Version 17 +VisualStudioVersion = 17.4.33122.133 MinimumVisualStudioVersion = 10.0.40219.1 Project("{E24C65DC-7377-472B-9ABA-BC803B73C61A}") = "web", "web\", "{793502B1-551F-4952-9C70-F20BAF89A3EA}" + ProjectSection(ProjectDependencies) = postProject + {6199DC29-D043-41B0-BDFD-AFA19ADC7848} = {6199DC29-D043-41B0-BDFD-AFA19ADC7848} + {C291753C-6A49-4705-B565-A830C43B4189} = {C291753C-6A49-4705-B565-A830C43B4189} + {337CD576-BA09-4182-9FDD-8F1AB1B30624} = {337CD576-BA09-4182-9FDD-8F1AB1B30624} + {D0CDBF9C-D79A-434F-ADB0-0A58B7B5E1D6} = {D0CDBF9C-D79A-434F-ADB0-0A58B7B5E1D6} + {AA804FAB-0293-4EB3-BF43-8103F1CC93F5} = {AA804FAB-0293-4EB3-BF43-8103F1CC93F5} + EndProjectSection ProjectSection(WebsiteProperties) = preProject TargetFrameworkMoniker = ".NETFramework,Version%3Dv4.0" - ProjectReferences = "{AA804FAB-0293-4EB3-BF43-8103F1CC93F5}|UMCLib.dll;{D0CDBF9C-D79A-434F-ADB0-0A58B7B5E1D6}|Dao.dll;{6199DC29-D043-41B0-BDFD-AFA19ADC7848}|App_Code.dll;{337CD576-BA09-4182-9FDD-8F1AB1B30624}|Model.dll;" + ProjectReferences = "" Debug.AspNetCompiler.VirtualPath = "/Web" Debug.AspNetCompiler.PhysicalPath = "Web\" Debug.AspNetCompiler.TargetPath = "PrecompiledWeb\Web\" @@ -24,13 +31,6 @@ VWDPort = "60960" SlnRelativePath = "web\" DefaultWebSiteLanguage = "Visual C#" - EndProjectSection - ProjectSection(ProjectDependencies) = postProject - {6199DC29-D043-41B0-BDFD-AFA19ADC7848} = {6199DC29-D043-41B0-BDFD-AFA19ADC7848} - {C291753C-6A49-4705-B565-A830C43B4189} = {C291753C-6A49-4705-B565-A830C43B4189} - {337CD576-BA09-4182-9FDD-8F1AB1B30624} = {337CD576-BA09-4182-9FDD-8F1AB1B30624} - {D0CDBF9C-D79A-434F-ADB0-0A58B7B5E1D6} = {D0CDBF9C-D79A-434F-ADB0-0A58B7B5E1D6} - {AA804FAB-0293-4EB3-BF43-8103F1CC93F5} = {AA804FAB-0293-4EB3-BF43-8103F1CC93F5} EndProjectSection EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Common", "Common\Common.csproj", "{C291753C-6A49-4705-B565-A830C43B4189}" diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/.signature.p7s b/web/packages/Oracle.ManagedDataAccess.19.18.0/.signature.p7s new file mode 100644 index 0000000..63eb3ab --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/.signature.p7s Binary files differ diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/LICENSE.txt b/web/packages/Oracle.ManagedDataAccess.19.18.0/LICENSE.txt new file mode 100644 index 0000000..431332a --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/LICENSE.txt @@ -0,0 +1,42 @@ +Your use of this Program is governed by the Oracle Free Distribution, Hosting, and Use Terms and Conditions set forth below, unless you have received this Program (alone or as part of another Oracle product) under an Oracle license agreement (including but not limited to the Oracle Master Agreement), in which case your use of this Program is governed solely by such license agreement with Oracle. + +Oracle Free Distribution, Hosting, and Use Terms and Conditions +Definitions +"Oracle" refers to Oracle America, Inc. "You" and "Your" refers to (a) a company or organization (each an "Entity") accessing the Programs, if use of the Programs will be on behalf of such Entity; or (b) an individual accessing the Programs, if use of the Programs will not be on behalf of an Entity. "Program(s)" refers to Oracle software provided by Oracle pursuant to the following terms and any updates, error corrections, and/or Program Documentation provided by Oracle. "Program Documentation" refers to Program user manuals and Program installation manuals, if any. If available, Program Documentation may be delivered with the Programs and/or may be accessed from www.oracle.com/documentation. "Separate Terms" refers to separate license terms that are specified in the Program Documentation, readmes or notice files and that apply to Separately Licensed Technology. "Separately Licensed Technology" refers to Oracle or third party technology that is licensed under Separate Terms and not under the terms of this license. + +Separately Licensed Technology +Oracle may provide certain notices to You in Program Documentation, readmes or notice files in connection with Oracle or third party technology provided as or with the Programs. If specified in the Program Documentation, readmes or notice files, such technology will be licensed to You under Separate Terms. Your rights to use Separately Licensed Technology under Separate Terms are not restricted in any way by the terms herein. For clarity, notwithstanding the existence of a notice, third party technology that is not Separately Licensed Technology shall be deemed part of the Programs licensed to You under the terms of this license. + +Source Code for Open Source Software +For software that You receive from Oracle in binary form that is licensed under an open source license that gives You the right to receive the source code for that binary, You can obtain a copy of the applicable source code from https://oss.oracle.com/sources/ or http://www.oracle.com/goto/opensourcecode. If the source code for such software was not provided to You with the binary, You can also receive a copy of the source code on physical media by submitting a written request pursuant to the instructions in the "Written Offer for Source Code" section of the latter website. + +------------------------------------------------------------------------------- +The following license terms apply to those Programs that are not provided to You under Separate Terms. +License Rights and Restrictions +Oracle grants to You, as a recipient of this Program, a nonexclusive, nontransferable, limited license to, subject to the conditions stated herein, use the unmodified Programs, including, without limitation, for the purposes of: +鈥� developing, testing, prototyping and demonstrating applications; +鈥� running the unmodified Programs for training, personal use, your business operations, and the business operations of third parties; +鈥� making the unmodified Programs available for use by third parties in your hosted environment and in cloud services; +鈥� redistributing unmodified Programs and Programs Documentation under the terms of this License; and +鈥� copying the unmodified Programs and Program Documentation to the extent reasonably necessary to exercise the license rights granted herein and for backup purposes. +For the purposes of this license, compiling, interpreting or configuring an otherwise unmodified Program as necessary to run the Program shall not be considered modification. + +Your license is contingent on Your compliance with the following conditions: +- You include a copy of this license with any distribution by You of the Programs; +- You do not charge your customers, end users, distributees or other third parties any additional fees for the distribution or use of the Programs; however, for clarity, if you comply with the foregoing condition, distribution or use of the Program as part of your for-fee product or service that adds substantial additional value is permitted; +- You do not remove markings or notices of either Oracle's or a licensor's proprietary rights from the Programs or Program Documentation; +- You comply with all U.S. and applicable export control and economic sanctions laws and regulations that govern Your use of the Programs (including technical data); and +- You do not cause or permit reverse engineering, disassembly or decompilation of the Programs (except as allowed by law) by You nor allow an associated party to do so. +Any source code that may be included in the distribution with the Programs may not be modified, unless such source code is under Separate Terms permitting modification. +Ownership +Oracle or its licensors retain all ownership and intellectual property rights to the Programs. + +Information Collection +The Programs' installation and/or auto-update processes, if any, may transmit a limited amount of data to Oracle or its service provider about those processes to help Oracle understand and optimize them. Oracle does not associate the data with personally identifiable information. Refer to Oracle's Privacy Policy at www.oracle.com/privacy. + +Disclaimer of Warranties; Limitation of Liability +THE PROGRAMS ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. ORACLE FURTHER DISCLAIMS ALL WARRANTIES, EXPRESS AND IMPLIED, INCLUDING WITHOUT LIMITATION, ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NONINFRINGEMENT. +IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW WILL ORACLE BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +Version 1.0 +Last updated: 28 June 2022 diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/PerfCounters/register_odpm_perfmon_counters.ps1 b/web/packages/Oracle.ManagedDataAccess.19.18.0/PerfCounters/register_odpm_perfmon_counters.ps1 new file mode 100644 index 0000000..b8a6bff --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/PerfCounters/register_odpm_perfmon_counters.ps1 @@ -0,0 +1,41 @@ +$categoryName = "ODP.NET, Managed Driver" +try{ +$categoryHelp = "$categoryName Performance Counter" +$categoryType = [System.Diagnostics.PerformanceCounterCategoryType]::MultiInstance +$categoryExists_reg = [System.Diagnostics.PerformanceCounterCategory]::Exists($categoryName) +if($categoryExists_reg) +{ +[System.Diagnostics.PerformanceCounterCategory]::Delete($categoryName) +} +$counterCreationDataList = New-Object -TypeName System.Diagnostics.CounterCreationDataCollection +$counterCreationDataList.Clear() +$RateOfCountsPerSecond64 = [System.Diagnostics.PerformanceCounterType]::RateOfCountsPerSecond64 +$NumberOfItems64 = [System.Diagnostics.PerformanceCounterType]::NumberOfItems64 +$counterCreationData1 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'HardConnectsPerSecond', [string]::Empty, $RateOfCountsPerSecond64 +$counterCreationData2 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'HardDisconnectsPerSecond', [string]::Empty, $RateOfCountsPerSecond64 +$counterCreationData3 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'SoftConnectsPerSecond', [string]::Empty, $RateOfCountsPerSecond64 +$counterCreationData4 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'SoftDisconnectsPerSecond', [string]::Empty, $RateOfCountsPerSecond64 +$counterCreationData5 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'NumberOfActiveConnectionPools', [string]::Empty, $NumberOfItems64 +$counterCreationData6 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'NumberOfInactiveConnectionPools',[string]::Empty, $NumberOfItems64 +$counterCreationData7 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'NumberOfActiveConnections', [string]::Empty, $NumberOfItems64 +$counterCreationData8 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'NumberOfFreeConnections', [string]::Empty, $NumberOfItems64 +$counterCreationData9 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'NumberOfPooledConnections', [string]::Empty, $NumberOfItems64 +$counterCreationData10 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'NumberOfNonPooledConnections', [string]::Empty, $NumberOfItems64 +$counterCreationData11 = New-Object -TypeName System.Diagnostics.CounterCreationData -ArgumentList 'NumberOfReclaimedConnections', [string]::Empty, $NumberOfItems64 +$counterCreationDataList.Add($counterCreationData1) | out-null +$counterCreationDataList.Add($counterCreationData2) | out-null +$counterCreationDataList.Add($counterCreationData3) | out-null +$counterCreationDataList.Add($counterCreationData4) | out-null +$counterCreationDataList.Add($counterCreationData5) | out-null +$counterCreationDataList.Add($counterCreationData6) | out-null +$counterCreationDataList.Add($counterCreationData7) | out-null +$counterCreationDataList.Add($counterCreationData8) | out-null +$counterCreationDataList.Add($counterCreationData9) | out-null +$counterCreationDataList.Add($counterCreationData10) | out-null +$counterCreationDataList.Add($counterCreationData11) | out-null +[System.Diagnostics.PerformanceCounterCategory]::Create($categoryName, $categoryHelp, $categoryType, $counterCreationDataList) | out-null +write-host("$categoryHelp was registered successfullly.") +} +catch{ +write-host("ERROR: $categoryHelp registration failed.") +} \ No newline at end of file diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/PerfCounters/unregister_odpm_perfmon_counters.ps1 b/web/packages/Oracle.ManagedDataAccess.19.18.0/PerfCounters/unregister_odpm_perfmon_counters.ps1 new file mode 100644 index 0000000..10277b9 --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/PerfCounters/unregister_odpm_perfmon_counters.ps1 @@ -0,0 +1,12 @@ +$categoryName = "ODP.NET, Managed Driver" +try{ +$categoryExists_unreg = [System.Diagnostics.PerformanceCounterCategory]::Exists($categoryName) +if($categoryExists_unreg) +{ +[System.Diagnostics.PerformanceCounterCategory]::Delete($categoryName) | out-null +} +write-host("$categoryName Performance Counter was un-registered successfullly.") +} +catch{ +write-host("ERROR: $categoryName Performance Counter un-registration failed.") +} diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.install.xdt b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.install.xdt new file mode 100644 index 0000000..91ec1c1 --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.install.xdt @@ -0,0 +1,115 @@ +<?xml version="1.0"?> +<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform"> + + <configSections xdt:Transform="InsertIfMissing"> + </configSections> + + <configSections xdt:Transform="InsertBefore(/configuration/*[1])"> + </configSections> + + <!-- remove existing entry --> + <configSections xdt:Locator="XPath(/configuration/configSections[last()])"> + <section name="oracle.manageddataaccess.client" xdt:Transform="Remove" xdt:Locator="Match(name)" /> + </configSections> + + <!-- insert new entry --> + <configSections xdt:Locator="XPath(/configuration/configSections[last()])"> + <section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" xdt:Transform="Insert" /> + </configSections> + + <configSections xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + + <!-- If system.data tag is absent --> + <system.data xdt:Transform="InsertIfMissing"> + <DbProviderFactories> + </DbProviderFactories> + </system.data> + + <!-- If system.data tag is present, but DbProviderFactories tag is absent --> + <system.data> + <DbProviderFactories xdt:Transform="InsertIfMissing"> + </DbProviderFactories> + </system.data> + + <!-- remove existing ODPM entry --> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" xdt:Transform="Remove" xdt:Locator="Match(invariant)" /> + <add name="ODP.NET, Managed Driver" xdt:Transform="Remove" xdt:Locator="Match(name)" /> + </DbProviderFactories> + </system.data> + + <!-- add new ODPM entry --> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" xdt:Transform="Insert"/> + <add name="ODP.NET, Managed Driver" invariant="Oracle.ManagedDataAccess.Client" description="Oracle Data Provider for .NET, Managed Driver" type="Oracle.ManagedDataAccess.Client.OracleClientFactory, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" xdt:Transform="Insert" /> + </DbProviderFactories> + </system.data> + + <!-- If runtime tag is absent --> + <runtime xdt:Transform="InsertIfMissing"> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + </assemblyBinding> + </runtime> + + <!-- If runtime tag is present, but assembly binding tag is absent --> + <runtime> + <assemblyBinding xdt:Transform="InsertIfMissing" xmlns="urn:schemas-microsoft-com:asm.v1"> + </assemblyBinding> + </runtime> + + <!-- remove existing entry --> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly xdt:Transform="Remove" + xdt:Locator="Condition(./_defaultNamespace:assemblyIdentity/@name='Oracle.ManagedDataAccess')" > + </dependentAssembly> + </assemblyBinding> + </runtime> + + <!-- insert new entry --> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly xdt:Transform="Insert"> + <publisherPolicy apply="no"/> + <assemblyIdentity name="Oracle.ManagedDataAccess" publicKeyToken="89b483f429c47342" culture="neutral" /> + <bindingRedirect oldVersion="4.121.0.0 - 4.65535.65535.65535" newVersion="4.122.19.1" /> + </dependentAssembly> + </assemblyBinding> + </runtime> + + <!-- If oracle.manageddataaccess.client tag is absent --> + <oracle.manageddataaccess.client xdt:Transform="InsertIfMissing"> + <version number="*"> + <dataSources> + </dataSources> + </version> + </oracle.manageddataaccess.client> + + <!-- If version tag is absent --> + <oracle.manageddataaccess.client> + <version number="*" xdt:Transform="InsertIfMissing"> + <dataSources> + </dataSources> + </version> + </oracle.manageddataaccess.client> + + <!-- If dataSources tag is absent --> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources xdt:Transform="InsertIfMissing"> + </dataSources> + </version> + </oracle.manageddataaccess.client> + + <!-- add entry if missing --> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " xdt:Transform="InsertIfMissing" xdt:Locator="Match(alias)"/> + </dataSources> + </version> + </oracle.manageddataaccess.client> + +</configuration> diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.transform b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.transform new file mode 100644 index 0000000..bfd5378 --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.transform @@ -0,0 +1,4 @@ +锘�<configuration> + <configSections> + </configSections> +</configuration> diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.uninstall.xdt b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.uninstall.xdt new file mode 100644 index 0000000..b14b77b --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/App.config.uninstall.xdt @@ -0,0 +1,64 @@ +<?xml version="1.0"?> +<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform"> + + <!-- remove existing entry --> + <configSections> + <section name="oracle.manageddataaccess.client" xdt:Transform="Remove" xdt:Locator="Match(name)" /> + </configSections> + + <!-- remove if section is empty --> + <configSections xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + + <!-- remove existing entry --> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" xdt:Transform="Remove" xdt:Locator="Match(invariant)" /> + <add name="ODP.NET, Managed Driver" xdt:Transform="Remove" xdt:Locator="Match(name)" /> + </DbProviderFactories> + </system.data> + + <!-- remove if section is empty --> + <system.data> + <DbProviderFactories xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + </system.data> + <system.data xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + + <!-- remove existing entry --> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly xdt:Transform="Remove" + xdt:Locator="Condition(./_defaultNamespace:assemblyIdentity/@name='Oracle.ManagedDataAccess')" > + </dependentAssembly> + </assemblyBinding> + </runtime> + + <!-- remove if section is empty --> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1" xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + </runtime> + <runtime xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + + <!-- remove existing entry --> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " xdt:Transform="Remove" xdt:Locator="Match(alias)"/> + </dataSources> + </version> + </oracle.manageddataaccess.client> + + <!-- remove if section is empty --> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + </version> + </oracle.manageddataaccess.client> + + <!-- remove existing entry --> + <oracle.manageddataaccess.client> + <version number="*" xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + </oracle.manageddataaccess.client> + + <oracle.manageddataaccess.client xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + +</configuration> diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.install.xdt b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.install.xdt new file mode 100644 index 0000000..08b1469 --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.install.xdt @@ -0,0 +1,114 @@ +<?xml version="1.0"?> +<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform"> + + <configSections xdt:Transform="InsertIfMissing"> + </configSections> + + <configSections xdt:Transform="InsertBefore(/configuration/*[1])"> + </configSections> + + <!-- remove existing entry --> + <configSections xdt:Locator="XPath(/configuration/configSections[last()])"> + <section name="oracle.manageddataaccess.client" xdt:Transform="Remove" xdt:Locator="Match(name)" /> + </configSections> + + <!-- insert new entry --> + <configSections xdt:Locator="XPath(/configuration/configSections[last()])"> + <section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" xdt:Transform="Insert" /> + </configSections> + + <configSections xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + + <!-- If system.data tag is absent --> + <system.data xdt:Transform="InsertIfMissing"> + <DbProviderFactories> + </DbProviderFactories> + </system.data> + + <!-- If system.data tag is present, but DbProviderFactories tag is absent --> + <system.data> + <DbProviderFactories xdt:Transform="InsertIfMissing"> + </DbProviderFactories> + </system.data> + + <!-- remove existing ODPM entry --> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" xdt:Transform="Remove" xdt:Locator="Match(invariant)" /> + <add name="ODP.NET, Managed Driver" xdt:Transform="Remove" xdt:Locator="Match(name)" /> + </DbProviderFactories> + </system.data> + + <!-- add new ODPM entry --> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" xdt:Transform="Insert"/> + <add name="ODP.NET, Managed Driver" invariant="Oracle.ManagedDataAccess.Client" description="Oracle Data Provider for .NET, Managed Driver" type="Oracle.ManagedDataAccess.Client.OracleClientFactory, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" xdt:Transform="Insert" /> + </DbProviderFactories> + </system.data> + + <!-- If runtime tag is absent --> + <runtime xdt:Transform="InsertIfMissing"> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + </assemblyBinding> + </runtime> + + <!-- If runtime tag is present, but assembly binding tag is absent --> + <runtime> + <assemblyBinding xdt:Transform="InsertIfMissing" xmlns="urn:schemas-microsoft-com:asm.v1"> + </assemblyBinding> + </runtime> + + <!-- remove existing entry --> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly xdt:Transform="Remove" + xdt:Locator="Condition(./_defaultNamespace:assemblyIdentity/@name='Oracle.ManagedDataAccess')" > + </dependentAssembly> + </assemblyBinding> + </runtime> + + <!-- insert new entry --> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly xdt:Transform="Insert"> + <publisherPolicy apply="no"/> + <assemblyIdentity name="Oracle.ManagedDataAccess" publicKeyToken="89b483f429c47342" culture="neutral" /> + </dependentAssembly> + </assemblyBinding> + </runtime> + + <!-- If oracle.manageddataaccess.client tag is absent --> + <oracle.manageddataaccess.client xdt:Transform="InsertIfMissing"> + <version number="*"> + <dataSources> + </dataSources> + </version> + </oracle.manageddataaccess.client> + + <!-- If version tag is absent --> + <oracle.manageddataaccess.client> + <version number="*" xdt:Transform="InsertIfMissing"> + <dataSources> + </dataSources> + </version> + </oracle.manageddataaccess.client> + + <!-- If dataSources tag is absent --> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources xdt:Transform="InsertIfMissing"> + </dataSources> + </version> + </oracle.manageddataaccess.client> + + <!-- add entry if missing --> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " xdt:Transform="InsertIfMissing" xdt:Locator="Match(alias)"/> + </dataSources> + </version> + </oracle.manageddataaccess.client> + +</configuration> diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.transform b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.transform new file mode 100644 index 0000000..bfd5378 --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.transform @@ -0,0 +1,4 @@ +锘�<configuration> + <configSections> + </configSections> +</configuration> diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.uninstall.xdt b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.uninstall.xdt new file mode 100644 index 0000000..b14b77b --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/content/net40/Web.config.uninstall.xdt @@ -0,0 +1,64 @@ +<?xml version="1.0"?> +<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform"> + + <!-- remove existing entry --> + <configSections> + <section name="oracle.manageddataaccess.client" xdt:Transform="Remove" xdt:Locator="Match(name)" /> + </configSections> + + <!-- remove if section is empty --> + <configSections xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + + <!-- remove existing entry --> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" xdt:Transform="Remove" xdt:Locator="Match(invariant)" /> + <add name="ODP.NET, Managed Driver" xdt:Transform="Remove" xdt:Locator="Match(name)" /> + </DbProviderFactories> + </system.data> + + <!-- remove if section is empty --> + <system.data> + <DbProviderFactories xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + </system.data> + <system.data xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + + <!-- remove existing entry --> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly xdt:Transform="Remove" + xdt:Locator="Condition(./_defaultNamespace:assemblyIdentity/@name='Oracle.ManagedDataAccess')" > + </dependentAssembly> + </assemblyBinding> + </runtime> + + <!-- remove if section is empty --> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1" xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + </runtime> + <runtime xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + + <!-- remove existing entry --> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " xdt:Transform="Remove" xdt:Locator="Match(alias)"/> + </dataSources> + </version> + </oracle.manageddataaccess.client> + + <!-- remove if section is empty --> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + </version> + </oracle.manageddataaccess.client> + + <!-- remove existing entry --> + <oracle.manageddataaccess.client> + <version number="*" xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + </oracle.manageddataaccess.client> + + <oracle.manageddataaccess.client xdt:Transform="RemoveAll" xdt:Locator="Condition(count(*)=0)" /> + +</configuration> diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/info.txt b/web/packages/Oracle.ManagedDataAccess.19.18.0/info.txt new file mode 100644 index 0000000..31db3c7 --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/info.txt @@ -0,0 +1,296 @@ +The following software may be included in Oracle Data Provider for .NET: + +Kerberos + +Copyright (C) 1985-2010 by the Massachusetts Institute of Technology. + +All rights reserved. + +Export of this software from the United States of America may require a specific license from the United States Government. It is the responsibility of any person or organization contemplating export to obtain such a license before exporting. + +WITHIN THAT CONSTRAINT, permission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of M.I.T. not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. Furthermore if you modify this software you must label your software as modified software and not distribute it in such a fashion that it might be confused with the original MIT software. M.I.T. makes no representations about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty. + +THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. + +Individual source code files are copyright MIT, Cygnus Support, Novell, OpenVision Technologies, Oracle, Red Hat, Sun Microsystems, FundsXpress, and others. + +Project Athena, Athena, Athena MUSE, Discuss, Hesiod, Kerberos, Moira, and Zephyr are trademarks of the Massachusetts Institute of Technology (MIT). No commercial use of these trademarks may be made without prior written permission of MIT. + +"Commercial use" means use of a name in a product or other for-profit manner. It does NOT prevent a commercial firm from referring to the MIT trademarks in order to convey information (although in doing so, recognition of their trademark status should be given). + +----------------------------------------- + +Portions of src/lib/crypto have the following copyright: + +Copyright (C) 1998 by the FundsXpress, INC. + +All rights reserved. + +Export of this software from the United States of America may require a specific license from the United States Government. It is the responsibility of any person or organization contemplating export to obtain such a license before exporting. + +WITHIN THAT CONSTRAINT, permission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of FundsXpress. not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. FundsXpress makes no representations about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty. + +THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. + +----------------------------------------- + +The following copyright and permission notice applies to the OpenVision Kerberos Administration system located in kadmin/create, kadmin/dbutil, kadmin/passwd, kadmin/server, lib/kadm5, and portions of lib/rpc: + +Copyright, OpenVision Technologies, Inc., 1996, All Rights Reserved + +WARNING: Retrieving the OpenVision Kerberos Administration system source code, as described below, indicates your acceptance of the following terms. If you do not agree to the following terms, do not retrieve the OpenVision Kerberos administration system. + +You may freely use and distribute the Source Code and Object Code compiled from it, with or without modification, but this Source Code is provided to you "AS IS" EXCLUSIVE OF ANY WARRANTY, INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, OR ANY OTHER WARRANTY, WHETHER EXPRESS OR IMPLIED. IN NO EVENT WILL OPENVISION HAVE ANY LIABILITY FOR ANY LOST PROFITS, LOSS OF DATA OR COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY SPECIAL, INDIRECT, OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, INCLUDING, WITHOUT LIMITATION, THOSE RESULTING FROM THE USE OF THE SOURCE CODE, OR THE FAILURE OF THE SOURCE CODE TO PERFORM, OR FOR ANY OTHER REASON. + +OpenVision retains all copyrights in the donated Source Code. OpenVision also retains copyright to derivative works of the Source Code, whether created by OpenVision or by a third party. The OpenVision copyright notice must be preserved if derivative works are made based on the donated Source Code. + +OpenVision Technologies, Inc. has donated this Kerberos Administration system to MIT for inclusion in the standard Kerberos 5 distribution. This donation underscores our commitment to continuing Kerberos technology development and our gratitude for the valuable work which has been performed by MIT and the Kerberos community. + +----------------------------------------- + +Portions contributed by Matt Crawford <crawdad@fnal.gov> were work performed at Fermi National Accelerator Laboratory, which is operated by Universities Research Association, Inc., under contract DE-AC02-76CHO3000 with the U.S. Department of Energy. + +----------------------------------------- + +The implementation of the Yarrow pseudo-random number generator in src/lib/crypto/yarrow has the following copyright: + +Copyright 2000 by Zero-Knowledge Systems, Inc. + +Permission to use, copy, modify, distribute, and sell this software and its documentation for any purpose is hereby granted without fee, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of Zero-Knowledge Systems, Inc. not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. Zero-Knowledge Systems, Inc. makes no representations about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty. + +ZERO-KNOWLEDGE SYSTEMS, INC. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL ZERO-KNOWLEDGE SYSTEMS, INC. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTUOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +----------------------------------------- + +The implementation of the AES encryption algorithm in src/lib/crypto/aes has the following copyright: + +Copyright (c) 2001, Dr Brian Gladman <brg@gladman.uk.net>, Worcester, UK. All rights reserved. + +LICENSE TERMS + +The free distribution and use of this software in both source and binary form is allowed (with or without changes) provided that: + +1. distributions of this source code include the above copyright notice, this list of conditions and the following disclaimer; + +2. distributions in binary form include the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other associated materials; + +3. the copyright holder's name is not used to endorse products built using this software without specific written permission. + +DISCLAIMER + +This software is provided 'as is' with no explicit or implied warranties in respect of any properties, including, but not limited to, correctness and fitness for purpose. + +----------------------------------------- + +Portions contributed by Red Hat, including the pre-authentication plug-ins framework, contain the following copyright: + +Copyright (c) 2006 Red Hat, Inc. + +Portions copyright (c) 2006 Massachusetts Institute of Technology + +All Rights Reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + + Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + Neither the name of Red Hat, Inc., nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +----------------------------------------- + +The implementations of GSSAPI mechglue in GSSAPI-SPNEGO in src/lib/gssapi, including the following files: + +lib/gssapi/generic/gssapi_err_generic.et +lib/gssapi/mechglue/g_accept_sec_context.c +lib/gssapi/mechglue/g_acquire_cred.c +lib/gssapi/mechglue/g_canon_name.c +lib/gssapi/mechglue/g_compare_name.c +lib/gssapi/mechglue/g_context_time.c +lib/gssapi/mechglue/g_delete_sec_context.c +lib/gssapi/mechglue/g_dsp_name.c +lib/gssapi/mechglue/g_dsp_status.c +lib/gssapi/mechglue/g_dup_name.c +lib/gssapi/mechglue/g_exp_sec_context.c +lib/gssapi/mechglue/g_export_name.c +lib/gssapi/mechglue/g_glue.c +lib/gssapi/mechglue/g_imp_name.c +lib/gssapi/mechglue/g_imp_sec_context.c +lib/gssapi/mechglue/g_init_sec_context.c +lib/gssapi/mechglue/g_initialize.c +lib/gssapi/mechglue/g_inquire_context.c +lib/gssapi/mechglue/g_inquire_cred.c +lib/gssapi/mechglue/g_inquire_names.c +lib/gssapi/mechglue/g_process_context.c +lib/gssapi/mechglue/g_rel_buffer.c +lib/gssapi/mechglue/g_rel_cred.c +lib/gssapi/mechglue/g_rel_name.c +lib/gssapi/mechglue/g_rel_oid_set.c +lib/gssapi/mechglue/g_seal.c +lib/gssapi/mechglue/g_sign.c +lib/gssapi/mechglue/g_store_cred.c +lib/gssapi/mechglue/g_unseal.c +lib/gssapi/mechglue/g_userok.c +lib/gssapi/mechglue/g_utils.c +lib/gssapi/mechglue/g_verify.c +lib/gssapi/mechglue/gssd_pname_to_uid.c +lib/gssapi/mechglue/mglueP.h +lib/gssapi/mechglue/oid_ops.c +lib/gssapi/spnego/gssapiP_spnego.h +lib/gssapi/spnego/spnego_mech.c + +and the initial implementation of incremental propagation, including the following new or changed files: + +include/iprop_hdr.h +kadmin/server/ipropd_svc.c +lib/kdb/iprop.x +lib/kdb/kdb_convert.c +lib/kdb/kdb_log.clib/kdb/kdb_log.h +lib/krb5/error_tables/kdb5_err.et +slave/kpropd_rpc.c +slave/kproplog.c + +and marked portions of the following files: + +lib/krb5/os/hst_realm.c + +are subject to the following license: + +Copyright (c) 2004 Sun Microsystems, Inc. + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +----------------------------------------- + +MIT Kerberos includes documentation and software developed at the University of California at Berkeley, which includes this copyright notice: + +Copyright (C) 1983 Regents of the University of California. + +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +3. Neither the name of the University nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +----------------------------------------- + +Portions contributed by Novell, Inc., including the LDAP database backend, are subject to the following license: + +Copyright (c) 2004-2005, Novell, Inc. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + + Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + The copyright holder's name is not used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +----------------------------------------- + +Portions funded by Sandia National Laboratory and developed by the University of Michigan's Center for Information Technology Integration, including the PKINIT implementation, are subject to the following license: + +COPYRIGHT (C) 2006-2007 + +THE REGENTS OF THE UNIVERSITY OF MICHIGAN + +ALL RIGHTS RESERVED + +Permission is granted to use, copy, create derivative works and redistribute this software and such derivative works for any purpose, so long as the name of The University of Michigan is not used in any advertising or publicity pertaining to the use of distribution of this software without specific, written prior authorization. If the above copyright notice or any other identification of the University of Michigan is included in any copy of any portion of this software, then the disclaimer below must also be included. + +THIS SOFTWARE IS PROVIDED AS IS, WITHOUT REPRESENTATION FROM THE UNIVERSITY OF MICHIGAN AS TO ITS FITNESS FOR ANY PURPOSE, AND WITHOUT WARRANTY BY THE UNIVERSITY OF MICHIGAN OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE REGENTS OF THE UNIVERSITY OF MICHIGAN SHALL NOT BE LIABLE FOR ANY DAMAGES, INCLUDING SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WITH RESPECT TO ANY CLAIM ARISING OUT OF OR IN CONNECTION WITH THE USE OF THE SOFTWARE, EVEN IF IT HAS BEEN OR IS HEREAFTER ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +----------------------------------------- + +The pkcs11.h file included in the PKINIT code has the following license: + +Copyright 2006 g10 Code GmbH + +Copyright 2006 Andreas Jellinghaus + +This file is free software; as a special exception the author gives unlimited permission to copy and/or distribute it, with or without modifications, as long as this notice is preserved. + +This file is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY, to the extent permitted by law; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +----------------------------------------- + +Portions contributed by Apple Inc. are subject to the following license: + +Copyright 2004-2008 Apple Inc. All Rights Reserved. + +Export of this software from the United States of America may require a specific license from the United States Government. It is the responsibility of any person or organization contemplating export to obtain such a license before exporting. + +WITHIN THAT CONSTRAINT, permission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of Apple Inc. not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. Apple Inc. makes no representations about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty. + +THIS SOFTWARE IS PROVIDED "AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. + +----------------------------------------- + +The implementations of strlcpy and strlcat in src/util/support/strlcat.c have the following copyright and permission notice: + +Copyright (c) 1998 Todd C. Miller <Todd.Miller@courtesan.com> + +Permission to use, copy, modify, and distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +----------------------------------------- + +The implementations of UTF-8 string handling in src/util/support and src/lib/krb5/unicode are subject to the following copyright and permission notice: + +The OpenLDAP Public License + +Version 2.8, 17 August 2003 + +Redistribution and use of this software and associated documentation ("Software"), with or without modification, are permitted provided that the following conditions are met: + + Redistributions in source form must retain copyright statements and notices, + + Redistributions in binary form must reproduce applicable copyright statements and notices, this list of conditions, and the following disclaimer in the documentation and/or other materials provided with the distribution, and + + Redistributions must contain a verbatim copy of this document. + +The OpenLDAP Foundation may revise this license from time to time. Each revision is distinguished by a version number. You may use this Software under terms of this license revision or under the terms of any subsequent revision of the license. + +THIS SOFTWARE IS PROVIDED BY THE OPENLDAP FOUNDATION AND ITS CONTRIBUTORS "AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OPENLDAP FOUNDATION, ITS CONTRIBUTORS, OR THE AUTHOR(S) OR OWNER(S) OF THE SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +The names of the authors and copyright holders must not be used in advertising or otherwise to promote the sale, use or other dealing in this Software without specific, written prior permission. Title to copyright in this Software shall at all times remain with copyright holders. + +OpenLDAP is a registered trademark of the OpenLDAP Foundation. + +Copyright 1999-2003 The OpenLDAP Foundation, Redwood City, California, USA. All Rights Reserved. Permission to copy and distribute verbatim copies of this document is granted. + +----------------------------------------- + +Marked test programs in src/lib/krb5/krb have the following copyright: + +Copyright (c) 2006 Kungliga Tekniska H鰃skolan + +(Royal Institute of Technology, Stockholm, Sweden). + +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + + Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + Neither the name of KTH nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY KTH AND ITS CONTRIBUTORS "AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL KTH OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/lib/net40/Oracle.ManagedDataAccess.dll b/web/packages/Oracle.ManagedDataAccess.19.18.0/lib/net40/Oracle.ManagedDataAccess.dll new file mode 100644 index 0000000..993f911 --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/lib/net40/Oracle.ManagedDataAccess.dll Binary files differ diff --git a/web/packages/Oracle.ManagedDataAccess.19.18.0/readme.txt b/web/packages/Oracle.ManagedDataAccess.19.18.0/readme.txt new file mode 100644 index 0000000..8b23046 --- /dev/null +++ b/web/packages/Oracle.ManagedDataAccess.19.18.0/readme.txt @@ -0,0 +1,208 @@ +Oracle.ManagedDataAccess NuGet Package 19.18.0 README +===================================================== +Release Notes: Oracle Data Provider for .NET, Managed Driver + +January 2023 + +This document provides information that supplements the Oracle Data Provider for .NET (ODP.NET) documentation. + +You have downloaded Oracle Data Provider for .NET. The license agreement is available here: +https://www.oracle.com/downloads/licenses/distribution-license.html + +TABLE OF CONTENTS +*New Features +*Bug Fixes +*Installation and Configuration Steps +*Installation Changes +*Documentation Corrections and Additions +*ODP.NET, Managed Driver Tips, Limitations, and Known Issues + +Note: The 32-bit "Oracle Developer Tools for Visual Studio" download from https://otn.oracle.com/dotnet is +required for Entity Framework design-time features and for other Visual Studio designers such as the +TableAdapter Wizard. This NuGet download does not enable design-time tools; it only provides run-time support. +This version of ODP.NET supports Oracle Database version 11.2.0.4 and higher. + + +Bug Fixes since Oracle.ManagedDataAccess.Core NuGet Package 19.17.0 +=================================================================== +Bug 31456063 ORA-03111 IS ENCOUNTERED WHILE CANCELLING THE CURRENT COMMAND EXECUTION +Bug 31793997 INCORRECT UDTS ARE RETURNED BY DATAREADER AFTER A NULL UDT IS FETCHED +Bug 34431232 CURRENT DATABASE EDITION NAME IS NOT RETURNED BY ORACLECONNECTION +Bug 34617083 RESOLVE CVE-2023-21893 + + +Installation and Configuration Steps +==================================== +The downloads are NuGet packages that can be installed with the NuGet Package Manager. These instructions apply +to install ODP.NET, Managed Driver. + +1. Un-GAC and un-configure any existing assembly (i.e. Oracle.ManagedDataAccess.dll) and policy DLL +(i.e. Policy.4.122.Oracle.ManagedDataAccess.dll) for the ODP.NET, Managed Driver, version 4.122.19.1 +that exist in the GAC. Remove all references of Oracle.ManagedDataAccess from machine.config file, if any exists. + +2. In Visual Studio, open NuGet Package Manager from an existing Visual Studio project. + +3. Install the NuGet package from NuGet Gallery (nuget.org). + + + From Local Package Source + ------------------------- + A. Click on the Settings button in the lower left of the dialog box. + + B. Click the "+" button to add a package source. In the Source field, enter in the directory location where the + NuGet package(s) were downloaded to. Click the Update button, then the Ok button. + + C. On the left side, under the Online root node, select the package source you just created. The ODP.NET NuGet + packages will appear. + + + From Nuget.org + -------------- + A. In the Search box in the upper right, search for the package with id, "Oracle.ManagedDataAccess". Verify + that the package uses this unique ID to ensure it is the official Oracle Data Provider for .NET, Managed Driver + download. + + B. Select the package you wish to install. + + +4. Click on the Install button to select the desired NuGet package(s) to include with the project. Accept the +license agreement and Visual Studio will continue the setup. + +5. Open the app/web.config file to configure the ODP.NET connection string and connect descriptors. +Below is an example of configuring the net service aliases and connect descriptors parameters: + + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <!-- Customize these connection alias settings to connect to Oracle DB --> + <dataSource alias="MyDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " /> + </dataSources> + </version> + </oracle.manageddataaccess.client> + +After following these instructions, ODP.NET is now configured and ready to use. + +IMPORTANT: Oracle recommends configuring net service aliases and connect descriptors in a .NET config file to +have the application configuration be self-contained rather than using tnsnames.ora or TNS_ADMIN. + +NOTE: ODP.NET, Managed Driver comes with one set of platform specific assemblies for Kerberos support: Oracle.ManagedDataAccessIOP.dll. + +The Oracle.ManagedDataAccessIOP.dll assembly is ONLY needed if you are using Kerberos5 based external +authentication. Kerberos5 users will need to download MIT Kerberos for Windows version 4.0.1 from + https://web.mit.edu/kerberos/dist/ +to utilize ODP.NET, Managed Driver's support of Kerberos5. + +The asssemblies are located under + packages\Oracle.ManagedDataAccess.<version>\bin\x64 +and + packages\Oracle.ManagedDataAccess.<version>\bin\x86 +depending on the platform. + +If these assemblies are required by your application, your Visual Studio project requires additional changes. + +Use the following steps for your application to use the 64-bit version of Oracle.ManagedDataAccessIOP.dll: + +1. Right click on the Visual Studio project. +2. Select Add -> New Folder. +3. Name the folder x64. +4. Right click on the newly created x64 folder. +5. Select Add -> Existing Item. +6. Browse to packages\Oracle.ManagedDataAccess.<version>\bin\x64 under your project solution directory. +7. Choose Oracle.ManagedDataAccessIOP.dll. +8. Click the 'Add' button. +9. Left click the newly added Oracle.ManagedDataAccessIOP.dll in the x64 folder. +10. In the properties window, set 'Copy To Output Directory' to 'Copy Always'. + +For x86 targeted applications, name the folder x86 and add assemblies from the +packages\Oracle.ManagedDataAccess.<version>\bin\x86 folder. + +To make your application platform independent even if it depends on Oracle.ManagedDataAccessIOP.dll, create both x64 and x86 folders with the necessary assemblies added to them. + + +Installation Changes +==================== +The following app/web.config entries are added by including the ODP.NET, Managed Driver NuGet package to your application: + +1) Configuration Section Handler + +The following entry is added to the app/web.config to enable applications to add an <oracle.manageddataaccess.client> +section for ODP.NET, Managed Driver-specific configuration: + +<configuration> + <configSections> + <section name="oracle.manageddataaccess.client" type="OracleInternal.Common.ODPMSectionHandler, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </configSections> +</configuration> + +Note: If your application is a web application and the above entry was added to a web.config and the same config +section handler for "oracle.manageddataaccess.client" also exists in machine.config but the "Version" attribute values +are different, an error message of "There is a duplicate 'oracle.manageddataaccess.client' section defined." may be +observed at runtime. If so, the config section handler entry in the machine.config for +"oracle.manageddataaccess.client" has to be removed from the machine.config for the web application to not encounter +this error. But given that there may be other applications on the machine that depended on this entry in the +machine.config, this config section handler entry may need to be moved to all of the application's .NET config file on +that machine that depend on it. + +2) DbProviderFactories + +The following entry is added for applications that use DbProviderFactories and DbProviderFactory classes. Also, any +DbProviderFactories entry for "Oracle.ManagedDataAccess.Client" in the machine.config will be ignored with the following +entry: + +<configuration> + <system.data> + <DbProviderFactories> + <remove invariant="Oracle.ManagedDataAccess.Client" /> + <add name="ODP.NET, Managed Driver" invariant="Oracle.ManagedDataAccess.Client" description="Oracle Data Provider for .NET, Managed Driver" type="Oracle.ManagedDataAccess.Client.OracleClientFactory, Oracle.ManagedDataAccess, Version=4.122.19.1, Culture=neutral, PublicKeyToken=89b483f429c47342" /> + </DbProviderFactories> + </system.data> +</configuration> + +3) Dependent Assembly + +The following entry is created to ignore policy DLLs for Oracle.ManagedDataAccess.dll and always use the +Oracle.ManagedDataAccess.dll version that is specified by the newVersion attribute in the <bindingRedirect> element. +The newVersion attribute corresponds to the Oracle.ManagedDataAccess.dll version which came with the NuGet package +associated with the application. + +<configuration> + <runtime> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly> + <publisherPolicy apply="no" /> + <assemblyIdentity name="Oracle.ManagedDataAccess" publicKeyToken="89b483f429c47342" culture="neutral" /> + <bindingRedirect oldVersion="4.122.0.0 - 4.65535.65535.65535" newVersion="4.122.19.1" /> + </dependentAssembly> + </assemblyBinding> + </runtime> +</configuration> + +4) Data Sources + +The following entry is added to provide a template on how a data source can be configured in the app/web.config. +Simply rename "MyDataSource" to an alias of your liking and modify the PROTOCOL, HOST, PORT, SERVICE_NAME as required +and un-comment the <dataSource> element. Once that is done, the alias can be used as the "data source" attribute in +your connection string when connecting to an Oracle Database through ODP.NET, Managed Driver. + +<configuration> + <oracle.manageddataaccess.client> + <version number="*"> + <dataSources> + <dataSource alias="SampleDataSource" descriptor="(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL))) " /> + </dataSources> + </version> + </oracle.manageddataaccess.client> +</configuration> + + +Documentation Corrections and Additions +======================================= +None + + +ODP.NET, Managed Driver Tips, Limitations, and Known Issues +=========================================================== +None + + + Copyright (c) 2021, 2023, Oracle and/or its affiliates. diff --git a/web/web/Bin/App_Code.dll b/web/web/Bin/App_Code.dll index 3fe27c7..815ff01 100644 --- a/web/web/Bin/App_Code.dll +++ b/web/web/Bin/App_Code.dll Binary files differ diff --git a/web/web/Bin/App_Code.pdb b/web/web/Bin/App_Code.pdb index 251ff8e..568a082 100644 --- a/web/web/Bin/App_Code.pdb +++ b/web/web/Bin/App_Code.pdb Binary files differ diff --git a/web/web/Bin/Common.dll b/web/web/Bin/Common.dll index debaf88..38094bf 100644 --- a/web/web/Bin/Common.dll +++ b/web/web/Bin/Common.dll Binary files differ diff --git a/web/web/Bin/Common.dll.refresh b/web/web/Bin/Common.dll.refresh deleted file mode 100644 index 4b3c8c8..0000000 --- a/web/web/Bin/Common.dll.refresh +++ /dev/null Binary files differ diff --git a/web/web/Bin/Common.pdb b/web/web/Bin/Common.pdb index be293b9..97663e8 100644 --- a/web/web/Bin/Common.pdb +++ b/web/web/Bin/Common.pdb Binary files differ diff --git a/web/web/Bin/Dao.dll b/web/web/Bin/Dao.dll index 0370d65..1c149ac 100644 --- a/web/web/Bin/Dao.dll +++ b/web/web/Bin/Dao.dll Binary files differ diff --git a/web/web/Bin/Dao.dll.refresh b/web/web/Bin/Dao.dll.refresh deleted file mode 100644 index d54e2d5..0000000 --- a/web/web/Bin/Dao.dll.refresh +++ /dev/null Binary files differ diff --git a/web/web/Bin/Dao.pdb b/web/web/Bin/Dao.pdb index 8693fc8..b283ec3 100644 --- a/web/web/Bin/Dao.pdb +++ b/web/web/Bin/Dao.pdb Binary files differ diff --git a/web/web/Bin/Model.dll b/web/web/Bin/Model.dll index dc67266..d380f8b 100644 --- a/web/web/Bin/Model.dll +++ b/web/web/Bin/Model.dll Binary files differ diff --git a/web/web/Bin/Model.dll.refresh b/web/web/Bin/Model.dll.refresh deleted file mode 100644 index 2e26436..0000000 --- a/web/web/Bin/Model.dll.refresh +++ /dev/null Binary files differ diff --git a/web/web/Bin/Model.pdb b/web/web/Bin/Model.pdb index 61d8d0d..088ca1c 100644 --- a/web/web/Bin/Model.pdb +++ b/web/web/Bin/Model.pdb Binary files differ diff --git a/web/web/Bin/Oracle.DataAccess.dll b/web/web/Bin/Oracle.DataAccess.dll deleted file mode 100644 index 289bd51..0000000 --- a/web/web/Bin/Oracle.DataAccess.dll +++ /dev/null Binary files differ diff --git a/web/web/Bin/UMCLib.dll b/web/web/Bin/UMCLib.dll index 7b4e055..de922c5 100644 --- a/web/web/Bin/UMCLib.dll +++ b/web/web/Bin/UMCLib.dll Binary files differ diff --git a/web/web/Bin/UMCLib.pdb b/web/web/Bin/UMCLib.pdb index dec77ed..287f30a 100644 --- a/web/web/Bin/UMCLib.pdb +++ b/web/web/Bin/UMCLib.pdb Binary files differ diff --git a/web/web/GwBlackMobile.ashx b/web/web/GwBlackMobile.ashx index 30965c6..8ddc610 100644 --- a/web/web/GwBlackMobile.ashx +++ b/web/web/GwBlackMobile.ashx @@ -1,6 +1,7 @@ 锘�<%@ WebHandler Language="C#" Class="GwBlackMobileHandler" %> - -using com.softwee.smgw.common; + +//using App_Code; +using Common; using Dao; using Model; using System; @@ -14,326 +15,326 @@ public class GwBlackMobileHandler : PageHandler<SysUser> { - private HashSet<long> Map = new HashSet<long>(); - private GwBlackPoolDao _GwBlackPoolDao = new GwBlackPoolDao(); + private HashSet<long> Map = new HashSet<long>(); + private GwBlackPoolDao _GwBlackPoolDao = new GwBlackPoolDao(); - public override JsonPageResult ProcessRequestInternal(PageContext<SysUser> context) - { - string @string = context.GetString("action"); - switch (@string) + public override JsonPageResult ProcessRequestInternal(PageContext<SysUser> context) { - case "saveMobileSegMent": - return this.SaveMobileSegMent(context); - case "getMobileSegment": - return this.GetMobileSegment(context); - case "loadGwBlackPool": - return this.LoadGwBlackPool(context); - case "getGwBlackPool": - return this.GetGwBlackPool(context); - case "save": - return this.Save(context); - - //娓呴櫎榛戝悕鍗曟暟鎹� - - case "truntateBlackMobile": - return this.truntateBlackMobile(context); - //娓呴櫎榛戝悕鍗曟暟鎹瓻ND - - case "update": - return this.Update(context); - case "deletePool": - return this.DeletePool(context); - case "loadGwBlackMobile": - return this.LoadGwBlackMobile(context); - case "addGwBlackMobile": - return this.AddGwBlackMobile(context); - case "deleteMobile": - return this.DeleteMobile(context); - case "txtimportBlackMobile": - return this.ZipImportBlackMobile(context); - default: - throw new Exception("Invalid Action=" + @string); + string @string = context.GetString("action"); + switch (@string) + { + case "saveMobileSegMent": + return this.SaveMobileSegMent(context); + case "getMobileSegment": + return this.GetMobileSegment(context); + case "loadGwBlackPool": + return this.LoadGwBlackPool(context); + case "getGwBlackPool": + return this.GetGwBlackPool(context); + case "save": + return this.Save(context); + + //娓呴櫎榛戝悕鍗曟暟鎹� + + case "truntateBlackMobile": + return this.truntateBlackMobile(context); + //娓呴櫎榛戝悕鍗曟暟鎹瓻ND + + case "update": + return this.Update(context); + case "deletePool": + return this.DeletePool(context); + case "loadGwBlackMobile": + return this.LoadGwBlackMobile(context); + case "addGwBlackMobile": + return this.AddGwBlackMobile(context); + case "deleteMobile": + return this.DeleteMobile(context); + case "txtimportBlackMobile": + return this.ZipImportBlackMobile(context); + default: + throw new Exception("Invalid Action=" + @string); + } } - } - private JsonPageResult SaveMobileSegMent(PageContext<SysUser> context) - { - int @int = context.GetInt("pid"); - string @string = context.GetString("mobileData"); - if (@int < 0) - throw new ArgumentException("鍙傛暟PoolID鑾峰彇澶辫触"); - if (string.IsNullOrEmpty(@string)) - throw new ArgumentException("璇峰~鍐欏彿娈�"); - if (new GwBlackPoolDao().UpMobileSegMentdate(new GwBlackPool() + private JsonPageResult SaveMobileSegMent(PageContext<SysUser> context) { - PoolID = @int, - MobileSegMent = SegmentHelper.Filrate(@string) - })) - return new JsonPageResult(true, (object) "鍙锋淇敼鎴愬姛"); - return new JsonPageResult(false, (object) "娣诲姞鍙锋澶辫触"); - } - - private JsonPageResult GetMobileSegment(PageContext<SysUser> context) - { - return new JsonPageResult(true, (object) new GwBlackPoolDao().GetGwBlackPool(context.GetInt("pid"))); - } - - private JsonPageResult LoadGwBlackPool(PageContext<SysUser> context) - { - string @string = context.GetString("poolName"); - int recordcount = 0; - int int1 = context.GetInt("pageIndex", 1); - int int2 = context.GetInt("pageSize", 20); - string str = ""; - using (GwBlackPoolDao gwBlackPoolDao = new GwBlackPoolDao()) - { - List<GwBlackPool> list = gwBlackPoolDao.LoadInfoList(@string, out recordcount, int1, int2); - if (list != null && list.Count > 0) - { - foreach (GwBlackPool gwBlackPool in list) + int @int = context.GetInt("pid"); + string @string = context.GetString("mobileData"); + if (@int < 0) + throw new ArgumentException("鍙傛暟PoolID鑾峰彇澶辫触"); + if (string.IsNullOrEmpty(@string)) + throw new ArgumentException("璇峰~鍐欏彿娈�"); + if (new GwBlackPoolDao().UpMobileSegMentdate(new GwBlackPool() { - str = str + (object) "<tr ><td>" + gwBlackPool.PoolName + "</td><td>" + (object) gwBlackPool.BlackPoolID + "</td>"; - str += "<td>"; - str += string.Format("<a class=\"btn btn-xs btn-primary btn-poolmobile\" href=\"javascript:;\" data-id=\"{0}\">", (object) gwBlackPool.PoolID); - str += " 鏌ヨ</a> "; - str += string.Format("<a class=\"btn btn-xs btn-primary btn-mobile-segment\" href=\"javascript:;\" data-id=\"{0}\">", (object) gwBlackPool.PoolID); - str += "<i class=\"fa fa-edit\"></i> 榛戝悕鍗曞彿娈�</a> "; - str += string.Format("<a class=\"action-txtimportBlack btn btn-info btn-xs \" href=\"javascript:;\" data-id=\"{0}\" data-name=\"{1}\">", (object) gwBlackPool.PoolID, (object) gwBlackPool.PoolName); - str += " 榛戝悕鍗曞鍏�</a> "; - if (gwBlackPool.PoolID > 0) - { - str += string.Format("<a class=\"action-modal-edit btn btn-success btn-xs \" href=\"javascript:;\" data-id=\"{0}\">", (object) gwBlackPool.PoolID); - str += "<i class='fa fa-edit'></i> 缂栬緫"; - str += "</a> "; - str += string.Format("<a class=\"action-delete btnbtn btn btn-default btn-xs\" href=\"javascript:;\" data-id=\"{0}\">", (object) gwBlackPool.PoolID); - str += "<i class='fa fa-trash'></i> 鍒犻櫎"; - str += "</a> "; - } - str += "</td>"; - str += "</tr>"; - } - } - else - str += "<tr><td colspan=\"3\" style=\"text-align: center;\">鏆傛棤淇℃伅</td></tr>"; + PoolID = @int, + MobileSegMent = SegmentHelper.Filrate(@string) + })) + return new JsonPageResult(true, (object) "鍙锋淇敼鎴愬姛"); + return new JsonPageResult(false, (object) "娣诲姞鍙锋澶辫触"); } - return new JsonPageResult(true, (object) new + + private JsonPageResult GetMobileSegment(PageContext<SysUser> context) { - Table = str.ToString(), - TotalCount = recordcount - }); - } - - private JsonPageResult Save(PageContext<SysUser> context) - { - string @string = context.GetString("poolName"); - if (string.IsNullOrEmpty(@string)) - throw new ArgumentException("榛戝悕鍗曟睜鍚嶇О涓嶈兘涓虹┖锛�"); - if (this._GwBlackPoolDao.IsExitsPoolName(@string)) - throw new ArgumentException("榛戝悕鍗曟睜鍚嶇О宸插瓨鍦紒"); - this._GwBlackPoolDao.Add(new GwBlackPool() - { - PoolName = @string - }); - return new JsonPageResult(true, (object) "鍒涘缓榛戝悕鍗曟睜鎴愬姛锛�"); - } - - private JsonPageResult Update(PageContext<SysUser> context) - { - int @int = context.GetInt("poolID"); - string @string = context.GetString("poolName"); - if (string.IsNullOrEmpty(@string)) - throw new ArgumentException("榛戝悕鍗曟睜鍚嶇О涓嶈兘涓虹┖锛�"); - if (this._GwBlackPoolDao.IsExitsPoolName(@string, @int)) - throw new ArgumentException("榛戝悕鍗曟睜鍚嶇О宸插瓨鍦紒"); - this._GwBlackPoolDao.Update(new GwBlackPool() - { - PoolID = @int, - PoolName = @string - }); - return new JsonPageResult(true, (object) "淇敼榛戝悕鍗曟睜鎴愬姛锛�"); - } - - private JsonPageResult DeletePool(PageContext<SysUser> context) - { - int @int = context.GetInt("poolID"); - if (this._GwBlackPoolDao.IsGwOpPortExits(@int)) - throw new Exception("閫氶亾淇℃伅閰嶇疆涓鍦ㄤ娇鐢ㄨ榛戝悕鍗曟睜锛屼笉鑳藉垹闄わ紒"); - this._GwBlackPoolDao.DeleteMobile(@int); - return new JsonPageResult(true, (object) "鍒犻櫎榛戝悕鍗曟睜鎴愬姛锛�"); - } - - - // 娓呴櫎榛戝悕鍗曟暟鎹垚鍔� - - private JsonPageResult truntateBlackMobile(PageContext<SysUser> context) - { - this._GwBlackPoolDao.truntateBlackMobile(); - - return new JsonPageResult(true,"娓呴櫎鍏ㄩ儴榛戝悕鍗曞彿鐮佹垚鍔燂紒"); - } - // 娓呴櫎榛戝悕鍗曟暟鎹垚鍔烢ND - - - private JsonPageResult GetGwBlackPool(PageContext<SysUser> context) - { - return new JsonPageResult(true, (object) this._GwBlackPoolDao.GetGwBlackPool(context.GetInt("poolID"))); - } - - private JsonPageResult LoadGwBlackMobile(PageContext<SysUser> context) - { - string string1 = context.GetString("blackpool"); - string string2 = context.GetString("mobile"); - if (string.IsNullOrEmpty(string2)) - throw new ArgumentException("鎵嬫満鍙风爜涓嶈兘涓虹┖锛�"); - string str = ""; - using (GwBlackPoolDao gwBlackPoolDao = new GwBlackPoolDao()) - { - List<GwBlackPool> list = gwBlackPoolDao.LoadInfoList(string1, string2); - if (list != null && list.Count > 0) - { - foreach (GwBlackPool gwBlackPool in list) - { - str = str + (object) "<tr ><td>" + gwBlackPool.Mobile + "</td><td>" + gwBlackPool.PoolName + "</td><td>" + (object) gwBlackPool.ModifyTime + "</td>"; - str += "<td>"; - str += string.Format("<a class=\"action-mobile-delete btnbtn btn btn-default btn-xs\" href=\"javascript:;\" data-id=\"{0}\" data-moblie=\"{1}\">", (object) gwBlackPool.BlackPoolID, (object) gwBlackPool.Mobile); - str += "<i class='fa fa-trash'></i> 鍒犻櫎"; - str += "</a>"; - str += "</td>"; - str += "</tr>"; - } - } - else - str += "<tr><td colspan=\"4\" style=\"text-align: center;\">鏆傛棤淇℃伅</td></tr>"; + return new JsonPageResult(true, (object) new GwBlackPoolDao().GetGwBlackPool(context.GetInt("pid"))); } - return new JsonPageResult(true, (object) new - { - Table = str.ToString() - }); - } - private JsonPageResult AddGwBlackMobile(PageContext<SysUser> context) - { - string string1 = context.GetString("blackpool"); - string string2 = context.GetString("mobile"); - if (string.IsNullOrEmpty(string1)) - throw new ArgumentException("榛戝悕鍗曟睜涓嶈兘涓虹┖锛�"); - if (string.IsNullOrEmpty(string2)) - throw new ArgumentException("鎵嬫満鍙风爜涓嶈兘涓虹┖锛�"); - if (!this._GwBlackPoolDao.IsPortExits(Convert.ToInt32(string1), string2)) - throw new Exception("榛戝悕鍗曞彿鐮佸凡瀛樺湪锛�"); - this._GwBlackPoolDao.AddMobile(Convert.ToInt32(string1), string2); - return new JsonPageResult(true, (object) "鏂板榛戝悕鍗曞彿鐮佹垚鍔燂紒"); - } - - private JsonPageResult DeleteMobile(PageContext<SysUser> context) - { - this._GwBlackPoolDao.DeleteMobile(context.GetInt("poolID"), context.GetString("mobile")); - return new JsonPageResult(true, (object) "鍒犻櫎榛戝悕鍗曞彿鐮佹垚鍔燂紒"); - } - - - - - - private JsonPageResult ZipImportBlackMobile(PageContext<SysUser> context) - { - Stopwatch stopwatch = new Stopwatch(); - stopwatch.Start(); - HttpPostedFile httpPostedFile = context.Files["certPath"]; - if (httpPostedFile == null || httpPostedFile.FileName == "") - throw new Exception("璇烽�夋嫨瑕佸鍏ョ殑zip鏂囦欢,骞舵鏌ユ枃浠跺ぇ灏忥紒"); - string extension = Path.GetExtension(httpPostedFile.FileName); - if (!extension.Equals(".zip", StringComparison.OrdinalIgnoreCase) && !extension.Equals(".txt", StringComparison.OrdinalIgnoreCase)) - throw new Exception("瀵煎叆鏂囦欢鏍煎紡涓嶆纭紝鍙厑璁稿鍏ip鎴杢xt鏂囦欢!"); - if (httpPostedFile.ContentLength > 104857600) - throw new Exception("鏂囦欢涓婁紶涓嶈兘瓒呰繃100M锛岃妫�鏌ユ枃浠跺ぇ灏忥紝鏄惁鏈夊啓鏉冮檺锛�"); - string @string = context.GetString("ablackpool"); - if (string.IsNullOrEmpty(@string)) - throw new Exception("璇烽�夋嫨榛戝悕鍗曟睜锛�"); - List<Stream> outputStreamList = new List<Stream>(); - if (extension.Equals(".txt", StringComparison.OrdinalIgnoreCase)) - outputStreamList.Add(httpPostedFile.InputStream); - else if (extension.Equals(".zip", StringComparison.OrdinalIgnoreCase)) - ZipUtils.Decompression(httpPostedFile.InputStream, ref outputStreamList, true); - HashSet<string> blackPoolMobile = this._GwBlackPoolDao.GetBlackPoolMobile(Convert.ToInt32(@string.ToString())); - HashSet<string> tempSet = new HashSet<string>(); - DataTable dt = new DataTable("GW_BLACKPOOL_MOBILE"); - dt.Columns.Add("MOBILE", typeof (string)); - DateTime now = DateTime.Now; - DataColumn column1 = new DataColumn("BLACKPOOL_ID", typeof (int)); - DataColumn column2 = new DataColumn("MODIFY_TIME", typeof (DateTime)); - DataColumn column3 = new DataColumn("IS_DELETED", typeof (int)); - column1.DefaultValue = (object) @string; - column2.DefaultValue = (object) now; - column3.DefaultValue = (object) 0; - dt.Columns.Add(column1); - dt.Columns.Add(column2); - dt.Columns.Add(column3); - StringBuilder errorBuilder = new StringBuilder(); - int count = 0; - foreach (Stream stream in outputStreamList) + private JsonPageResult LoadGwBlackPool(PageContext<SysUser> context) { - stream.Seek(0L, SeekOrigin.Begin); - count += this.ProcessStream(blackPoolMobile, tempSet, dt, errorBuilder, stream); - } - int num = this.SaveDataTable(dt, now, count); - stopwatch.Stop(); - string str = "鏁伴噺锛�" + (object) num + "涓紝鑰楁椂锛�" + (object) stopwatch.ElapsedMilliseconds + "ms"; - if (errorBuilder.Length > 0) - str = str + ",閿欒鍙风爜鍖呭惈锛�" + errorBuilder.ToString(); - return new JsonPageResult(true, (object) new - { - Message = "鍏ㄥ眬榛戝悕鍗曞鍏ユ垚鍔燂紒", - Msg = str - }); - } - - private int SaveDataTable(DataTable dt, DateTime dtime, int count) - { - if (dt != null) - { - if (dt.Rows.Count > 0) - { - try + string @string = context.GetString("poolName"); + int recordcount = 0; + int int1 = context.GetInt("pageIndex", 1); + int int2 = context.GetInt("pageSize", 20); + string str = ""; + using (GwBlackPoolDao gwBlackPoolDao = new GwBlackPoolDao()) { - this._GwBlackPoolDao.Import(dt); - this._GwBlackPoolDao.Add_EventLog(dtime); - count += dt.Rows.Count; - } - catch (Exception ex) - { - throw new Exception("鍐欏叆鏁版嵁鍑洪敊锛�" + ex.Message); - } - } - } - return count; - } - - private int ProcessStream(HashSet<string> existsSet, HashSet<string> tempSet, DataTable dt, StringBuilder errorBuilder, Stream stream) - { - int count = 0; - using (StreamReader streamReader = new StreamReader(stream, Encoding.Default)) - { - Regex regex = new Regex("^1[34578]\\d{9}$"); - int num = 0; - while (!streamReader.EndOfStream) - { - string str1; - try - { - str1 = streamReader.ReadLine(); - } - catch (Exception ex) - { - throw new Exception("璇诲彇鏂囦欢鍑洪敊锛屾墜鏈哄彿鐮佽鎹㈣锛�"); - } - if (!string.IsNullOrEmpty(str1)) - { - string[] strArray; - try - { - strArray = str1.Split(new char[8] + List<GwBlackPool> list = gwBlackPoolDao.LoadInfoList(@string, out recordcount, int1, int2); + if (list != null && list.Count > 0) { + foreach (GwBlackPool gwBlackPool in list) + { + str = str + (object) "<tr ><td>" + gwBlackPool.PoolName + "</td><td>" + (object) gwBlackPool.BlackPoolID + "</td>"; + str += "<td>"; + str += string.Format("<a class=\"btn btn-xs btn-primary btn-poolmobile\" href=\"javascript:;\" data-id=\"{0}\">", (object) gwBlackPool.PoolID); + str += " 鏌ヨ</a> "; + str += string.Format("<a class=\"btn btn-xs btn-primary btn-mobile-segment\" href=\"javascript:;\" data-id=\"{0}\">", (object) gwBlackPool.PoolID); + str += "<i class=\"fa fa-edit\"></i> 榛戝悕鍗曞彿娈�</a> "; + str += string.Format("<a class=\"action-txtimportBlack btn btn-info btn-xs \" href=\"javascript:;\" data-id=\"{0}\" data-name=\"{1}\">", (object) gwBlackPool.PoolID, (object) gwBlackPool.PoolName); + str += " 榛戝悕鍗曞鍏�</a> "; + if (gwBlackPool.PoolID > 0) + { + str += string.Format("<a class=\"action-modal-edit btn btn-success btn-xs \" href=\"javascript:;\" data-id=\"{0}\">", (object) gwBlackPool.PoolID); + str += "<i class='fa fa-edit'></i> 缂栬緫"; + str += "</a> "; + str += string.Format("<a class=\"action-delete btnbtn btn btn-default btn-xs\" href=\"javascript:;\" data-id=\"{0}\">", (object) gwBlackPool.PoolID); + str += "<i class='fa fa-trash'></i> 鍒犻櫎"; + str += "</a> "; + } + str += "</td>"; + str += "</tr>"; + } + } + else + str += "<tr><td colspan=\"3\" style=\"text-align: center;\">鏆傛棤淇℃伅</td></tr>"; + } + return new JsonPageResult(true, (object) new + { + Table = str.ToString(), + TotalCount = recordcount + }); + } + + private JsonPageResult Save(PageContext<SysUser> context) + { + string @string = context.GetString("poolName"); + if (string.IsNullOrEmpty(@string)) + throw new ArgumentException("榛戝悕鍗曟睜鍚嶇О涓嶈兘涓虹┖锛�"); + if (this._GwBlackPoolDao.IsExitsPoolName(@string)) + throw new ArgumentException("榛戝悕鍗曟睜鍚嶇О宸插瓨鍦紒"); + this._GwBlackPoolDao.Add(new GwBlackPool() + { + PoolName = @string + }); + return new JsonPageResult(true, (object) "鍒涘缓榛戝悕鍗曟睜鎴愬姛锛�"); + } + + private JsonPageResult Update(PageContext<SysUser> context) + { + int @int = context.GetInt("poolID"); + string @string = context.GetString("poolName"); + if (string.IsNullOrEmpty(@string)) + throw new ArgumentException("榛戝悕鍗曟睜鍚嶇О涓嶈兘涓虹┖锛�"); + if (this._GwBlackPoolDao.IsExitsPoolName(@string, @int)) + throw new ArgumentException("榛戝悕鍗曟睜鍚嶇О宸插瓨鍦紒"); + this._GwBlackPoolDao.Update(new GwBlackPool() + { + PoolID = @int, + PoolName = @string + }); + return new JsonPageResult(true, (object) "淇敼榛戝悕鍗曟睜鎴愬姛锛�"); + } + + private JsonPageResult DeletePool(PageContext<SysUser> context) + { + int @int = context.GetInt("poolID"); + if (this._GwBlackPoolDao.IsGwOpPortExits(@int)) + throw new Exception("閫氶亾淇℃伅閰嶇疆涓鍦ㄤ娇鐢ㄨ榛戝悕鍗曟睜锛屼笉鑳藉垹闄わ紒"); + this._GwBlackPoolDao.DeleteMobile(@int); + return new JsonPageResult(true, (object) "鍒犻櫎榛戝悕鍗曟睜鎴愬姛锛�"); + } + + + // 娓呴櫎榛戝悕鍗曟暟鎹垚鍔� + + private JsonPageResult truntateBlackMobile(PageContext<SysUser> context) + { + this._GwBlackPoolDao.truntateBlackMobile(); + + return new JsonPageResult(true,"娓呴櫎鍏ㄩ儴榛戝悕鍗曞彿鐮佹垚鍔燂紒"); + } + // 娓呴櫎榛戝悕鍗曟暟鎹垚鍔烢ND + + + private JsonPageResult GetGwBlackPool(PageContext<SysUser> context) + { + return new JsonPageResult(true, (object) this._GwBlackPoolDao.GetGwBlackPool(context.GetInt("poolID"))); + } + + private JsonPageResult LoadGwBlackMobile(PageContext<SysUser> context) + { + string string1 = context.GetString("blackpool"); + string string2 = context.GetString("mobile"); + if (string.IsNullOrEmpty(string2)) + throw new ArgumentException("鎵嬫満鍙风爜涓嶈兘涓虹┖锛�"); + string str = ""; + using (GwBlackPoolDao gwBlackPoolDao = new GwBlackPoolDao()) + { + List<GwBlackPool> list = gwBlackPoolDao.LoadInfoList(string1, string2); + if (list != null && list.Count > 0) + { + foreach (GwBlackPool gwBlackPool in list) + { + str = str + (object) "<tr ><td>" + gwBlackPool.Mobile + "</td><td>" + gwBlackPool.PoolName + "</td><td>" + (object) gwBlackPool.ModifyTime + "</td>"; + str += "<td>"; + str += string.Format("<a class=\"action-mobile-delete btnbtn btn btn-default btn-xs\" href=\"javascript:;\" data-id=\"{0}\" data-moblie=\"{1}\">", (object) gwBlackPool.BlackPoolID, (object) gwBlackPool.Mobile); + str += "<i class='fa fa-trash'></i> 鍒犻櫎"; + str += "</a>"; + str += "</td>"; + str += "</tr>"; + } + } + else + str += "<tr><td colspan=\"4\" style=\"text-align: center;\">鏆傛棤淇℃伅</td></tr>"; + } + return new JsonPageResult(true, (object) new + { + Table = str.ToString() + }); + } + + private JsonPageResult AddGwBlackMobile(PageContext<SysUser> context) + { + string string1 = context.GetString("blackpool"); + string string2 = context.GetString("mobile"); + if (string.IsNullOrEmpty(string1)) + throw new ArgumentException("榛戝悕鍗曟睜涓嶈兘涓虹┖锛�"); + if (string.IsNullOrEmpty(string2)) + throw new ArgumentException("鎵嬫満鍙风爜涓嶈兘涓虹┖锛�"); + if (!this._GwBlackPoolDao.IsPortExits(Convert.ToInt32(string1), string2)) + throw new Exception("榛戝悕鍗曞彿鐮佸凡瀛樺湪锛�"); + this._GwBlackPoolDao.AddMobile(Convert.ToInt32(string1), string2); + return new JsonPageResult(true, (object) "鏂板榛戝悕鍗曞彿鐮佹垚鍔燂紒"); + } + + private JsonPageResult DeleteMobile(PageContext<SysUser> context) + { + this._GwBlackPoolDao.DeleteMobile(context.GetInt("poolID"), context.GetString("mobile")); + return new JsonPageResult(true, (object) "鍒犻櫎榛戝悕鍗曞彿鐮佹垚鍔燂紒"); + } + + + + + + private JsonPageResult ZipImportBlackMobile(PageContext<SysUser> context) + { + Stopwatch stopwatch = new Stopwatch(); + stopwatch.Start(); + HttpPostedFile httpPostedFile = context.Files["certPath"]; + if (httpPostedFile == null || httpPostedFile.FileName == "") + throw new Exception("璇烽�夋嫨瑕佸鍏ョ殑zip鏂囦欢,骞舵鏌ユ枃浠跺ぇ灏忥紒"); + string extension = Path.GetExtension(httpPostedFile.FileName); + if (!extension.Equals(".zip", StringComparison.OrdinalIgnoreCase) && !extension.Equals(".txt", StringComparison.OrdinalIgnoreCase)) + throw new Exception("瀵煎叆鏂囦欢鏍煎紡涓嶆纭紝鍙厑璁稿鍏ip鎴杢xt鏂囦欢!"); + if (httpPostedFile.ContentLength > 104857600) + throw new Exception("鏂囦欢涓婁紶涓嶈兘瓒呰繃100M锛岃妫�鏌ユ枃浠跺ぇ灏忥紝鏄惁鏈夊啓鏉冮檺锛�"); + string @string = context.GetString("ablackpool"); + if (string.IsNullOrEmpty(@string)) + throw new Exception("璇烽�夋嫨榛戝悕鍗曟睜锛�"); + List<Stream> outputStreamList = new List<Stream>(); + if (extension.Equals(".txt", StringComparison.OrdinalIgnoreCase)) + outputStreamList.Add(httpPostedFile.InputStream); + else if (extension.Equals(".zip", StringComparison.OrdinalIgnoreCase)) + ZipUtils.Decompression(httpPostedFile.InputStream, ref outputStreamList, true); + HashSet<string> blackPoolMobile = this._GwBlackPoolDao.GetBlackPoolMobile(Convert.ToInt32(@string.ToString())); + HashSet<string> tempSet = new HashSet<string>(); + DataTable dt = new DataTable("GW_BLACKPOOL_MOBILE"); + dt.Columns.Add("MOBILE", typeof (string)); + DateTime now = DateTime.Now; + DataColumn column1 = new DataColumn("BLACKPOOL_ID", typeof (int)); + DataColumn column2 = new DataColumn("MODIFY_TIME", typeof (DateTime)); + DataColumn column3 = new DataColumn("IS_DELETED", typeof (int)); + column1.DefaultValue = (object) @string; + column2.DefaultValue = (object) now; + column3.DefaultValue = (object) 0; + dt.Columns.Add(column1); + dt.Columns.Add(column2); + dt.Columns.Add(column3); + StringBuilder errorBuilder = new StringBuilder(); + int count = 0; + foreach (Stream stream in outputStreamList) + { + stream.Seek(0L, SeekOrigin.Begin); + count += this.ProcessStream(blackPoolMobile, tempSet, dt, errorBuilder, stream); + } + int num = this.SaveDataTable(dt, now, count); + stopwatch.Stop(); + string str = "鏁伴噺锛�" + (object) num + "涓紝鑰楁椂锛�" + (object) stopwatch.ElapsedMilliseconds + "ms"; + if (errorBuilder.Length > 0) + str = str + ",閿欒鍙风爜鍖呭惈锛�" + errorBuilder.ToString(); + return new JsonPageResult(true, (object) new + { + Message = "鍏ㄥ眬榛戝悕鍗曞鍏ユ垚鍔燂紒", + Msg = str + }); + } + + private int SaveDataTable(DataTable dt, DateTime dtime, int count) + { + if (dt != null) + { + if (dt.Rows.Count > 0) + { + try + { + this._GwBlackPoolDao.Import(dt); + this._GwBlackPoolDao.Add_EventLog(dtime); + count += dt.Rows.Count; + } + catch (Exception ex) + { + throw new Exception("鍐欏叆鏁版嵁鍑洪敊锛�" + ex.Message); + } + } + } + return count; + } + + private int ProcessStream(HashSet<string> existsSet, HashSet<string> tempSet, DataTable dt, StringBuilder errorBuilder, Stream stream) + { + int count = 0; + using (StreamReader streamReader = new StreamReader(stream, Encoding.Default)) + { + Regex regex = new Regex("^1[34578]\\d{9}$"); + int num = 0; + while (!streamReader.EndOfStream) + { + string str1; + try + { + str1 = streamReader.ReadLine(); + } + catch (Exception ex) + { + throw new Exception("璇诲彇鏂囦欢鍑洪敊锛屾墜鏈哄彿鐮佽鎹㈣锛�"); + } + if (!string.IsNullOrEmpty(str1)) + { + string[] strArray; + try + { + strArray = str1.Split(new char[8] + { '\r', '\n', ',', @@ -342,126 +343,126 @@ '|', '锛�', '锛�' - }, StringSplitOptions.RemoveEmptyEntries); - } - catch (Exception ex) - { - throw new Exception("鍒嗗壊鎵嬫満鍙风爜鍑洪敊锛�"); - } - foreach (string str2 in strArray) - { - string input = str2.Trim(); - if (!regex.IsMatch(input)) - errorBuilder.AppendFormat("{0};", (object) input); - else if (!existsSet.Contains(input) && !tempSet.Contains(input)) - { - ++num; - DataRow row = dt.NewRow(); - row["MOBILE"] = (object) input; - dt.Rows.Add(row); - tempSet.Add(input); + }, StringSplitOptions.RemoveEmptyEntries); + } + catch (Exception ex) + { + throw new Exception("鍒嗗壊鎵嬫満鍙风爜鍑洪敊锛�"); + } + foreach (string str2 in strArray) + { + string input = str2.Trim(); + if (!regex.IsMatch(input)) + errorBuilder.AppendFormat("{0};", (object) input); + else if (!existsSet.Contains(input) && !tempSet.Contains(input)) + { + ++num; + DataRow row = dt.NewRow(); + row["MOBILE"] = (object) input; + dt.Rows.Add(row); + tempSet.Add(input); + } + if (num == 1000000) + { + count = this.SaveDataTable(dt, DateTime.Now, count); + num = 0; + dt.Clear(); + } + } + } } - if (num == 1000000) - { - count = this.SaveDataTable(dt, DateTime.Now, count); - num = 0; - dt.Clear(); - } - } } - } + return count; } - return count; - } - private JsonPageResult TxtImportBlackMobile(PageContext<SysUser> context) - { - Stopwatch stopwatch = new Stopwatch(); - stopwatch.Start(); - HttpPostedFile httpPostedFile = context.Files["certPath"]; - if (httpPostedFile == null) - throw new Exception("鏈�夋嫨鏂囦欢鎴栦笂浼犳枃浠惰秴杩�10M锛�"); - if (httpPostedFile.FileName == "") - throw new Exception("璇烽�夋嫨瑕佸鍏ョ殑txt鏂囦欢锛�"); - string extension = Path.GetExtension(httpPostedFile.FileName); - if (!extension.Equals(".txt") && !extension.Equals(".TXT")) - throw new Exception("瀵煎叆鏂囦欢鏍煎紡涓嶆纭紝鍙厑璁稿鍏xt鏂囦欢!"); - if (httpPostedFile.ContentLength > 10485760) - throw new Exception("鏂囦欢涓婁紶涓嶈兘瓒呰繃10M锛岃妫�鏌ユ枃浠跺ぇ灏忥紝鏄惁鏈夊啓鏉冮檺锛�"); - string @string = context.GetString("ablackpool"); - if (string.IsNullOrEmpty(@string)) - throw new Exception("璇烽�夋嫨榛戝悕鍗曟睜锛�"); - HashSet<string> blackPoolMobile = this._GwBlackPoolDao.GetBlackPoolMobile(Convert.ToInt32(@string.ToString())); - HashSet<string> hashSet = new HashSet<string>(); - DataTable dt = new DataTable("GW_BLACKPOOL_MOBILE"); - dt.Columns.Add("MOBILE", typeof (string)); - DateTime dtime = Convert.ToDateTime(DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")); - DataColumn column1 = new DataColumn("BLACKPOOL_ID", typeof (int)); - DataColumn column2 = new DataColumn("MODIFY_TIME", typeof (DateTime)); - DataColumn column3 = new DataColumn("IS_DELETED", typeof (int)); - column1.DefaultValue = (object) @string; - column2.DefaultValue = (object) dtime; - column3.DefaultValue = (object) 0; - dt.Columns.Add(column1); - dt.Columns.Add(column2); - dt.Columns.Add(column3); - StringBuilder stringBuilder = new StringBuilder(); - using (StreamReader streamReader = new StreamReader(httpPostedFile.InputStream, Encoding.Default)) + private JsonPageResult TxtImportBlackMobile(PageContext<SysUser> context) { - Regex regex = new Regex("^1[34578]\\d{9}$"); - string str1 = streamReader.ReadToEnd(); - if (!string.IsNullOrEmpty(str1)) - { - string str2 = str1; - char[] separator = new char[6] + Stopwatch stopwatch = new Stopwatch(); + stopwatch.Start(); + HttpPostedFile httpPostedFile = context.Files["certPath"]; + if (httpPostedFile == null) + throw new Exception("鏈�夋嫨鏂囦欢鎴栦笂浼犳枃浠惰秴杩�10M锛�"); + if (httpPostedFile.FileName == "") + throw new Exception("璇烽�夋嫨瑕佸鍏ョ殑txt鏂囦欢锛�"); + string extension = Path.GetExtension(httpPostedFile.FileName); + if (!extension.Equals(".txt") && !extension.Equals(".TXT")) + throw new Exception("瀵煎叆鏂囦欢鏍煎紡涓嶆纭紝鍙厑璁稿鍏xt鏂囦欢!"); + if (httpPostedFile.ContentLength > 10485760) + throw new Exception("鏂囦欢涓婁紶涓嶈兘瓒呰繃10M锛岃妫�鏌ユ枃浠跺ぇ灏忥紝鏄惁鏈夊啓鏉冮檺锛�"); + string @string = context.GetString("ablackpool"); + if (string.IsNullOrEmpty(@string)) + throw new Exception("璇烽�夋嫨榛戝悕鍗曟睜锛�"); + HashSet<string> blackPoolMobile = this._GwBlackPoolDao.GetBlackPoolMobile(Convert.ToInt32(@string.ToString())); + HashSet<string> hashSet = new HashSet<string>(); + DataTable dt = new DataTable("GW_BLACKPOOL_MOBILE"); + dt.Columns.Add("MOBILE", typeof (string)); + DateTime dtime = Convert.ToDateTime(DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")); + DataColumn column1 = new DataColumn("BLACKPOOL_ID", typeof (int)); + DataColumn column2 = new DataColumn("MODIFY_TIME", typeof (DateTime)); + DataColumn column3 = new DataColumn("IS_DELETED", typeof (int)); + column1.DefaultValue = (object) @string; + column2.DefaultValue = (object) dtime; + column3.DefaultValue = (object) 0; + dt.Columns.Add(column1); + dt.Columns.Add(column2); + dt.Columns.Add(column3); + StringBuilder stringBuilder = new StringBuilder(); + using (StreamReader streamReader = new StreamReader(httpPostedFile.InputStream, Encoding.Default)) { + Regex regex = new Regex("^1[34578]\\d{9}$"); + string str1 = streamReader.ReadToEnd(); + if (!string.IsNullOrEmpty(str1)) + { + string str2 = str1; + char[] separator = new char[6] + { '\r', '\n', ',', ';', ' ', '|' - }; - int num = 1; - foreach (string str3 in str2.Split(separator, (StringSplitOptions) num)) - { - string input = str3.Trim(); - if (!regex.IsMatch(input)) - stringBuilder.AppendFormat("{0};", (object) input); - else if (!blackPoolMobile.Contains(input) && !hashSet.Contains(input)) - { - DataRow row = dt.NewRow(); - row["MOBILE"] = (object) input; - dt.Rows.Add(row); - hashSet.Add(input); - } + }; + int num = 1; + foreach (string str3 in str2.Split(separator, (StringSplitOptions) num)) + { + string input = str3.Trim(); + if (!regex.IsMatch(input)) + stringBuilder.AppendFormat("{0};", (object) input); + else if (!blackPoolMobile.Contains(input) && !hashSet.Contains(input)) + { + DataRow row = dt.NewRow(); + row["MOBILE"] = (object) input; + dt.Rows.Add(row); + hashSet.Add(input); + } + } + } } - } + int num1 = 0; + if (dt != null) + { + if (dt.Rows.Count > 0) + { + try + { + num1 = this._GwBlackPoolDao.Import(dt, dtime); + } + catch (Exception ex) + { + throw new Exception("鍐欏叆鏁版嵁鍑洪敊锛�" + ex.Message); + } + } + } + stopwatch.Stop(); + string str = "鏁伴噺锛�" + (object) num1 + "涓紝鑰楁椂锛�" + (object) stopwatch.ElapsedMilliseconds + "ms"; + if (stringBuilder.Length > 0) + str = str + ",閿欒鍙风爜鍖呭惈锛�" + stringBuilder.ToString(); + "".TrimEnd(','); + return new JsonPageResult(true, (object) new + { + Message = "鍏ㄥ眬榛戝悕鍗曞鍏ユ垚鍔燂紒", + Msg = str + }); } - int num1 = 0; - if (dt != null) - { - if (dt.Rows.Count > 0) - { - try - { - num1 = this._GwBlackPoolDao.Import(dt, dtime); - } - catch (Exception ex) - { - throw new Exception("鍐欏叆鏁版嵁鍑洪敊锛�" + ex.Message); - } - } - } - stopwatch.Stop(); - string str = "鏁伴噺锛�" + (object) num1 + "涓紝鑰楁椂锛�" + (object) stopwatch.ElapsedMilliseconds + "ms"; - if (stringBuilder.Length > 0) - str = str + ",閿欒鍙风爜鍖呭惈锛�" + stringBuilder.ToString(); - "".TrimEnd(','); - return new JsonPageResult(true, (object) new - { - Message = "鍏ㄥ眬榛戝悕鍗曞鍏ユ垚鍔燂紒", - Msg = str - }); - } } diff --git a/web/web/GwClientSub.aspx b/web/web/GwClientSub.aspx new file mode 100644 index 0000000..e1b1cf0 --- /dev/null +++ b/web/web/GwClientSub.aspx @@ -0,0 +1,1072 @@ +锘�<%@ Page Language="C#" MasterPageFile="~/Main.master" AutoEventWireup="true" CodeFile="GwClientSub.aspx.cs" Inherits="_GwClient" %> + +<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server"> + <script type="text/javascript" src="/web/js/jquery.min.js?v=2.1.4"></script> + <%--<link href="css/plugins/bootstrap-fileinput/fileinput.min.css" rel="stylesheet"/> + <script src="js/plugins/bootstrap-fileinput/fileinput.min.js" type="text/javascript"></script>--%> + <script type="text/javascript"> + $(document).ready(function () { + $("textarea").numberedtextarea(); + + //鍏ㄩ�� + $("#checkAll").click(function () { + $("input[name='checkbox']").prop("checked", $(this).is(":checked")); + }); + + $(document).on("click", ".action-query", function () { + loadPageList(); + }); + loadPageList(); + + $(document).on("click", ".action-modal-create", function () { + $("#clientDialog .modal-title").text("鍒涘缓瀹㈡埛淇℃伅"); + $("#clientDialog input").attr("readonly", false); + $("#clientDialog input[name=action]").val("save"); + + //$("#clientDialog #id").val(""); + $("#clientDialog #clientID").val(""); + $("#clientDialog #company").val(""); + $("#clientDialog #clientName").val(""); + $("#clientDialog #agent").val(""); + $("#clientDialog #address").val(""); + $("#clientDialog #telephone").val(""); + $("#clientDialog #chargeType").val(""); + $("#clientDialog #smsStatusReport").val(""); + $("#clientDialog #mmsStatusReport").val(""); + $("#clientDialog #customerManager").val(""); + $("#clientDialog #salesman").val(""); + $("#clientDialog #supportStaff").val(""); + $("#clientDialog #financialStaff").val(""); + $("#clientDialog #remark").val(""); + $("#clientDialog input[name=permissionData]").iCheck("uncheck"); + + $("#clientDialog input[name=isEnableWhite][value='" + 0 + "']").iCheck("check"); + $("#clientDialog input[name=isEnableBlack][value='" + 0 + "']").iCheck("check"); + $("#clientDialog input[name=isRemoteLoginNotice][value='" + 0 + "']").iCheck("check"); + $("#clientDialog input[name=isMobileCaptcha][value='" + 0 + "']").iCheck("check"); + $("#clientDialog input[name=isHideMobile][value='" + 0 + "']").iCheck("check"); + $("#clientDialog input[name=isDisplayStatus][value='" + 0 + "']").iCheck("check"); + $("#clientDialog input[name=isLoginIpRestrict][value='" + 0 + "']").iCheck("check"); + + $("#clientDialog #isLoginIpAllowGather").val(""); + $("#clientDialog input[name=isLoginCityRestrict][value='" + 0 + "']").iCheck("check"); + $("#clientDialog #isLoginCityAllowGather").val(""); + + $("#clientDialog").modal("show"); + + //鍒锋柊涓�娆¢殢鏈哄瘑鐮� + $("#password").val(randomString(8)); + + $(".pwdCss").show(); + + }); + + //缂栬緫 + $(document).on("click", ".action-modal-edit", function () { + $("#clientDialog .modal-title").text("淇敼瀹㈡埛璧勬枡"); + $("#clientDialog input[name=action]").val("update"); + var id = $(this).data("id"); + $.get("gwclient.ashx?action=get", { clientID: id }, function (r) { + if (r.OK) { + try { + $("#clientDialog #id").val(r.Message.Id); + $("#clientDialog #clientID").val(r.Message.ClientID); + $("#clientDialog #company").val(r.Message.Company); + //$("#clientDialog #password").val(r.Message.Password); + $("#clientDialog #password").val(""); + //缂栬緫鏃跺瘑鐮佹闅愯棌 + $(".pwdCss").hide(); + + $("#clientDialog #clientName").val(r.Message.ClientName); + $("#clientDialog #agent").val(r.Message.Agent); + $("#clientDialog #address").val(r.Message.Address); + $("#clientDialog #telephone").val(r.Message.Telephone); + $("#clientDialog #chargeType").val(r.Message.ChargeType); + $("#clientDialog #smsStatusReport").val(r.Message.SmsStatusReport); + $("#clientDialog #mmsStatusReport").val(r.Message.MmsStatusReport); + $("#clientDialog #customerManager").val(r.Message.CustomerManager); + $("#clientDialog #salesman").val(r.Message.Salesman); + $("#clientDialog #supportStaff").val(r.Message.SupportStaff); + $("#clientDialog #financialStaff").val(r.Message.FinancialStaff); + $("#clientDialog #remark").val(r.Message.Remark); + var permissionData = $.evalJSON(r.Message.PermissionData); + $("#clientDialog input[name=permissionData]").iCheck("uncheck"); + $.each(permissionData, function (i) { + $("#clientDialog input[name=permissionData][value='" + this + "']").iCheck("check"); + }); + + //$("#clientDialog #isEnableWhite").val(r.Message.IsEnableWhite); + $("#clientDialog input[name=isEnableWhite]").iCheck("uncheck"); + $("#clientDialog input[name=isEnableWhite][value='" + r.Message.IsEnableWhite + "']").iCheck("check"); + + //$("#clientDialog #isEnableBlack").val(r.Message.IsEnableBlack); + $("#clientDialog input[name=isEnableBlack]").iCheck("uncheck"); + $("#clientDialog input[name=isEnableBlack][value='" + r.Message.IsEnableBlack + "']").iCheck("check"); + //$("#clientDialog #isRemoteLoginNotice").val(r.Message.IsRemoteLoginNotice); + $("#clientDialog input[name=isRemoteLoginNotice]").iCheck("uncheck"); + $("#clientDialog input[name=isRemoteLoginNotice][value='" + r.Message.IsRemoteLoginNotice + "']").iCheck("check"); + //$("#clientDialog #isMobileCaptcha").val(r.Message.IsMobileCaptcha); + $("#clientDialog input[name=isMobileCaptcha]").iCheck("uncheck"); + $("#clientDialog input[name=isMobileCaptcha][value='" + r.Message.IsMobileCaptcha + "']").iCheck("check"); + //$("#clientDialog #isHideMobile").val(r.Message.IsHideMobile); + $("#clientDialog input[name=isHideMobile]").iCheck("uncheck"); + $("#clientDialog input[name=isHideMobile][value='" + r.Message.IsHideMobile + "']").iCheck("check"); + //$("#clientDialog #isDisplayStatus").val(r.Message.IsDisplayStatus); + $("#clientDialog input[name=isDisplayStatus]").iCheck("uncheck"); + $("#clientDialog input[name=isDisplayStatus][value='" + r.Message.IsDisplayStatus + "']").iCheck("check"); + //$("#clientDialog #isLoginIpRestrict").val(r.Message.IsLoginIpRestrict); + $("#clientDialog input[name=isLoginIpRestrict]").iCheck("uncheck"); + $("#clientDialog input[name=isLoginIpRestrict][value='" + r.Message.IsLoginIpRestrict + "']").iCheck("check"); + + $("#clientDialog #isLoginIpAllowGather").val(r.Message.IsLoginIpAllowGather); + //$("#clientDialog #isLoginCityRestrict").val(r.Message.IsLoginCityRestrict); + $("#clientDialog input[name=isLoginCityRestrict]").iCheck("uncheck"); + $("#clientDialog input[name=isLoginCityRestrict][value='" + r.Message.IsLoginCityRestrict + "']").iCheck("check"); + $("#clientDialog #isLoginCityAllowGather").val(r.Message.IsLoginCityAllowGather); + } + catch (e) { + } + + $("#clientDialog").modal("show"); + } + else { + mytek.alert(r.Message, r.OK); + } + }, "json"); + }); + + //鍏嶅瘑鐧诲綍 + $(document).on("click", ".action-modal-login", function () { + var url = $(this).data("url"); + var id = $(this).data("id"); + + var milliseconds = new Date().getTime(); //鑾峰緱褰撳墠鏃堕棿鐨勬绉掑�� + url += "&t=" + milliseconds; + //console.log(url); + window.open(url, "_blank"); + + + }); + + //榛戝悕鍗� + $(document).on("click", ".action-modal-black", function () { + var id = $(this).data("id"); + $.get("gwclient.ashx?action=getBlack", { clientID: id }, function (r) { + if (r.OK) { + $("#blackDialog input[name='clientID']").val(id); + $("#blackDialog textarea").val(r.Message); + $("#blackDialog").modal("show"); + } + else { + mytek.alert(r.Message, r.OK); + } + }, "json"); + }); + + //鐧藉悕鍗� + $(document).on("click", ".action-modal-white", function () { + var id = $(this).data("id"); + $.get("gwclient.ashx?action=getWhite", { clientID: id }, function (r) { + if (r.OK) { + $("#whiteDialog input[name='clientID']").val(id); + $("#whiteDialog textarea").val(r.Message); + $("#whiteDialog").modal("show"); + } + else { + mytek.alert(r.Message, r.OK); + } + }, "json"); + }); + + //闈㈡澘椤垫彁浜わ細闅愯棌闈㈡澘锛堢櫧鍚嶅崟锛岄粦鍚嶅崟锛屼慨鏀瑰瘑鐮侊級 + $("#blackForm, #whiteForm").ajaxForm({ + success: function (r) { + mytek.alert(r.Message, r.OK, function () { + $("#whiteDialog, #blackDialog").modal("hide"); + }); + } + }); + + //闈㈡澘椤垫彁浜わ細閲嶆柊鍔犺浇鍒楄〃 + $("#clientForm, #updatePwdForm").ajaxForm({ + success: function (r) { + mytek.alert(r.Message, r.OK, function () { + r.OK && (window.location.reload()); + }); + } + }); + + //淇敼瀵嗙爜锛氭墦寮�鐣岄潰 + $(document).on("click", ".action-modal-updatePwd", function () { + //$("#updatePwdDialog .modal-title").text("淇敼瀹㈡埛璧勬枡"); + $("#updatePwdDialog input[name=action]").val("updatePwd"); + var id = $(this).data("id"); + + $("#updatePwdDialog input[name='clientID']").val(id); + $("#updatePwdDialog #newPwd").val(""); + + $("#updatePwdDialog").modal("show"); + + }); + + //淇敼鍒嗛厤涓�т骇鍝侊細鏄剧ず瀹㈡埛瀵瑰簲鐨勫垎閰嶄釜鎬т骇鍝� + $(document).on("click", ".action-modal-updateProduct", function () { + var clientId = $(this).data("id"); + $.get("GwClient.ashx", { action: "getPersonalityProduct", clientId: clientId }, function (result) { + if (!result.OK) { + mytek.alert(result.Message, result.OK); + } + else { + $("#updateProductDialog input[name='clientID']").val(clientId); + $("#updateProductDialog #_ProductId").prop("checked", false); + $.each(result.Message, function (i) { + $("#updateProductDialog #_ProductId[value='" + this + "']").prop("checked", true); + }); + } + $("#updateProductDialog").modal("show"); + }, "json"); + }); + + //淇敼鍒嗛厤涓�т骇鍝侊細淇敼纭 + $(document).on("click", ".action-updateProduct", function () { + var productIdArray = []; + //mytek.confirm("鏄惁闇�瑕佷慨鏀瑰鎴峰垎閰嶄釜鎬т骇鍝侊紵", "纭鍒嗛厤涓�т骇鍝侊紝璇疯皑鎱庢搷浣滐紒", function (b) { + //if (b) { + if (confirm("鏄惁闇�瑕佷慨鏀瑰鎴峰垎閰嶄釜鎬т骇鍝侊紵") == true) { + $("#updateProductDialog #_ProductId").each(function () { + if ($(this).is(":checked")) { + productIdArray.push($(this).val()); + } + }); + + //var clientId = $("#updateProductDialog").data("id"); + var clientId = $("#updateProductDialog input[name='clientID']").val(); + $.ajax({ + url: "GwClient.ashx", + type: "POST", + data: { action: "updateProduct", clientId: clientId, productIdArray: $.toJSON(productIdArray) }, + success: function (result) { + if (result.OK) { + $("#updateProductDialog").modal("hide"); + loadPageList(); + } else { + mytek.alert(result.Message, result.OK); + } + } + }); + + //swal.close(); + //} + //}); + } + }); + + + //鍏呭�� + $(document).on("click", ".action-modal-orderCreate", function () { + var clientId = $(this).data("id"); //瀹㈡埛璐﹀彿 + //window.open("gwOrderCreate.aspx?spId=" + spID, 'gwOrderCreate'); + window.location.href = "gwOrderCreate.aspx?clientId=" + clientId; + }); + + //鍏呭�兼棩蹇� + $(document).on("click", ".action-modal-orderLog", function () { + var clientId = $(this).data("id"); + window.location.href = "GwOrderList.aspx?clientId=" + clientId + ""; + }); + + //鍚敤鎴栧仠鐢� + $(document).on("click", ".action-modal-updateStatus", function () { + //data鐨勫睘鎬у弬鏁颁笉鑳藉惈鏈夊ぇ鍐欏瓧姣嶃�� + var clientId = $(this).data("id"); + var isEnable = $(this).data("status"); + var statusMsg = ""; + if (isEnable == 0) { + statusMsg = "銆愬仠鐢ㄣ��"; + } + else { + statusMsg = "銆愬惎鐢ㄣ��"; + } + mytek.confirm("鏄惁闇�瑕�" + statusMsg + "璇ヤ俊鎭紵", "纭鏇存柊淇℃伅鐘舵�侊紝璇疯皑鎱庢搷浣滐紒", function (b) { + if (b) { + $.post("gwclient.ashx", { "action": "updateStatus", clientId: clientId, isEnable: isEnable }, function (r) { + mytek.alert(r.Message, r.OK, function () { + loadPageList(); + }); + }); + } + }); + }); + + //鍒犻櫎 + $(document).on("click", ".action-delete", function () { + var id = $(this).data("id"); + mytek.confirm("鏄惁闇�瑕佸垹闄よ瀹㈡埛锛�", "瀹㈡埛鍒犻櫎鍚庡皢鏃犳硶鎭㈠锛岃璋ㄦ厧鎿嶄綔锛�", function (b) { + if (b) { + $.post("gwclient.ashx", { action: "delete", clientID: id }, function (r) { + mytek.alert(r.Message, r.OK, function () { + window.location.reload(); + }); + }); + } + }); + }); + + /** + //閲嶇疆瀵嗙爜 + $(document).on("click", ".action-modal-resetPwd", function () { + var id = $(this).data("id"); + mytek.confirm("閲嶇疆瀵嗙爜锛�", "鏄惁閲嶇疆瀵嗙爜锛熻璋ㄦ厧鎿嶄綔锛�", function (b) { + if (b) { + $.post("gwclient.ashx", { action: "resetPwd", clientID: id }, function (r) { + mytek.alert(r.Message, r.OK, function () { + window.location.reload(); + }); + }); + } + }); + }); + **/ + + }) + + + $("#pager").Pager({ + pageSize: 20, + onChange: function (pageIndex, pageSize) { + loadPageList(); + } + }); + + function loadPageList() { + var ClientID = $("#ClientID").val(); + var Company = $("#Company").val(); + var ClientName = $("#ClientName").val(); + var Telephone = $("#Telephone").val(); + //var Agent = $("#Agent").val(); + var Agent = ""; + var Salesman = $("#Salesman").val(); + var SupportStaff = $("#SupportStaff").val(); + var ProductId = $("#ProductId").val(); + var IsEnable = <%=IsEnable%>; + $.ajax({ + url: "GwClient.ashx", + type: "POST", + data: { action: "loadGwClientPageList", ClientID: ClientID, Company: Company, ClientName: ClientName, Telephone: Telephone, Agent: Agent, Salesman: Salesman, SupportStaff: SupportStaff, ProductId: ProductId, IsEnable: IsEnable , pageSize: $("#pager").Pager("getPageSize"), pageIndex: $("#pager").Pager("getPageIndex") }, + success: function (result) { + if (result.OK) { + $("#gwclientTable tbody").html(result.Message.Table); + $("#pager").Pager("setTotalCount", result.Message.TotalCount); + } else { + mytek.alert(result.Message, result.OK); + } + } + }); + } + + function randomString(len) { + len = len || 32; + var $chars = 'ABCDEFGHJKMNPQRSTWXYZabcdefhijkmnprstwxyz2345678'; /****榛樿鍘绘帀浜嗗鏄撴贩娣嗙殑瀛楃oOLl,9gq,Vv,Uu,I1****/ + var maxPos = $chars.length; + var pwd = ''; + for (i = 0; i < len; i++) { + pwd += $chars.charAt(Math.floor(Math.random() * maxPos)); + } + return pwd; + } + + + + + + //鎵归噺鍒嗛厤涓�т骇鍝�:鎵撳紑鐣岄潰 + $(document).on("click", ".action-modal-setProduct", function () { + var idArray = []; + + $("input[name='checkbox']:checkbox:checked").each(function () { + var id = $(this).val(); + idArray.push(id); + }); + + if (idArray.length == 0) { + mytek.alert("璇烽�夋嫨瑕佸垎閰嶄釜鎬т骇鍝佺殑瀹㈡埛锛�", false); + return; + } + + $("#selected-op-box").text(idArray.join(",")); + + $("#setProductDialog").modal("show"); + }); + + //鎵归噺鍒嗛厤瀹㈡埛涓�т骇鍝�--纭淇敼 + $(document).on("click", ".action-update-setProduct", function () { + var idArray = []; + + $("input[name='checkbox']:checkbox:checked").each(function () { + var id = $(this).val(); + idArray.push(id); + }); + + if (idArray.length == 0) { + mytek.alert("璇烽�夋嫨瑕佸垎閰嶄釜鎬т骇鍝佺殑瀹㈡埛锛�", false); + return; + } + + var productId = $("#productId").val(); + + $.ajax({ + url: "GwClient.ashx", + method: "POST", + data: { idArray: $.toJSON(idArray), productId: productId, action: "batchUpdateClientProduct" }, + success: function (result) { + mytek.alert(result.Message, result.OK, function () { + $("#setProductDialog #productId").val(""); + $("#setProductDialog").modal("hide"); + loadPageList(); + }); + } + }); + }); + + //瀵煎嚭鏁版嵁 + $(document).on("click", ".action-export", function () { + var ClientID = $("#ClientID").val(); + var Company = $("#Company").val(); + var ClientName = $("#ClientName").val(); + var Telephone = $("#Telephone").val(); + //var Agent = $("#Agent").val(); + var Agent = ""; + var Salesman = $("#Salesman").val(); + var SupportStaff = $("#SupportStaff").val(); + var ProductId = $("#ProductId").val(); + var IsEnable = <%=IsEnable%>; + var url = "ExportDocument.aspx?action=exportGwClient&ClientID=" + ClientID + "&Company=" + Company + "&ClientName=" + ClientName + "&Telephone=" + Telephone + "&Agent=" + Agent + "&Salesman=" + Salesman + "&SupportStaff=" + SupportStaff + "&ProductId=" + ProductId + "&IsEnable=" + IsEnable + ""; + + window.location.href = url; + }); + + + //娣诲姞瀹㈡埛锛氱敓鎴愬瘑鐮� + $(document).on("click", ".action-generate-password", function () { + $("#password").val(randomString(8)); + }); + + //娣诲姞瀹㈡埛锛氬鍒跺瘑鐮� + $(document).on("click", ".action-copyPwd", function () { + var value = $("#password").val(); + if (value == "") { + mytek.alert("璇风敓鎴愬瘑鐮侊紒"); + return false; + } + // for ie + if (window.clipboardData) { + window.clipboardData.clearData(); + window.clipboardData.setData('text', value); + } + // for modern browser + else if (document.execCommand) { + var element = document.createElement('SPAN'); + element.textContent = value; + document.body.appendChild(element); + if (document.selection) { + var range = document.body.createTextRange(); + range.moveToElementText(element); + range.select(); + } else if (window.getSelection) { + var range = document.createRange(); + range.selectNode(element); + window.getSelection().removeAllRanges(); + window.getSelection().addRange(range); + } + document.execCommand('copy'); + element.remove ? element.remove() : element.removeNode(true); + } + mytek.alert("澶嶅埗鎴愬姛锛�", true); + + }); + + //淇敼瀵嗙爜锛氱敓鎴愬瘑鐮� + $(document).on("click", ".action-generate-newPwd", function () { + $("#newPwd").val(randomString(8)); + }); + + //淇敼瀵嗙爜锛氬鍒跺瘑鐮� + $(document).on("click", ".action-copyNewPwd", function () { + var value = $("#newPwd").val(); + if (value == "") { + mytek.alert("璇风敓鎴愬瘑鐮侊紒"); + return false; + } + + // for ie + if (window.clipboardData) { + window.clipboardData.clearData(); + window.clipboardData.setData('text', value); + } + // for modern browser + else if (document.execCommand) { + var element = document.createElement('SPAN'); + element.textContent = value; + document.body.appendChild(element); + if (document.selection) { + var range = document.body.createTextRange(); + range.moveToElementText(element); + range.select(); + } else if (window.getSelection) { + var range = document.createRange(); + range.selectNode(element); + window.getSelection().removeAllRanges(); + window.getSelection().addRange(range); + } + document.execCommand('copy'); + element.remove ? element.remove() : element.removeNode(true); + } + mytek.alert("澶嶅埗鎴愬姛锛�", false); + + }); + + </script> +</asp:Content> +<asp:Content ID="Content2" ContentPlaceHolderID="title" runat="Server">瀹㈡埛淇℃伅</asp:Content> +<asp:Content ID="Content3" ContentPlaceHolderID="content" runat="Server"> + <div class="modal inmodal fade" id="whiteDialog" tabindex="-1" role="dialog" aria-hidden="true"> + <form name="whiteForm" method="post" action="gwclient.ashx?action=updateWhite" id="whiteForm" + class="form-horizontal"> + <div class="modal-dialog modal-sm"> + <div class="modal-content "> + <div class="modal-header"> + <button type="button" class="close" data-dismiss="modal"> + <span aria-hidden="true">×</span><span class="sr-only">Close</span></button> + <h4 class="modal-title">瀹㈡埛鐧藉悕鍗� + </h4> + 瀹㈡埛鐧藉悕鍗曞璇ュ鎴蜂笅鎵�鏈夋帴鍏ヨ处鍙峰潎鏈夋晥<input type="hidden" value="" name="clientID" /> + </div> + <div class="modal-body"> + <div class="form-group"> + <span class="help-block m-b-none">姣忚涓�涓彿鐮侊紝瀹㈡埛鐧藉悕鍗曞唴鐨勬墜鏈哄彿鐮佸皢涓嶅彈姣忓皬鏃朵笅鍙戞鏁伴檺鍒讹紱 鐧藉悕鍗曟�绘暟灏介噺鎺у埗2000浠ュ唴</span> + </div> + <div class="form-group"> + <textarea class="form-control" name="mobileData" rows="6"></textarea> + </div> + </div> + <div class="modal-footer"> + <button class="btn btn-warning" data-dismiss="modal" aria-hidden="true"> + 鍙栨秷</button> + <button class="btn btn-primary action-save"> + 淇濆瓨</button> + </div> + </div> + </div> + </form> + </div> + <div class="modal inmodal fade" id="blackDialog" tabindex="-1" role="dialog" aria-hidden="true"> + <form name="blackForm" method="post" action="gwclient.ashx?action=updateBlack" id="blackForm" + class="form-horizontal"> + <div class="modal-dialog modal-sm"> + <div class="modal-content "> + <div class="modal-header"> + <button type="button" class="close" data-dismiss="modal"> + <span aria-hidden="true">×</span><span class="sr-only">Close</span></button> + <h4 class="modal-title">瀹㈡埛榛戝悕鍗� + </h4> + 瀹㈡埛榛戝悕鍗曞璇ュ鎴蜂笅鎵�鏈夋帴鍏ヨ处鍙峰潎鏈夋晥<input type="hidden" value="" name="clientID" /> + </div> + <div class="modal-body"> + <div class="form-group"> + <span class="help-block m-b-none">姣忚涓�涓彿鐮侊紝瀹㈡埛榛戝悕鍗曞唴鐨勬墜鏈哄彿鐮佸皢鏃犳硶涓嬪彂鐭俊锛� 榛戝悕鍗曟�绘暟灏介噺鎺у埗2000浠ュ唴锛涘闇�鏇村ぇ榛戝悕鍗曪紝璇蜂娇鐢ㄥ叏灞�榛戝悕鍗�</span> + </div> + <div class="form-group"> + <textarea class="form-control" name="mobileData" rows="6"> </textarea> + </div> + </div> + <div class="modal-footer"> + <button class="btn btn-warning" data-dismiss="modal" aria-hidden="true"> + 鍙栨秷</button> + <button class="btn btn-primary action-save"> + 淇濆瓨</button> + </div> + </div> + </div> + </form> + </div> + + <!--閲嶇疆瀵嗙爜鎴栦慨鏀瑰瘑鐮� --> + <div class="modal inmodal fade" id="updatePwdDialog" tabindex="-1" role="dialog" aria-hidden="true"> + <form name="updatePwdForm" method="post" action="gwclient.ashx?action=updatePwd" id="updatePwdForm" + class="form-horizontal"> + <div class="modal-dialog modal-lg"> + <div class="modal-content "> + <div class="modal-header"> + <button type="button" class="close" data-dismiss="modal"> + <span aria-hidden="true">×</span><span class="sr-only">Close</span></button> + <h4 class="modal-title">瀹㈡埛淇℃伅瀵嗙爜淇敼 + </h4> + 璇峰厛鎵ц銆愮敓鎴愬瘑鐮併�戝悗锛屽啀鎵ц銆愬鍒跺瘑鐮併�戙�� + </div> + <div class="modal-body"> + <input type="hidden" value="" name="clientID" /> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鐧诲綍瀵嗙爜 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <input type="password" name="newPwd" id="newPwd" value="" class="form-control" /> + </div> + <div class="col-sm-6"> + <a class="btn btn-xs btn-primary action-generate-newPwd ">鐢熸垚瀵嗙爜</a> + <a class="btn btn-xs btn-success action-copyNewPwd " >澶嶅埗瀵嗙爜</a> + </div> + </div> + </div> + <div class="modal-footer"> + <button class="btn btn-warning" data-dismiss="modal" aria-hidden="true"> + 鍙栨秷</button> + <button class="btn btn-primary action-save"> + 淇濆瓨</button> + </div> + </div> + </div> + </form> + </div> + + + <!--鍒涘缓瀹㈡埛淇℃伅闈㈡澘 --> + <div class="modal inmodal fade" id="clientDialog" tabindex="-1" role="dialog" aria-hidden="true"> + <form name="clientForm" method="post" action="gwclient.ashx" id="clientForm" class="form-horizontal"> + <div class="modal-dialog modal-lg"> + <div class="modal-content "> + <div class="modal-header"> + <button type="button" class="close" data-dismiss="modal"> + <span aria-hidden="true">×</span><span class="sr-only">Close</span></button> + <h4 class="modal-title">鍒涘缓/淇敼瀹㈡埛淇℃伅 + </h4> + <input name="action" value="add" type="hidden" /> + <input name="id" id="id" type="hidden" value="" /> + </div> + <div class="modal-body"> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鐧诲綍璐︽埛 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <input type="text" name="clientID" id="clientID" value="" class="form-control" /> + </div> + <!--<span class="help-block m-b-none"><i class="fa fa-exclamation-triangle"></i>璇疯緭鍏ュ叕鍙稿崟浣嶅悕绉�</span>--> + </div> + + <div class="form-group"> + <label class="control-label col-sm-2"> + 鍏徃鍚嶇О锛堝叏绉帮級 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <input type="text" name="company" id="company" value="" class="form-control" /> + </div> + <!--<span class="help-block m-b-none"><i class="fa fa-exclamation-triangle"></i>璇疯緭鍏ュ叕鍙稿崟浣嶅悕绉�</span>--> + </div> + + + <div class="form-group pwdCss"> + <label class="control-label col-sm-2"> + 鐧诲綍瀵嗙爜 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <input type="password" name="password" id="password" value="123456" class="form-control" /> + </div> + <div class="col-sm-6"> + <a class="btn btn-xs btn-primary action-generate-password ">鐢熸垚瀵嗙爜</a> + <a class="btn btn-xs btn-success action-copyPwd " >澶嶅埗瀵嗙爜</a> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鑱旂郴浜� <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <input type="text" name="clientName" id="clientName" value="" class="form-control" /> + </div> + </div> + <div class="form-group "> + <label class="control-label col-sm-2"> + 鑱旂郴鐢佃瘽 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <input type="text" name="telephone" id="telephone" value="" class="form-control" /> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鑱旂郴鍦板潃 + </label> + <div class="col-sm-10"> + <input type="text" name="address" id="address" value="" class="form-control" /> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 缁撹垂鏂瑰紡 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <select name="chargeType" id="chargeType" class="form-control"> + <option value="" ></option> + <option value="1" >棰勪粯璐�</option> + <option value="2" >鍚庝粯璐�</option> + </select> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鐭俊鏄惁鏄剧ず鐘舵�佹姤鍛� <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <select name="smsStatusReport" id="smsStatusReport" class="form-control"> + <option value="0" >涓嶆樉绀�</option> + <%--<option value="1" >鍙樉绀烘彁浜ゅけ璐ヤ负鍙戦�佸け璐ョ姸鎬�</option>--%> + <option value="2" >鏄剧ず</option> + </select> + </div> + </div> + + <div class="form-group"> + <label class="control-label col-sm-2"> + 褰掑睘瀹㈡埛缁忕悊 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <select name="customerManager" id="customerManager" class="form-control"> + <%=customerManagerOptions(0)%> + </select> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 褰掑睘涓氬姟鍛� <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <select name="salesman" id="salesman" class="form-control"> + <%=salesmanOptions(0)%> + </select> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 褰掑睘瀹㈡湇浜哄憳 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <select name="supportStaff" id="supportStaff" class="form-control"> + <%=supportStaffOptions(0)%> + </select> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 褰掑睘璐㈠姟浜哄憳 <span style="color:red">*</span> + </label> + <div class="col-sm-4"> + <select name="financialStaff" id="financialStaff" class="form-control"> + <%=financialStaffOptions(0)%> + </select> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2">钀ヤ笟鎵х収</label> + <div class="col-sm-4"> + <input type="file" name="txt_file" id="txt_file" class="file-loading" /> + </div> + </div> + <!-- + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏉冮檺绠$悊 + </label> + <div class="col-sm-10"> + <input type="checkbox" class="icheck-me" value="GwClientList.aspx" name="permissionData" />浠g悊鍟嗙鐞�(*鏄惁鏀寔鍒涘缓涓嬬骇浠g悊) + <!//-- + <input type="checkbox" class="icheck-me" value="LgSmsDetailReport.aspx" name="permissionData" />鏌ョ湅鐘舵�佹姤鍛� + <input type="checkbox" class="icheck-me" value="1" name="permissionData" />鍙戦�佹潈闄� + <input type="checkbox" class="icheck-me" value="2" name="permissionData" />鏌ョ湅鏁版嵁鏉冮檺 + --//> + </div> + </div> + --> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏄惁鍚敤鐧藉悕鍗� + </label> + <div class="col-sm-4"> + <input type="radio" class="icheck-me" name="isEnableWhite" value="0" checked="checked" /><label>绂佺敤</label> + <input type="radio" class="icheck-me" name="isEnableWhite" value="1" /><label>鍚敤</label> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏄惁鍚敤榛戝悕鍗� + </label> + <div class="col-sm-4"> + <input type="radio" class="icheck-me" name="isEnableBlack" value="0" checked="checked" /><label>绂佺敤</label> + <input type="radio" class="icheck-me" name="isEnableBlack" value="1" /><label>鍚敤</label> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏄惁寮傚湴鐧诲綍閫氱煡 + </label> + <div class="col-sm-4"> + <input type="radio" class="icheck-me" name="isRemoteLoginNotice" value="0" checked="checked" /><label>绂佺敤</label> + <input type="radio" class="icheck-me" name="isRemoteLoginNotice" value="1" /><label>鍚敤</label> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏄惁鍚敤鎵嬫満楠岃瘉鐮� + </label> + <div class="col-sm-4"> + <input type="radio" class="icheck-me" name="isMobileCaptcha" value="0" checked="checked" /><label>绂佺敤</label> + <input type="radio" class="icheck-me" name="isMobileCaptcha" value="1" /><label>鍚敤</label> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏄惁闅愯棌瀹㈡埛绔墜鏈哄彿 + </label> + <div class="col-sm-4"> + <input type="radio" class="icheck-me" name="isHideMobile" value="0" checked="checked" /><label>绂佺敤</label> + <input type="radio" class="icheck-me" name="isHideMobile" value="1" /><label>鍚敤</label> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏄惁鏄剧ず鐘舵�佹帴鍙� + </label> + <div class="col-sm-8"> + <input type="radio" class="icheck-me" name="isDisplayStatus" value="0" checked="checked" /><label>涓嶆樉绀�</label> + <input type="radio" class="icheck-me" name="isDisplayStatus" value="1" /><label>鍙樉绀烘彁浜ゅけ璐ヤ负鍙戦�佸け璐ョ姸鎬�</label> + <input type="radio" class="icheck-me" name="isDisplayStatus" value="2" /><label>鏄剧ず鍏ㄩ儴鐘舵�佺姸鎬�</label> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏄惁鍚敤鐧诲綍IP闄愬埗 + </label> + <div class="col-sm-4"> + <input type="radio" class="icheck-me" name="isLoginIpRestrict" value="0" checked="checked" /><label>绂佺敤</label> + <input type="radio" class="icheck-me" name="isLoginIpRestrict" value="1" /><label>鍚敤</label> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鐧诲綍IP鍏佽闆嗗悎 + </label> + <div class="col-sm-4"> + <textarea class="form-control" name="isLoginIpAllowGather" id="isLoginIpAllowGather" rows="4" ></textarea> + <!--<span class="help-block m-b-none">閰嶅悎鏄惁鍚敤鐧诲綍IP闄愬埗涓�璧蜂娇鐢紝澶氫釜闄愬埗IP鏃讹紝鎸夊崐瑙掗�楀彿","鍒嗛殧銆傚彲浣跨敤IP娈碉紝濡傦細202.203.1.*銆�</span>--> + <span class="help-block m-b-none">閰嶅悎鏄惁鍚敤鐧诲綍IP闄愬埗涓�璧蜂娇鐢紝澶氫釜闄愬埗IP鏃讹紝姣忎竴琛屼负1涓狪P銆傚彲浣跨敤IP娈碉紝濡傦細202.203.1.*銆�</span> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鏄惁鍚敤鐧诲綍鍦板尯锛堝煄甯傦級闄愬埗 + </label> + <div class="col-sm-4"> + <input type="radio" class="icheck-me" name="isLoginCityRestrict" value="0" checked="checked" /><label>绂佺敤</label> + <input type="radio" class="icheck-me" name="isLoginCityRestrict" value="1" /><label>鍚敤</label> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 鐧诲綍鍦板尯锛堝煄甯傦級鍏佽闆嗗悎 + </label> + <div class="col-sm-4"> + <textarea class="form-control" name="isLoginCityAllowGather" id="isLoginCityAllowGather" rows="4" ></textarea> + <!--<span class="help-block m-b-none">閰嶅悎鏄惁鍚敤鐧诲綍鍩庡競闄愬埗涓�璧蜂娇鐢紝澶氫釜闄愬埗鍦板尯鏃讹紝鎸夊崐瑙掗�楀彿","鍒嗛殧銆� </span>--> + <span class="help-block m-b-none">閰嶅悎鏄惁鍚敤鐧诲綍鍩庡競闄愬埗涓�璧蜂娇鐢紝澶氫釜闄愬埗鍦板尯鏃讹紝姣忎竴琛屼负1涓湴鍖猴紙鍩庡競锛夈�� </span> + </div> + </div> + <div class="form-group"> + <label class="control-label col-sm-2"> + 澶囨敞 + </label> + <div class="col-sm-10"> + <input type="text" name="remark" id="remark" value="" class="form-control" /> + </div> + </div> + </div> + <div class="modal-footer"> + <button class="btn btn-warning" data-dismiss="modal" aria-hidden="true"> + 鍙栨秷</button> + <button class="btn btn-primary action-save"> + 淇濆瓨</button> + </div> + </div> + </div> + </form> + </div> + + <!-- 鏉′欢鏌ヨ --> + <form name="queryForm" method="post" id="queryForm" class="form-inline"> + <div class="form-group"> + <div class="input-group m-b"> + <span class="input-group-addon">瀹㈡埛璐︽埛</span> + <input type="text" name="ClientID" id="ClientID" class="form-control" /> + </div> + </div> + <div class="form-group"> + <div class="input-group m-b"> + <span class="input-group-addon">鍏徃鍚嶇О</span> + <input type="text" name="Company" id="Company" class=" form-control" /> + </div> + </div> + <div class="form-group"> + <div class="input-group m-b"> + <span class="input-group-addon">鑱旂郴浜�</span> + <input type="text" name="ClientName" id="ClientName" class="form-control" /> + </div> + </div> + <div class="form-group"> + <div class="input-group m-b"> + <span class="input-group-addon">鑱旂郴鐢佃瘽</span> + <input type="text" name="Telephone" id="Telephone" class="form-control" /> + </div> + </div> + <div class="form-group"> + <div class="input-group m-b"> + <span class="input-group-addon">褰掑睘涓氬姟鍛�</span> + <select name="Salesman" id="Salesman" class="form-control"> + <%=salesmanOptions(-1)%> + </select> + </div> + </div> + <div class="form-group"> + <div class="input-group m-b"> + <span class="input-group-addon">褰掑睘瀹㈡湇浜哄憳</span> + <select name="SupportStaff" id="SupportStaff" class="form-control"> + <%=supportStaffOptions(-1)%> + </select> + </div> + </div> + <div class="form-group"> + <div class="input-group m-b"> + <span class="input-group-addon">宸插垎閰嶆縺娲讳骇鍝�</span> + <select name="ProductId" id="ProductId" class="form-control"> + <%=GetProductOptions("")%> + </select> + </div> + </div> + <div class="form-group"> + <div class="input-group m-b"> + <input type="button" value="鏌ヨ" class="btn btn-primary action-query" />  + + <% if(IsEnable==1) { %> + <input class="btn btn-success action-modal-create" value="鍒涘缓瀹㈡埛" type="button" />  + <%} %> + </div> + + </div> + </form> + + <!-- 鍒楄〃 --> + <div class="table-responsive"> + <% if(IsEnable==1) { %> + <input class="btn btn-danger action-modal-setProduct" value="鎵归噺鍒嗛厤涓�т骇鍝�" type="button" /> + <%} %> + <input class="btn btn-info action-export" value="瀵煎嚭鏁版嵁" type="button" /> + <table class="table table-striped table-bordered table-hover" id="gwclientTable" style="margin:10px 0 0 0;"> + <thead> + <tr class="header"> + <th> + <input type='checkbox' name='checkAll' id='checkAll' /> + </th> + <th>瀹㈡埛璐︽埛 + </th> + <th>鍏徃鍚嶇О</th> + <th>鑱旂郴浜� + </th> + <th>鑱旂郴鐢佃瘽 + </th> + <th>璐︽埛浣欓(鍏�) + </th> + <th>绱鍏呭��(鍏�) + </th> + + <th>涓氬姟鍛� + </th> + + <th>宸插垎閰嶄釜鎬т骇鍝�(澶氫釜鎸夆��,鈥濆垎闅�) + </th> + <!-- + <th>璁よ瘉鐘舵�� + </th> + --> + + <th>鐘舵�� + </th> + <th>鎿嶄綔 + </th> + </tr> + </thead> + <tbody> + </tbody> + + </table> + </div> + <div id="pager" style="margin:10px 0 0 0;"> + </div> + + <!--鎵归噺淇敼涓�т骇鍝� --> + <div class="modal inmodal fade" id="setProductDialog" tabindex="-1" role="dialog" aria-hidden="true"> + <div class="modal-dialog form-horizontal"> + <div class="modal-content animated "> + <div class="modal-header"> + <span class="title"><h3>鎵归噺鍒嗛厤涓�т骇鍝�</h3></span><a class="close" data-dismiss="modal" aria-hidden="true">脳</a> + <span class="text-muted"> + 鎵归噺鍒嗛厤涓�т骇鍝佸皢浼氭洿鏂版墍鏈夐�変腑鐨勮处鎴风殑瀹㈡埛锛�<br /> + 纭畾鍒嗛厤涓嶈兘鍙栨秷锛岃璋ㄦ厧鎿嶄綔锛�<br /> + </span> + </div> + <div class="modal-body"> + <div class="form-group"> + <label class="col-sm-2 control-label"> + 涓�т骇鍝� + </label> + <div class="col-sm-10"> + <select name="productId" id="productId" class="form-control"> + <%=GetPersonalityProductOptions("")%> + </select> + </div> + </div> + </div> + <div class="modal-footer"> + <button class="btn-default btn" data-dismiss="modal" aria-hidden="true"> + 鍙栨秷</button> + <input class="btn btn-primary action-update-setProduct" value="纭畾淇敼" type="button" /> + </div> + </div> + </div> + </div> + + <!-- 瀹㈡埛淇敼涓�т骇鍝� --> + <div class="modal inmodal fade" id="updateProductDialog" tabindex="-1" role="dialog" aria-hidden="true"> + <div class="modal-dialog"> + <div class="modal-content animated bounceInRight"> + <input type="hidden" value="" name="clientID" /> + <div class="modal-header"> + <span class="title">璁剧疆瀹㈡埛涓�т骇鍝�</span><a class="close" data-dismiss="modal" aria-hidden="true">脳</a> + </div> + <div class="modal-body"> + <%=ClientProductAll() %> + </div> + <div class="modal-footer"> + <button class="btn-default btn" data-dismiss="modal" aria-hidden="true"> + 鍙栨秷</button> + <button class="btn btn-primary action-updateProduct" data-dismiss="modal" aria-hidden="true"> + 淇濆瓨</button> + </div> + </div> + </div> + </div> + + <!-- footBar --> + <div id="mask" class="mask"> + <span></span> + <img src="img/spinning-circles.svg" alt="杞藉叆涓�..." /> + </div> +</asp:Content> + diff --git a/web/web/GwClientSub.aspx.cs b/web/web/GwClientSub.aspx.cs new file mode 100644 index 0000000..11ff8cb --- /dev/null +++ b/web/web/GwClientSub.aspx.cs @@ -0,0 +1,287 @@ +锘� +using Common; +using Model; +using System; +using System.Web; +using System.Web.Profile; +using System.Web.SessionState; +using Dao; +using System.Collections.Generic; +using System.Text; +using System.Configuration; +using System.Linq; + +public partial class _GwClient : PageBase<SysUser>, IRequiresSessionState +{ + + protected List<SysUser> SysUserList; + protected List<GwProduct> GwProductList; + + string addressClasses = ConfigurationManager.AppSettings["addressClasses"]; + + protected void Page_Load(object sender, EventArgs e) + { + //鏉冮檺鏍¢獙 + this.CheckRight("301", FailedOperation.ErrorMsgOnly); + + //鑾峰彇鍚敤鐨勪骇鍝佸垎绫� + using (UserDao userDao = new UserDao()) + { + + int recordCount = 0; + int int1 = 999999999; + int int2 = 1; + this.SysUserList = userDao.LoadInfoList(out recordCount, int1, int2); + + } + + //鑾峰彇鍚敤鐨勪骇鍝� + using (GwProductDao gwProductDao = new GwProductDao()) + { + GwProduct bean = new GwProduct(); + bean.Classes = 1; + bean.IsDefault = -1; + bean.IsEnable = -1; + this.GwProductList = gwProductDao.getAllList(bean); + } + } + public int IsEnable + { + get + { + return this.AppContext.GetInt("IsEnable"); + } + } + + + //褰掑睘涓氬姟鍛� + public string salesmanOptions(int userId) + { + StringBuilder stringBuilder = new StringBuilder(); + if (this.SysUserList.Count == 0) + return "<option value=''>鏃�</option>"; + stringBuilder.AppendFormat("<option value=\"{0}\" >{1}</option>", (object)"", (object)"鏃�"); + foreach (SysUser bean in this.SysUserList) + { + //鍋滅敤鐨勭敤鎴蜂笉鍐嶆樉绀� + if (bean.Status == 0) + { + continue; + } + //杩囨护鐢ㄦ埛绫诲瀷 1-绠$悊鍛�;2-涓氬姟鍛�--鍏ㄥ憳;3-瀹㈡埛缁忕悊;4-瀹㈡湇浜哄憳;5-璐㈠姟浜哄憳 + if (!checkStrForArrayStr(1, bean.UserType) && !checkStrForArrayStr(2, bean.UserType) ) + { + continue; + } + + if (userId == bean.UserID) + stringBuilder.AppendFormat("<option value=\"{0}\" selected>{1}</option>", (object)bean.UserID, (object)bean.UserName); + else + stringBuilder.AppendFormat("<option value=\"{0}\">{1}</option>", (object)bean.UserID, (object)bean.UserName); + } + return stringBuilder.ToString(); + } + + //褰掑睘瀹㈡埛缁忕悊 + public string customerManagerOptions(int userId) + { + StringBuilder stringBuilder = new StringBuilder(); + if (this.SysUserList.Count == 0) + return "<option value=''>鏃�</option>"; + stringBuilder.AppendFormat("<option value=\"{0}\" >{1}</option>", (object)"", (object)"鏃�"); + foreach (SysUser bean in this.SysUserList) + { + //鍋滅敤鐨勭敤鎴蜂笉鍐嶆樉绀� + if (bean.Status == 0) + { + continue; + } + //杩囨护鐢ㄦ埛绫诲瀷 1-绠$悊鍛�;2-涓氬姟鍛�--鍏ㄥ憳;3-瀹㈡埛缁忕悊;4-瀹㈡湇浜哄憳;5-璐㈠姟浜哄憳 + if (!checkStrForArrayStr(1, bean.UserType) && !checkStrForArrayStr(3, bean.UserType)) + { + continue; + } + + if (userId == bean.UserID) + stringBuilder.AppendFormat("<option value=\"{0}\" selected>{1}</option>", (object)bean.UserID, (object)bean.UserName); + else + stringBuilder.AppendFormat("<option value=\"{0}\">{1}</option>", (object)bean.UserID, (object)bean.UserName); + } + return stringBuilder.ToString(); + } + + //褰掑睘瀹㈡湇浜哄憳 + public string supportStaffOptions(int userId) + { + StringBuilder stringBuilder = new StringBuilder(); + if (this.SysUserList.Count == 0) + return "<option value=''>鏃�</option>"; + stringBuilder.AppendFormat("<option value=\"{0}\" >{1}</option>", (object)"", (object)"鏃�"); + foreach (SysUser bean in this.SysUserList) + { + //鍋滅敤鐨勭敤鎴蜂笉鍐嶆樉绀� + if (bean.Status == 0) + { + continue; + } + //杩囨护鐢ㄦ埛绫诲瀷 1-绠$悊鍛�;2-涓氬姟鍛�--鍏ㄥ憳;3-瀹㈡埛缁忕悊;4-瀹㈡湇浜哄憳;5-璐㈠姟浜哄憳 + if (!checkStrForArrayStr(1, bean.UserType) && !checkStrForArrayStr(4, bean.UserType)) + { + continue; + } + + if (userId == bean.UserID) + stringBuilder.AppendFormat("<option value=\"{0}\" selected>{1}</option>", (object)bean.UserID, (object)bean.UserName); + else + stringBuilder.AppendFormat("<option value=\"{0}\">{1}</option>", (object)bean.UserID, (object)bean.UserName); + } + return stringBuilder.ToString(); + } + + //褰掑睘璐㈠姟浜哄憳 + public string financialStaffOptions(int userId) + { + StringBuilder stringBuilder = new StringBuilder(); + if (this.SysUserList.Count == 0) + return "<option value=''>鏃�</option>"; + stringBuilder.AppendFormat("<option value=\"{0}\" >{1}</option>", (object)"", (object)"鏃�"); + foreach (SysUser bean in this.SysUserList) + { + //鍋滅敤鐨勭敤鎴蜂笉鍐嶆樉绀� + if (bean.Status == 0) + { + continue; + } + //杩囨护鐢ㄦ埛绫诲瀷 1-绠$悊鍛�;2-涓氬姟鍛�--鍏ㄥ憳;3-瀹㈡埛缁忕悊;4-瀹㈡湇浜哄憳;5-璐㈠姟浜哄憳 + if (!checkStrForArrayStr(1, bean.UserType) && !checkStrForArrayStr(5, bean.UserType)) + { + continue; + } + + if (userId == bean.UserID) + stringBuilder.AppendFormat("<option value=\"{0}\" selected>{1}</option>", (object)bean.UserID, (object)bean.UserName); + else + stringBuilder.AppendFormat("<option value=\"{0}\">{1}</option>", (object)bean.UserID, (object)bean.UserName); + } + return stringBuilder.ToString(); + } + + + //鑾峰彇浜у搧淇℃伅 + public string GetProductOptions(string productId) + { + StringBuilder stringBuilder = new StringBuilder(); + if (this.GwProductList.Count == 0) + return "<option value=''>鏃�</option>"; + stringBuilder.AppendFormat("<option value=\"{0}\" >{1}</option>", (object)"", (object)"鏃�"); + foreach (GwProduct bean in this.GwProductList) + { + //鍋滅敤鐨勪骇鍝佸垎绫讳笉鍐嶆樉绀� + if (bean.IsEnable == 0) + { + continue; + } + //杩囨护浜у搧绫诲埆 + if (bean.Classes == 0) + { + continue; + } + + if (productId.Equals(bean.Id)) + stringBuilder.AppendFormat("<option value=\"{0}\" selected>{1}</option>", (object)bean.Id, (object)bean.Name); + else + stringBuilder.AppendFormat("<option value=\"{0}\">{1}</option>", (object)bean.Id, (object)bean.Name); + } + return stringBuilder.ToString(); + } + + + //鑾峰彇涓�т骇鍝佷俊鎭� + public string GetPersonalityProductOptions(string productId) + { + StringBuilder stringBuilder = new StringBuilder(); + if (this.GwProductList.Count == 0) + return "<option value=''>鏃�</option>"; + stringBuilder.AppendFormat("<option value=\"{0}\" >{1}</option>", (object)"", (object)"鏃�"); + foreach (GwProduct bean in this.GwProductList) + { + //鍋滅敤鐨勪骇鍝佸垎绫讳笉鍐嶆樉绀� + if (bean.IsEnable == 0) + { + continue; + } + //杩囨护浜у搧绫诲埆 + if (bean.Classes == 0) + { + continue; + } + //杩囨护鎺ㄥ箍鏂瑰紡 + if (bean.IsDefault == 1) + { + continue; + } + + if (productId.Equals(bean.Id)) + stringBuilder.AppendFormat("<option value=\"{0}\" selected>{1}</option>", (object)bean.Id, (object)bean.Name); + else + stringBuilder.AppendFormat("<option value=\"{0}\">{1}</option>", (object)bean.Id, (object)bean.Name); + } + return stringBuilder.ToString(); + } + + //鎵�鏈変釜鎬т骇鍝� + protected string ClientProductAll() + { + using (GwProductDao gwProductDao = new GwProductDao()) + { + GwProduct gwProduct = new GwProduct(); + gwProduct.Classes = 1; //0-浜у搧鍒嗙被锛�1-浜у搧 + gwProduct.IsDefault = 0; //榛樿鍊�0銆�0-涓�у寲锛�1-绯荤粺榛樿銆� + gwProduct.IsEnable = 1; //0-鍋滅敤锛�1-鍚敤锛涢粯璁�1 + List<GwProduct> list = gwProductDao.getAllList(gwProduct); + + StringBuilder stringBuilder = new StringBuilder(); + stringBuilder.Append("<table cellpadding='5'>"); + if(list.Count>0) + { + for (int i = 0; i < list.Count; i++) + { + GwProduct bean = (GwProduct)list[i]; + + //琛屽紑濮嬬 + if (i%5 == 0) + { + stringBuilder.Append("<tr>"); + } + + //琛屽崟鍏冩牸 + stringBuilder.AppendFormat("<td><input type=\"checkbox\" id=\"_ProductId\" name=\"_ProductId\" value=\"{0}\" /><span style='padding:5px;'>{1} </span> \r\n </td>", (object)bean.Id, (object)bean.Name); + + //琛岀粨鏉熺 + if (i % 5 == 4 || i == (list.Count - 1)) + { + stringBuilder.Append("</tr>"); + } + + } + } + stringBuilder.Append("</table>"); + + return stringBuilder.ToString(); + } + } + + //妫�鏌ユ暟缁勬牸寮忓瓧绗︿覆涓槸鍚﹀寘鍚煇鍏冪礌 + public static bool checkStrForArrayStr(object str, string arrayStr) + { + return stringToArray(arrayStr).Contains(str.ToString()); + } + + //瀛楃涓茶浆鏁扮粍 + public static object[] stringToArray(string str) + { + object[] array = str.Split(','); + return array; + } + +} diff --git a/web/web/GwTransfer.ashx b/web/web/GwTransfer.ashx index fd0c87b..1b90469 100644 --- a/web/web/GwTransfer.ashx +++ b/web/web/GwTransfer.ashx @@ -2,7 +2,7 @@ using System; using System.Web; -using com.softwee.smgw.common; +//using com.softwee.smgw.common; using Dao; using Model; using System.Collections.Generic; diff --git a/web/web/Index.aspx b/web/web/Index.aspx index 8a489c6..5f3d706 100644 --- a/web/web/Index.aspx +++ b/web/web/Index.aspx @@ -145,6 +145,8 @@ <a href="#"><i class="fa fa-user-secret"></i><span class="nav-label">瀹㈡埛绠$悊 </span><span class="fa arrow"></span></a> <ul class="nav nav-second-level"> <li><a href="GwClient.aspx?IsEnable=1" class="J_menuItem">瀹㈡埛淇℃伅绠$悊</a> </li> + <li><a href="GwClient.aspx?IsEnable=1" class="J_menuItem">鍒嗛攢鍟嗕笅绾у鎴蜂俊鎭鐞�</a> </li> + <li><a href="GwClient.aspx?IsEnable=0" class="J_menuItem">鍋滅敤瀹㈡埛淇℃伅绠$悊</a> </li> <li><a href="GwSp.aspx" class="J_menuItem">鐭俊璐﹀彿绠$悊</a> </li> <li><a href="GwMoRoute.aspx" class="J_menuItem">涓婅璺敱閰嶇疆</a> </li> diff --git a/web/web/gwdiverter.ashx b/web/web/gwdiverter.ashx index ebd854a..162a4cf 100644 --- a/web/web/gwdiverter.ashx +++ b/web/web/gwdiverter.ashx @@ -1,7 +1,7 @@ 锘�<%@ WebHandler Language="C#" Class="gwdiverterHandler" %> - //杩欎釜椤甸潰鏂板姞鐨勪负浜嗗疄鐜板娴� +//杩欎釜椤甸潰鏂板姞鐨勪负浜嗗疄鐜板娴� -using com.softwee.smgw.common; +//using App_Code; using Common; using Dao; using Model; @@ -12,201 +12,201 @@ public class gwdiverterHandler : PageHandler<SysUser> { - private GwDiverterDao _Dao = new GwDiverterDao(); - //private SysOperationLogDao _OperationLogDao = new SysOperationLogDao(); - private List<GwOp> OpList; + private GwDiverterDao _Dao = new GwDiverterDao(); + //private SysOperationLogDao _OperationLogDao = new SysOperationLogDao(); + private List<GwOp> OpList; - public override JsonPageResult ProcessRequestInternal(PageContext<SysUser> context) - { - string @string = context.GetString("action"); - switch (@string) + public override JsonPageResult ProcessRequestInternal(PageContext<SysUser> context) { - case "loadGwDiverter": - return this.LoadGwDiverter(context); - case "delete": - return this.Delete(context); - case "editDeal": - return this.Update(context); - default: - throw new Exception("Invalid Action=" + @string); - } - } - - private JsonPageResult Delete(PageContext<SysUser> context) - { - context.CheckRight("1064", FailedOperation.ErrorMsgOnly); - string @string = context.GetString("did"); - if (string.IsNullOrEmpty(@string)) - throw new ArgumentException("鍙傛暟寮傚父"); - this._Dao.Delete(@string); - //WriteSysLogHelper.WriteSysLog(context.SessionObject.Account, 1064, 106, string.Format("鍒犻櫎瀵兼祦绛栫暐锛氱瓥鐣ョ紪鍙凤細{0}", (object) @string), context.ClientIP); - return new JsonPageResult(true, (object) "鍒犻櫎鎴愬姛"); - } - - private JsonPageResult Update(PageContext<SysUser> context) - { - context.CheckRight("1062", FailedOperation.ErrorMsgOnly); - int @int = context.GetInt("DiverterID"); - string string1 = context.GetString("DiverterName"); - string string2 = context.GetString("Content"); - if (string.IsNullOrEmpty(string1)) - throw new ArgumentException("绛栫暐鍚嶇О涓嶈兘涓虹┖"); - GwDiverter diverter = new GwDiverter(); - diverter.DiverterID = @int; - diverter.DiverterName = string1; - List<GwDiverterItem> list1 = JsonConvert.DeserializeObject<List<GwDiverterItem>>(string2); - if (list1 == null) - throw new ArgumentException("绛栫暐鏁版嵁寮傚父锛岃閲嶈瘯"); - List<GwDiverterItem> items = new List<GwDiverterItem>(); - List<GwDiverterItem> list2 = new List<GwDiverterItem>(); - foreach (GwDiverterItem gwDiverterItem1 in list1) - { - GwDiverterItem gwDiverterItem2 = new GwDiverterItem() - { - Mode = gwDiverterItem1.Mode, - Keywords = "", - SmMaxLength = gwDiverterItem1.SmMaxLength, - SmMinLength = gwDiverterItem1.SmMinLength, - Segments = "", - ExtNoMode = gwDiverterItem1.ExtNoMode, - Province = "", - CMOPID = gwDiverterItem1.CMOPID, - CUOPID = gwDiverterItem1.CUOPID, - CTOPID = gwDiverterItem1.CTOPID, - CMExtNo = gwDiverterItem1.CMExtNo, - CUExtNo = gwDiverterItem1.CUExtNo, - CTExtNo = gwDiverterItem1.CTExtNo, - CMExtParams = gwDiverterItem1.CMExtParams, - CTExtParams = gwDiverterItem1.CTExtParams, - CUExtParams = gwDiverterItem1.CUExtParams - }; - GwDiverterItem gwDiverterItem3 = new GwDiverterItem() - { - Mode = gwDiverterItem1.Mode, - Keywords = gwDiverterItem1.Keywords, - SmMaxLength = gwDiverterItem1.SmMaxLength, - SmMinLength = gwDiverterItem1.SmMinLength, - Segments = SegmentHelper.Filrate(gwDiverterItem1.Segments), - Province = gwDiverterItem1.Province, - ExtNoMode = gwDiverterItem1.ExtNoMode, - CMOPID = gwDiverterItem1.CMOPID, - CUOPID = gwDiverterItem1.CUOPID, - CTOPID = gwDiverterItem1.CTOPID, - CMExtNo = gwDiverterItem1.CMExtNo, - CUExtNo = gwDiverterItem1.CUExtNo, - CTExtNo = gwDiverterItem1.CTExtNo, - CMExtParams = gwDiverterItem1.CMExtParams, - CTExtParams = gwDiverterItem1.CTExtParams, - CUExtParams = gwDiverterItem1.CUExtParams - }; - list2.Add(gwDiverterItem2); - items.Add(gwDiverterItem3); - } - string str = JsonConvert.SerializeObject((object) list2); - if (str.Length > 5000) - throw new ArgumentException("瀵兼祦瑙勫垯涓嶈兘瓒呰繃5000瀛楃"); - diverter.Content = str; - if (this._Dao.Exists(diverter.DiverterID, diverter.DiverterName)) - throw new ArgumentException("璇ョ瓥鐣ュ悕绉板凡缁忓瓨鍦�"); - this._Dao.UpdateInfo(diverter, items); -// WriteSysLogHelper.WriteSysLog(context.SessionObject.Account, 1062, 106, string.Format("瀵兼祦绛栫暐锛氱瓥鐣ョ紪鍙凤細{0}绛栫暐鍚嶇О锛歿1}", (object) @int, (object) string1), context.ClientIP); - return new JsonPageResult(true, (object) "瀵兼祦绛栫暐淇濆瓨鎴愬姛"); - } - - private JsonPageResult LoadGwDiverter(PageContext<SysUser> context) - { - List<GwDiverter> list = this._Dao.LoadList(); - string str = ""; - if (list != null && list.Count > 0) - { - int num = 0; - foreach (GwDiverter gwDiverter in list) - { - ++num; - str = string.Concat(new object[4] + string @string = context.GetString("action"); + switch (@string) { + case "loadGwDiverter": + return this.LoadGwDiverter(context); + case "delete": + return this.Delete(context); + case "editDeal": + return this.Update(context); + default: + throw new Exception("Invalid Action=" + @string); + } + } + + private JsonPageResult Delete(PageContext<SysUser> context) + { + context.CheckRight("1064", FailedOperation.ErrorMsgOnly); + string @string = context.GetString("did"); + if (string.IsNullOrEmpty(@string)) + throw new ArgumentException("鍙傛暟寮傚父"); + this._Dao.Delete(@string); + //WriteSysLogHelper.WriteSysLog(context.SessionObject.Account, 1064, 106, string.Format("鍒犻櫎瀵兼祦绛栫暐锛氱瓥鐣ョ紪鍙凤細{0}", (object) @string), context.ClientIP); + return new JsonPageResult(true, (object) "鍒犻櫎鎴愬姛"); + } + + private JsonPageResult Update(PageContext<SysUser> context) + { + context.CheckRight("1062", FailedOperation.ErrorMsgOnly); + int @int = context.GetInt("DiverterID"); + string string1 = context.GetString("DiverterName"); + string string2 = context.GetString("Content"); + if (string.IsNullOrEmpty(string1)) + throw new ArgumentException("绛栫暐鍚嶇О涓嶈兘涓虹┖"); + GwDiverter diverter = new GwDiverter(); + diverter.DiverterID = @int; + diverter.DiverterName = string1; + List<GwDiverterItem> list1 = JsonConvert.DeserializeObject<List<GwDiverterItem>>(string2); + if (list1 == null) + throw new ArgumentException("绛栫暐鏁版嵁寮傚父锛岃閲嶈瘯"); + List<GwDiverterItem> items = new List<GwDiverterItem>(); + List<GwDiverterItem> list2 = new List<GwDiverterItem>(); + foreach (GwDiverterItem gwDiverterItem1 in list1) + { + GwDiverterItem gwDiverterItem2 = new GwDiverterItem() + { + Mode = gwDiverterItem1.Mode, + Keywords = "", + SmMaxLength = gwDiverterItem1.SmMaxLength, + SmMinLength = gwDiverterItem1.SmMinLength, + Segments = "", + ExtNoMode = gwDiverterItem1.ExtNoMode, + Province = "", + CMOPID = gwDiverterItem1.CMOPID, + CUOPID = gwDiverterItem1.CUOPID, + CTOPID = gwDiverterItem1.CTOPID, + CMExtNo = gwDiverterItem1.CMExtNo, + CUExtNo = gwDiverterItem1.CUExtNo, + CTExtNo = gwDiverterItem1.CTExtNo, + CMExtParams = gwDiverterItem1.CMExtParams, + CTExtParams = gwDiverterItem1.CTExtParams, + CUExtParams = gwDiverterItem1.CUExtParams + }; + GwDiverterItem gwDiverterItem3 = new GwDiverterItem() + { + Mode = gwDiverterItem1.Mode, + Keywords = gwDiverterItem1.Keywords, + SmMaxLength = gwDiverterItem1.SmMaxLength, + SmMinLength = gwDiverterItem1.SmMinLength, + Segments = SegmentHelper.Filrate(gwDiverterItem1.Segments), + Province = gwDiverterItem1.Province, + ExtNoMode = gwDiverterItem1.ExtNoMode, + CMOPID = gwDiverterItem1.CMOPID, + CUOPID = gwDiverterItem1.CUOPID, + CTOPID = gwDiverterItem1.CTOPID, + CMExtNo = gwDiverterItem1.CMExtNo, + CUExtNo = gwDiverterItem1.CUExtNo, + CTExtNo = gwDiverterItem1.CTExtNo, + CMExtParams = gwDiverterItem1.CMExtParams, + CTExtParams = gwDiverterItem1.CTExtParams, + CUExtParams = gwDiverterItem1.CUExtParams + }; + list2.Add(gwDiverterItem2); + items.Add(gwDiverterItem3); + } + string str = JsonConvert.SerializeObject((object) list2); + if (str.Length > 5000) + throw new ArgumentException("瀵兼祦瑙勫垯涓嶈兘瓒呰繃5000瀛楃"); + diverter.Content = str; + if (this._Dao.Exists(diverter.DiverterID, diverter.DiverterName)) + throw new ArgumentException("璇ョ瓥鐣ュ悕绉板凡缁忓瓨鍦�"); + this._Dao.UpdateInfo(diverter, items); + // WriteSysLogHelper.WriteSysLog(context.SessionObject.Account, 1062, 106, string.Format("瀵兼祦绛栫暐锛氱瓥鐣ョ紪鍙凤細{0}绛栫暐鍚嶇О锛歿1}", (object) @int, (object) string1), context.ClientIP); + return new JsonPageResult(true, (object) "瀵兼祦绛栫暐淇濆瓨鎴愬姛"); + } + + private JsonPageResult LoadGwDiverter(PageContext<SysUser> context) + { + List<GwDiverter> list = this._Dao.LoadList(); + string str = ""; + if (list != null && list.Count > 0) + { + int num = 0; + foreach (GwDiverter gwDiverter in list) + { + ++num; + str = string.Concat(new object[4] + { (object) str, (object) "<tr><td>", (object) gwDiverter.DiverterID, (object) "</td>" - }); - str = str + "<td>" + gwDiverter.DiverterName + "</td>"; - str = str + "<td>" + this.FormatContent(gwDiverter.Content) + "</td>"; - str += "<td nowrap=\"true\">"; - str = string.Concat(new object[4] - { + }); + str = str + "<td>" + gwDiverter.DiverterName + "</td>"; + str = str + "<td>" + this.FormatContent(gwDiverter.Content) + "</td>"; + str += "<td nowrap=\"true\">"; + str = string.Concat(new object[4] + { (object) str, (object) "<a href='javascript:;' data-id='", (object) gwDiverter.DiverterID, (object) "' class='action-edit btn btn-xs btn-success operator'><i class=\"fa fa-edit\"></i> 缂栬緫</a> " - }); - str = string.Concat(new object[4] - { + }); + str = string.Concat(new object[4] + { (object) str, (object) "<a href='javascript:;' data-id='", (object) gwDiverter.DiverterID, (object) "' class='action-delete btn btn-xs btn-default operator'><i class=\"fa fa-trash\"></i> 鍒犻櫎</a>" + }); + str += "</td>"; + str += "</tr>"; + } + } + else + str += "<tr><td colspan=\"4\" style=\"padding-left:5px; text-align: center;\">鏆傛棤淇℃伅</td></tr>"; + return new JsonPageResult(true, (object) new + { + Table = str.ToString() }); - str += "</td>"; - str += "</tr>"; - } } - else - str += "<tr><td colspan=\"4\" style=\"padding-left:5px; text-align: center;\">鏆傛棤淇℃伅</td></tr>"; - return new JsonPageResult(true, (object) new - { - Table = str.ToString() - }); - } - private string FormatContent(string content) - { - StringBuilder stringBuilder = new StringBuilder(); - try + private string FormatContent(string content) { - foreach (GwDiverterItem gwDiverterItem in JsonConvert.DeserializeObject<List<GwDiverterItem>>(content)) - { - stringBuilder.AppendFormat("<div class=\"m-b\">"); - stringBuilder.AppendFormat("{0}", (object) this.ModeStr(gwDiverterItem.Mode)); - stringBuilder.AppendFormat("鐭俊灏嗕粠 绉诲姩 <span class=\"label label-success\">{0}</span> 鑱旈�� <span class=\"label label-primary\">{1}</span> 鐢典俊 <span class=\"label label-warning\"> {2} </span>瀵兼祦銆�", (object) this.GetOpName(gwDiverterItem.CMOPID), (object) this.GetOpName(gwDiverterItem.CUOPID), (object) this.GetOpName(gwDiverterItem.CTOPID)); - stringBuilder.AppendLine("</div>"); - } + StringBuilder stringBuilder = new StringBuilder(); + try + { + foreach (GwDiverterItem gwDiverterItem in JsonConvert.DeserializeObject<List<GwDiverterItem>>(content)) + { + stringBuilder.AppendFormat("<div class=\"m-b\">"); + stringBuilder.AppendFormat("{0}", (object) this.ModeStr(gwDiverterItem.Mode)); + stringBuilder.AppendFormat("鐭俊灏嗕粠 绉诲姩 <span class=\"label label-success\">{0}</span> 鑱旈�� <span class=\"label label-primary\">{1}</span> 鐢典俊 <span class=\"label label-warning\"> {2} </span>瀵兼祦銆�", (object) this.GetOpName(gwDiverterItem.CMOPID), (object) this.GetOpName(gwDiverterItem.CUOPID), (object) this.GetOpName(gwDiverterItem.CTOPID)); + stringBuilder.AppendLine("</div>"); + } + } + catch (Exception ex) + { + LogHelper.Error(ex); + } + return stringBuilder.ToString(); } - catch (Exception ex) - { - LogHelper.Error(ex); - } - return stringBuilder.ToString(); - } - public string ModeStr(int mode) - { - string str1 = ""; - string str2; - switch (mode) + public string ModeStr(int mode) { - case 1: - return str2 = string.Format("褰撶煭淇″唴瀹瑰尮閰嶃�愬叧閿瓧銆戞椂锛�"); - case 2: - return str2 = string.Format("褰撶煭淇″唴瀹瑰尮閰� 鈥滃瓧鏁扳�� 鏃�,"); - case 3: - return str2 = string.Format("褰撶煭淇″彿鐮佸尮閰� 鈥滃彿娈碘�� 鏃讹紝"); - case 4: - return str2 = string.Format("褰撶煭淇″彿鐮佸尮閰� 鈥滅渷浠解�� 鏃讹紝"); - default: - return str1.ToString(); + string str1 = ""; + string str2; + switch (mode) + { + case 1: + return str2 = string.Format("褰撶煭淇″唴瀹瑰尮閰嶃�愬叧閿瓧銆戞椂锛�"); + case 2: + return str2 = string.Format("褰撶煭淇″唴瀹瑰尮閰� 鈥滃瓧鏁扳�� 鏃�,"); + case 3: + return str2 = string.Format("褰撶煭淇″彿鐮佸尮閰� 鈥滃彿娈碘�� 鏃讹紝"); + case 4: + return str2 = string.Format("褰撶煭淇″彿鐮佸尮閰� 鈥滅渷浠解�� 鏃讹紝"); + default: + return str1.ToString(); + } } - } - private string GetOpName(int opID) - { - using (GwOpDao gwOpDao = new GwOpDao()) - this.OpList = gwOpDao.LoadInfoList(); - if (this.OpList == null) - return string.Empty; - GwOp gwOp = this.OpList.Find((Predicate<GwOp>) (op => op.OpID == opID)); - if (gwOp != null) - return string.Format("{0}-{1}", (object) gwOp.OpID, (object) gwOp.OpName); - return "鏈缃�氶亾"; - } + private string GetOpName(int opID) + { + using (GwOpDao gwOpDao = new GwOpDao()) + this.OpList = gwOpDao.LoadInfoList(); + if (this.OpList == null) + return string.Empty; + GwOp gwOp = this.OpList.Find((Predicate<GwOp>) (op => op.OpID == opID)); + if (gwOp != null) + return string.Format("{0}-{1}", (object) gwOp.OpID, (object) gwOp.OpName); + return "鏈缃�氶亾"; + } } -- Gitblit v1.9.1