This commit is contained in:
DESKTOP-E401PHE\Administrator 2025-04-11 10:54:54 +08:00
commit 630f9184a2
1229 changed files with 792244 additions and 0 deletions

16
.gitignore vendored Normal file
View File

@ -0,0 +1,16 @@
**/layout
**/report
**/实施文件
**/image
**/doc
**/wav
**/__history
**/__recovery
*.dll
*.exe
*.ddp
*.dcu
*.~pas
*.~dfm
*.~ddp
*.~dpr

4
A00通用模板/File.INI Normal file
View File

@ -0,0 +1,4 @@
[生产车间配置]
卷条码机台标志=99
成品DLL文件=CYZZ.dll
成品DLL调用号=11

View File

@ -0,0 +1,7 @@
[FILEPATH]
FileClass=YP,AA,BB,HT
YP=D:\YP
AA=D:\AA
BB=D:\BB
HT=D:\HT
OTHER=D:\OTHER

View File

@ -0,0 +1,42 @@
-$A8
-$B-
-$C+
-$D+
-$E-
-$F-
-$G+
-$H+
-$I+
-$J-
-$K-
-$L+
-$M-
-$N+
-$O+
-$P+
-$Q-
-$R-
-$S-
-$T-
-$U-
-$V+
-$W-
-$X+
-$YD
-$Z1
-cg
-AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
-H+
-W+
-M
-$M16384,1048576
-K$00400000
-LE"c:\program files (x86)\borland\delphi7\Projects\Bpl"
-LN"c:\program files (x86)\borland\delphi7\Projects\Bpl"
-U"D:\말繫ERP"
-O"D:\말繫ERP"
-I"D:\말繫ERP"
-R"D:\말繫ERP"
-w-UNSAFE_TYPE
-w-UNSAFE_CODE
-w-UNSAFE_CAST

View File

@ -0,0 +1,138 @@
[FileVersion]
Version=7.0
[Compiler]
A=8
B=0
C=1
D=1
E=0
F=0
G=1
H=1
I=1
J=0
K=0
L=1
M=0
N=1
O=1
P=1
Q=0
R=0
S=0
T=0
U=0
V=1
W=0
X=1
Y=1
Z=1
ShowHints=1
ShowWarnings=1
UnitAliases=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
NamespacePrefix=
SymbolDeprecated=1
SymbolLibrary=1
SymbolPlatform=1
UnitLibrary=1
UnitPlatform=1
UnitDeprecated=1
HResultCompat=1
HidingMember=1
HiddenVirtual=1
Garbage=1
BoundsError=1
ZeroNilCompat=1
StringConstTruncated=1
ForLoopVarVarPar=1
TypedConstVarPar=1
AsgToTypedConst=1
CaseLabelRange=1
ForVariable=1
ConstructingAbstract=1
ComparisonFalse=1
ComparisonTrue=1
ComparingSignedUnsigned=1
CombiningSignedUnsigned=1
UnsupportedConstruct=1
FileOpen=1
FileOpenUnitSrc=1
BadGlobalSymbol=1
DuplicateConstructorDestructor=1
InvalidDirective=1
PackageNoLink=1
PackageThreadVar=1
ImplicitImport=1
HPPEMITIgnored=1
NoRetVal=1
UseBeforeDef=1
ForLoopVarUndef=1
UnitNameMismatch=1
NoCFGFileFound=1
MessageDirective=1
ImplicitVariants=1
UnicodeToLocale=1
LocaleToUnicode=1
ImagebaseMultiple=1
SuspiciousTypecast=1
PrivatePropAccessor=1
UnsafeType=0
UnsafeCode=0
UnsafeCast=0
[Linker]
MapFile=0
OutputObjs=0
ConsoleApp=1
DebugInfo=0
RemoteSymbols=0
MinStackSize=16384
MaxStackSize=1048576
ImageBase=4194304
ExeDescription=
[Directories]
OutputDir=
UnitOutputDir=
PackageDLLOutputDir=
PackageDCPOutputDir=
SearchPath=D:\말繫ERP
Packages=vcl;rtl;vclx;indy;inet;xmlrtl;vclie;inetdbbde;inetdbxpress;dbrtl;dsnap;dsnapcon;vcldb;soaprtl;VclSmp;dbexpress;dbxcds;bdertl;vcldbx;webdsnap;websnap;adortl;ibxpress;teeui;teedb;tee;dss;visualclx;visualdbclx;vclactnband;vclshlctrls;IntrawebDB_50_70;Intraweb_50_70;dclOffice2k;Rave50CLX;Rave50VCL
Conditionals=
DebugSourceDirs=
UsePackages=0
[Parameters]
RunParams=
HostApplication=D:\땀둑룟역랙덜쯤\淃커덜쯤\낀菫介놉\虔廉셕뺍데(ShuttleSchedule.dll)\testDll.exe
Launcher=
UseLauncher=0
DebugCWD=
[Language]
ActiveLang=
ProjectLang=
RootDir=
[Version Info]
IncludeVerInfo=0
AutoIncBuild=0
MajorVer=1
MinorVer=0
Release=0
Build=0
Debug=0
PreRelease=0
Special=0
Private=0
DLL=0
Locale=2052
CodePage=936
[Version Info Keys]
CompanyName=
FileDescription=
FileVersion=1.0.0.0
InternalName=
LegalCopyright=
LegalTrademarks=
OriginalFilename=
ProductName=
ProductVersion=1.0.0.0
Comments=
[Excluded Packages]
c:\program files\borland\delphi7\Bin\DBWEBXPRT.BPL=Borland Web Wizard Package

View File

@ -0,0 +1,55 @@
library InformationBase;
uses
SysUtils,
classes,
forms,
WinTypes,
WinProcs,
midaslib,
U_GetDllForm in 'U_GetDllForm.pas',
U_DataLink in 'U_DataLink.pas' {DataLink_InformationBase: TDataModule},
U_iniParam in 'U_iniParam.pas',
U_BaseHelp in '..\..\..\public10\design\U_BaseHelp.pas' {frmBaseHelp},
U_BaseInput in '..\..\..\public10\design\U_BaseInput.pas' {frmBaseInput},
U_BaseList in '..\..\..\public10\design\U_BaseList.pas' {frmBaseList},
U_cxGridCustomCss in '..\..\..\public10\design\U_cxGridCustomCss.pas',
U_globalVar in '..\..\..\public10\design\U_globalVar.pas',
U_WindowFormdesign in '..\..\..\public10\design\U_WindowFormdesign.pas',
U_CompressionFun in '..\..\..\public10\ThreeFun\Fun\U_CompressionFun.pas',
U_RTFun in '..\..\..\public10\ThreeFun\Fun\U_RTFun.pas',
U_ZDYHelp in '..\..\..\public10\ThreeFun\Form\U_ZDYHelp.pas' {frmZDYHelp},
Unit1 in 'Unit1.pas' {Form1},
U_AttachmentUpload in '..\A00通用窗体\U_AttachmentUpload.pas' {frmFjList_RZ},
U_ClothInfoSel in '..\A00通用窗体\U_ClothInfoSel.pas' {frmClothInfoSel},
U_CompanySel in '..\A00通用窗体\U_CompanySel.pas' {frmCompanySel},
U_EmployeeSel in '..\A00通用窗体\U_EmployeeSel.pas' {frmEmployeeSel},
U_LablePrint in '..\A00通用窗体\U_LablePrint.pas' {frmLablePrint},
U_LbaelMapSet in '..\A00通用窗体\U_LbaelMapSet.pas' {frmLbaelMapSet};
{$R *.res}
procedure DllEnterPoint(dwReason: DWORD); far; stdcall;
begin
DLLProc := @DLLEnterPoint;
DllEnterPoint(DLL_PROCESS_ATTACH);
end;
procedure DLLUnloadProc(Reason: Integer); register;
begin
// if (Reason = DLL_PROCESS_DETACH) or (Reason = DLL_THREAD_DETACH) then
// Application := NewDllApp;
end;
exports
GetDllForm;
begin
try
NewDllApp := Application;
DLLProc := @DLLUnloadProc;
except
end;
end.

View File

@ -0,0 +1,923 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{7B70AA99-C84C-40AE-B4AE-13C5223B874C}</ProjectGuid>
<MainSource>InformationBase.dpr</MainSource>
<Base>True</Base>
<Config Condition="'$(Config)'==''">Debug</Config>
<TargetedPlatforms>38017</TargetedPlatforms>
<AppType>Library</AppType>
<FrameworkType>VCL</FrameworkType>
<ProjectVersion>19.2</ProjectVersion>
<Platform Condition="'$(Platform)'==''">Win32</Platform>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Android64' and '$(Base)'=='true') or '$(Base_Android64)'!=''">
<Base_Android64>true</Base_Android64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSDevice64' and '$(Base)'=='true') or '$(Base_iOSDevice64)'!=''">
<Base_iOSDevice64>true</Base_iOSDevice64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Base)'=='true') or '$(Base_Win32)'!=''">
<Base_Win32>true</Base_Win32>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win64' and '$(Base)'=='true') or '$(Base_Win64)'!=''">
<Base_Win64>true</Base_Win64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Release' or '$(Cfg_1)'!=''">
<Cfg_1>true</Cfg_1>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Debug' or '$(Cfg_2)'!=''">
<Cfg_2>true</Cfg_2>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Android64' and '$(Cfg_2)'=='true') or '$(Cfg_2_Android64)'!=''">
<Cfg_2_Android64>true</Cfg_2_Android64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSDevice64' and '$(Cfg_2)'=='true') or '$(Cfg_2_iOSDevice64)'!=''">
<Cfg_2_iOSDevice64>true</Cfg_2_iOSDevice64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='OSX64' and '$(Cfg_2)'=='true') or '$(Cfg_2_OSX64)'!=''">
<Cfg_2_OSX64>true</Cfg_2_OSX64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Cfg_2)'=='true') or '$(Cfg_2_Win32)'!=''">
<Cfg_2_Win32>true</Cfg_2_Win32>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Base)'!=''">
<DCC_E>false</DCC_E>
<DCC_F>false</DCC_F>
<DCC_K>false</DCC_K>
<DCC_N>true</DCC_N>
<DCC_S>false</DCC_S>
<DCC_ImageBase>00400000</DCC_ImageBase>
<DCC_DebugInformation>1</DCC_DebugInformation>
<DCC_SymbolReferenceInfo>1</DCC_SymbolReferenceInfo>
<DCC_UnitSearchPath>D:\富通ERP;$(DCC_UnitSearchPath)</DCC_UnitSearchPath>
<DCC_UsePackage>vcl;rtl;vclx;indy;inet;xmlrtl;vclie;inetdbbde;inetdbxpress;dbrtl;dsnap;dsnapcon;vcldb;soaprtl;VclSmp;dbexpress;dbxcds;bdertl;vcldbx;webdsnap;websnap;adortl;ibxpress;teeui;teedb;tee;dss;visualclx;visualdbclx;vclactnband;vclshlctrls;IntrawebDB_50_70;Intraweb_50_70;dclOffice2k;Rave50CLX;Rave50VCL;$(DCC_UsePackage)</DCC_UsePackage>
<GenDll>true</GenDll>
<SanitizedProjectName>InformationBase</SanitizedProjectName>
<DCC_Namespace>Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;System;Xml;Data;Datasnap;Web;Soap;Winapi;Data.Win;$(DCC_Namespace)</DCC_Namespace>
<VerInfo_Locale>2052</VerInfo_Locale>
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Android64)'!=''">
<Android_LauncherIcon192>$(BDS)\bin\Artwork\Android\FM_LauncherIcon_192x192.png</Android_LauncherIcon192>
<EnabledSysJars>android-support-v4.dex.jar;cloud-messaging.dex.jar;com-google-android-gms.play-services-ads-base.17.2.0.dex.jar;com-google-android-gms.play-services-ads-identifier.16.0.0.dex.jar;com-google-android-gms.play-services-ads-lite.17.2.0.dex.jar;com-google-android-gms.play-services-ads.17.2.0.dex.jar;com-google-android-gms.play-services-analytics-impl.16.0.8.dex.jar;com-google-android-gms.play-services-analytics.16.0.8.dex.jar;com-google-android-gms.play-services-base.16.0.1.dex.jar;com-google-android-gms.play-services-basement.16.2.0.dex.jar;com-google-android-gms.play-services-gass.17.2.0.dex.jar;com-google-android-gms.play-services-identity.16.0.0.dex.jar;com-google-android-gms.play-services-maps.16.1.0.dex.jar;com-google-android-gms.play-services-measurement-base.16.4.0.dex.jar;com-google-android-gms.play-services-measurement-sdk-api.16.4.0.dex.jar;com-google-android-gms.play-services-stats.16.0.1.dex.jar;com-google-android-gms.play-services-tagmanager-v4-impl.16.0.8.dex.jar;com-google-android-gms.play-services-tasks.16.0.1.dex.jar;com-google-android-gms.play-services-wallet.16.0.1.dex.jar;com-google-firebase.firebase-analytics.16.4.0.dex.jar;com-google-firebase.firebase-common.16.1.0.dex.jar;com-google-firebase.firebase-iid-interop.16.0.1.dex.jar;com-google-firebase.firebase-iid.17.1.1.dex.jar;com-google-firebase.firebase-measurement-connector.17.0.1.dex.jar;com-google-firebase.firebase-messaging.17.5.0.dex.jar;fmx.dex.jar;google-play-billing.dex.jar;google-play-licensing.dex.jar</EnabledSysJars>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_iOSDevice64)'!=''">
<iOS_AppStore1024>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_1024x1024.png</iOS_AppStore1024>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win32)'!=''">
<DCC_Namespace>System.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace)</DCC_Namespace>
<BT_BuildType>Debug</BT_BuildType>
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
<VerInfo_Keys>CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName)</VerInfo_Keys>
<VerInfo_Locale>1033</VerInfo_Locale>
<Icon_MainIcon>InformationBase_Icon.ico</Icon_MainIcon>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win64)'!=''">
<Icon_MainIcon>InformationBase_Icon.ico</Icon_MainIcon>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1)'!=''">
<DCC_Define>RELEASE;$(DCC_Define)</DCC_Define>
<DCC_DebugInformation>0</DCC_DebugInformation>
<DCC_LocalDebugSymbols>false</DCC_LocalDebugSymbols>
<DCC_SymbolReferenceInfo>0</DCC_SymbolReferenceInfo>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2)'!=''">
<DCC_Define>DEBUG;$(DCC_Define)</DCC_Define>
<DCC_Optimize>false</DCC_Optimize>
<DCC_GenerateStackFrames>true</DCC_GenerateStackFrames>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_Android64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_iOSDevice64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_OSX64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_Win32)'!=''">
<VerInfo_Keys>CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName)</VerInfo_Keys>
<Debugger_HostApplication>D:\Dp10Repo\项目代码\RTBasics\A00通用模板\testDll.exe</Debugger_HostApplication>
</PropertyGroup>
<ItemGroup>
<DelphiCompile Include="$(MainSource)">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="U_GetDllForm.pas"/>
<DCCReference Include="U_DataLink.pas">
<Form>DataLink_InformationBase</Form>
<DesignClass>TDataModule</DesignClass>
</DCCReference>
<DCCReference Include="U_iniParam.pas"/>
<DCCReference Include="..\..\..\public10\design\U_BaseHelp.pas">
<Form>frmBaseHelp</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\..\..\public10\design\U_BaseInput.pas">
<Form>frmBaseInput</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\..\..\public10\design\U_BaseList.pas">
<Form>frmBaseList</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\..\..\public10\design\U_cxGridCustomCss.pas"/>
<DCCReference Include="..\..\..\public10\design\U_globalVar.pas"/>
<DCCReference Include="..\..\..\public10\design\U_WindowFormdesign.pas"/>
<DCCReference Include="..\..\..\public10\ThreeFun\Fun\U_CompressionFun.pas"/>
<DCCReference Include="..\..\..\public10\ThreeFun\Fun\U_RTFun.pas"/>
<DCCReference Include="..\..\..\public10\ThreeFun\Form\U_ZDYHelp.pas">
<Form>frmZDYHelp</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="Unit1.pas">
<Form>Form1</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_AttachmentUpload.pas">
<Form>frmFjList_RZ</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_ClothInfoSel.pas">
<Form>frmClothInfoSel</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_CompanySel.pas">
<Form>frmCompanySel</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_EmployeeSel.pas">
<Form>frmEmployeeSel</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_LablePrint.pas">
<Form>frmLablePrint</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_LbaelMapSet.pas">
<Form>frmLbaelMapSet</Form>
<FormType>dfm</FormType>
</DCCReference>
<BuildConfiguration Include="Debug">
<Key>Cfg_2</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
<BuildConfiguration Include="Base">
<Key>Base</Key>
</BuildConfiguration>
<BuildConfiguration Include="Release">
<Key>Cfg_1</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Delphi.Personality.12</Borland.Personality>
<Borland.ProjectType/>
<BorlandProject>
<Delphi.Personality>
<Source>
<Source Name="MainSource">InformationBase.dpr</Source>
</Source>
</Delphi.Personality>
<Platforms>
<Platform value="Android64">True</Platform>
<Platform value="iOSDevice64">True</Platform>
<Platform value="Linux64">True</Platform>
<Platform value="OSX64">True</Platform>
<Platform value="Win32">True</Platform>
<Platform value="Win64">False</Platform>
</Platforms>
<Deployment Version="3">
<DeployFile LocalName="InformationBase.dll" Configuration="Debug" Class="ProjectOutput">
<Platform Name="Win32">
<RemoteName>InformationBase.dll</RemoteName>
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployClass Name="AdditionalDebugSymbols">
<Platform Name="OSX32">
<Operation>1</Operation>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidClassesDexFile">
<Platform Name="Android">
<RemoteDir>classes</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>classes</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidFileProvider">
<Platform Name="Android">
<RemoteDir>res\xml</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\xml</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidGDBServer">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeArmeabiFile">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>library\lib\armeabi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeArmeabiv7aFile">
<Platform Name="Android64">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeMipsFile">
<Platform Name="Android">
<RemoteDir>library\lib\mips</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>library\lib\mips</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidServiceOutput">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>library\lib\arm64-v8a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidServiceOutput_Android32">
<Platform Name="Android64">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashImageDef">
<Platform Name="Android">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashStyles">
<Platform Name="Android">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashStylesV21">
<Platform Name="Android">
<RemoteDir>res\values-v21</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\values-v21</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_Colors">
<Platform Name="Android">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_DefaultAppIcon">
<Platform Name="Android">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon144">
<Platform Name="Android">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon192">
<Platform Name="Android">
<RemoteDir>res\drawable-xxxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xxxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon36">
<Platform Name="Android">
<RemoteDir>res\drawable-ldpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-ldpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon48">
<Platform Name="Android">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon72">
<Platform Name="Android">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon96">
<Platform Name="Android">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon24">
<Platform Name="Android">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon36">
<Platform Name="Android">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon48">
<Platform Name="Android">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon72">
<Platform Name="Android">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon96">
<Platform Name="Android">
<RemoteDir>res\drawable-xxxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xxxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage426">
<Platform Name="Android">
<RemoteDir>res\drawable-small</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-small</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage470">
<Platform Name="Android">
<RemoteDir>res\drawable-normal</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-normal</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage640">
<Platform Name="Android">
<RemoteDir>res\drawable-large</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-large</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage960">
<Platform Name="Android">
<RemoteDir>res\drawable-xlarge</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xlarge</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_Strings">
<Platform Name="Android">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DebugSymbols">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<Operation>1</Operation>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DependencyFramework">
<Platform Name="OSX32">
<Operation>1</Operation>
<Extensions>.framework</Extensions>
</Platform>
<Platform Name="OSX64">
<Operation>1</Operation>
<Extensions>.framework</Extensions>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DependencyModule">
<Platform Name="OSX32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.dll;.bpl</Extensions>
</Platform>
</DeployClass>
<DeployClass Required="true" Name="DependencyPackage">
<Platform Name="iOSDevice32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.bpl</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="File">
<Platform Name="Android">
<Operation>0</Operation>
</Platform>
<Platform Name="Android64">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>0</Operation>
</Platform>
<Platform Name="OSX32">
<Operation>0</Operation>
</Platform>
<Platform Name="OSX64">
<Operation>0</Operation>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iOS_AppStore1024">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_AppIcon152">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_AppIcon167">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch2x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_LaunchDark2x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Notification40">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Setting58">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_SpotLight80">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_AppIcon120">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_AppIcon180">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch2x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch3x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_LaunchDark2x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_LaunchDark3x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Notification40">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Notification60">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Setting58">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Setting87">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Spotlight120">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Spotlight80">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectAndroidManifest">
<Platform Name="Android">
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSDeviceDebug">
<Platform Name="iOSDevice32">
<RemoteDir>..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSEntitlements"/>
<DeployClass Name="ProjectiOSInfoPList"/>
<DeployClass Name="ProjectiOSLaunchScreen"/>
<DeployClass Name="ProjectiOSResource">
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOSXDebug"/>
<DeployClass Name="ProjectOSXEntitlements"/>
<DeployClass Name="ProjectOSXInfoPList"/>
<DeployClass Name="ProjectOSXResource">
<Platform Name="OSX32">
<RemoteDir>Contents\Resources</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="OSX64">
<RemoteDir>Contents\Resources</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Required="true" Name="ProjectOutput">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>library\lib\arm64-v8a</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="Linux64">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX64">
<Operation>1</Operation>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOutput_Android32">
<Platform Name="Android64">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectUWPManifest">
<Platform Name="Win32">
<Operation>1</Operation>
</Platform>
<Platform Name="Win64">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="UWP_DelphiLogo150">
<Platform Name="Win32">
<RemoteDir>Assets</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Win64">
<RemoteDir>Assets</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="UWP_DelphiLogo44">
<Platform Name="Win32">
<RemoteDir>Assets</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Win64">
<RemoteDir>Assets</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<ProjectRoot Platform="iOSDevice64" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Win64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSDevice32" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Linux64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="Win32" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="OSX32" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="Android" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="OSX64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSSimulator" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Android64" Name="$(PROJECTNAME)"/>
</Deployment>
</BorlandProject>
<ProjectFileVersion>12</ProjectFileVersion>
</ProjectExtensions>
<Import Project="$(BDS)\Bin\CodeGear.Delphi.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Delphi.Targets')"/>
<Import Project="$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj" Condition="Exists('$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj')"/>
<Import Project="$(MSBuildProjectName).deployproj" Condition="Exists('$(MSBuildProjectName).deployproj')"/>
</Project>

View File

@ -0,0 +1,97 @@
<?xml version="1.0" encoding="utf-8"?>
<BorlandProject>
<Transactions>
<Transaction>1899-12-30 00:00:00.000.422,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_CompanySel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.692,D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_CompanySel.pas=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_ClothInfoSel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.092,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_EmployeeSel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.939,=D:\Dp10Repo\public10\design\U_BaseInput.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.630,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_CompanySel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.734,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_CompanySel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.149,=D:\Dp10Repo\public10\ThreeFun\Form\U_ZDYHelp.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.716,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_ProcessSel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.339,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_ClothInfoSel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.616,D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_LablePrint.pas=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_CompanySel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.487,D:\Dp10Repo\项目代码\睿特\新DLL初始化(CSH.dll)\U_ZDYHelpSel.pas=</Transaction>
<Transaction>1899-12-30 00:00:00.000.493,=D:\Dp10Repo\项目代码\RTBasics\A00通用模板\Unit1.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.135,D:\Dp10Repo\项目代码\睿特\新DLL初始化(CSH.dll)\U_ZDYHelp.pas=</Transaction>
<Transaction>1899-12-30 00:00:00.000.616,D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_LablePrint.dfm=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_CompanySel.dfm</Transaction>
<Transaction>1899-12-30 00:00:00.000.832,=D:\Dp10Repo\public10\design\U_BaseHelp.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.015,=D:\Dp10Repo\public10\ThreeFun\Fun\U_RTFun.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.692,D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_CompanySel.dfm=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_ClothInfoSel.dfm</Transaction>
<Transaction>1899-12-30 00:00:00.000.975,=D:\Dp10Repo\public10\ThreeFun\Fun\U_CompressionFun.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.844,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_AttachmentUpload.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.178,=D:\Dp10Repo\public10\design\U_WindowFormdesign.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.048,=D:\Dp10Repo\public10\design\U_BaseList.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.736,D:\Dp10Repo\项目代码\睿特\新DLL初始化(CSH.dll)\U_ModuleNote.pas=</Transaction>
<Transaction>1899-12-30 00:00:00.000.873,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_LbaelMapSet.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.086,=D:\Dp10Repo\public10\design\U_cxGridCustomCss.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.123,=D:\Dp10Repo\public10\design\U_globalVar.pas</Transaction>
</Transactions>
<ProjectSortOrder AutoSort="0" SortType="0">
<File Path="android-support-v4.dex.jar"/>
<File Path="cloud-messaging.dex.jar"/>
<File Path="com-google-android-gms.play-services-ads-base.17.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-ads-identifier.16.0.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-ads-lite.17.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-ads.17.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-analytics-impl.16.0.8.dex.jar"/>
<File Path="com-google-android-gms.play-services-analytics.16.0.8.dex.jar"/>
<File Path="com-google-android-gms.play-services-base.16.0.1.dex.jar"/>
<File Path="com-google-android-gms.play-services-basement.16.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-gass.17.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-identity.16.0.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-maps.16.1.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-measurement-base.16.4.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-measurement-sdk-api.16.4.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-stats.16.0.1.dex.jar"/>
<File Path="com-google-android-gms.play-services-tagmanager-v4-impl.16.0.8.dex.jar"/>
<File Path="com-google-android-gms.play-services-tasks.16.0.1.dex.jar"/>
<File Path="com-google-android-gms.play-services-wallet.16.0.1.dex.jar"/>
<File Path="com-google-firebase.firebase-analytics.16.4.0.dex.jar"/>
<File Path="com-google-firebase.firebase-common.16.1.0.dex.jar"/>
<File Path="com-google-firebase.firebase-iid-interop.16.0.1.dex.jar"/>
<File Path="com-google-firebase.firebase-iid.17.1.1.dex.jar"/>
<File Path="com-google-firebase.firebase-measurement-connector.17.0.1.dex.jar"/>
<File Path="com-google-firebase.firebase-messaging.17.5.0.dex.jar"/>
<File Path="fmx.dex.jar"/>
<File Path="google-play-billing.dex.jar"/>
<File Path="google-play-licensing.dex.jar"/>
<File Path="U_GetDllForm.pas"/>
<File Path="U_DataLink.pas"/>
<File Path="U_DataLink.dfm"/>
<File Path="U_iniParam.pas"/>
<File Path="D:\Dp10Repo"/>
<File Path="..\..\..\public10"/>
<File Path="..\..\..\public10\design"/>
<File Path="..\..\..\public10\design\U_BaseHelp.pas"/>
<File Path="..\..\..\public10\design\U_BaseHelp.dfm"/>
<File Path="..\..\..\public10\design\U_BaseInput.pas"/>
<File Path="..\..\..\public10\design\U_BaseInput.dfm"/>
<File Path="..\..\..\public10\design\U_BaseList.pas"/>
<File Path="..\..\..\public10\design\U_BaseList.dfm"/>
<File Path="..\..\..\public10\design\U_cxGridCustomCss.pas"/>
<File Path="..\..\..\public10\design\U_globalVar.pas"/>
<File Path="..\..\..\public10\design\U_WindowFormdesign.pas"/>
<File Path="..\..\..\public10\ThreeFun"/>
<File Path="..\..\..\public10\ThreeFun\Form"/>
<File Path="..\..\..\public10\ThreeFun\Form\U_ZDYHelp.pas"/>
<File Path="..\..\..\public10\ThreeFun\Form\U_ZDYHelp.dfm"/>
<File Path="..\..\..\public10\ThreeFun\Fun"/>
<File Path="..\..\..\public10\ThreeFun\Fun\U_CompressionFun.pas"/>
<File Path="..\..\..\public10\ThreeFun\Fun\U_RTFun.pas"/>
<File Path="Unit1.pas"/>
<File Path="Unit1.dfm"/>
<File Path="..\..\东亚"/>
<File Path="..\A00通用窗体"/>
<File Path="..\A00通用窗体\U_AttachmentUpload.pas"/>
<File Path="..\A00通用窗体\U_AttachmentUpload.dfm"/>
<File Path="..\A00通用窗体\U_ClothInfoSel.pas"/>
<File Path="..\A00通用窗体\U_ClothInfoSel.dfm"/>
<File Path="..\A00通用窗体\U_EmployeeSel.pas"/>
<File Path="..\A00通用窗体\U_EmployeeSel.dfm"/>
<File Path="..\A00通用窗体\U_LablePrint.pas"/>
<File Path="..\A00通用窗体\U_CompanySel.pas"/>
<File Path="..\A00通用窗体\U_CompanySel.dfm"/>
<File Path="..\A00通用窗体\U_LbaelMapSet.pas"/>
</ProjectSortOrder>
</BorlandProject>

Binary file not shown.

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 766 B

View File

@ -0,0 +1,23 @@
#------------------------------------------------------------------------------
VERSION = BWS.01
#------------------------------------------------------------------------------
!ifndef ROOT
ROOT = $(MAKEDIR)\..
!endif
#------------------------------------------------------------------------------
MAKE = $(ROOT)\bin\make.exe -$(MAKEFLAGS) -f$**
DCC = $(ROOT)\bin\dcc32.exe $**
BRCC = $(ROOT)\bin\brcc32.exe $**
#------------------------------------------------------------------------------
PROJECTS = testDll.exe ProductPrice.dll
#------------------------------------------------------------------------------
default: $(PROJECTS)
#------------------------------------------------------------------------------
testDll.exe: testDll.dpr
$(DCC)
ProductPrice.dll: ProductPrice.dpr
$(DCC)

View File

@ -0,0 +1,48 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{D75EC075-444C-40C2-8ACB-0AAD801B39FF}</ProjectGuid>
</PropertyGroup>
<ItemGroup>
<Projects Include="InformationBase.dproj">
<Dependencies/>
</Projects>
<Projects Include="testDll.dproj">
<Dependencies/>
</Projects>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Default.Personality.12</Borland.Personality>
<Borland.ProjectType/>
<BorlandProject>
<Default.Personality/>
</BorlandProject>
</ProjectExtensions>
<Target Name="InformationBase">
<MSBuild Projects="InformationBase.dproj"/>
</Target>
<Target Name="InformationBase:Clean">
<MSBuild Projects="InformationBase.dproj" Targets="Clean"/>
</Target>
<Target Name="InformationBase:Make">
<MSBuild Projects="InformationBase.dproj" Targets="Make"/>
</Target>
<Target Name="testDll">
<MSBuild Projects="testDll.dproj"/>
</Target>
<Target Name="testDll:Clean">
<MSBuild Projects="testDll.dproj" Targets="Clean"/>
</Target>
<Target Name="testDll:Make">
<MSBuild Projects="testDll.dproj" Targets="Make"/>
</Target>
<Target Name="Build">
<CallTarget Targets="InformationBase;testDll"/>
</Target>
<Target Name="Clean">
<CallTarget Targets="InformationBase:Clean;testDll:Clean"/>
</Target>
<Target Name="Make">
<CallTarget Targets="InformationBase:Make;testDll:Make"/>
</Target>
<Import Project="$(BDS)\Bin\CodeGear.Group.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Group.Targets')"/>
</Project>

View File

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<BorlandProject>
<Transactions/>
<Default.Personality>
<Projects ActiveProject="D:\Dp10Repo\项目代码\东亚\A00通用模板\InformationBase.dproj"/>
</Default.Personality>
</BorlandProject>

View File

@ -0,0 +1,6 @@
[SERVER]
服务器地址=101.132.143.144
服务器地址类型=2002
是否自动更新=1
软件名称=睿特版本库
登陆标题=sss

14275
A00通用模板/U_DataLink.dfm Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,127 @@
unit U_DataLink;
interface
uses
SysUtils, Classes, DB, ADODB, ImgList, Controls, cxStyles, cxLookAndFeels,
Windows, Messages, forms, OleCtnrs, DateUtils, ExtCtrls, SyncObjs, cxClasses,
dxSkinsCore, dxSkinsDefaultPainters, System.ImageList;
type
TMyThread = class(TThread)
protected
procedure Execute; override;
end;
var
DConString: string; {全局连接字符串}
server, dtbase, user, pswd: string; {数据库连接参数}
DCurHandle: hwnd; //当前窗体句柄
DName: string; //#用户名#//
DCode: string; //#用户编号#//
Ddatabase: string; //#数据库名称#//
DTitCaption: string; //#主窗体名称#//
PicSvr: string;
fDllFileName: string;
DParameters1, DParameters2, DParameters3, DParameters4, DParameters5: string; // 外部参数;
DParameters6, DParameters7, DParameters8, DParameters9, DParameters10: string; //外部参数;
OldDllApp: Tapplication; //保存原有句柄
NewDllApp: Tapplication; //当前句柄
MainApplication: Tapplication;
DFormCode: integer; //当前窗口号
IsDelphiLanguage: integer;
DServerDate: TdateTime; //服务器时间
DCompany: string; //公司
IpCall: Integer;
IpWLDZStr: string;
UserDataFlag: string;
type
TDataLink_InformationBase = class(TDataModule)
AdoDataLink: TADOQuery;
ADOLink: TADOConnection;
ThreeImgList: TImageList;
ThreeLookAndFeelCol: TcxLookAndFeelController;
ThreeColorBase: TcxStyleRepository;
SHuangSe: TcxStyle;
SkyBlue: TcxStyle;
Default: TcxStyle;
QHuangSe: TcxStyle;
Red: TcxStyle;
FontBlue: TcxStyle;
TextSHuangSe: TcxStyle;
FonePurple: TcxStyle;
FoneClMaroon: TcxStyle;
FoneRed: TcxStyle;
RowColor: TcxStyle;
handBlack: TcxStyle;
cxBlue: TcxStyle;
SHuangSeCu: TcxStyle;
Timer_link: TTimer;
ImageList_new32: TImageList;
procedure DataModuleDestroy(Sender: TObject);
procedure Timer_linkTimer(Sender: TObject);
procedure DataModuleCreate(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
TMakebar = procedure(ucData: pchar; nDataLen: integer; nErrLevel: integer; nMask: integer; nBarEdition: integer; szBmpFileName: pchar; nScale: integer); stdcall;
TMixtext = procedure(szSrcBmpFileName: PChar; szDstBmpFileName: PChar; sztext: PChar; fontsize, txtheight, hmargin, vmargin, txtcntoneline: integer); stdcall;
var
DataLink_InformationBase: TDataLink_InformationBase;
CriticalSection: TCriticalSection; {声明临界}
implementation
{$R *.dfm}
procedure TMyThread.Execute;
begin
FreeOnTerminate := True;
CriticalSection.Enter;
try
with DataLink_InformationBase.AdoDataLink do
begin
close;
sql.Clear;
sql.Add('select getdate()');
open;
end;
except
try
with DataLink_InformationBase.ADOLink do
begin
Connected := false;
ConnectionString := DConString;
LoginPrompt := false;
Connected := true;
end;
except
end;
end;
CriticalSection.Leave;
end;
procedure TDataLink_InformationBase.DataModuleDestroy(Sender: TObject);
begin
CriticalSection.Free;
DataLink_InformationBase := nil;
end;
procedure TDataLink_InformationBase.Timer_linkTimer(Sender: TObject);
begin
TMyThread.Create(False);
end;
procedure TDataLink_InformationBase.DataModuleCreate(Sender: TObject);
begin
CriticalSection := TCriticalSection.Create;
end;
end.

View File

@ -0,0 +1,218 @@
unit U_GetDllForm;
interface
uses
Windows, Messages, forms, OleCtnrs, DateUtils, SysUtils, ADODB, dxCore,
ActiveX, IniFiles;
function GetDllForm(App: Tapplication; FormH: hwnd; FormID: integer; Language: integer; WinStyle: integer; GCode: Pchar; GName: Pchar; DataBase: Pchar; Title: PChar; Parameters1: PChar; Parameters2: PChar; Parameters3: PChar; Parameters4: PChar; Parameters5: PChar; Parameters6: PChar; Parameters7: PChar; Parameters8: PChar; Parameters9: PChar; Parameters10: PChar; DataBaseStr: PChar): hwnd; export; stdcall;
function ConnData(): Boolean;
function GetsysParam(muserId: pchar; fparam1: pchar): Boolean;
implementation
uses
U_DataLink, U_iniParam, Unit1;
/////////////////////////////////////////////////////////////////
// 功能说明:取Dll中得窗体 //
// 参数说明App>>调用应用程序; //
// FormH>>调用窗口句柄 //
// FormID>>窗口号; //
// Language>>语言种类; //
// WinStyle>>窗口类型; //
/////////////////////////////////////////////////////////////////
function GetDllForm(App: Tapplication; FormH: hwnd; FormID: integer; Language: integer; WinStyle: integer; GCode: Pchar; GName: Pchar; DataBase: Pchar; Title: PChar; Parameters1: PChar; Parameters2: PChar; Parameters3: PChar; Parameters4: PChar; Parameters5: PChar; Parameters6: PChar; Parameters7: PChar; Parameters8: PChar; Parameters9: PChar; Parameters10: PChar; DataBaseStr: PChar): hwnd;
var
i: Integer;
bFound: Boolean;
mnewHandle: hwnd;
mstyle: TFormStyle; // 0:子窗口; 1:普通窗口
mstate: TWindowState;
mborderstyle: TFormBorderStyle;
begin
mnewHandle := 0;
DName := PChar(GName);
DCode := PChar(GCode);
DdataBase := DataBase;
DTitCaption := Title;
DParameters1 := Parameters1;
DParameters2 := Parameters2;
DParameters3 := Parameters3;
DParameters4 := Parameters4;
DParameters5 := Parameters5;
DParameters6 := Parameters6;
DParameters7 := Parameters7;
DParameters8 := Parameters8;
DParameters9 := Parameters9;
DParameters10 := Parameters10;
SetLength(fDllFileName, 255);
GetModuleFileName(HInstance, PChar(fDllFileName), Length(fDllFileName));
fDllFileName := ExtractFileName(PChar(fDllFileName));
MainApplication := App;
DCurHandle := FormH;
IsDelphiLanguage := Language;
Application := TApplication(App);
DCurHandle := 0;
//赋值链接字符串
SetLength(server, 255);
SetLength(dtbase, 255);
SetLength(user, 255);
SetLength(pswd, 255);
if trim(DataBaseStr) = '' then
begin
server := '101.132.143.144,7781';
dtbase := 'RTBasicsData';
user := 'rtsa';
pswd := 'rightsoft@5740';
DConString := 'Provider=SQLOLEDB.1;Password=' + pswd + ';Persist Security Info=True;User ID=' + user + ';Initial Catalog=' + dtbase + ';Data Source=' + server;
// DParameters1:='高权限';
end
else
begin
DConString := DataBaseStr;
end;
if not ConnData() then
begin
result := 0;
exit;
end;
if IsINIFile() then
ReadINIFile()
else
WriteINIFile;
GetsysParam('', '');
// 定义窗口类型 、状态
if WinStyle = 0 then
begin
mstyle := fsMDIChild;
mstate := wsMaximized;
mborderstyle := bsSizeable;
end
else
begin
mstyle := fsNormal;
mstate := wsNormal;
mborderstyle := bsSizeable;
end;
bFound := False;
if FormID <> 10000 then
begin
for i := 0 to Application.MainForm.MDIChildCount - 1 do
begin
if Application.MainForm.MDIChildren[i].Caption = Title then
begin
mnewHandle := Application.MainForm.MDIChildren[i].Handle;
Application.MainForm.MDIChildren[i].BringToFront;
bFound := True;
Result := mnewHandle;
exit;
end;
end;
end;
/////////////////////
//调用子模块窗口
case FormID of
1: //测试用
begin
with TForm1.Create(Application.MainForm, Title, trim(Parameters1), trim(Parameters2), trim(Parameters3), trim(Parameters4), trim(Parameters5), trim(Parameters10)) do //
begin
fFormID := FormID;
FormStyle := mstyle;
WindowState := mstate;
BorderStyle := mborderstyle;
mnewHandle := Handle;
end;
end;
10000:
begin
for i := 0 to application.MainForm.MDIChildCount - 1 do
begin
if application.MainForm.MDIChildren[i].Caption = Title then
begin
application.MainForm.MDIChildren[i].Close;
end;
end;
end;
end;
Result := mnewHandle;
end;
function GetsysParam(muserId: pchar; fparam1: pchar): Boolean;
begin
result := true;
//////////////////////////////
// shortDateFormat := 'yyyy-MM-dd';
//服务器日期
with DataLink_InformationBase.AdoDataLink do
begin
close;
sql.Clear;
sql.Add('select getDate()as dt');
open;
DServerDate := fieldByName('dt').AsDatetime;
end;
result := true;
end;
//===========================================================
//建立数据库连接池
//===========================================================
function ConnData(): Boolean;
var
IniFile: TIniFile;
begin
try
IniFile := TIniFile.Create(ExtractFilePath(Application.ExeName) + 'SYSTEMSET.INI');
PicSvr := IniFile.ReadString('SERVER', '服务器地址', '127.0.0.1');
UserDataFlag := IniFile.ReadString('SERVER', '服务器地址类型', '-1');
finally
IniFile.Free;
end;
if not Assigned(DataLink_InformationBase) then
DataLink_InformationBase := TDataLink_InformationBase.Create(Application);
try
with DataLink_InformationBase.ADOLink do
begin
if not Connected then
begin
Connected := false;
ConnectionString := DConString;
LoginPrompt := false;
Connected := true;
end;
end;
Result := true;
except
Result := false;
application.MessageBox('数据库连接失败!', '错误', mb_Ok + MB_ICONERROR);
end;
end;
initialization
CoInitialize(nil);
dxUnitsLoader.Initialize;
finalization
DataLink_InformationBase.Free;
application := NewDllApp;
dxUnitsLoader.Finalize;
end.

View File

@ -0,0 +1,77 @@
unit U_iniParam;
interface
uses
IniFiles, SysUtils;
var
Filename: string; //文件名
iParam2: integer;
bParam1: Boolean;
bParam2: Boolean;
SCXFlag: string; //生产线 根据此标志获取卷条码前缀 不能包含字母 1,2
SCXCount: string; //机台个数
PortNoStr: string; //端口号
DllName: string; //端口Dll文件
DZCDYDllName: string; //电子秤调用Dll文件
MBDYDllName: string; // 码表调用Dll文件
function IsINIFile(): Boolean; //判断InI配置文件是否存在
procedure ReadINIFile();
procedure WriteINIFile();
implementation
///////////////////////////////////////////////////////////////////
//读取ini文件设置参数
//参数:
////////////////////////////////////////////////////////////////////
procedure ReadINIFile();
var
programIni: Tinifile; //配置文件名
begin
FileName := ExtractFilePath(Paramstr(0)) + 'File.INI';
programIni := Tinifile.create(FileName);
SCXFlag := programIni.ReadString('生产车间配置', '卷条码机台标志', '1');
SCXCount := programIni.ReadString('生产车间配置', '机台个数', '1');
PortNoStr := programIni.ReadString('生产车间配置', '端口号', 'com1');
DllName := programIni.ReadString('生产车间配置', '端口Dll文件', 'JZCRS323C.DLL');
DZCDYDllName := programIni.ReadString('生产车间配置', '电子秤调用Dll文件', '');
MBDYDllName := programIni.ReadString('生产车间配置', '码表调用Dll文件', '');
programIni.Free;
end;
//////////////////////////////////////////////////////////////////
//写设置信息到INI文件
//参数
//////////////////////////////////////////////////////////////////
procedure WriteINIFile();
var
programIni: Tinifile; //配置文件名
begin
FileName := ExtractFilePath(Paramstr(0)) + 'File.INI';
programIni := Tinifile.create(FileName);
programIni.WriteString('生产车间配置', '卷条码机台标志', SCXFlag);
programIni.WriteString('生产车间配置', '机台个数', SCXCount);
programIni.WriteString('生产车间配置', '端口号', PortNoStr);
programIni.WriteString('生产车间配置', '端口Dll文件', DllName);
programIni.Free;
end;
//////////////////////////////////////////////////////////////////
//判断InI文件是否存在
//////////////////////////////////////////////////////////////////
function IsINIFile(): Boolean;
begin
FileName := ExtractFilePath(Paramstr(0)) + 'File.INI';
if FileExists(FileName) then
Result := true
else
Result := false;
end;
end.

View File

@ -0,0 +1,221 @@
object Form1: TForm1
Left = 203
Top = 121
Caption = 'Form1'
ClientHeight = 426
ClientWidth = 716
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'MS Sans Serif'
Font.Style = []
FormStyle = fsMDIForm
Menu = MainMenu1
OldCreateOrder = False
WindowState = wsMaximized
OnClose = FormClose
OnResize = FormResize
PixelsPerInch = 96
TextHeight = 13
object ToolBar1: TToolBar
Left = 0
Top = 0
Width = 716
Height = 25
ButtonWidth = 57
Caption = 'ToolBar1'
Images = ImageList1
TabOrder = 0
ExplicitWidth = 120
object Edit1: TEdit
Left = 0
Top = 0
Width = 81
Height = 22
TabOrder = 0
Text = '1'
end
object ToolButton1: TToolButton
Left = 81
Top = 0
Caption = #20851#38381
ImageIndex = 0
OnClick = ToolButton1Click
end
object Label1: TLabel
Left = 138
Top = 0
Width = 79
Height = 22
Caption = ' DllName'#65306
end
object DllName: TEdit
Left = 217
Top = 0
Width = 135
Height = 22
TabOrder = 1
end
end
object MainMenu1: TMainMenu
Left = 232
Top = 40
object test1: TMenuItem
Caption = 'test'
OnClick = test1Click
end
end
object ImageList1: TImageList
Left = 320
Top = 56
Bitmap = {
494C010101000400040010001000FFFFFFFFFF10FFFFFFFFFFFFFFFF424D3600
0000000000003600000028000000400000001000000001002000000000000010
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000EFEFEF000000
0000EFEFEF00EFEFEF000000000000000000EFEFEF0000000000000000000000
0000EFEFEF00EFEFEF0000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000EFEFEF0000000000EFEFEF00EFEFEF0000000000EFEFEF00000000008080
00008080000000000000C0C0C000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000EFEFEF00EFEFEF000000
0000EFEFEF00EFEFEF000000000000000000C0C0C00000000000000000008080
00008080000080800000EFEFEF00EFEFEF000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
000000000000EFEFEF0000000000000000000000000000000000000000008080
0000808000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
000000000000EFEFEF0000000000808080008080800080808000000000008080
0000808000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000008080000000000000808080008080800080808000000000008080
0000000000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000EFEFEF00EFEF
EF0000000000FFFF000080800000000000008080800080808000000000000000
0000000000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
000000000000FFFF0000FFFF0000808000000000000080808000000000008080
0000000000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000808000008080
000080800000FFFF0000FFFF0000FFFF00000000000080808000000000008080
0000808000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000FFFF0000FFFF
0000FFFF0000FFFF000000000000FFFF00000000000080808000000000008080
0000808000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
000000000000FFFF0000FFFF0000FFFF00000000000080808000000000008080
0000808000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
000000000000808000000000000080808000808080008080800080808000FFFF
0000808000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000808080008080800080808000808080000000
0000808000008080000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000424D3E000000000000003E000000
2800000040000000100000000100010000000000800000000000000000000000
000000000000000000000000FFFFFF00FFFF000000000000D343000000000000
F4810000000000009340000000000000F801000000000000F001000000000000
F001000000000000C001000000000000C001000000000000C001000000000000
C201000000000000C001000000000000F001000000000000F001000000000000
FC03000000000000FFFF00000000000000000000000000000000000000000000
000000000000}
end
object ADOConnection1: TADOConnection
ConnectionString =
'Provider=SQLOLEDB.1;Password=sa;Persist Security Info=True;User ' +
'ID=sa;Initial Catalog=rzdata;Data Source=6GMFFMYKYMJDZW7'
LoginPrompt = False
Provider = 'SQLOLEDB.1'
Left = 408
Top = 64
end
end

View File

@ -0,0 +1,94 @@
unit U_testdll;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, ExtCtrls, StdCtrls, Menus, ToolWin, ComCtrls, ImgList, DB, ADODB,
System.ImageList;
type
TForm1 = class(TForm)
MainMenu1: TMainMenu;
test1: TMenuItem;
ToolBar1: TToolBar;
Edit1: TEdit;
ToolButton1: TToolButton;
ImageList1: TImageList;
ADOConnection1: TADOConnection;
DllName: TEdit;
Label1: TLabel;
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure test1Click(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure FormResize(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
newh: hwnd;
implementation
{$R *.dfm}
procedure TForm1.FormClose(Sender: TObject; var Action: TCloseAction);
begin
sendmessage(newh, 1034, 4, 0);
Action := cafree;
end;
procedure TForm1.test1Click(Sender: TObject);
type
TMyFunc = function(App: Tapplication; FormH: hwnd; FormID: integer; Language: integer; WinStyle: integer; GCode: Pchar; GName: Pchar; DataBase: Pchar; Title: PChar; Parameters1: PChar; Parameters2: PChar; Parameters3: PChar; Parameters4: PChar; Parameters5: PChar; Parameters6: PChar; Parameters7: PChar; Parameters8: PChar; Parameters9: PChar; Parameters10: PChar; DataBaseStr: PChar): hwnd; stdcall;
var
Tf: TMyFunc;
Tp: TFarProc;
Th: Thandle;
begin
//静态加载
//newh:=getForm(Application,1,ADOConnection1,PChar('sa'),PChar('dsa'));
//动态加载
// showMessage(intTostr(application.Handle));
Th := LoadLibrary('InformationBase.dll');
if Th > 0 then
begin
try
Tp := GetProcAddress(Th, 'GetDllForm');
if Tp <> nil then
begin
Tf := TMyFunc(Tp);
newh := Tf(Application, 0, strToint(edit1.text), 0, 0, PChar('ygcode'), PChar('ygname'), PChar('datebase'), PChar('title'), PChar(''), PChar(''), '', '', '', '', '', '', '', '', '');
end
else
begin
ShowMessage('打印执行错误');
end;
finally
// FreeLibrary();
end;
end
else
begin
ShowMessage('找不到' + Trim(DllName.Text));
end;
end;
procedure TForm1.ToolButton1Click(Sender: TObject);
begin
close;
end;
procedure TForm1.FormResize(Sender: TObject);
begin
sendmessage(newh, 1034, 1, 0);
end;
end.

64
A00通用模板/Unit1.dfm Normal file
View File

@ -0,0 +1,64 @@
inherited Form1: TForm1
Caption = 'Form1'
ClientHeight = 299
ClientWidth = 635
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Height = -11
Font.Name = 'Tahoma'
ExplicitWidth = 651
ExplicitHeight = 338
PixelsPerInch = 96
TextHeight = 13
object Button1: TButton [0]
Left = 32
Top = 16
Width = 75
Height = 25
Caption = #23458#25143
TabOrder = 0
OnClick = Button1Click
end
object Button2: TButton [1]
Left = 32
Top = 47
Width = 75
Height = 25
Caption = #26679#21697
TabOrder = 1
OnClick = Button2Click
end
object Button3: TButton [2]
Left = 32
Top = 78
Width = 75
Height = 25
Caption = #24037#24207#36873#25321
TabOrder = 2
end
object Button4: TButton [3]
Left = 32
Top = 118
Width = 75
Height = 25
Caption = #21592#24037#36873#25321
TabOrder = 3
OnClick = Button4Click
end
object Button5: TButton [4]
Left = 32
Top = 174
Width = 75
Height = 25
Caption = #26631#31614#25171#21360
TabOrder = 4
OnClick = Button5Click
end
inherited ADOQueryBaseCmd: TADOQuery
Connection = DataLink_InformationBase.ADOLink
Left = 345
end
inherited ADOQueryBaseTemp: TADOQuery
Connection = DataLink_InformationBase.ADOLink
end
end

106
A00通用模板/Unit1.pas Normal file
View File

@ -0,0 +1,106 @@
unit Unit1;
interface
uses
Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
System.Classes, Vcl.Graphics, Vcl.Controls, Vcl.Forms, Vcl.Dialogs, U_BaseList,
Data.DB, Data.Win.ADODB, Vcl.StdCtrls;
type
TForm1 = class(TfrmBaseList)
Button1: TButton;
Button2: TButton;
Button3: TButton;
Button4: TButton;
Button5: TButton;
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure Button4Click(Sender: TObject);
procedure Button5Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
uses
U_DataLink, U_CompanySel, U_ClothInfoSel, U_EmployeeSel, U_LablePrint;
{$R *.dfm}
procedure TForm1.Button1Click(Sender: TObject);
begin
try
frmCompanySel := TfrmCompanySel.Create(Application);
with frmCompanySel do
begin
if ShowModal = 1 then
begin
// Self.InitGrid();
end;
end;
finally
frmCompanySel.Free;
end;
end;
procedure TForm1.Button2Click(Sender: TObject);
begin
try
frmClothInfoSel := TfrmClothInfoSel.Create(Application);
with frmClothInfoSel do
begin
if ShowModal = 1 then
begin
// Self.InitGrid();
end;
end;
finally
frmClothInfoSel.Free;
end;
end;
procedure TForm1.Button4Click(Sender: TObject);
begin
try
frmEmployeeSel := TfrmEmployeeSel.Create(Application);
with frmEmployeeSel do
begin
if ShowModal = 1 then
begin
// Self.InitGrid();
end;
end;
finally
frmEmployeeSel.Free;
end;
end;
procedure TForm1.Button5Click(Sender: TObject);
begin
try
frmLablePrint := TfrmLablePrint.Create(Application);
with frmLablePrint do
begin
if ShowModal = 1 then
begin
// Self.InitGrid();
end;
end;
finally
frmLablePrint.Free;
end;
end;
end.

View File

@ -0,0 +1,2 @@
[SERVER]
SERVER=192.168.88.254

View File

@ -0,0 +1,38 @@
-$A8
-$B-
-$C+
-$D+
-$E-
-$F-
-$G+
-$H+
-$I+
-$J-
-$K-
-$L+
-$M-
-$N+
-$O+
-$P+
-$Q-
-$R-
-$S-
-$T-
-$U-
-$V+
-$W-
-$X+
-$YD
-$Z1
-cg
-AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
-H+
-W+
-M
-$M16384,1048576
-K$00400000
-LE"c:\program files (x86)\borland\delphi7\Projects\Bpl"
-LN"c:\program files (x86)\borland\delphi7\Projects\Bpl"
-w-UNSAFE_TYPE
-w-UNSAFE_CODE
-w-UNSAFE_CAST

136
A00通用模板/testDll.dof Normal file
View File

@ -0,0 +1,136 @@
[FileVersion]
Version=7.0
[Compiler]
A=8
B=0
C=1
D=1
E=0
F=0
G=1
H=1
I=1
J=0
K=0
L=1
M=0
N=1
O=1
P=1
Q=0
R=0
S=0
T=0
U=0
V=1
W=0
X=1
Y=1
Z=1
ShowHints=1
ShowWarnings=1
UnitAliases=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
NamespacePrefix=
SymbolDeprecated=1
SymbolLibrary=1
SymbolPlatform=1
UnitLibrary=1
UnitPlatform=1
UnitDeprecated=1
HResultCompat=1
HidingMember=1
HiddenVirtual=1
Garbage=1
BoundsError=1
ZeroNilCompat=1
StringConstTruncated=1
ForLoopVarVarPar=1
TypedConstVarPar=1
AsgToTypedConst=1
CaseLabelRange=1
ForVariable=1
ConstructingAbstract=1
ComparisonFalse=1
ComparisonTrue=1
ComparingSignedUnsigned=1
CombiningSignedUnsigned=1
UnsupportedConstruct=1
FileOpen=1
FileOpenUnitSrc=1
BadGlobalSymbol=1
DuplicateConstructorDestructor=1
InvalidDirective=1
PackageNoLink=1
PackageThreadVar=1
ImplicitImport=1
HPPEMITIgnored=1
NoRetVal=1
UseBeforeDef=1
ForLoopVarUndef=1
UnitNameMismatch=1
NoCFGFileFound=1
MessageDirective=1
ImplicitVariants=1
UnicodeToLocale=1
LocaleToUnicode=1
ImagebaseMultiple=1
SuspiciousTypecast=1
PrivatePropAccessor=1
UnsafeType=0
UnsafeCode=0
UnsafeCast=0
[Linker]
MapFile=0
OutputObjs=0
ConsoleApp=1
DebugInfo=0
RemoteSymbols=0
MinStackSize=16384
MaxStackSize=1048576
ImageBase=4194304
ExeDescription=
[Directories]
OutputDir=
UnitOutputDir=
PackageDLLOutputDir=
PackageDCPOutputDir=
SearchPath=
Packages=
Conditionals=
DebugSourceDirs=
UsePackages=0
[Parameters]
RunParams=
HostApplication=D:\selfware_83398\selfware\马国钢开发代码\项目代码\self\坯布码单待检DDMD.dll)\testDll.exe
Launcher=
UseLauncher=0
DebugCWD=
[Language]
ActiveLang=
ProjectLang=
RootDir=
[Version Info]
IncludeVerInfo=0
AutoIncBuild=0
MajorVer=1
MinorVer=0
Release=0
Build=0
Debug=0
PreRelease=0
Special=0
Private=0
DLL=0
Locale=2052
CodePage=936
[Version Info Keys]
CompanyName=
FileDescription=
FileVersion=1.0.0.0
InternalName=
LegalCopyright=
LegalTrademarks=
OriginalFilename=
ProductName=
ProductVersion=1.0.0.0
Comments=

View File

@ -0,0 +1,14 @@
program testDll;
uses
Forms,
U_testdll in 'U_testdll.pas' {Form1};
{$R *.res}
begin
Application.Initialize;
Application.CreateForm(TForm1, Form1);
Application.Run;
end.

View File

@ -0,0 +1,184 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{6ED24B72-E038-4A45-BA13-AC1AB432C410}</ProjectGuid>
<MainSource>testDll.dpr</MainSource>
<Base>True</Base>
<Config Condition="'$(Config)'==''">Debug</Config>
<TargetedPlatforms>38017</TargetedPlatforms>
<AppType>Application</AppType>
<FrameworkType>VCL</FrameworkType>
<ProjectVersion>19.2</ProjectVersion>
<Platform Condition="'$(Platform)'==''">Win32</Platform>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Android64' and '$(Base)'=='true') or '$(Base_Android64)'!=''">
<Base_Android64>true</Base_Android64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSDevice64' and '$(Base)'=='true') or '$(Base_iOSDevice64)'!=''">
<Base_iOSDevice64>true</Base_iOSDevice64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Base)'=='true') or '$(Base_Win32)'!=''">
<Base_Win32>true</Base_Win32>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win64' and '$(Base)'=='true') or '$(Base_Win64)'!=''">
<Base_Win64>true</Base_Win64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Release' or '$(Cfg_1)'!=''">
<Cfg_1>true</Cfg_1>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Cfg_1)'=='true') or '$(Cfg_1_Win32)'!=''">
<Cfg_1_Win32>true</Cfg_1_Win32>
<CfgParent>Cfg_1</CfgParent>
<Cfg_1>true</Cfg_1>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Debug' or '$(Cfg_2)'!=''">
<Cfg_2>true</Cfg_2>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Android64' and '$(Cfg_2)'=='true') or '$(Cfg_2_Android64)'!=''">
<Cfg_2_Android64>true</Cfg_2_Android64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSDevice64' and '$(Cfg_2)'=='true') or '$(Cfg_2_iOSDevice64)'!=''">
<Cfg_2_iOSDevice64>true</Cfg_2_iOSDevice64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='OSX64' and '$(Cfg_2)'=='true') or '$(Cfg_2_OSX64)'!=''">
<Cfg_2_OSX64>true</Cfg_2_OSX64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Cfg_2)'=='true') or '$(Cfg_2_Win32)'!=''">
<Cfg_2_Win32>true</Cfg_2_Win32>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Base)'!=''">
<DCC_E>false</DCC_E>
<DCC_F>false</DCC_F>
<DCC_K>false</DCC_K>
<DCC_N>true</DCC_N>
<DCC_S>false</DCC_S>
<DCC_ImageBase>00400000</DCC_ImageBase>
<DCC_DebugInformation>1</DCC_DebugInformation>
<DCC_SymbolReferenceInfo>1</DCC_SymbolReferenceInfo>
<SanitizedProjectName>testDll</SanitizedProjectName>
<DCC_Namespace>Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;System;Xml;Data;Datasnap;Web;Soap;Winapi;Data.Win;$(DCC_Namespace)</DCC_Namespace>
<VerInfo_Locale>2052</VerInfo_Locale>
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Android64)'!=''">
<Android_LauncherIcon192>$(BDS)\bin\Artwork\Android\FM_LauncherIcon_192x192.png</Android_LauncherIcon192>
<EnabledSysJars>android-support-v4.dex.jar;cloud-messaging.dex.jar;com-google-android-gms.play-services-ads-base.17.2.0.dex.jar;com-google-android-gms.play-services-ads-identifier.16.0.0.dex.jar;com-google-android-gms.play-services-ads-lite.17.2.0.dex.jar;com-google-android-gms.play-services-ads.17.2.0.dex.jar;com-google-android-gms.play-services-analytics-impl.16.0.8.dex.jar;com-google-android-gms.play-services-analytics.16.0.8.dex.jar;com-google-android-gms.play-services-base.16.0.1.dex.jar;com-google-android-gms.play-services-basement.16.2.0.dex.jar;com-google-android-gms.play-services-gass.17.2.0.dex.jar;com-google-android-gms.play-services-identity.16.0.0.dex.jar;com-google-android-gms.play-services-maps.16.1.0.dex.jar;com-google-android-gms.play-services-measurement-base.16.4.0.dex.jar;com-google-android-gms.play-services-measurement-sdk-api.16.4.0.dex.jar;com-google-android-gms.play-services-stats.16.0.1.dex.jar;com-google-android-gms.play-services-tagmanager-v4-impl.16.0.8.dex.jar;com-google-android-gms.play-services-tasks.16.0.1.dex.jar;com-google-android-gms.play-services-wallet.16.0.1.dex.jar;com-google-firebase.firebase-analytics.16.4.0.dex.jar;com-google-firebase.firebase-common.16.1.0.dex.jar;com-google-firebase.firebase-iid-interop.16.0.1.dex.jar;com-google-firebase.firebase-iid.17.1.1.dex.jar;com-google-firebase.firebase-measurement-connector.17.0.1.dex.jar;com-google-firebase.firebase-messaging.17.5.0.dex.jar;fmx.dex.jar;google-play-billing.dex.jar;google-play-licensing.dex.jar</EnabledSysJars>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_iOSDevice64)'!=''">
<iOS_AppStore1024>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_1024x1024.png</iOS_AppStore1024>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win32)'!=''">
<DCC_Namespace>Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace)</DCC_Namespace>
<BT_BuildType>Debug</BT_BuildType>
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
<VerInfo_Keys>CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName)</VerInfo_Keys>
<VerInfo_Locale>1033</VerInfo_Locale>
<Manifest_File>$(BDS)\bin\default_app.manifest</Manifest_File>
<Icon_MainIcon>testDll_Icon.ico</Icon_MainIcon>
<AppEnableRuntimeThemes>true</AppEnableRuntimeThemes>
<UWP_DelphiLogo44>$(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png</UWP_DelphiLogo44>
<UWP_DelphiLogo150>$(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png</UWP_DelphiLogo150>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win64)'!=''">
<Icon_MainIcon>testDll_Icon.ico</Icon_MainIcon>
<UWP_DelphiLogo44>$(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png</UWP_DelphiLogo44>
<UWP_DelphiLogo150>$(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png</UWP_DelphiLogo150>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1)'!=''">
<DCC_Define>RELEASE;$(DCC_Define)</DCC_Define>
<DCC_DebugInformation>0</DCC_DebugInformation>
<DCC_LocalDebugSymbols>false</DCC_LocalDebugSymbols>
<DCC_SymbolReferenceInfo>0</DCC_SymbolReferenceInfo>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1_Win32)'!=''">
<AppEnableRuntimeThemes>true</AppEnableRuntimeThemes>
<AppDPIAwarenessMode>PerMonitorV2</AppDPIAwarenessMode>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2)'!=''">
<DCC_Define>DEBUG;$(DCC_Define)</DCC_Define>
<DCC_Optimize>false</DCC_Optimize>
<DCC_GenerateStackFrames>true</DCC_GenerateStackFrames>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_Android64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_iOSDevice64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_OSX64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_Win32)'!=''">
<AppEnableRuntimeThemes>true</AppEnableRuntimeThemes>
<AppDPIAwarenessMode>PerMonitorV2</AppDPIAwarenessMode>
<VerInfo_Keys>CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName)</VerInfo_Keys>
</PropertyGroup>
<ItemGroup>
<DelphiCompile Include="$(MainSource)">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="U_testdll.pas">
<Form>Form1</Form>
</DCCReference>
<BuildConfiguration Include="Debug">
<Key>Cfg_2</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
<BuildConfiguration Include="Base">
<Key>Base</Key>
</BuildConfiguration>
<BuildConfiguration Include="Release">
<Key>Cfg_1</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Delphi.Personality.12</Borland.Personality>
<Borland.ProjectType/>
<BorlandProject>
<Delphi.Personality>
<Source>
<Source Name="MainSource">testDll.dpr</Source>
</Source>
</Delphi.Personality>
<Platforms>
<Platform value="Android64">True</Platform>
<Platform value="iOSDevice64">True</Platform>
<Platform value="Linux64">True</Platform>
<Platform value="OSX64">True</Platform>
<Platform value="Win32">True</Platform>
<Platform value="Win64">False</Platform>
</Platforms>
</BorlandProject>
<ProjectFileVersion>12</ProjectFileVersion>
</ProjectExtensions>
<Import Project="$(BDS)\Bin\CodeGear.Delphi.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Delphi.Targets')"/>
<Import Project="$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj" Condition="Exists('$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj')"/>
</Project>

View File

@ -0,0 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
<BorlandProject/>

Binary file not shown.

BIN
A00通用模板/testDll.res Normal file

Binary file not shown.

View File

@ -0,0 +1,38 @@
-$A8
-$B-
-$C+
-$D+
-$E-
-$F-
-$G+
-$H+
-$I+
-$J-
-$K-
-$L+
-$M-
-$N+
-$O+
-$P+
-$Q-
-$R-
-$S-
-$T-
-$U-
-$V+
-$W-
-$X+
-$YD
-$Z1
-cg
-AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
-H+
-W+
-M
-$M16384,1048576
-K$00400000
-LE"c:\program files (x86)\borland\delphi7\Projects\Bpl"
-LN"c:\program files (x86)\borland\delphi7\Projects\Bpl"
-w-UNSAFE_TYPE
-w-UNSAFE_CODE
-w-UNSAFE_CAST

View File

@ -0,0 +1,136 @@
[FileVersion]
Version=7.0
[Compiler]
A=8
B=0
C=1
D=1
E=0
F=0
G=1
H=1
I=1
J=0
K=0
L=1
M=0
N=1
O=1
P=1
Q=0
R=0
S=0
T=0
U=0
V=1
W=0
X=1
Y=1
Z=1
ShowHints=1
ShowWarnings=1
UnitAliases=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
NamespacePrefix=
SymbolDeprecated=1
SymbolLibrary=1
SymbolPlatform=1
UnitLibrary=1
UnitPlatform=1
UnitDeprecated=1
HResultCompat=1
HidingMember=1
HiddenVirtual=1
Garbage=1
BoundsError=1
ZeroNilCompat=1
StringConstTruncated=1
ForLoopVarVarPar=1
TypedConstVarPar=1
AsgToTypedConst=1
CaseLabelRange=1
ForVariable=1
ConstructingAbstract=1
ComparisonFalse=1
ComparisonTrue=1
ComparingSignedUnsigned=1
CombiningSignedUnsigned=1
UnsupportedConstruct=1
FileOpen=1
FileOpenUnitSrc=1
BadGlobalSymbol=1
DuplicateConstructorDestructor=1
InvalidDirective=1
PackageNoLink=1
PackageThreadVar=1
ImplicitImport=1
HPPEMITIgnored=1
NoRetVal=1
UseBeforeDef=1
ForLoopVarUndef=1
UnitNameMismatch=1
NoCFGFileFound=1
MessageDirective=1
ImplicitVariants=1
UnicodeToLocale=1
LocaleToUnicode=1
ImagebaseMultiple=1
SuspiciousTypecast=1
PrivatePropAccessor=1
UnsafeType=0
UnsafeCode=0
UnsafeCast=0
[Linker]
MapFile=0
OutputObjs=0
ConsoleApp=1
DebugInfo=0
RemoteSymbols=0
MinStackSize=16384
MaxStackSize=1048576
ImageBase=4194304
ExeDescription=
[Directories]
OutputDir=
UnitOutputDir=
PackageDLLOutputDir=
PackageDCPOutputDir=
SearchPath=
Packages=
Conditionals=
DebugSourceDirs=
UsePackages=0
[Parameters]
RunParams=
HostApplication=D:\selfware_83398\selfware\马国钢开发代码\项目代码\self\长阳针织(CYZZ.dll)\testDll.exe
Launcher=
UseLauncher=0
DebugCWD=
[Language]
ActiveLang=
ProjectLang=
RootDir=
[Version Info]
IncludeVerInfo=0
AutoIncBuild=0
MajorVer=1
MinorVer=0
Release=0
Build=0
Debug=0
PreRelease=0
Special=0
Private=0
DLL=0
Locale=2052
CodePage=936
[Version Info Keys]
CompanyName=
FileDescription=
FileVersion=1.0.0.0
InternalName=
LegalCopyright=
LegalTrademarks=
OriginalFilename=
ProductName=
ProductVersion=1.0.0.0
Comments=

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 766 B

View File

@ -0,0 +1,186 @@
inherited frmAttachmentUpload: TfrmAttachmentUpload
Left = 192
Top = 134
BorderIcons = [biSystemMenu, biMinimize]
Caption = #38468#20214#20449#24687
ClientHeight = 463
ClientWidth = 851
Font.Charset = GB2312_CHARSET
Font.Height = -13
Font.Name = #23435#20307
Position = poScreenCenter
OnClose = FormClose
ExplicitWidth = 867
ExplicitHeight = 502
PixelsPerInch = 107
TextHeight = 13
object ListView1: TListView [0]
Left = 43
Top = 22
Width = 465
Height = 83
Columns = <>
TabOrder = 0
OnDblClick = ListView1DblClick
end
object Panel1: TPanel [1]
Left = 687
Top = 0
Width = 164
Height = 463
Align = alRight
TabOrder = 1
object FileName: TcxButton
Left = 33
Top = 63
Width = 81
Height = 27
Hint = 'Filesother'
Caption = #28155#21152
LookAndFeel.Kind = lfOffice11
TabOrder = 0
OnClick = FileNameClick
end
object cxButton1: TcxButton
Left = 33
Top = 104
Width = 81
Height = 27
Hint = 'Filesother'
Caption = #21024#38500
LookAndFeel.Kind = lfOffice11
TabOrder = 1
OnClick = cxButton1Click
end
object cxButton2: TcxButton
Left = 33
Top = 143
Width = 81
Height = 27
Hint = 'Filesother'
Caption = #19979#36733
LookAndFeel.Kind = lfOffice11
TabOrder = 2
OnClick = cxButton2Click
end
object cxButton3: TcxButton
Left = 33
Top = 186
Width = 81
Height = 27
Hint = 'Filesother'
Caption = #20851#38381
LookAndFeel.Kind = lfOffice11
TabOrder = 3
Visible = False
OnClick = cxButton3Click
end
end
object Panel2: TPanel [2]
Left = 191
Top = 152
Width = 209
Height = 44
BevelInner = bvRaised
BevelOuter = bvLowered
Caption = 'Panel2'
Font.Charset = GB2312_CHARSET
Font.Color = clBlue
Font.Height = -13
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
TabOrder = 2
Visible = False
OnDblClick = Panel2DblClick
end
object cxGrid1: TcxGrid [3]
Left = 0
Top = 0
Width = 687
Height = 463
Align = alClient
TabOrder = 3
object Tv1: TcxGridDBTableView
OnDblClick = Tv1DblClick
Navigator.Buttons.CustomButtons = <>
DataController.DataSource = DataSource1
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <>
DataController.Summary.SummaryGroups = <>
OptionsCustomize.ColumnFiltering = False
OptionsData.Deleting = False
OptionsData.Editing = False
OptionsView.GroupByBox = False
OptionsView.Indicator = True
object v1Column1: TcxGridDBColumn
Caption = #25991#20214#21517#31216
DataBinding.FieldName = 'FileName'
HeaderAlignmentHorz = taCenter
Width = 146
end
object v1Column4: TcxGridDBColumn
Caption = #25991#20214#20462#25913#26102#38388
DataBinding.FieldName = 'TFdate'
HeaderAlignmentHorz = taCenter
Width = 140
end
object v1Column2: TcxGridDBColumn
Caption = #25805#20316#21592
DataBinding.FieldName = 'Filler'
HeaderAlignmentHorz = taCenter
Width = 83
end
object v1Column3: TcxGridDBColumn
Caption = #19978#20256#26102#38388
DataBinding.FieldName = 'FillTime'
HeaderAlignmentHorz = taCenter
Width = 140
end
end
object cxGrid1Level1: TcxGridLevel
GridView = Tv1
end
end
inherited ADOQueryBaseCmd: TADOQuery
Left = 113
Top = 64
end
object ADOQueryTmp: TADOQuery
Connection = ADOConnection1
Parameters = <>
Left = 323
Top = 149
end
object ADOQueryCmd: TADOQuery
Connection = ADOConnection1
Parameters = <>
Left = 624
Top = 96
end
object ImageList1: TImageList
Left = 536
Top = 228
end
object IdFTP1: TIdFTP
ConnectTimeout = 0
NATKeepAlive.UseKeepAlive = False
NATKeepAlive.IdleTimeMS = 0
NATKeepAlive.IntervalMS = 0
ProxySettings.ProxyType = fpcmNone
ProxySettings.Port = 0
ReadTimeout = 0
Left = 492
Top = 198
end
object ADOConnection1: TADOConnection
LoginPrompt = False
Left = 380
Top = 272
end
object DataSource1: TDataSource
DataSet = ADOQueryTmp
Left = 548
Top = 140
end
end

View File

@ -0,0 +1,380 @@
unit U_AttachmentUpload;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, ExtCtrls, ComCtrls, Menus, cxLookAndFeelPainters, StdCtrls, cxButtons,
DB, ADODB, ImgList, shellapi, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
cxDataStorage, cxEdit, cxDBData, cxGridCustomTableView, cxGridTableView,
cxGridDBTableView, cxGridLevel, cxClasses, cxControls, cxGridCustomView,
cxGrid, cxLookAndFeels, dxSkinsCore, dxSkinsDefaultPainters, cxNavigator,
dxDateRanges, IdExplicitTLSClientServerBase, System.ImageList, U_BaseHelp;
type
TfrmAttachmentUpload = class(TfrmBaseHelp)
ListView1: TListView;
Panel1: TPanel;
FileName: TcxButton;
cxButton1: TcxButton;
cxButton2: TcxButton;
cxButton3: TcxButton;
ADOQueryTmp: TADOQuery;
ADOQueryCmd: TADOQuery;
ImageList1: TImageList;
Panel2: TPanel;
IdFTP1: TIdFTP;
ADOConnection1: TADOConnection;
Tv1: TcxGridDBTableView;
cxGrid1Level1: TcxGridLevel;
cxGrid1: TcxGrid;
v1Column1: TcxGridDBColumn;
v1Column2: TcxGridDBColumn;
v1Column3: TcxGridDBColumn;
DataSource1: TDataSource;
v1Column4: TcxGridDBColumn;
procedure cxButton3Click(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure FileNameClick(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure ListView1DblClick(Sender: TObject);
procedure cxButton1Click(Sender: TObject);
procedure cxButton2Click(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure Panel2DblClick(Sender: TObject);
procedure Tv1DblClick(Sender: TObject);
private
procedure InitData();
{ Private declarations }
public
fkeyNO: string;
fType: string;
fId: integer;
FEditAuthority: Boolean;
{ Public declarations }
end;
var
frmAttachmentUpload: TfrmAttachmentUpload;
implementation
uses
U_DataLink, U_RTFun, U_CompressionFun;
{$R *.dfm}
procedure TfrmAttachmentUpload.InitData();
var
ListItem: TListItem;
Flag: Cardinal;
info: SHFILEINFOA;
Icon: TIcon;
begin
ListView1.Items.Clear;
try
with adoqueryTmp do
begin
close;
sql.Clear;
sql.Add('select * from FJ_File ');
sql.Add('where WBID=' + quotedstr(trim(fkeyNO)));
sql.Add('and TFType=' + quotedstr(trim(fType)));
open;
end;
except
end;
end;
procedure TfrmAttachmentUpload.cxButton3Click(Sender: TObject);
begin
ADOQueryTmp.Close;
ADOQuerycmd.Close;
ListView1.Items.Free;
ModalResult := -1;
end;
procedure TfrmAttachmentUpload.FormDestroy(Sender: TObject);
begin
frmAttachmentUpload := nil;
end;
procedure TfrmAttachmentUpload.FileNameClick(Sender: TObject);
var
OpenDiaLog: TOpenDialog;
fFileName: string;
fFilePath: string;
maxNo: string;
FJStream: TMemoryStream;
mfileSize: integer;
mCreationTime: TdateTime;
mWriteTime: TdateTime;
begin
try
adoqueryCmd.Connection.BeginTrans;
OpenDiaLog := TOpenDialog.Create(Self);
if OpenDiaLog.Execute then
begin
fFilePath := OpenDiaLog.FileName;
fFileName := ExtractFileName(OpenDiaLog.FileName);
Panel2.Caption := '正在上传数据,请稍等...';
Panel2.Visible := true;
application.ProcessMessages;
if GetLSNo(ADOQueryCmd, maxNo, 'FJ', 'FJ_File', 4, 1) = False then
begin
adoqueryCmd.Connection.RollbackTrans;
Application.MessageBox('取最大号失败!', '提示', 0);
Exit;
end;
//获取文件信息
GetFileInfo(fFilePath, mfileSize, mCreationTime, mWriteTime);
with adoqueryCmd do
begin
close;
sql.Clear;
sql.Add('delete from FJ_File ');
sql.Add('where TFID=' + quotedstr(trim(maxNo)));
execsql;
end;
try
FJStream := TMemoryStream.Create;
with adoqueryCmd do
begin
close;
sql.Clear;
sql.Add('select * from FJ_File ');
sql.Add('where TFID=' + quotedstr(trim(maxNo)));
open;
append;
fieldbyname('TFID').Value := trim(maxNo);
fieldbyname('WBID').Value := trim(fkeyNO);
fieldbyname('TFType').Value := trim(fType);
fieldbyname('Filler').Value := trim(DName);
fieldbyname('FileName').Value := trim(fFileName);
fieldbyname('TFDate').Value := mWriteTime;
FJStream.LoadFromFile(fFilePath);
CompressionStream(FJStream);
tblobfield(FieldByName('Filesother')).LoadFromStream(FJStream);
post;
end;
Panel2.Visible := false;
initdata();
finally
FJStream.Free;
end;
end;
adoqueryCmd.Connection.CommitTrans;
except
adoqueryCmd.Connection.RollbackTrans;
application.MessageBox('附件保存失败!', '提示信息', 0);
end;
end;
procedure TfrmAttachmentUpload.FormCreate(Sender: TObject);
begin
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
application.MessageBox('网络连接失败!', '提示信息');
end;
end;
procedure TfrmAttachmentUpload.FormShow(Sender: TObject);
begin
if FEditAuthority then
Panel1.Visible := true
else
Panel1.Visible := false;
initdata();
end;
procedure TfrmAttachmentUpload.ListView1DblClick(Sender: TObject);
var
sFieldName: string;
fileName: string;
begin
if ListView1.Items.Count < 1 then
EXIT;
if listView1.SelCount < 1 then
exit;
sFieldName := 'D:\附件查看';
if not DirectoryExists(pchar(sFieldName)) then
CreateDirectory(pchar(sFieldName), nil);
fileName := ListView1.Selected.Caption;
sFieldName := sFieldName + '\' + trim(fileName);
try
IdFTP1.Host := PicSvr;
IdFTP1.Username := 'three';
IdFTP1.Password := '641010';
IdFTP1.Connect();
except
;
end;
if IdFTP1.Connected then
begin
Panel2.Caption := '正在下载数据,请稍等...';
Panel2.Visible := true;
application.ProcessMessages;
try
IdFTP1.Get('FJ\' + Trim(fileName), sFieldName, false, true);
except
Panel2.Visible := false;
Application.MessageBox('附件文件不存在', '提示', MB_ICONWARNING);
IdFTP1.Quit;
Exit;
end;
end
else
begin
Panel2.Visible := false;
Application.MessageBox('无法连接文件服务器', '提示', MB_ICONWARNING);
IdFTP1.Quit;
Exit;
end;
Panel2.Visible := false;
if IdFTP1.Connected then
IdFTP1.Quit;
ShellExecute(Handle, 'open', PChar(sFieldName), '', '', SW_SHOWNORMAL);
end;
procedure TfrmAttachmentUpload.cxButton1Click(Sender: TObject);
var
fFileName: string;
fFilePath: string;
begin
if ADOQueryTmp.IsEmpty then
exit;
try
with ADOQueryCmd do
begin
close;
sql.Clear;
sql.Add('delete from FJ_File ');
sql.Add('where TFID=' + quotedstr(trim(ADOQueryTmp.fieldbyname('TFID').AsString)));
execsql;
end;
initData();
except
end;
end;
procedure TfrmAttachmentUpload.cxButton2Click(Sender: TObject);
var
SaveDialog: TSaveDialog;
fFileName: string;
fFilePath: string;
ff: TADOBlobStream;
FJStream: TMemoryStream;
begin
if adoqueryTmp.IsEmpty then
exit;
try
fFileName := adoqueryTmp.fieldbyname('FileName').AsString;
SaveDialog := TSaveDialog.Create(Self);
SaveDialog.FileName := fFileName;
if SaveDialog.Execute then
begin
Panel2.Caption := '正在保存数据,请稍等...';
Panel2.Visible := true;
application.ProcessMessages;
fFilePath := SaveDialog.FileName;
try
ff := TADOBlobstream.Create(adoqueryTmp.fieldByName('FilesOther') as TblobField, bmRead);
FJStream := TMemoryStream.Create;
ff.SaveToStream(FJStream);
UnCompressionStream(FJStream);
FJStream.SaveToFile(fFilePath);
// ShellExecute(Handle, 'open',PChar(sFieldName),'', '', SW_SHOWNORMAL);
finally
FJStream.free;
ff.Free;
end;
Panel2.Visible := false;
// if IdFTP1.Connected then IdFTP1.Quit;
end;
except
Panel2.Visible := false;
end;
end;
procedure TfrmAttachmentUpload.FormClose(Sender: TObject; var Action: TCloseAction);
begin
if fId = 10 then
Action := cafree
else
Action := cahide;
end;
procedure TfrmAttachmentUpload.Panel2DblClick(Sender: TObject);
begin
Panel2.Visible := false;
end;
procedure TfrmAttachmentUpload.Tv1DblClick(Sender: TObject);
var
sFieldName: string;
fileName: string;
ff: TADOBlobStream;
FJStream: TMemoryStream;
begin
if adoqueryTmp.IsEmpty then
exit;
sFieldName := 'D:\附件查看';
if not DirectoryExists(pchar(sFieldName)) then
CreateDirectory(pchar(sFieldName), nil);
fileName := adoqueryTmp.fieldbyname('FileName').AsString;
sFieldName := sFieldName + '\' + trim(fileName);
try
ff := TADOBlobstream.Create(adoqueryTmp.fieldByName('FilesOther') as TblobField, bmRead);
FJStream := TMemoryStream.Create;
ff.SaveToStream(FJStream);
UnCompressionStream(FJStream);
FJStream.SaveToFile(sFieldName);
ShellExecute(Handle, 'open', PChar(sFieldName), '', '', SW_SHOWNORMAL);
finally
FJStream.free;
ff.Free;
end;
end;
end.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,181 @@
unit U_BankSel;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
cxEdit, DB, cxDBData, ToolWin, ComCtrls, U_BaseHelp, cxGridCustomTableView,
cxGridTableView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls,
cxGridCustomView, cxGrid, DBClient, ADODB, ImgList, StdCtrls, ExtCtrls,
cxTextEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels,
cxLookAndFeelPainters, dxSkinsCore, dxSkinsDefaultPainters, cxNavigator,
dxDateRanges, dxBarBuiltInMenu, System.ImageList, U_BaseInput, cxButtonEdit,
cxDropDownEdit;
type
TfrmBankSel = class(TfrmBaseHelp)
ToolBar1: TToolBar;
ADOQueryMain: TADOQuery;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
DS_1: TDataSource;
CDS_1: TClientDataSet;
TBSave: TToolButton;
TBClose: TToolButton;
ToolButton1: TToolButton;
ADOConnection1: TADOConnection;
Panel1: TPanel;
Label1: TLabel;
BankName: TEdit;
GPM_1: TcxGridPopupMenu;
ImageList1: TImageList;
ThreeColorBase: TcxStyleRepository;
SHuangSe: TcxStyle;
SkyBlue: TcxStyle;
Default: TcxStyle;
QHuangSe: TcxStyle;
Red: TcxStyle;
FontBlue: TcxStyle;
TextSHuangSe: TcxStyle;
FonePurple: TcxStyle;
FoneClMaroon: TcxStyle;
FoneRed: TcxStyle;
RowColor: TcxStyle;
handBlack: TcxStyle;
cxBlue: TcxStyle;
SHuangSeCu: TcxStyle;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
v2Column1: TcxGridDBColumn;
Tv1Column3: TcxGridDBColumn;
Tv1Column4: TcxGridDBColumn;
Tv1Column1: TcxGridDBColumn;
Tv1Column5: TcxGridDBColumn;
Tv1Column6: TcxGridDBColumn;
cxGridLevel1: TcxGridLevel;
procedure FormCreate(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormShow(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure TBSaveClick(Sender: TObject);
procedure TV1DblClick(Sender: TObject);
procedure TBCloseClick(Sender: TObject);
procedure BankNameChange(Sender: TObject);
private
procedure InitGrid();
{ Private declarations }
public
FCoType, FAuthority: string;
{ Public declarations }
end;
var
frmBankSel: TfrmBankSel;
implementation
uses
U_DataLink, U_RTFun;
{$R *.dfm}
procedure TfrmBankSel.FormCreate(Sender: TObject);
begin
inherited;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
application.MessageBox('网络连接失败!', '提示信息');
end;
end;
procedure TfrmBankSel.BankNameChange(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmBankSel.FormClose(Sender: TObject; var Action: TCloseAction);
begin
BankName.SetFocus;
Action := cahide;
end;
procedure TfrmBankSel.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Close;
sql.Clear;
sql.Add(' select * from BS_Bank order by SerialNo ');
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmBankSel.FormShow(Sender: TObject);
begin
inherited;
InitGrid();
ReadCxGrid('单位名称' + Trim(FCoType), TV1, '自定义数据');
end;
procedure TfrmBankSel.TBCloseClick(Sender: TObject);
begin
inherited;
Close;
end;
procedure TfrmBankSel.TBSaveClick(Sender: TObject);
begin
WriteCxGrid('单位名称' + Trim(FCoType), TV1, '自定义数据');
end;
procedure TfrmBankSel.ToolButton1Click(Sender: TObject);
begin
BankName.SetFocus;
ModalResult := 1;
end;
procedure TfrmBankSel.TV1DblClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmBankSel.FormDestroy(Sender: TObject);
begin
inherited;
frmBankSel := nil;
end;
end.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,320 @@
unit U_ClothInfoSel;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
cxEdit, DB, cxDBData, ToolWin, ComCtrls, U_BaseHelp, cxGridCustomTableView,
cxGridTableView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls,
cxGridCustomView, cxGrid, DBClient, ADODB, ImgList, StdCtrls, ExtCtrls,
cxTextEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels,
cxLookAndFeelPainters, dxSkinsCore, dxSkinsDefaultPainters, cxNavigator,
dxDateRanges, dxBarBuiltInMenu, System.ImageList, U_BaseInput, cxTL,
cxMaskEdit, cxTLdxBarBuiltInMenu, cxCheckBox, cxInplaceContainer, cxDBTL,
cxTLData, math, dxScrollbarAnnotations;
type
TfrmClothInfoSel = class(TfrmBaseHelp)
ToolBar1: TToolBar;
ADOQueryMain: TADOQuery;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
DS_1: TDataSource;
CDS_1: TClientDataSet;
TBSave: TToolButton;
TBClose: TToolButton;
ToolButton1: TToolButton;
ADOConnection1: TADOConnection;
GPM_1: TcxGridPopupMenu;
ImageList1: TImageList;
cxDBTreeList1: TcxDBTreeList;
cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn;
DS_Tree: TDataSource;
CDS_Tree: TClientDataSet;
ADOQueryTree: TADOQuery;
Panel3: TPanel;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
v1SSel: TcxGridDBColumn;
v1Column12: TcxGridDBColumn;
v1CYNo: TcxGridDBColumn;
v1Column9: TcxGridDBColumn;
Tv1Column11: TcxGridDBColumn;
v1Column3: TcxGridDBColumn;
v1Column1: TcxGridDBColumn;
Tv1Column2: TcxGridDBColumn;
cxGrid1Level1: TcxGridLevel;
Panel7: TPanel;
Panel4: TPanel;
Label14: TLabel;
LBCPAP1: TLabel;
Button1: TButton;
Button2: TButton;
TCBNOR1: TComboBox;
Panel1: TPanel;
Label3: TLabel;
Label4: TLabel;
Label9: TLabel;
Label8: TLabel;
C_Code: TEdit;
C_Name: TEdit;
C_GramWeight: TEdit;
C_Width: TEdit;
ThreeColorBase: TcxStyleRepository;
SHuangSe: TcxStyle;
SkyBlue: TcxStyle;
Default: TcxStyle;
QHuangSe: TcxStyle;
Red: TcxStyle;
FontBlue: TcxStyle;
TextSHuangSe: TcxStyle;
FonePurple: TcxStyle;
FoneClMaroon: TcxStyle;
FoneRed: TcxStyle;
RowColor: TcxStyle;
handBlack: TcxStyle;
cxBlue: TcxStyle;
SHuangSeCu: TcxStyle;
Tv1Column1: TcxGridDBColumn;
Tv1Column3: TcxGridDBColumn;
Tv1Column4: TcxGridDBColumn;
Tv1Column5: TcxGridDBColumn;
Label1: TLabel;
C_KnitGramWeight: TEdit;
Tv1Column6: TcxGridDBColumn;
Tv1Column7: TcxGridDBColumn;
Label2: TLabel;
Filler: TEdit;
Tv1Column8: TcxGridDBColumn;
C_KHName: TEdit;
lbl1: TLabel;
cxgrdbclmnTv1Column9: TcxGridDBColumn;
cxgrdbclmnTv1Column10: TcxGridDBColumn;
lbl2: TLabel;
C_KHCode: TEdit;
procedure FormCreate(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormShow(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure TBSaveClick(Sender: TObject);
procedure TV1DblClick(Sender: TObject);
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure TCBNOR1Change(Sender: TObject);
procedure C_NameChange(Sender: TObject);
procedure TBCloseClick(Sender: TObject);
procedure cxDBTreeList1DblClick(Sender: TObject);
private
CurrentPage, RecordsNumber: Integer;
procedure InitGrid();
procedure InitTree();
{ Private declarations }
public
FCoType: string;
FAuthority: string;
{ Public declarations }
end;
var
frmClothInfoSel: TfrmClothInfoSel;
implementation
uses
U_DataLink, U_RTFun;
{$R *.dfm}
procedure TfrmClothInfoSel.InitTree();
var
i: Integer;
begin
with ADOQueryTree do
begin
Close;
SQL.Clear;
SQL.Add('select * from BS_Cloth_Type');
Open;
end;
SCreateCDS(ADOQueryTree, CDS_Tree);
SInitCDSData(ADOQueryTree, CDS_Tree);
cxDBTreeList1.Items[0].Expand(false);
end;
procedure TfrmClothInfoSel.FormCreate(Sender: TObject);
begin
inherited;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
{if Application.MessageBox('网络连接失败,是否要再次连接?','提示',32+4)=IDYES then
begin
try
with ADOConnection1 do
begin
Connected:=false;
ConnectionString:=DConString;
//ConnectionString:='23242';
Connected:=true;
end;
except
end;
end; }
//frmZDYHelp.Free;
end;
end;
procedure TfrmClothInfoSel.Button1Click(Sender: TObject);
begin
if CurrentPage > 1 then
CurrentPage := CurrentPage - 1;
InitGrid();
end;
procedure TfrmClothInfoSel.Button2Click(Sender: TObject);
begin
if CurrentPage < CDS_1.FieldByName('TotalCount').AsInteger / RecordsNumber then
CurrentPage := CurrentPage + 1;
InitGrid();
end;
procedure TfrmClothInfoSel.cxDBTreeList1DblClick(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmClothInfoSel.C_NameChange(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmClothInfoSel.FormClose(Sender: TObject; var Action: TCloseAction);
begin
C_Code.SetFocus;
Action := cahide;
end;
procedure TfrmClothInfoSel.InitGrid();
var
fwhere, MCIID, Pwhere: string;
begin
if Trim(FAuthority) = '理单业务' then
begin
filler.text := trim(DName);
filler.Enabled := false;
end;
if not CDS_1.IsEmpty then
MCIID := Trim(CDS_1.FieldByName('BCIID').AsString)
else
MCIID := '';
Pwhere := SGetFilters(Panel1, 1, 2);
if trim(Pwhere) <> '' then
begin
if fwhere <> '' then
fwhere := fwhere + ' and ' + trim(Pwhere)
else
fwhere := ' where ' + trim(Pwhere);
end;
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Close;
Filtered := False;
sql.Clear;
sql.Add(' exec P_BS_CloInfo_Get ');
sql.Add(' @CTID=' + quotedstr(Trim(CDS_Tree.fieldbyname('CTID').AsString)));
sql.Add(',@pageIndex=' + inttostr(CurrentPage));
sql.Add(',@pageSize=' + inttostr(RecordsNumber));
sql.Add(',@criteria= ' + quotedstr(fwhere));
// ShowMessage(sql.Text);
Open;
end;
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
TV1.DataController.Filter.Clear;
LBCPAP1.Caption := inttostr(CurrentPage) + '/' + inttostr(ceil(CDS_1.FieldByName('TotalCount').AsInteger / RecordsNumber));
finally
ADOQueryMain.EnableControls;
TV1.DataController.Filter.Clear;
end;
if MCIID <> '' then
CDS_1.Locate('BCIID', MCIID, []);
end;
procedure TfrmClothInfoSel.FormShow(Sender: TObject);
begin
inherited;
RecordsNumber := 500;
CurrentPage := 1;
ReadCxGrid('单位名称' + Trim(FCoType), TV1, '自定义数据');
InitTree();
InitGrid();
end;
procedure TfrmClothInfoSel.TBCloseClick(Sender: TObject);
begin
Close;
end;
procedure TfrmClothInfoSel.TBSaveClick(Sender: TObject);
begin
WriteCxGrid('单位名称' + Trim(FCoType), TV1, '自定义数据');
end;
procedure TfrmClothInfoSel.TCBNOR1Change(Sender: TObject);
begin
RecordsNumber := StrToInt(TCBNOR1.Text);
CurrentPage := 1;
C_Code.SetFocus;
InitGrid();
end;
procedure TfrmClothInfoSel.ToolButton1Click(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmClothInfoSel.TV1DblClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmClothInfoSel.FormDestroy(Sender: TObject);
begin
inherited;
frmClothInfoSel := nil;
end;
end.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,185 @@
unit U_CompanySel;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
cxEdit, DB, cxDBData, ToolWin, ComCtrls, U_BaseHelp, cxGridCustomTableView,
cxGridTableView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls,
cxGridCustomView, cxGrid, DBClient, ADODB, ImgList, StdCtrls, ExtCtrls,
cxTextEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels,
cxLookAndFeelPainters, dxSkinsCore, dxSkinsDefaultPainters, cxNavigator,
dxDateRanges, dxBarBuiltInMenu, System.ImageList, U_BaseInput,
dxScrollbarAnnotations;
type
TfrmCompanySel = class(TfrmBaseHelp)
TV1: TcxGridDBTableView;
cxGrid1Level1: TcxGridLevel;
cxGrid1: TcxGrid;
ToolBar1: TToolBar;
ADOQueryMain: TADOQuery;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
DS_1: TDataSource;
CDS_1: TClientDataSet;
TBSave: TToolButton;
TBClose: TToolButton;
ToolButton1: TToolButton;
ADOConnection1: TADOConnection;
Panel1: TPanel;
Label1: TLabel;
CoName: TEdit;
GPM_1: TcxGridPopupMenu;
ImageList1: TImageList;
TV1Column1: TcxGridDBColumn;
TV1Column2: TcxGridDBColumn;
TV1Column3: TcxGridDBColumn;
ThreeColorBase: TcxStyleRepository;
SHuangSe: TcxStyle;
SkyBlue: TcxStyle;
Default: TcxStyle;
QHuangSe: TcxStyle;
Red: TcxStyle;
FontBlue: TcxStyle;
TextSHuangSe: TcxStyle;
FonePurple: TcxStyle;
FoneClMaroon: TcxStyle;
FoneRed: TcxStyle;
RowColor: TcxStyle;
handBlack: TcxStyle;
cxBlue: TcxStyle;
SHuangSeCu: TcxStyle;
procedure FormCreate(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormShow(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure TBSaveClick(Sender: TObject);
procedure TV1DblClick(Sender: TObject);
procedure TBCloseClick(Sender: TObject);
procedure CoNameChange(Sender: TObject);
private
procedure InitGrid();
{ Private declarations }
public
FCoType, FAuthority: string;
{ Public declarations }
end;
var
frmCompanySel: TfrmCompanySel;
implementation
uses
U_DataLink, U_RTFun;
{$R *.dfm}
procedure TfrmCompanySel.FormCreate(Sender: TObject);
begin
inherited;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
application.MessageBox('网络连接失败!', '提示信息');
end;
end;
procedure TfrmCompanySel.CoNameChange(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmCompanySel.FormClose(Sender: TObject; var Action: TCloseAction);
begin
CoName.SetFocus;
Action := cahide;
end;
procedure TfrmCompanySel.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Close;
sql.Clear;
sql.Add('select A.* from BS_Company A where 1=1 ');
if Trim(FCoType) <> '' then
begin
sql.Add(' and A.CoType=''' + Trim(FCoType) + '''');
end;
if Trim(FAuthority) = '理单业务' then
begin
sql.Add(' and ( SalesId=' + quotedstr(trim(DCode)) + ' or exists (select * from [dbo].[F_Tool_SplitString](TallyId,'','') X where X.RTValue =' + quotedstr(trim(DCode)) + '))');
end;
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmCompanySel.FormShow(Sender: TObject);
begin
inherited;
InitGrid();
ReadCxGrid('单位名称' + Trim(FCoType), TV1, '自定义数据');
end;
procedure TfrmCompanySel.TBCloseClick(Sender: TObject);
begin
inherited;
Close;
end;
procedure TfrmCompanySel.TBSaveClick(Sender: TObject);
begin
WriteCxGrid('单位名称' + Trim(FCoType), TV1, '自定义数据');
end;
procedure TfrmCompanySel.ToolButton1Click(Sender: TObject);
begin
CoName.SetFocus;
ModalResult := 1;
end;
procedure TfrmCompanySel.TV1DblClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmCompanySel.FormDestroy(Sender: TObject);
begin
inherited;
frmCompanySel := nil;
end;
end.

View File

@ -0,0 +1,937 @@
inherited frmEmployeeSel: TfrmEmployeeSel
Left = 342
Top = 13
Caption = #25968#25454#36873#25321
ClientHeight = 637
ClientWidth = 731
Font.Charset = GB2312_CHARSET
Font.Height = -12
Font.Name = #23435#20307
Position = poScreenCenter
OnClose = FormClose
ExplicitWidth = 747
ExplicitHeight = 676
PixelsPerInch = 96
TextHeight = 12
object ScrollBox1: TScrollBox [0]
Left = 0
Top = 0
Width = 731
Height = 637
Align = alClient
TabOrder = 0
object btn1: TSpeedButton
Left = 23
Top = 3
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clBlack
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
OnClick = btn1Click
end
object btn2: TSpeedButton
Left = 111
Top = 3
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn3: TSpeedButton
Left = 199
Top = 3
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn4: TSpeedButton
Left = 287
Top = 3
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn5: TSpeedButton
Left = 375
Top = 3
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn6: TSpeedButton
Left = 463
Top = 3
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn7: TSpeedButton
Left = 551
Top = 3
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn8: TSpeedButton
Left = 639
Top = 3
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn58: TSpeedButton
Left = 23
Top = 81
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn9: TSpeedButton
Left = 111
Top = 81
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn10: TSpeedButton
Left = 199
Top = 81
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn11: TSpeedButton
Left = 287
Top = 81
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn12: TSpeedButton
Left = 375
Top = 81
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn13: TSpeedButton
Left = 463
Top = 81
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn14: TSpeedButton
Left = 551
Top = 81
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn15: TSpeedButton
Left = 639
Top = 81
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn59: TSpeedButton
Left = 23
Top = 158
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn16: TSpeedButton
Left = 111
Top = 158
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn17: TSpeedButton
Left = 199
Top = 158
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn18: TSpeedButton
Left = 287
Top = 158
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn19: TSpeedButton
Left = 375
Top = 158
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn20: TSpeedButton
Left = 463
Top = 158
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn21: TSpeedButton
Left = 551
Top = 158
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn22: TSpeedButton
Left = 639
Top = 158
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn60: TSpeedButton
Left = 23
Top = 236
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn23: TSpeedButton
Left = 111
Top = 236
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn24: TSpeedButton
Left = 199
Top = 236
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn25: TSpeedButton
Left = 287
Top = 236
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn26: TSpeedButton
Left = 375
Top = 236
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn27: TSpeedButton
Left = 463
Top = 236
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn28: TSpeedButton
Left = 551
Top = 236
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn29: TSpeedButton
Left = 639
Top = 236
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn61: TSpeedButton
Left = 23
Top = 314
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn30: TSpeedButton
Left = 111
Top = 314
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn31: TSpeedButton
Left = 199
Top = 314
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn32: TSpeedButton
Left = 287
Top = 314
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn33: TSpeedButton
Left = 375
Top = 314
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn34: TSpeedButton
Left = 463
Top = 314
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn35: TSpeedButton
Left = 551
Top = 314
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn36: TSpeedButton
Left = 639
Top = 314
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn62: TSpeedButton
Left = 23
Top = 392
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn37: TSpeedButton
Left = 111
Top = 392
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn38: TSpeedButton
Left = 199
Top = 392
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn39: TSpeedButton
Left = 287
Top = 392
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn40: TSpeedButton
Left = 375
Top = 392
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn41: TSpeedButton
Left = 463
Top = 392
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn42: TSpeedButton
Left = 551
Top = 392
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn43: TSpeedButton
Left = 639
Top = 392
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn63: TSpeedButton
Left = 23
Top = 469
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn44: TSpeedButton
Left = 111
Top = 469
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn45: TSpeedButton
Left = 199
Top = 469
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn46: TSpeedButton
Left = 287
Top = 469
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn47: TSpeedButton
Left = 375
Top = 469
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn48: TSpeedButton
Left = 463
Top = 469
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn49: TSpeedButton
Left = 551
Top = 469
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn50: TSpeedButton
Left = 639
Top = 469
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn64: TSpeedButton
Left = 23
Top = 547
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn51: TSpeedButton
Left = 111
Top = 547
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn52: TSpeedButton
Left = 199
Top = 547
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn53: TSpeedButton
Left = 287
Top = 547
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn54: TSpeedButton
Left = 375
Top = 547
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn55: TSpeedButton
Left = 463
Top = 547
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn56: TSpeedButton
Left = 551
Top = 547
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
object btn57: TSpeedButton
Left = 639
Top = 547
Width = 70
Height = 70
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -21
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
Visible = False
OnClick = btn1Click
end
end
inherited ADOQueryBaseCmd: TADOQuery
Connection = ADOConnection1
end
inherited ADOQueryBaseTemp: TADOQuery
Connection = ADOConnection1
end
object ADOTmp: TADOQuery
Connection = ADOConnection1
LockType = ltReadOnly
Parameters = <>
Left = 120
Top = 176
end
object ADOConnection1: TADOConnection
LoginPrompt = False
Left = 296
Top = 192
end
end

View File

@ -0,0 +1,218 @@
unit U_EmployeeSel;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, Buttons, DB, ADODB, U_BaseHelp, System.ImageList, Vcl.ImgList;
type
TfrmEmployeeSel = class(TfrmBaseHelp)
ScrollBox1: TScrollBox;
btn1: TSpeedButton;
btn2: TSpeedButton;
btn3: TSpeedButton;
btn4: TSpeedButton;
btn5: TSpeedButton;
btn6: TSpeedButton;
btn7: TSpeedButton;
btn8: TSpeedButton;
btn58: TSpeedButton;
btn9: TSpeedButton;
btn10: TSpeedButton;
btn11: TSpeedButton;
btn12: TSpeedButton;
btn13: TSpeedButton;
btn14: TSpeedButton;
btn15: TSpeedButton;
btn59: TSpeedButton;
btn16: TSpeedButton;
btn17: TSpeedButton;
btn18: TSpeedButton;
btn19: TSpeedButton;
btn20: TSpeedButton;
btn21: TSpeedButton;
btn22: TSpeedButton;
btn60: TSpeedButton;
btn23: TSpeedButton;
btn24: TSpeedButton;
btn25: TSpeedButton;
btn26: TSpeedButton;
btn27: TSpeedButton;
btn28: TSpeedButton;
btn29: TSpeedButton;
btn61: TSpeedButton;
btn30: TSpeedButton;
btn31: TSpeedButton;
btn32: TSpeedButton;
btn33: TSpeedButton;
btn34: TSpeedButton;
btn35: TSpeedButton;
btn36: TSpeedButton;
btn62: TSpeedButton;
btn37: TSpeedButton;
btn38: TSpeedButton;
btn39: TSpeedButton;
btn40: TSpeedButton;
btn41: TSpeedButton;
btn42: TSpeedButton;
btn43: TSpeedButton;
btn63: TSpeedButton;
btn44: TSpeedButton;
btn45: TSpeedButton;
btn46: TSpeedButton;
btn47: TSpeedButton;
btn48: TSpeedButton;
btn49: TSpeedButton;
btn50: TSpeedButton;
btn64: TSpeedButton;
btn51: TSpeedButton;
btn52: TSpeedButton;
btn53: TSpeedButton;
btn54: TSpeedButton;
btn55: TSpeedButton;
btn56: TSpeedButton;
btn57: TSpeedButton;
ADOTmp: TADOQuery;
ADOConnection1: TADOConnection;
procedure FormDestroy(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure btn1Click(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormCreate(Sender: TObject);
private
procedure InitEmployee();
{ Private declarations }
public
FRCode, FRName, FPost: string;
{ Public declarations }
end;
var
frmEmployeeSel: TfrmEmployeeSel;
implementation
uses
U_DataLink;
{$R *.dfm}
procedure TfrmEmployeeSel.FormDestroy(Sender: TObject);
begin
inherited;
frmEmployeeSel := nil;
end;
procedure TfrmEmployeeSel.InitEmployee();
type
FdDy = record
inc: integer;
FCode: string[32];
FName: string[32];
end;
var
BB: array[0..100] of FdDy;
i, j: Integer;
begin
with ADOTmp do
begin
Close;
sql.Clear;
sql.Add('select EECode,EEName from SY_Employee where Post=''' + Trim(FPost) + ''' ');
SQL.Add('order by EECode,EEName ');
Open;
end;
if ADOTmp.IsEmpty then
begin
Application.MessageBox('没有定义数据!', '提示', 0);
Exit;
end;
with ADOTmp do
begin
First;
i := 0;
while not Eof do
begin
BB[i].inc := i;
BB[i].FCode := Trim(fieldbyname('EECode').AsString);
BB[i].FName := Trim(fieldbyname('EEName').AsString);
i := i + 1;
Next;
end;
end;
i := i - 1;
if i > 63 then
begin
i := 63;
end;
for j := 0 to i do
begin
with ScrollBox1 do
begin
TSpeedButton(Controls[j]).Visible := True;
TSpeedButton(Controls[j]).Hint := BB[j].FCode;
TSpeedButton(Controls[j]).Caption := BB[j].FName;
{TSpeedButton(Controls[j]).Hint:=BB[j];
if Length(BB[j])>4 then
begin
TSpeedButton(Controls[j]).Caption:=Copy(Trim(BB[j]),1,4)+#13+Copy(Trim(BB[j]),5,Length(BB[j])-4);
end else
TSpeedButton(Controls[j]).Caption:=BB[j]; }
end;
end;
end;
procedure TfrmEmployeeSel.FormShow(Sender: TObject);
begin
inherited;
InitEmployee();
end;
procedure TfrmEmployeeSel.btn1Click(Sender: TObject);
begin
FRCode := Trim(TSpeedButton(Sender).Hint);
FRName := Trim(TSpeedButton(Sender).Caption);
ModalResult := 1;
end;
procedure TfrmEmployeeSel.FormClose(Sender: TObject; var Action: TCloseAction);
begin
inherited;
// Action:=caHide;
end;
procedure TfrmEmployeeSel.FormCreate(Sender: TObject);
begin
inherited;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
{if Application.MessageBox('网络连接失败,是否要再次连接?','提示',32+4)=IDYES then
begin
try
with ADOConnection1 do
begin
Connected:=false;
ConnectionString:=DConString;
//ConnectionString:='23242';
Connected:=true;
end;
except
end;
end; }
end;
end;
end.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,337 @@
unit U_LabelMapSet;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls,
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
cxTextEdit, cxPC, cxCheckComboBox, cxDropDownEdit, Menus, RM_e_Xls,
cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxSkinsCore,
dxSkinsDefaultPainters, dxDateRanges, dxBarBuiltInMenu, System.ImageList,
Vcl.ImgList, U_BaseHelp;
type
TfrmLabelMapSet = class(Tform)
ToolBar1: TToolBar;
TBRafresh: TToolButton;
TBClose: TToolButton;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
ToolButton2: TToolButton;
ADOQueryMain: TADOQuery;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
cxGridLevel1: TcxGridLevel;
cxGridPopupMenu2: TcxGridPopupMenu;
DS_1: TDataSource;
CDS_1: TClientDataSet;
Panel1: TPanel;
LMName: TEdit;
v2Column8: TcxGridDBColumn;
Label1: TLabel;
v2Column12: TcxGridDBColumn;
ToolButton4: TToolButton;
ToolButton5: TToolButton;
Label2: TLabel;
LMType: TEdit;
v2Column1: TcxGridDBColumn;
Tv1Column1: TcxGridDBColumn;
ToolButton1: TToolButton;
Tv1Column2: TcxGridDBColumn;
ADOConnection1: TADOConnection;
ImageList1: TImageList;
cxGrid2: TcxGrid;
TV2: TcxGridDBTableView;
cxGridLevel2: TcxGridLevel;
DS_2: TDataSource;
ToolBar2: TToolBar;
ToolButton12: TToolButton;
ToolButton6: TToolButton;
ToolButton7: TToolButton;
ToolButton3: TToolButton;
ADO_2: TADOQuery;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure TBRafreshClick(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
procedure cxTabControl1Change(Sender: TObject);
procedure CustomerChange(Sender: TObject);
procedure v2Column8PropertiesEditValueChanged(Sender: TObject);
procedure ToolButton4Click(Sender: TObject);
procedure ToolButton5Click(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure ToolButton12Click(Sender: TObject);
procedure ToolButton6Click(Sender: TObject);
procedure ToolButton7Click(Sender: TObject);
procedure ToolButton3Click(Sender: TObject);
private
{ Private declarations }
procedure InitGrid();
procedure Getfields(MSql: Integer);
public
FLMType: string;
FFiltration1, FFiltration2, FFiltration3: string;
{ Public declarations }
end;
var
frmLabelMapSet: TfrmLabelMapSet;
implementation
uses
U_DataLink, U_RTFun, U_ZDYHelp;
{$R *.dfm}
procedure TfrmLabelMapSet.Getfields(MSql: Integer);
begin
case MSql of
1:
begin
if trim(CDS_1.fieldbyname('LMSql1').AsString) <> '' then
begin
with ADO_2 do
begin
Close;
sql.Clear;
sql.add('exec ' + trim(CDS_1.fieldbyname('LMSql1').AsString) + ' @Filtration=' + quotedstr(Trim(FFiltration1)));
Open;
end;
end;
TV2.ClearItems; //清空数据
(TV2.DataController as IcxCustomGridDataController).DeleteAllItems; //删除所有列
(TV2.DataController as IcxCustomGridDataController).CreateAllItems(false); //创建数据源中的所有列
TV2.ApplyBestFit; //让列宽自适应 .BestFitMaxWidth;
end;
2:
begin
if trim(CDS_1.fieldbyname('LMSql2').AsString) <> '' then
begin
with ADO_2 do
begin
Close;
sql.Clear;
sql.add('exec ' + trim(CDS_1.fieldbyname('LMSql2').AsString) + ' @Filtration=' + quotedstr(Trim(FFiltration2)));
Open;
end;
end;
TV2.ClearItems; //清空数据
(TV2.DataController as IcxCustomGridDataController).DeleteAllItems; //删除所有列
(TV2.DataController as IcxCustomGridDataController).CreateAllItems(False); //创建数据源中的所有列
TV2.ApplyBestFit; //让列宽自适应 .BestFitMaxWidth;
end;
3:
begin
if trim(CDS_1.fieldbyname('LMSql3').AsString) <> '' then
begin
with ADO_2 do
begin
Close;
sql.Clear;
sql.add('exec ' + trim(CDS_1.fieldbyname('LMSql3').AsString) + ' @Filtration=' + quotedstr(Trim(FFiltration3)));
Open;
end;
end;
TV2.ClearItems; //清空数据
(TV2.DataController as IcxCustomGridDataController).DeleteAllItems; //删除所有列
(TV2.DataController as IcxCustomGridDataController).CreateAllItems(false); //创建数据源中的所有列
TV2.ApplyBestFit; //让列宽自适应 .BestFitMaxWidth;
end;
end;
end;
procedure TfrmLabelMapSet.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Close;
SQL.Clear;
sql.Add(' select A.* from BS_Label_Map A ');
sql.Add(' where LMType=' + quotedstr(FLMType));
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
finally
ADOQueryMain.EnableControls;
ToolButton2.Click;
end;
end;
procedure TfrmLabelMapSet.FormDestroy(Sender: TObject);
begin
frmLabelMapSet := nil;
end;
procedure TfrmLabelMapSet.FormClose(Sender: TObject; var Action: TCloseAction);
begin
Action := caFree;
end;
procedure TfrmLabelMapSet.FormCreate(Sender: TObject);
begin
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
// ADOQueryBaseCmd.Connection := ADOConnection1;
// ADOQueryBaseTemp.Connection := ADOConnection1;
except
end;
end;
procedure TfrmLabelMapSet.TBCloseClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmLabelMapSet.FormShow(Sender: TObject);
begin
ReadCxGrid(Trim(Self.Caption), Tv1, '标签管理');
InitGrid();
end;
procedure TfrmLabelMapSet.TBRafreshClick(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmLabelMapSet.ToolButton12Click(Sender: TObject);
begin
Getfields(1);
end;
procedure TfrmLabelMapSet.ToolButton1Click(Sender: TObject);
begin
WriteCxGrid(Trim(Self.Caption), Tv1, '标签管理');
end;
procedure TfrmLabelMapSet.ToolButton2Click(Sender: TObject);
var
sql: string;
begin
if ADOQueryMain.Active then
begin
sql := SGetFilters(Panel1, 1, 2);
SDofilter(ADOQueryMain, sql);
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmLabelMapSet.ToolButton3Click(Sender: TObject);
begin
TcxGridToExcel('sql字段', cxgrid2);
end;
procedure TfrmLabelMapSet.cxTabControl1Change(Sender: TObject);
begin
InitGrid;
end;
procedure TfrmLabelMapSet.CustomerChange(Sender: TObject);
begin
ToolButton2.Click;
end;
procedure TfrmLabelMapSet.v2Column8PropertiesEditValueChanged(Sender: TObject);
var
mvalue, FFieldName: string;
begin
mvalue := TcxTextEdit(Sender).EditingText;
FFieldName := Trim(Tv1.Controller.FocusedColumn.DataBinding.FilterFieldName);
try
ADOQueryCmd.Connection.BeginTrans;
with CDS_1 do
begin
Edit;
FieldByName(FFieldName).Value := Trim(mvalue);
Post;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('UPdate BS_Label_Map ');
sql.Add(' Set ' + FFieldName + '=''' + Trim(mvalue) + '''');
sql.Add(' , Editer=''' + Trim(DName) + '''');
sql.Add(' , Edittime=getdate()');
sql.Add(' where LMID=' + quotedstr(CDS_1.fieldbyname('LMID').AsString));
ExecSQL;
end;
ADOQueryCmd.Connection.CommitTrans;
tv1.Controller.EditingController.ShowEdit();
except
tv1.Controller.EditingController.ShowEdit();
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('保存失败!', '提示', 0);
end
end;
procedure TfrmLabelMapSet.ToolButton4Click(Sender: TObject);
begin
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('insert into BS_Label_Map(LMType,Filler) values(' + quotedstr(Trim(FLMType)) + ',' + quotedstr(Trim(dname)) + ')');
ExecSQL;
end;
InitGrid();
end;
procedure TfrmLabelMapSet.ToolButton5Click(Sender: TObject);
begin
if CDS_1.IsEmpty then
Exit;
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
Exit;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('delete BS_Label_Map where LMID=' + QuotedStr(CDS_1.FieldByName('LMID').AsString));
ExecSQL;
end;
CDS_1.Delete;
end;
procedure TfrmLabelMapSet.ToolButton6Click(Sender: TObject);
begin
Getfields(2);
end;
procedure TfrmLabelMapSet.ToolButton7Click(Sender: TObject);
begin
Getfields(3);
end;
end.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,272 @@
unit U_LabelPrint;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
cxEdit, DB, cxDBData, ToolWin, ComCtrls, U_BaseHelp, cxGridCustomTableView,
cxGridTableView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls,
cxGridCustomView, cxGrid, DBClient, ADODB, ImgList, StdCtrls, ExtCtrls,
cxTextEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels,
cxLookAndFeelPainters, dxSkinsCore, dxSkinsDefaultPainters, cxNavigator,
dxDateRanges, dxBarBuiltInMenu, System.ImageList, U_BaseInput, RM_Common,
RM_Class, RM_GridReport, RM_Dataset, Vcl.Buttons, RM_E_llPDF, RM_BarCode,
RM_e_Graphic, RM_e_Jpeg, RM_e_Xls, cxContainer, cxMaskEdit, cxDropDownEdit,
cxMRUEdit;
type
TfrmLabelPrint = class(TfrmBaseHelp)
ADOQueryTemp: TADOQuery;
ADOConnection1: TADOConnection;
Panel1: TPanel;
ImageList1: TImageList;
RMDB_1: TRMDBDataSet;
RM1: TRMGridReport;
RMDB_2: TRMDBDataSet;
CDS_Label: TClientDataSet;
ADO_1: TADOQuery;
btnPrint: TSpeedButton;
btnShow: TSpeedButton;
ADO_2: TADOQuery;
RMDB_3: TRMDBDataSet;
ADO_3: TADOQuery;
RMXLSExport1: TRMXLSExport;
RMJPEGExport1: TRMJPEGExport;
RMBarCodeObject1: TRMBarCodeObject;
RMllPDFExport1: TRMllPDFExport;
CheckBox1: TCheckBox;
ComboBox1: TComboBox;
Label1: TLabel;
cbbLab: TcxMRUEdit;
CheckBox2: TCheckBox;
procedure FormCreate(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormShow(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure TV1DblClick(Sender: TObject);
procedure btnPrintClick(Sender: TObject);
procedure btnShowClick(Sender: TObject);
procedure cbbLabPropertiesButtonClick(Sender: TObject);
private
procedure InitGrid();
procedure PrintLabel(MIsShow: Boolean);
{ Private declarations }
public
FPreviewPrint: Boolean;
FLMType: string; //标签类型
FFiltration1, FFiltration2, FFiltration3: string;
{ Public declarations }
end;
var
frmLabelPrint: TfrmLabelPrint;
implementation
uses
U_DataLink, U_RTFun, U_LabelMapSet;
{$R *.dfm}
procedure TfrmLabelPrint.PrintLabel(MIsShow: Boolean);
var
fPrintFile, fPrintFile10, FMainID, LBName: string;
begin
if CDS_Label.IsEmpty then
begin
Application.MessageBox(PChar('类型' + FLMType + '没有设置标签!'), '提示', 0);
Exit;
end;
RMllPDFExport1.ShowDialog := CheckBox2.Checked;
RMJPEGExport1.ShowDialog := CheckBox2.Checked;
RMXLSExport1.ShowDialog := CheckBox2.Checked;
RM1.ShowPrintDialog := CheckBox1.Checked;
LBName := cbbLab.text;
ExportFtErpFile(LBName + '.rmf', ADOQueryTemp);
if CDS_Label.Locate('LMName', LBName, []) then
begin
if trim(CDS_Label.fieldbyname('LMSql1').AsString) <> '' then
begin
with ADO_1 do
begin
Close;
sql.Clear;
sql.add('exec ' + trim(CDS_Label.fieldbyname('LMSql1').AsString) + ' @Filtration=' + quotedstr(Trim(FFiltration1)));
// ShowMessage(sql.text);
Open;
end;
end;
if trim(CDS_Label.fieldbyname('LMSql2').AsString) <> '' then
begin
with ADO_2 do
begin
Close;
sql.Clear;
sql.add('exec ' + trim(CDS_Label.fieldbyname('LMSql2').AsString) + ' @Filtration=' + quotedstr(Trim(FFiltration2)));
Open;
end;
end;
if trim(CDS_Label.fieldbyname('LMSql3').AsString) <> '' then
begin
with ADO_3 do
begin
Close;
sql.Clear;
sql.add('exec ' + trim(CDS_Label.fieldbyname('LMSql3').AsString) + ' @Filtration=' + quotedstr(Trim(FFiltration3)));
Open;
end;
end;
end;
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\' + LBName + '.rmf';
if FileExists(fPrintFile) then
begin
RM1.LoadFromFile(fPrintFile);
RM1.DefaultCopies := StrToIntDef(ComboBox1.Text, 1);
if MIsShow then
RM1.ShowReport
else
RM1.PrintReport;
end
else
begin
Application.MessageBox(PChar('没有找' + fPrintFile), '提示', 0);
end;
end;
procedure TfrmLabelPrint.FormCreate(Sender: TObject);
begin
inherited;
FPreviewPrint := True;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
{if Application.MessageBox('网络连接失败,是否要再次连接?','提示',32+4)=IDYES then
begin
try
with ADOConnection1 do
begin
Connected:=false;
ConnectionString:=DConString;
//ConnectionString:='23242';
Connected:=true;
end;
except
end;
end; }
end;
end;
procedure TfrmLabelPrint.btnPrintClick(Sender: TObject);
begin
PrintLabel(False);
ModalResult := 1;
end;
procedure TfrmLabelPrint.btnShowClick(Sender: TObject);
begin
PrintLabel(true);
end;
procedure TfrmLabelPrint.cbbLabPropertiesButtonClick(Sender: TObject);
begin
try
frmLabelMapSet := TfrmLabelMapSet.Create(Application);
with frmLabelMapSet do
begin
FFiltration1 := self.FFiltration1;
FFiltration2 := self.FFiltration2;
FFiltration3 := self.FFiltration3;
FLMType := self.FLMType;
if ShowModal = 1 then
begin
Self.InitGrid();
end;
end;
finally
frmLabelMapSet.Free;
end;
end;
procedure TfrmLabelPrint.FormClose(Sender: TObject; var Action: TCloseAction);
begin
inherited;
Action := cahide;
end;
procedure TfrmLabelPrint.InitGrid();
begin
with ADOQueryTemp do
begin
close;
sql.Clear;
sql.Add('select distinct(LMName) name from BS_Label_Map where LMType=' + QuotedStr(TRIM(FLMType)));
Open;
if isEmpty then
begin
exit;
end;
cbbLab.Properties.LookupItems.Clear;
while not Eof do
begin
cbbLab.Properties.LookupItems.Add(Trim(fieldByName('Name').AsString));
Next;
end;
cbbLab.ItemIndex := 0;
end;
with ADOQueryTemp do
begin
Filtered := False;
Close;
sql.Clear;
Sql.Add('select * from BS_Label_Map where LMType=' + QuotedStr(TRIM(FLMType)));
Open;
end;
SCreateCDS(ADOQueryTemp, CDS_Label);
SInitCDSData(ADOQueryTemp, CDS_Label);
if CDS_Label.IsEmpty then
begin
Application.MessageBox(PChar('类型' + FLMType + '没有设置标签!'), '提示', 0);
Exit;
end;
end;
procedure TfrmLabelPrint.FormShow(Sender: TObject);
begin
inherited;
if FPreviewPrint then
RM1.PreviewButtons := [rmpbZoom, rmpbLoad, rmpbSave, rmpbPrint, rmpbFind, rmpbPageSetup, rmpbExit, rmpbSaveToXLS, rmpbExport, rmpbNavigator]
else
RM1.PreviewButtons := [rmpbZoom, rmpbLoad, rmpbSave, rmpbFind, rmpbPageSetup, rmpbExit, rmpbSaveToXLS, rmpbExport, rmpbNavigator];
InitGrid();
end;
procedure TfrmLabelPrint.TV1DblClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmLabelPrint.FormDestroy(Sender: TObject);
begin
inherited;
frmLabelPrint := nil;
end;
end.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,229 @@
unit U_PictureList;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
cxEdit, DB, cxDBData, ToolWin, ComCtrls, U_BaseHelp, cxGridCustomTableView,
cxGridTableView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls,
cxGridCustomView, cxGrid, DBClient, ADODB, ImgList, StdCtrls, ExtCtrls,
cxTextEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels,
cxLookAndFeelPainters, dxSkinsCore, dxSkinsDefaultPainters, cxNavigator,
dxDateRanges, dxBarBuiltInMenu, System.ImageList, U_BaseInput, IdBaseComponent,
IdComponent, IdTCPConnection, IdTCPClient, IdExplicitTLSClientServerBase,
IdFTP, Winapi.UrlMon, Winapi.ShellAPI;
type
TfrmPictureList = class(TfrmBaseHelp)
ToolBar1: TToolBar;
ADOQueryMain: TADOQuery;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
DS_1: TDataSource;
CDS_1: TClientDataSet;
TBSave: TToolButton;
TBClose: TToolButton;
ToolButton1: TToolButton;
ADOConnection1: TADOConnection;
Panel1: TPanel;
Label1: TLabel;
CoName: TEdit;
GPM_1: TcxGridPopupMenu;
ImageList1: TImageList;
ThreeColorBase: TcxStyleRepository;
SHuangSe: TcxStyle;
SkyBlue: TcxStyle;
Default: TcxStyle;
QHuangSe: TcxStyle;
Red: TcxStyle;
FontBlue: TcxStyle;
TextSHuangSe: TcxStyle;
FonePurple: TcxStyle;
FoneClMaroon: TcxStyle;
FoneRed: TcxStyle;
RowColor: TcxStyle;
handBlack: TcxStyle;
cxBlue: TcxStyle;
SHuangSeCu: TcxStyle;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
v1Column1: TcxGridDBColumn;
v1Column4: TcxGridDBColumn;
v1Column3: TcxGridDBColumn;
v1Column2: TcxGridDBColumn;
cxGrid1Level1: TcxGridLevel;
ToolButton2: TToolButton;
IdFTP1: TIdFTP;
procedure FormCreate(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormShow(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure TBSaveClick(Sender: TObject);
procedure TV1DblClick(Sender: TObject);
procedure TBCloseClick(Sender: TObject);
procedure CoNameChange(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
procedure Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
private
procedure InitGrid();
{ Private declarations }
public
FWBID: string;
{ Public declarations }
end;
var
frmPictureList: TfrmPictureList;
implementation
uses
U_DataLink, U_RTFun, U_CompanySel;
{$R *.dfm}
procedure TfrmPictureList.FormCreate(Sender: TObject);
begin
inherited;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
application.MessageBox('网络连接失败!', '提示信息');
end;
end;
procedure TfrmPictureList.CoNameChange(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmPictureList.FormClose(Sender: TObject; var Action: TCloseAction);
begin
CoName.SetFocus;
Action := cahide;
end;
procedure TfrmPictureList.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Close;
sql.Clear;
sql.Add('select * from TP_File A');
sql.Add('where isnull(WBID,'''')<>'''' and WBID=' + quotedstr(Trim(FWBID)));
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmPictureList.FormShow(Sender: TObject);
begin
inherited;
InitGrid();
ReadCxGrid('图片列表', TV1, '自定义数据');
end;
procedure TfrmPictureList.TBCloseClick(Sender: TObject);
begin
inherited;
Close;
end;
procedure TfrmPictureList.TBSaveClick(Sender: TObject);
begin
WriteCxGrid('图片列表', TV1, '自定义数据');
end;
procedure TfrmPictureList.ToolButton1Click(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmPictureList.ToolButton2Click(Sender: TObject);
var
IdFTP1: TIdFTP;
FPath, FFName, fPdfFilePath, fPdfFilePath1: string;
FInt: integer;
begin
if CDS_1.IsEmpty then
Exit;
fPdfFilePath := ExtractFilePath(Application.ExeName) + '\Picture';
if not DirectoryExists(PChar(fPdfFilePath)) then
CreateDirectory(pchar(fPdfFilePath), nil);
fPdfFilePath := fPdfFilePath + '\' + FWBID;
if not DirectoryExists(pchar(fPdfFilePath)) then
CreateDirectory(pchar(fPdfFilePath), nil);
with ADOQueryTemp do
begin
close;
sql.Clear;
sql.Add('select * from TP_File A');
sql.Add('where isnull(WBID,'''')<>'''' and WBID=' + quotedstr(Trim(FWBID)));
open;
end;
ADOQueryTemp.First;
while not ADOQueryTemp.Eof do
begin
if Trim(ADOQueryTemp.FieldByName('URL').AsString) <> '' then
begin
fPdfFilePath1 := fPdfFilePath + '\' + trim(Trim(ADOQueryTemp.FieldByName('FileName').AsString));
UrlDownloadToFile(nil, PChar(Trim(ADOQueryTemp.FieldByName('URL').AsString)), PChar(fPdfFilePath1), 0, nil);
end;
ADOQueryTemp.Next;
end;
ShellExecute(Handle, 'open', PChar(fPdfFilePath + '\' + trim(CDS_1.FieldByName('FileName').AsString)), '', '', SW_SHOWNORMAL);
end;
procedure TfrmPictureList.Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
begin
ToolButton2.Click;
end;
procedure TfrmPictureList.TV1DblClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmPictureList.FormDestroy(Sender: TObject);
begin
inherited;
frmPictureList := nil;
end;
end.

View File

@ -0,0 +1,165 @@
object frmPictureUpload: TfrmPictureUpload
Left = 697
Top = 183
BorderIcons = [biSystemMenu]
BorderStyle = bsSingle
Caption = #33719#21462#22270#29255
ClientHeight = 449
ClientWidth = 496
Color = clWhite
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
OldCreateOrder = False
Position = poDesktopCenter
OnCreate = FormCreate
OnDestroy = FormDestroy
OnShow = FormShow
PixelsPerInch = 96
TextHeight = 12
object Image2: TImage
Left = 464
Top = 8
Width = 160
Height = 120
end
object SpeedButton3: TSpeedButton
Left = 500
Top = 426
Width = 80
Height = 22
Caption = #25918#24323
end
object ScrollBox1: TScrollBox
Left = 0
Top = 38
Width = 496
Height = 411
HorzScrollBar.Visible = False
VertScrollBar.Visible = False
Align = alClient
TabOrder = 0
ExplicitLeft = 5
ExplicitTop = 5
ExplicitWidth = 300
ExplicitHeight = 400
object Image1: TImage
Left = 0
Top = 0
Width = 492
Height = 407
Cursor = crSizeAll
Align = alClient
Center = True
IncrementalDisplay = True
Stretch = True
OnMouseDown = Image1MouseDown
OnMouseMove = Image1MouseMove
ExplicitLeft = -2
ExplicitTop = 3
ExplicitWidth = 275
ExplicitHeight = 436
end
end
object ToolBar1: TToolBar
Tag = 1
Left = 0
Top = 0
Width = 496
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 103
Caption = 'ToolBar1'
Color = clWhite
DisabledImages = DataLink_Contract.ImageList_new32
Images = DataLink_Contract.ImageList_new32
List = True
ParentColor = False
ShowCaptions = True
TabOrder = 1
ExplicitWidth = 509
object ToolButton1: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #25171#24320#22270#29255
ImageIndex = 23
OnClick = ToolButton1Click
end
object TBSave: TToolButton
Left = 95
Top = 0
AutoSize = True
Caption = #20445#23384
Enabled = False
ImageIndex = 16
OnClick = TBSaveClick
end
object ToolButton3: TToolButton
Left = 166
Top = 0
AutoSize = True
Caption = #22270#29255#21478#23384#20026
ImageIndex = 13
OnClick = ToolButton3Click
end
object ToolButton2: TToolButton
Left = 273
Top = 0
AutoSize = True
Caption = #21024#38500
ImageIndex = 14
OnClick = ToolButton2Click
end
object ToolButton4: TToolButton
Left = 344
Top = 0
AutoSize = True
Caption = #25918#24323
ImageIndex = 10
OnClick = ToolButton4Click
end
object TBClose: TToolButton
Left = 415
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object OpenPictureDialog1: TOpenPictureDialog
Left = 112
Top = 128
end
object ADOQuery1: TADOQuery
Connection = DataLink_Contract.ADOLink
Parameters = <>
Left = 224
Top = 264
end
object SaveDialog1: TSavePictureDialog
Left = 96
Top = 235
end
object adoqueryImage: TADOQuery
Connection = DataLink_Contract.ADOLink
Parameters = <>
Left = 224
Top = 184
end
object IdFTP1: TIdFTP
ConnectTimeout = 0
NATKeepAlive.UseKeepAlive = False
NATKeepAlive.IdleTimeMS = 0
NATKeepAlive.IntervalMS = 0
ProxySettings.ProxyType = fpcmNone
ProxySettings.Port = 0
ReadTimeout = 0
Left = 244
Top = 118
end
end

View File

@ -0,0 +1,536 @@
unit U_PictureUpload;
interface
uses
Windows, Messages, SysUtils, strUtils, Variants, Classes, Graphics, Controls,
Forms, Dialogs, ComCtrls, ToolWin, ExtCtrls, jpeg, IniFiles, ExtDlgs, Buttons,
StdCtrls, DB, ADODB, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, IdExplicitTLSClientServerBase;
type
TfrmPictureUpload = class(TForm)
ScrollBox1: TScrollBox;
Image1: TImage;
OpenPictureDialog1: TOpenPictureDialog;
Image2: TImage;
SpeedButton3: TSpeedButton;
ADOQuery1: TADOQuery;
SaveDialog1: TSavePictureDialog;
adoqueryImage: TADOQuery;
IdFTP1: TIdFTP;
ToolBar1: TToolBar;
TBSave: TToolButton;
TBClose: TToolButton;
ToolButton1: TToolButton;
ToolButton2: TToolButton;
ToolButton3: TToolButton;
ToolButton4: TToolButton;
procedure ToolButton1Click(Sender: TObject);
procedure ToolButton3Click(Sender: TObject);
procedure TwainTwainAcquire(Sender: TObject; const Index: Integer; Image: TBitmap; var Cancel: Boolean);
procedure FormShow(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure Image1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
procedure Image1MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
procedure Initimage();
procedure TBCloseClick(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
procedure TBSaveClick(Sender: TObject);
procedure ToolButton4Click(Sender: TObject);
private
hWndC: THandle;
CapturingAVI: bool;
ClickPos: TPoint;
SelectedSource, PicLeft, PicTop, PicWidth, PicHeight: Integer;
FilePath, FileName: string;
MyJpeg: TJPEGImage;
procedure CreThumb(Width, Height: Integer);
function SaveImage(): Boolean;
procedure Rotate90(Source: TGraphic; Target: TJpegImage);
public
FTFType, fFlileFlag: string;
FWidth, FHeight: Integer;
FPictureName, FDataId: string;
{ Public declarations }
end;
var
frmPictureUpload: TfrmPictureUpload;
implementation
uses
U_DataLink, U_RTFun;
const
WM_CAP_START = WM_USER;
const
WM_CAP_STOP = WM_CAP_START + 68;
const
WM_CAP_DRIVER_CONNECT = WM_CAP_START + 10;
const
WM_CAP_DRIVER_DISCONNECT = WM_CAP_START + 11;
const
WM_CAP_SAVEDIB = WM_CAP_START + 25;
const
WM_CAP_GRAB_FRAME = WM_CAP_START + 60;
const
WM_CAP_SEQUENCE = WM_CAP_START + 62;
const
WM_CAP_FILE_SET_CAPTURE_FILEA = WM_CAP_START + 20;
const
WM_CAP_SEQUENCE_NOFILE = WM_CAP_START + 63;
const
WM_CAP_SET_OVERLAY = WM_CAP_START + 51;
const
WM_CAP_SET_PREVIEW = WM_CAP_START + 50;
const
WM_CAP_SET_CALLBACK_VIDEOSTREAM = WM_CAP_START + 6;
const
WM_CAP_SET_CALLBACK_ERROR = WM_CAP_START + 2;
const
WM_CAP_SET_CALLBACK_STATUSA = WM_CAP_START + 3;
const
WM_CAP_SET_CALLBACK_FRAME = WM_CAP_START + 5;
const
WM_CAP_SET_SCALE = WM_CAP_START + 53;
const
WM_CAP_SET_PREVIEWRATE = WM_CAP_START + 52;
function capCreateCaptureWindowA(lpszWindowName: PCHAR; dwStyle: longint; x: integer; y: integer; nWidth: integer; nHeight: integer; ParentWin: HWND; nId: integer): HWND; stdcall external 'AVICAP32.DLL';
{$R *.dfm}
procedure TfrmPictureUpload.Rotate90(Source: TGraphic; Target: TJpegImage);
var
SourceBmp, TargetBmp: TBitmap;
r, c: Integer;
x, y: Integer;
begin
SourceBmp := TBitmap.Create;
SourceBmp.Assign(Source);
TargetBmp := TBitmap.Create;
TargetBmp.Width := SourceBmp.Height;
TargetBmp.Height := SourceBmp.Width;
for r := 0 to SourceBmp.Height - 1 do
begin
for c := 0 to SourceBmp.Width - 1 do
begin
//x := (SourceBmp.Height-1) - r; // -90
//y := c; //-90
x := r; //90
y := (SourceBmp.Width - 1) - c; //90
// look into Bitmap.ScanLine for faster pixel access
TargetBmp.Canvas.Pixels[x, y] := SourceBmp.Canvas.Pixels[c, r];
end;
end;
Target.Assign(TargetBmp);
SourceBmp.Free;
TargetBmp.Free;
end;
procedure TfrmPictureUpload.Initimage();
var
jpg: TJpegImage;
myStream: TADOBlobStream;
sFieldName: string;
JPStream: TMemoryStream;
begin
jpg := TJpegImage.Create();
JPStream := TMemoryStream.Create;
try
with adoqueryImage do
begin
close;
sql.Clear;
sql.Add('select * from TP_File where WBID=' + quotedstr(trim(FDataId)));
sql.Add('and TFType=' + quotedstr(trim(FTFType)));
open;
if not IsEmpty then
begin
if not fieldbyname('FilesOther').IsNull then
begin
myStream := tadoblobstream.Create(tblobfield(adoqueryImage.fieldbyname('FilesOther')), bmread);
jpg.LoadFromStream(myStream);
Image2.Picture.Assign(jpg);
myStream.Free;
try
IdFTP1.Host := ReadINIFileStr('SYSTEMSET.INI', 'SERVER', '服务器地址', '127.0.0.1');
IdFTP1.Username := 'three';
IdFTP1.Password := '641010';
IdFTP1.Connect();
except
;
end;
JPStream.Clear;
if IdFTP1.Connected then
begin
try
IdFTP1.Get(fFlileFlag + '\' + Trim(fieldbyname('FileName').AsString), JPStream);
except
Application.MessageBox('客户图样文件不存在', '提示', MB_ICONWARNING);
IdFTP1.Quit;
Exit;
end;
end
else
begin
Application.MessageBox('无法连接文件服务器', '提示', MB_ICONWARNING);
IdFTP1.Quit;
Exit;
end;
if IdFTP1.Connected then
IdFTP1.Quit;
JPStream.Position := 0;
jpg.LoadFromStream(JPStream);
Image1.Picture.Assign(jpg);
end;
end;
end;
finally
jpg.free;
JPStream.Free;
end;
end;
function TfrmPictureUpload.SaveImage(): Boolean;
var
myStream: TADOBlobStream;
maxNo: string;
fNewFileName: string;
begin
//取文件后缀 ExtractFileExt(FilePath)
if FPictureName = '' then
begin
fNewFileName := formatdatetime('yyyyMMddhhnnsszzz', now()) + ExtractFileExt(FilePath);
FPictureName := fNewFileName;
end;
result := false;
try
with adoqueryImage do
begin
close;
sql.Clear;
sql.Add('select * from TP_File where WBID=' + quotedstr(trim(FDataId)));
sql.Add('and TFType=' + quotedstr(trim(FTFType)));
open;
if RecordCount <= 0 then
begin
Append;
if GetLSNo(ADOQuery1, maxNo, 'FJ', 'TP_File', 4, 1) = False then
begin
Application.MessageBox('取最大号失败!', '提示', 0);
Exit;
end;
fieldByName('TFID').AsString := maxNo;
fieldByName('WBID').AsString := FDataId;
end
else
begin
edit;
end;
fieldByName('FileName').AsString := trim(FPictureName);
fieldByName('Filler').AsString := trim(dName);
fieldByName('TFType').AsString := trim(FTFType);
myStream := TADOBlobStream.Create(TBlobField(FieldByName('FilesOther')), bmWrite);
MyJpeg.Assign(Image2.Picture.Graphic);
MyJpeg.SaveToStream(myStream);
myStream.Free;
Post;
end;
if FilePath <> '' then
begin
try
IdFTP1.Host := ReadINIFileStr('SYSTEMSET.INI', 'SERVER', '服务器地址', '127.0.0.1');
IdFTP1.Username := 'three';
IdFTP1.Password := '641010';
IdFTP1.Connect();
IdFTP1.Put(FilePath, fFlileFlag + '\' + Trim(FPictureName));
IdFTP1.Quit;
except
IdFTP1.Quit;
Application.MessageBox('上传客户图样文件失败,请检查文件服务器!', '提示', MB_ICONWARNING);
end;
end;
IdFTP1.Quit;
result := true;
except
myStream.Free;
end;
end;
procedure TfrmPictureUpload.TBCloseClick(Sender: TObject);
begin
Close;
end;
procedure TfrmPictureUpload.TBSaveClick(Sender: TObject);
begin
if SaveImage() then
begin
ModalResult := 1;
end
else
begin
application.MessageBox('数据保存失败!', '提示信息', 0)
end;
end;
procedure TfrmPictureUpload.ToolButton1Click(Sender: TObject);
var
Jpeg: TJPEGImage;
begin
if OpenPictureDialog1.Execute then
begin
Image1.Top := 0;
Image1.Left := 0;
Image1.Picture.LoadFromFile(OpenPictureDialog1.FileName);
FilePath := OpenPictureDialog1.FileName;
FileName := ExtractFileName(FilePath);
// Jpeg := TJPEGImage.Create;
// Rotate90(Image1.Picture.Graphic, Jpeg);
// Image1.Picture.Assign(Jpeg);
// Jpeg.Free;
CreThumb(FWidth, FHeight);
TBSave.Enabled := TRUE;
end;
end;
procedure TfrmPictureUpload.ToolButton2Click(Sender: TObject);
begin
try
with adoqueryImage do
begin
close;
sql.Clear;
sql.Add('select * from TP_File where WBID=' + quotedstr(trim(FPictureName)));
open;
if RecordCount > 0 then
begin
edit;
fieldByName('FileName').Value := null;
FieldByName('FilesOther').Value := null;
post;
Image1.Picture.Assign(nil);
Image2.Picture.Assign(nil);
end;
end;
except
end;
end;
procedure TfrmPictureUpload.ToolButton3Click(Sender: TObject);
var
MJPG: TJpegImage;
pathFile: string;
begin
if Image1.Picture.Graphic = nil then
exit;
MJPG := TJpegImage.Create;
try
SaveDialog1.FileName := FileName;
if SaveDialog1.Execute then
begin
if SaveDialog1.FileName <> '' then
begin
pathFile := trim(SaveDialog1.FileName);
if (RightStr(UPPERCASE(pathFile), 4) <> '.JPG') and (RightStr(UPPERCASE(pathFile), 5) <> '.JPEG') then
begin
pathFile := pathFile + '.JPG';
end;
MJPG.Assign(Image1.Picture.Graphic);
if fileexists(pathFile) then
begin
if application.MessageBox(pchar('文件[' + trim(pathFile) + ']已存在,是否要替换它?'), '提示信息', MB_YESNO + mb_iconinformation + MB_DEFBUTTON2) = idyes then
MJPG.SaveToFile(pathFile);
end
else
MJPG.SaveToFile(pathFile);
end;
end;
finally
MJPG.Free;
end;
end;
procedure TfrmPictureUpload.ToolButton4Click(Sender: TObject);
begin
ModalResult := 2;
end;
procedure TfrmPictureUpload.TwainTwainAcquire(Sender: TObject; const Index: Integer; Image: TBitmap; var Cancel: Boolean);
begin
Image1.Picture.Assign(Image);
Cancel := TRUE;
CreThumb(150, 150);
TBSave.Enabled := TRUE;
end;
procedure TfrmPictureUpload.FormShow(Sender: TObject);
var
Ini: TIniFile;
begin
{ Ini := TIniFile.Create(ExtractFilePath(ParamStr(0)) + 'scanner.ini');
try
SelectedSource := Ini.ReadInteger( 'SCANNER', 'Scanner', 0);
PicLeft := Ini.ReadInteger( 'SCANNER', 'Left', 0);
PicTop := Ini.ReadInteger( 'SCANNER', 'Top', 0);
PicWidth := Ini.ReadInteger( 'SCANNER', 'Width', 100);
PicHeight := Ini.ReadInteger( 'SCANNER', 'Height', 100);
finally
Ini.Free;
end; }
Initimage();
end;
{
procedure TfrmPictureUpload.ToolButton6Click(Sender: TObject);
var
Ini: TIniFile;
begin
FormGetPos := TFormGetPos.Create(Self);
FormGetPos.SpinEdit1.Value := PicLeft;
FormGetPos.SpinEdit2.Value := PicTop;
FormGetPos.SpinEdit3.Value := PicWidth;
FormGetPos.SpinEdit4.Value := PicHeight;
if FormGetPos.ShowModal = 1 then
begin
PicLeft := FormGetPos.SpinEdit1.Value;
PicTop := FormGetPos.SpinEdit2.Value;
PicWidth := FormGetPos.SpinEdit3.Value;
PicHeight := FormGetPos.SpinEdit4.Value;
Ini := TIniFile.Create(ExtractFilePath(ParamStr(0)) + 'scanner.ini');
try
Ini.WriteInteger( 'SCANNER', 'Left', PicLeft);
Ini.WriteInteger( 'SCANNER', 'Top', PicTop);
Ini.WriteInteger( 'SCANNER', 'Width', PicWidth);
Ini.WriteInteger( 'SCANNER', 'Height', PicHeight);
finally
Ini.Free;
end;
end;
FormGetPos.Free;
end;
}
procedure TfrmPictureUpload.CreThumb(Width, Height: Integer);
var
Bitmap: TBitmap;
Ratio: Double;
ARect: TRect;
AHeight, AHeightOffset: Integer;
AWidth, AWidthOffset: Integer;
begin
Bitmap := TBitmap.Create;
try
Ratio := Image1.Picture.Graphic.Width / Image1.Picture.Graphic.Height;
if Ratio > 0.75 then
begin
AHeight := Round(Width / Ratio);
AHeightOffset := (Height - AHeight) div 2;
AWidth := Width;
AWidthOffset := 0;
end
else
begin
AWidth := Round(Height * Ratio);
AWidthOffset := (Width - AWidth) div 2;
AHeight := Height;
AHeightOffset := 0;
end;
Bitmap.Width := Width;
Bitmap.Height := Height;
Bitmap.Canvas.Brush.Color := clBtnFace;
Bitmap.Canvas.FillRect(Rect(0, 0, Width, Height));
ARect := Rect(AWidthOffset, AHeightOffset, AWidth + AWidthOffset, AHeight + AHeightOffset);
Bitmap.Canvas.StretchDraw(ARect, Image1.Picture.Graphic);
Image2.Picture.Assign(Bitmap);
finally
Bitmap.Free;
end;
end;
procedure TfrmPictureUpload.FormCreate(Sender: TObject);
begin
MyJpeg := TJpegImage.Create;
TBSave.Enabled := false;
if FWidth = 0 then
FWidth := 197;
if FHeight = 0 then
FHeight := 110;
end;
procedure TfrmPictureUpload.FormDestroy(Sender: TObject);
begin
// MyJpeg1.Free;
MyJpeg.Free;
end;
procedure TfrmPictureUpload.Image1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
begin
ClickPos.x := X;
ClickPos.y := Y;
end;
procedure TfrmPictureUpload.Image1MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
var
NewPos: TPoint;
begin
{The left button was pressed}
if ssLeft in Shift then
begin
{Calculate new position}
NewPos.X := Image1.Left + X - ClickPos.x;
NewPos.Y := Image1.Top + Y - ClickPos.y;
if NewPos.x + Image1.Width < ScrollBox1.Width then
NewPos.x := ScrollBox1.Width - Image1.Width;
if NewPos.y + Image1.Height < ScrollBox1.Height then
NewPos.y := ScrollBox1.Height - Image1.Height;
if NewPos.X > 0 then
NewPos.X := 0;
if NewPos.Y > 0 then
NewPos.Y := 0;
Image1.Top := NewPos.Y;
Image1.Left := NewPos.X;
end {if ssLeft in Shift}
end;
end.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,185 @@
unit U_ProductInfoSel;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
cxEdit, DB, cxDBData, ToolWin, ComCtrls, U_BaseHelp, cxGridCustomTableView,
cxGridTableView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls,
cxGridCustomView, cxGrid, DBClient, ADODB, ImgList, StdCtrls, ExtCtrls,
cxTextEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels,
cxLookAndFeelPainters, dxSkinsCore, dxSkinsDefaultPainters, cxNavigator,
dxDateRanges, dxBarBuiltInMenu, System.ImageList, U_BaseInput, cxButtonEdit,
cxDropDownEdit;
type
TfrmProductInfoSel = class(TfrmBaseHelp)
ToolBar1: TToolBar;
ADOQueryMain: TADOQuery;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
DS_1: TDataSource;
CDS_1: TClientDataSet;
TBSave: TToolButton;
TBClose: TToolButton;
ToolButton1: TToolButton;
ADOConnection1: TADOConnection;
Panel1: TPanel;
Label1: TLabel;
Brand: TEdit;
GPM_1: TcxGridPopupMenu;
ImageList1: TImageList;
ThreeColorBase: TcxStyleRepository;
SHuangSe: TcxStyle;
SkyBlue: TcxStyle;
Default: TcxStyle;
QHuangSe: TcxStyle;
Red: TcxStyle;
FontBlue: TcxStyle;
TextSHuangSe: TcxStyle;
FonePurple: TcxStyle;
FoneClMaroon: TcxStyle;
FoneRed: TcxStyle;
RowColor: TcxStyle;
handBlack: TcxStyle;
cxBlue: TcxStyle;
SHuangSeCu: TcxStyle;
cxGrid2: TcxGrid;
Tv1: TcxGridDBTableView;
v1Column1: TcxGridDBColumn;
Tv1Column2: TcxGridDBColumn;
v2Column1: TcxGridDBColumn;
v1Column8: TcxGridDBColumn;
v1Column10: TcxGridDBColumn;
v1Column18: TcxGridDBColumn;
v1Column3: TcxGridDBColumn;
v1Column9: TcxGridDBColumn;
v1Column17: TcxGridDBColumn;
v1Column12: TcxGridDBColumn;
cxGrid2Level1: TcxGridLevel;
Label2: TLabel;
P_Name: TEdit;
Label3: TLabel;
P_Spec: TEdit;
procedure FormCreate(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormShow(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure TBSaveClick(Sender: TObject);
procedure TV1DblClick(Sender: TObject);
procedure TBCloseClick(Sender: TObject);
procedure BrandChange(Sender: TObject);
private
procedure InitGrid();
{ Private declarations }
public
FSTKName: string;
{ Public declarations }
end;
var
frmProductInfoSel: TfrmProductInfoSel;
implementation
uses
U_DataLink, U_RTFun;
{$R *.dfm}
procedure TfrmProductInfoSel.FormCreate(Sender: TObject);
begin
inherited;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
application.MessageBox('网络连接失败!', '提示信息');
end;
end;
procedure TfrmProductInfoSel.BrandChange(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmProductInfoSel.FormClose(Sender: TObject; var Action: TCloseAction);
begin
P_Name.SetFocus;
Action := cahide;
end;
procedure TfrmProductInfoSel.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Close;
sql.Clear;
sql.Add(' select A.* ');
sql.Add(' from BS_Product_Info A');
sql.Add(' where isnull(STKNAME,'''')=''' + Trim(FSTKName) + '''');
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmProductInfoSel.FormShow(Sender: TObject);
begin
inherited;
ReadCxGrid('物料类型' + Trim(FSTKName), TV1, '通用窗体');
InitGrid();
end;
procedure TfrmProductInfoSel.TBCloseClick(Sender: TObject);
begin
inherited;
Close;
end;
procedure TfrmProductInfoSel.TBSaveClick(Sender: TObject);
begin
WriteCxGrid('物料类型' + Trim(FSTKName), TV1, '通用窗体');
end;
procedure TfrmProductInfoSel.ToolButton1Click(Sender: TObject);
begin
P_Name.SetFocus;
ModalResult := 1;
end;
procedure TfrmProductInfoSel.TV1DblClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmProductInfoSel.FormDestroy(Sender: TObject);
begin
inherited;
frmProductInfoSel := nil;
end;
end.

View File

@ -0,0 +1,222 @@
inherited frmUserSel: TfrmUserSel
Left = 770
Top = 211
Caption = #29992#25143#36873#25321
ClientHeight = 522
ClientWidth = 604
Color = clWhite
Font.Charset = GB2312_CHARSET
Font.Height = -12
Font.Name = #23435#20307
OnClose = FormClose
ExplicitWidth = 620
ExplicitHeight = 561
PixelsPerInch = 96
TextHeight = 12
object ToolBar1: TToolBar [0]
Tag = 1
Left = 0
Top = 0
Width = 604
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 75
Caption = 'ToolBar1'
Color = clSkyBlue
DisabledImages = DataLink_Company.ImageList_new32
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ShowCaptions = True
TabOrder = 0
object TBRafresh: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #21047#26032
ImageIndex = 1
OnClick = TBRafreshClick
end
object ToolButton2: TToolButton
Left = 71
Top = 0
AutoSize = True
Caption = #36807#28388
ImageIndex = 0
OnClick = ToolButton2Click
end
object btnOK: TToolButton
Left = 142
Top = 0
AutoSize = True
Caption = #30830#35748
ImageIndex = 12
OnClick = btnOKClick
end
object TBClose: TToolButton
Left = 213
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object Panel1: TPanel [1]
Left = 0
Top = 38
Width = 604
Height = 39
Align = alTop
BevelInner = bvRaised
BevelOuter = bvLowered
Color = clSkyBlue
TabOrder = 1
object Label3: TLabel
Left = 202
Top = 13
Width = 24
Height = 12
Caption = #21517#31216
end
object Label1: TLabel
Left = 22
Top = 13
Width = 24
Height = 12
Caption = #32534#21495
end
object UserName: TEdit
Tag = 2
Left = 232
Top = 9
Width = 89
Height = 20
ImeName = #20013#25991' - QQ'#25340#38899#36755#20837#27861
TabOrder = 1
OnChange = UserNameChange
end
object UserID: TEdit
Tag = 2
Left = 52
Top = 9
Width = 89
Height = 20
ImeName = #20013#25991' - QQ'#25340#38899#36755#20837#27861
TabOrder = 0
OnChange = UserNameChange
end
end
object cxGrid1: TcxGrid [2]
Left = 0
Top = 77
Width = 604
Height = 445
Align = alClient
TabOrder = 2
object Tv1: TcxGridDBTableView
OnDblClick = Tv1DblClick
Navigator.Buttons.CustomButtons = <>
Navigator.Buttons.Delete.Enabled = False
Navigator.Buttons.Delete.Visible = False
DataController.DataSource = DS_1
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <>
DataController.Summary.SummaryGroups = <>
OptionsBehavior.GoToNextCellOnEnter = True
OptionsCustomize.ColumnFiltering = False
OptionsView.GroupByBox = False
Styles.IncSearch = DataLink_Company.SHuangSe
Styles.Footer = DataLink_Company.handBlack
Styles.Header = DataLink_Company.handBlack
Styles.Inactive = DataLink_Company.SHuangSe
Styles.Selection = DataLink_Company.SHuangSe
object VC_SSel: TcxGridDBColumn
Caption = #36873#25321
DataBinding.FieldName = 'SSel'
PropertiesClassName = 'TcxCheckBoxProperties'
Properties.ImmediatePost = True
HeaderAlignmentHorz = taCenter
Width = 48
end
object v2Column1: TcxGridDBColumn
Caption = #32534#21495
DataBinding.FieldName = 'UserID'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 76
end
object v2Column2: TcxGridDBColumn
Caption = #21517#31216
DataBinding.FieldName = 'UserName'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 171
end
object v2Column3: TcxGridDBColumn
Caption = #37096#38376
DataBinding.FieldName = 'Udept'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 71
end
end
object cxGridLevel1: TcxGridLevel
GridView = Tv1
end
end
inherited ADOQueryBaseCmd: TADOQuery
Connection = ADOConnection1
Left = 473
Top = 184
end
inherited ADOQueryBaseTemp: TADOQuery
Connection = ADOConnection1
Left = 465
Top = 105
end
object ADOQueryTemp: TADOQuery
Connection = ADOConnection1
LockType = ltReadOnly
Parameters = <>
Left = 68
Top = 136
end
object ADOQueryCmd: TADOQuery
Connection = ADOConnection1
Parameters = <>
Left = 188
Top = 224
end
object ADOQueryMain: TADOQuery
Connection = ADOConnection1
LockType = ltReadOnly
Parameters = <>
Left = 54
Top = 224
end
object cxGridPopupMenu2: TcxGridPopupMenu
Grid = cxGrid1
PopupMenus = <>
Left = 211
Top = 124
end
object DS_1: TDataSource
DataSet = CDS_1
Left = 262
Top = 320
end
object CDS_1: TClientDataSet
Aggregates = <>
Params = <>
Left = 158
Top = 304
end
object ADOConnection1: TADOConnection
LoginPrompt = False
Left = 336
Top = 176
end
end

View File

@ -0,0 +1,189 @@
unit U_UserSel;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls,
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
cxTextEdit, cxDBLookupComboBox, ComObj, cxLookAndFeels, cxLookAndFeelPainters,
dxSkinsCore, dxSkinsDefaultPainters, cxNavigator, dxDateRanges, U_BaseHelp,
dxBarBuiltInMenu, System.ImageList, Vcl.ImgList;
type
FdDy = record
inc: integer; //客户端套接字句柄
FDdys: string[32]; //客户端套接字
FdDysName: string[32]; //客户端套接字
end;
TfrmUserSel = class(TfrmBaseHelp)
ToolBar1: TToolBar;
TBRafresh: TToolButton;
TBClose: TToolButton;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
Panel1: TPanel;
ToolButton2: TToolButton;
ADOQueryMain: TADOQuery;
Label3: TLabel;
UserName: TEdit;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
cxGridLevel1: TcxGridLevel;
cxGridPopupMenu2: TcxGridPopupMenu;
DS_1: TDataSource;
CDS_1: TClientDataSet;
Label1: TLabel;
UserID: TEdit;
btnOK: TToolButton;
v2Column1: TcxGridDBColumn;
v2Column2: TcxGridDBColumn;
v2Column3: TcxGridDBColumn;
VC_SSel: TcxGridDBColumn;
ADOConnection1: TADOConnection;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure TBRafreshClick(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
procedure UserNameChange(Sender: TObject);
procedure btnOKClick(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure Tv1DblClick(Sender: TObject);
private
{ Private declarations }
procedure InitGrid();
public
Fdept: string;
FMultiple: Boolean;
end;
var
frmUserSel: TfrmUserSel;
implementation
uses
U_DataLink, U_RTFun;
{$R *.dfm}
procedure TfrmUserSel.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Filtered := False;
Close;
SQL.Clear;
sql.Add(' select * from SY_User where 1=1 ');
if Trim(Fdept) <> '' then
begin
sql.Add('and Udept=' + QuotedStr(Trim(Fdept)));
end;
Open;
end;
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmUserSel.FormCreate(Sender: TObject);
begin
inherited;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
application.MessageBox('网络连接失败!', '提示信息');
end;
end;
procedure TfrmUserSel.FormDestroy(Sender: TObject);
begin
inherited;
frmUserSel := nil;
end;
procedure TfrmUserSel.FormClose(Sender: TObject; var Action: TCloseAction);
begin
inherited;
Action := caFree;
end;
procedure TfrmUserSel.TBCloseClick(Sender: TObject);
begin
WriteCxGrid(trim(self.caption), Tv1, '账户选择');
Close;
end;
procedure TfrmUserSel.FormShow(Sender: TObject);
begin
inherited;
ReadCxGrid(trim(self.Caption), Tv1, '账户选择');
if FMultiple then
begin
VC_SSel.Visible := True;
VC_SSel.Hidden := False;
end
else
begin
VC_SSel.Visible := False;
VC_SSel.Hidden := True;
end;
InitGrid();
end;
procedure TfrmUserSel.TBRafreshClick(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmUserSel.ToolButton2Click(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmUserSel.Tv1DblClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmUserSel.UserNameChange(Sender: TObject);
begin
ToolButton2.Click;
end;
procedure TfrmUserSel.btnOKClick(Sender: TObject);
begin
ModalResult := 1;
end;
end.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,202 @@
unit U_YarnInfoSel;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
cxEdit, DB, cxDBData, ToolWin, ComCtrls, U_BaseHelp, cxGridCustomTableView,
cxGridTableView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls,
cxGridCustomView, cxGrid, DBClient, ADODB, ImgList, StdCtrls, ExtCtrls,
cxTextEdit, cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels,
cxLookAndFeelPainters, dxSkinsCore, dxSkinsDefaultPainters, cxNavigator,
dxDateRanges, dxBarBuiltInMenu, System.ImageList, U_BaseInput, cxButtonEdit,
cxCheckBox, Vcl.Menus;
type
TfrmYarnInfoSel = class(TfrmBaseHelp)
ToolBar1: TToolBar;
ADOQueryMain: TADOQuery;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
DS_1: TDataSource;
CDS_1: TClientDataSet;
TBSave: TToolButton;
TBClose: TToolButton;
ToolButton1: TToolButton;
ADOConnection1: TADOConnection;
Panel1: TPanel;
Label1: TLabel;
Y_Name: TEdit;
GPM_1: TcxGridPopupMenu;
ImageList1: TImageList;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
v1Column2: TcxGridDBColumn;
v1Column18: TcxGridDBColumn;
v1Column15: TcxGridDBColumn;
v1SPName: TcxGridDBColumn;
v1SPSpec: TcxGridDBColumn;
v1Column1: TcxGridDBColumn;
v1QtyUnit: TcxGridDBColumn;
v1Column10: TcxGridDBColumn;
v1Column3: TcxGridDBColumn;
v1Column12: TcxGridDBColumn;
cxGrid1Level1: TcxGridLevel;
ThreeColorBase: TcxStyleRepository;
SHuangSe: TcxStyle;
SkyBlue: TcxStyle;
Default: TcxStyle;
QHuangSe: TcxStyle;
Red: TcxStyle;
FontBlue: TcxStyle;
TextSHuangSe: TcxStyle;
FonePurple: TcxStyle;
FoneClMaroon: TcxStyle;
FoneRed: TcxStyle;
RowColor: TcxStyle;
handBlack: TcxStyle;
cxBlue: TcxStyle;
SHuangSeCu: TcxStyle;
Tv1Column1: TcxGridDBColumn;
Tv1Column2: TcxGridDBColumn;
PM_1: TPopupMenu;
N1: TMenuItem;
N2: TMenuItem;
procedure FormCreate(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormShow(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure TBSaveClick(Sender: TObject);
procedure TV1DblClick(Sender: TObject);
procedure TBCloseClick(Sender: TObject);
procedure Y_NameChange(Sender: TObject);
procedure N1Click(Sender: TObject);
procedure N2Click(Sender: TObject);
private
procedure InitGrid();
{ Private declarations }
public
FSTKName, FAuthority: string;
{ Public declarations }
end;
var
frmYarnInfoSel: TfrmYarnInfoSel;
implementation
uses
U_DataLink, U_RTFun;
{$R *.dfm}
procedure TfrmYarnInfoSel.FormCreate(Sender: TObject);
begin
inherited;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
Connected := true;
end;
ADOQueryBaseCmd.Connection := ADOConnection1;
ADOQueryBaseTemp.Connection := ADOConnection1;
except
application.MessageBox('网络连接失败!', '提示信息');
end;
end;
procedure TfrmYarnInfoSel.Y_NameChange(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmYarnInfoSel.FormClose(Sender: TObject; var Action: TCloseAction);
begin
Y_Name.SetFocus;
Action := cahide;
end;
procedure TfrmYarnInfoSel.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Close;
sql.Clear;
sql.Add(' select A.* ');
sql.Add(' from BS_Yarn_Info A');
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmYarnInfoSel.N1Click(Sender: TObject);
begin
SelOKNo(CDS_1, true);
end;
procedure TfrmYarnInfoSel.N2Click(Sender: TObject);
begin
SelOKNo(CDS_1, False);
end;
procedure TfrmYarnInfoSel.FormShow(Sender: TObject);
begin
inherited;
InitGrid();
ReadCxGrid('单位名称' + Trim(FSTKName), TV1, '自定义数据');
end;
procedure TfrmYarnInfoSel.TBCloseClick(Sender: TObject);
begin
inherited;
Close;
end;
procedure TfrmYarnInfoSel.TBSaveClick(Sender: TObject);
begin
WriteCxGrid('单位名称' + Trim(FSTKName), TV1, '自定义数据');
end;
procedure TfrmYarnInfoSel.ToolButton1Click(Sender: TObject);
begin
Y_Name.SetFocus;
ModalResult := 1;
end;
procedure TfrmYarnInfoSel.TV1DblClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmYarnInfoSel.FormDestroy(Sender: TObject);
begin
inherited;
frmYarnInfoSel := nil;
end;
end.

144
A00通用窗体/getpic.dfm Normal file
View File

@ -0,0 +1,144 @@
object FormGetPic: TFormGetPic
Left = 697
Top = 183
BorderIcons = [biSystemMenu]
BorderStyle = bsSingle
Caption = #33719#21462#22270#29255
ClientHeight = 449
ClientWidth = 670
Color = clBtnFace
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
OldCreateOrder = False
Position = poDesktopCenter
OnCreate = FormCreate
OnDestroy = FormDestroy
OnShow = FormShow
PixelsPerInch = 96
TextHeight = 12
object Image2: TImage
Left = 464
Top = 8
Width = 160
Height = 120
end
object SpeedButton1: TSpeedButton
Left = 500
Top = 334
Width = 80
Height = 22
Caption = #25171#24320#22270#29255'...'
OnClick = SpeedButton1Click
end
object SpeedButton2: TSpeedButton
Left = 500
Top = 380
Width = 80
Height = 22
Caption = #30830#23450
Enabled = False
OnClick = SpeedButton2Click
end
object SpeedButton3: TSpeedButton
Left = 500
Top = 426
Width = 80
Height = 22
Caption = #25918#24323
OnClick = SpeedButton3Click
end
object SpeedButton4: TSpeedButton
Left = 500
Top = 358
Width = 80
Height = 22
Caption = #22270#29255#21478#23384'...'
OnClick = SpeedButton4Click
end
object SpeedButton5: TSpeedButton
Left = 500
Top = 404
Width = 80
Height = 22
Caption = #21024#38500
OnClick = SpeedButton5Click
end
object ScrollBox1: TScrollBox
Left = 5
Top = 5
Width = 300
Height = 400
HorzScrollBar.Visible = False
VertScrollBar.Visible = False
TabOrder = 0
object Image1: TImage
Left = 0
Top = 0
Width = 296
Height = 396
Cursor = crSizeAll
Align = alClient
Center = True
IncrementalDisplay = True
Stretch = True
OnMouseDown = Image1MouseDown
OnMouseMove = Image1MouseMove
ExplicitLeft = -2
ExplicitTop = 3
ExplicitWidth = 275
ExplicitHeight = 436
end
end
object Button1: TButton
Left = 464
Top = 252
Width = 81
Height = 21
Caption = #25171#24320#25668#20687#22836
TabOrder = 1
OnClick = Button1Click
end
object Button2: TButton
Left = 560
Top = 252
Width = 81
Height = 21
Caption = #25235#22270
TabOrder = 2
OnClick = Button2Click
end
object OpenPictureDialog1: TOpenPictureDialog
Left = 336
Top = 176
end
object ADOQuery1: TADOQuery
Connection = DataLink_YPGL.ADOLink
Parameters = <>
Left = 504
Top = 280
end
object SaveDialog1: TSavePictureDialog
Left = 344
Top = 251
end
object adoqueryImage: TADOQuery
Connection = DataLink_YPGL.ADOLink
Parameters = <>
Left = 488
Top = 184
end
object IdFTP1: TIdFTP
ConnectTimeout = 0
NATKeepAlive.UseKeepAlive = False
NATKeepAlive.IdleTimeMS = 0
NATKeepAlive.IntervalMS = 0
ProxySettings.ProxyType = fpcmNone
ProxySettings.Port = 0
ReadTimeout = 0
Left = 492
Top = 134
end
end

669
A00通用窗体/getpic.pas Normal file
View File

@ -0,0 +1,669 @@
unit getpic;
interface
uses
Windows, Messages, SysUtils, strUtils, Variants, Classes, Graphics, Controls,
Forms, Dialogs, ComCtrls, ToolWin, ExtCtrls, jpeg, IniFiles, ExtDlgs, Buttons,
StdCtrls, DB, ADODB, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, IdExplicitTLSClientServerBase;
type
TFormGetPic = class(TForm)
ScrollBox1: TScrollBox;
Image1: TImage;
OpenPictureDialog1: TOpenPictureDialog;
Image2: TImage;
SpeedButton1: TSpeedButton;
SpeedButton2: TSpeedButton;
SpeedButton3: TSpeedButton;
Button1: TButton;
Button2: TButton;
ADOQuery1: TADOQuery;
SpeedButton4: TSpeedButton;
SaveDialog1: TSavePictureDialog;
adoqueryImage: TADOQuery;
IdFTP1: TIdFTP;
SpeedButton5: TSpeedButton;
procedure ToolButton1Click(Sender: TObject);
procedure ToolButton3Click(Sender: TObject);
procedure TwainTwainAcquire(Sender: TObject; const Index: Integer; Image: TBitmap; var Cancel: Boolean);
procedure FormShow(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure Image1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
procedure Image1MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
procedure SpeedButton1Click(Sender: TObject);
procedure SpeedButton2Click(Sender: TObject);
procedure SpeedButton3Click(Sender: TObject);
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure SpeedButton4Click(Sender: TObject);
procedure Initimage();
procedure SpeedButton5Click(Sender: TObject);
private
hWndC: THandle;
CapturingAVI: bool;
{ Private declarations }
ClickPos: TPoint;
SelectedSource, PicLeft, PicTop, PicWidth, PicHeight: Integer;
procedure CreThumb(Width, Height: Integer);
function SaveImage(): Boolean;
procedure Rotate90(Source: TGraphic; Target: TJpegImage);
public
FilePath: string;
FileName: string;
FTFType: string;
pat1: string;
pic1: string;
fkeyNo, FMainId: string;
fFlileFlag: string;
FWidth, FHeight: INTEGER;
{ Public declarations }
MyJpeg: TJPEGImage;
// JPStream: TMemoryStream;
end;
var
FormGetPic: TFormGetPic;
implementation
uses
U_DataLink, U_RTFun;
const
WM_CAP_START = WM_USER;
const
WM_CAP_STOP = WM_CAP_START + 68;
const
WM_CAP_DRIVER_CONNECT = WM_CAP_START + 10;
const
WM_CAP_DRIVER_DISCONNECT = WM_CAP_START + 11;
const
WM_CAP_SAVEDIB = WM_CAP_START + 25;
const
WM_CAP_GRAB_FRAME = WM_CAP_START + 60;
const
WM_CAP_SEQUENCE = WM_CAP_START + 62;
const
WM_CAP_FILE_SET_CAPTURE_FILEA = WM_CAP_START + 20;
const
WM_CAP_SEQUENCE_NOFILE = WM_CAP_START + 63;
const
WM_CAP_SET_OVERLAY = WM_CAP_START + 51;
const
WM_CAP_SET_PREVIEW = WM_CAP_START + 50;
const
WM_CAP_SET_CALLBACK_VIDEOSTREAM = WM_CAP_START + 6;
const
WM_CAP_SET_CALLBACK_ERROR = WM_CAP_START + 2;
const
WM_CAP_SET_CALLBACK_STATUSA = WM_CAP_START + 3;
const
WM_CAP_SET_CALLBACK_FRAME = WM_CAP_START + 5;
const
WM_CAP_SET_SCALE = WM_CAP_START + 53;
const
WM_CAP_SET_PREVIEWRATE = WM_CAP_START + 52;
function capCreateCaptureWindowA(lpszWindowName: PCHAR; dwStyle: longint; x: integer; y: integer; nWidth: integer; nHeight: integer; ParentWin: HWND; nId: integer): HWND; stdcall external 'AVICAP32.DLL';
{$R *.dfm}
procedure TFormGetPic.Rotate90(Source: TGraphic; Target: TJpegImage);
var
SourceBmp, TargetBmp: TBitmap;
r, c: Integer;
x, y: Integer;
begin
SourceBmp := TBitmap.Create;
SourceBmp.Assign(Source);
TargetBmp := TBitmap.Create;
TargetBmp.Width := SourceBmp.Height;
TargetBmp.Height := SourceBmp.Width;
for r := 0 to SourceBmp.Height - 1 do
begin
for c := 0 to SourceBmp.Width - 1 do
begin
//x := (SourceBmp.Height-1) - r; // -90
//y := c; //-90
x := r; //90
y := (SourceBmp.Width - 1) - c; //90
// look into Bitmap.ScanLine for faster pixel access
TargetBmp.Canvas.Pixels[x, y] := SourceBmp.Canvas.Pixels[c, r];
end;
end;
Target.Assign(TargetBmp);
SourceBmp.Free;
TargetBmp.Free;
end;
procedure TFormGetPic.Initimage();
var
jpg: TJpegImage;
myStream: TADOBlobStream;
sFieldName: string;
JPStream: TMemoryStream;
begin
jpg := TJpegImage.Create();
JPStream := TMemoryStream.Create;
try
with adoqueryImage do
begin
close;
sql.Clear;
sql.Add('select * from TP_File where WBID=' + quotedstr(trim(FMainId)));
sql.Add('and TFType=' + quotedstr(trim(FTFType)));
open;
if not IsEmpty then
begin
if not fieldbyname(pic1).IsNull then
begin
myStream := tadoblobstream.Create(tblobfield(adoqueryImage.fieldbyname(pic1)), bmread);
jpg.LoadFromStream(myStream);
Image2.Picture.Assign(jpg);
myStream.Free;
try
IdFTP1.Host := ReadINIFileStr('SYSTEMSET.INI', 'SERVER', '服务器地址', '127.0.0.1');
IdFTP1.Username := 'three';
IdFTP1.Password := '641010';
IdFTP1.Connect();
except
;
end;
JPStream.Clear;
if IdFTP1.Connected then
begin
try
IdFTP1.Get(fFlileFlag + '\' + Trim(fieldbyname(pat1).AsString), JPStream);
except
Application.MessageBox('客户图样文件不存在', '提示', MB_ICONWARNING);
IdFTP1.Quit;
Exit;
end;
end
else
begin
Application.MessageBox('无法连接文件服务器', '提示', MB_ICONWARNING);
IdFTP1.Quit;
Exit;
end;
if IdFTP1.Connected then
IdFTP1.Quit;
JPStream.Position := 0;
jpg.LoadFromStream(JPStream);
Image1.Picture.Assign(jpg);
end;
end;
end;
finally
jpg.free;
JPStream.Free;
end;
end;
function TFormGetPic.SaveImage(): Boolean;
var
myStream: TADOBlobStream;
maxNo: string;
fNewFileName: string;
begin
//取文件后缀 ExtractFileExt(FilePath)
if fkeyNO = '' then
begin
fNewFileName := formatdatetime('yyyyMMddhhnnsszzz', now()) + ExtractFileExt(FilePath);
fkeyNO := fNewFileName;
end;
result := false;
try
with adoqueryImage do
begin
close;
sql.Clear;
sql.Add('select * from TP_File where WBID=' + quotedstr(trim(FMainId)));
sql.Add('and TFType=' + quotedstr(trim(FTFType)));
open;
if RecordCount <= 0 then
begin
Append;
if GetLSNo(ADOQuery1, maxNo, 'FJ', 'TP_File', 4, 1) = False then
begin
Application.MessageBox('取最大号失败!', '提示', 0);
Exit;
end;
fieldByName('TFID').AsString := maxNo;
fieldByName('WBID').AsString := FMainId;
end
else
begin
edit;
end;
fieldByName(pat1).AsString := trim(fkeyNO);
fieldByName('Filler').AsString := trim(dName);
fieldByName('TFType').AsString := trim(FTFType);
myStream := TADOBlobStream.Create(TBlobField(FieldByName(pic1)), bmWrite);
MyJpeg.Assign(Image2.Picture.Graphic);
MyJpeg.SaveToStream(myStream);
myStream.Free;
Post;
end;
if FilePath <> '' then
begin
try
IdFTP1.Host := ReadINIFileStr('SYSTEMSET.INI', 'SERVER', '服务器地址', '127.0.0.1');
IdFTP1.Username := 'three';
IdFTP1.Password := '641010';
IdFTP1.Connect();
// IdFTP1.Delete(fFlileFlag + '\' + Trim(fNewFileName));
IdFTP1.Put(FilePath, fFlileFlag + '\' + Trim(fkeyNO));
IdFTP1.Quit;
except
IdFTP1.Quit;
Application.MessageBox('上传客户图样文件失败,请检查文件服务器!', '提示', MB_ICONWARNING);
end;
end;
IdFTP1.Quit;
result := true;
except
myStream.Free;
end;
end;
procedure TFormGetPic.ToolButton1Click(Sender: TObject);
var
Ini: TIniFile;
begin
// if Twain.LoadLibrary then
// begin
// {Load source manager}
// Twain.SourceManagerLoaded := TRUE;
// {Allow user to select source}
// SelectedSource := Twain.SelectSource;
// if SelectedSource <> -1 then
// begin
// Ini := TIniFile.Create(ExtractFilePath(ParamStr(0)) + 'scanner.ini');
// try
// Ini.WriteInteger( 'SCANNER', 'Scanner', SelectedSource);
// finally
// Ini.Free;
// end;
// end {if SelectedSource <> -1}
// end
// else
// ShowMessage('未安装扫描仪');
end;
procedure TFormGetPic.ToolButton3Click(Sender: TObject);
begin
// if Twain.LoadLibrary then
// begin
// {Load source manager}
// Twain.SourceManagerLoaded := TRUE;
//
// if SelectedSource <> -1 then
// begin
// {Load source, select transference method and enable (display interface)}
// Twain.Source[SelectedSource].Loaded := TRUE;
// Twain.Source[SelectedSource].SetICapUnits(tuInches);
// Twain.Source[SelectedSource].SetImagelayoutFrame(PicLeft/25.4, PicTop/25.4, (PicLeft+PicWidth)/25.4, (PicTop+PicHeight)/25.4);
// Twain.Source[SelectedSource].SetIYResolution(200);
// Twain.Source[SelectedSource].SetIXResolution(200);
// Twain.Source[SelectedSource].TransferMode := ttmMemory;
// Twain.Source[SelectedSource].EnableSource(FALSE, TRUE);
// while Twain.Source[SelectedSource].Enabled do Application.ProcessMessages;
// end; {if SelectedSource <> -1}
//// Twain.UnloadLibrary;
// end
// else
// ShowMessage('未安装扫描仪');
end;
procedure TFormGetPic.TwainTwainAcquire(Sender: TObject; const Index: Integer; Image: TBitmap; var Cancel: Boolean);
begin
Image1.Picture.Assign(Image);
Cancel := TRUE;
CreThumb(150, 150);
SpeedButton2.Enabled := TRUE;
end;
procedure TFormGetPic.FormShow(Sender: TObject);
var
Ini: TIniFile;
begin
{ Ini := TIniFile.Create(ExtractFilePath(ParamStr(0)) + 'scanner.ini');
try
SelectedSource := Ini.ReadInteger( 'SCANNER', 'Scanner', 0);
PicLeft := Ini.ReadInteger( 'SCANNER', 'Left', 0);
PicTop := Ini.ReadInteger( 'SCANNER', 'Top', 0);
PicWidth := Ini.ReadInteger( 'SCANNER', 'Width', 100);
PicHeight := Ini.ReadInteger( 'SCANNER', 'Height', 100);
finally
Ini.Free;
end; }
Initimage();
end;
{
procedure TFormGetPic.ToolButton6Click(Sender: TObject);
var
Ini: TIniFile;
begin
FormGetPos := TFormGetPos.Create(Self);
FormGetPos.SpinEdit1.Value := PicLeft;
FormGetPos.SpinEdit2.Value := PicTop;
FormGetPos.SpinEdit3.Value := PicWidth;
FormGetPos.SpinEdit4.Value := PicHeight;
if FormGetPos.ShowModal = 1 then
begin
PicLeft := FormGetPos.SpinEdit1.Value;
PicTop := FormGetPos.SpinEdit2.Value;
PicWidth := FormGetPos.SpinEdit3.Value;
PicHeight := FormGetPos.SpinEdit4.Value;
Ini := TIniFile.Create(ExtractFilePath(ParamStr(0)) + 'scanner.ini');
try
Ini.WriteInteger( 'SCANNER', 'Left', PicLeft);
Ini.WriteInteger( 'SCANNER', 'Top', PicTop);
Ini.WriteInteger( 'SCANNER', 'Width', PicWidth);
Ini.WriteInteger( 'SCANNER', 'Height', PicHeight);
finally
Ini.Free;
end;
end;
FormGetPos.Free;
end;
}
procedure TFormGetPic.CreThumb(Width, Height: Integer);
var
Bitmap: TBitmap;
Ratio: Double;
ARect: TRect;
AHeight, AHeightOffset: Integer;
AWidth, AWidthOffset: Integer;
begin
Bitmap := TBitmap.Create;
try
Ratio := Image1.Picture.Graphic.Width / Image1.Picture.Graphic.Height;
if Ratio > 0.75 then
begin
AHeight := Round(Width / Ratio);
AHeightOffset := (Height - AHeight) div 2;
AWidth := Width;
AWidthOffset := 0;
end
else
begin
AWidth := Round(Height * Ratio);
AWidthOffset := (Width - AWidth) div 2;
AHeight := Height;
AHeightOffset := 0;
end;
Bitmap.Width := Width;
Bitmap.Height := Height;
Bitmap.Canvas.Brush.Color := clBtnFace;
Bitmap.Canvas.FillRect(Rect(0, 0, Width, Height));
// StretchDraw original image
ARect := Rect(AWidthOffset, AHeightOffset, AWidth + AWidthOffset, AHeight + AHeightOffset);
Bitmap.Canvas.StretchDraw(ARect, Image1.Picture.Graphic);
// Assign back to the Jpeg, and save to the file
Image2.Picture.Assign(Bitmap);
// MyJpeg1.Assign(Image2.Picture.Graphic);
finally
Bitmap.Free;
end;
end;
procedure TFormGetPic.FormCreate(Sender: TObject);
begin
MyJpeg := TJpegImage.Create;
// MyJpeg1 := TJpegImage.Create;
Button2.Enabled := false;
if FWidth = 0 then
FWidth := 197;
if FHeight = 0 then
FHeight := 110;
end;
procedure TFormGetPic.FormDestroy(Sender: TObject);
begin
// MyJpeg1.Free;
MyJpeg.Free;
end;
procedure TFormGetPic.Image1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
begin
ClickPos.x := X;
ClickPos.y := Y;
end;
procedure TFormGetPic.Image1MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
var
NewPos: TPoint;
begin
{The left button was pressed}
if ssLeft in Shift then
begin
{Calculate new position}
NewPos.X := Image1.Left + X - ClickPos.x;
NewPos.Y := Image1.Top + Y - ClickPos.y;
if NewPos.x + Image1.Width < ScrollBox1.Width then
NewPos.x := ScrollBox1.Width - Image1.Width;
if NewPos.y + Image1.Height < ScrollBox1.Height then
NewPos.y := ScrollBox1.Height - Image1.Height;
if NewPos.X > 0 then
NewPos.X := 0;
if NewPos.Y > 0 then
NewPos.Y := 0;
Image1.Top := NewPos.Y;
Image1.Left := NewPos.X;
end {if ssLeft in Shift}
end;
procedure TFormGetPic.SpeedButton1Click(Sender: TObject);
var
Jpeg: TJPEGImage;
begin
if OpenPictureDialog1.Execute then
begin
Image1.Top := 0;
Image1.Left := 0;
Image1.Picture.LoadFromFile(OpenPictureDialog1.FileName);
FilePath := OpenPictureDialog1.FileName;
FileName := ExtractFileName(FilePath);
// Jpeg := TJPEGImage.Create;
// Rotate90(Image1.Picture.Graphic, Jpeg);
// Image1.Picture.Assign(Jpeg);
// Jpeg.Free;
CreThumb(FWidth, FHeight);
SpeedButton2.Enabled := TRUE;
end;
end;
procedure TFormGetPic.SpeedButton2Click(Sender: TObject);
begin
if SaveImage() then
begin
ModalResult := 1;
end
else
begin
application.MessageBox('数据保存失败!', '提示信息', 0)
end;
// JPStream := TMemoryStream.Create;
// MyJPeg.Assign(Image1.Picture.Graphic);
// MyJPeg.SaveToStream(JPStream);
end;
procedure TFormGetPic.SpeedButton3Click(Sender: TObject);
begin
ModalResult := 2;
end;
procedure TFormGetPic.Button1Click(Sender: TObject);
begin
hWndC := 0;
try
hWndC := capCreateCaptureWindowA('My Own Capture Window', WS_CHILD or WS_VISIBLE, ScrollBox1.Left, ScrollBox1.Top, ScrollBox1.Width, ScrollBox1.Height, FormGetPic.Handle, 0);
if hWndC <> 0 then
begin
SendMessage(hWndC, WM_CAP_SET_CALLBACK_VIDEOSTREAM, 0, 0);
SendMessage(hWndC, WM_CAP_SET_CALLBACK_ERROR, 0, 0);
SendMessage(hWndC, WM_CAP_SET_CALLBACK_STATUSA, 0, 0);
SendMessage(hWndC, WM_CAP_DRIVER_CONNECT, 0, 0);
SendMessage(hWndC, WM_CAP_SET_SCALE, 1, 0);
SendMessage(hWndC, WM_CAP_SET_PREVIEWRATE, 66, 0);
//SendMessage(hWndC, WM_CAP_SEQUENCE_NOFILE, 1, 0);
SendMessage(hWndC, WM_CAP_SET_OVERLAY, 1, 0);
SendMessage(hWndC, WM_CAP_SET_PREVIEW, 1, 0);
Button1.Enabled := false;
Button2.Enabled := true;
end
else
begin
application.MessageBox('连接摄像头失败!', '错误信息', MB_ICONERROR);
end;
except
end;
application.ProcessMessages;
end;
procedure TFormGetPic.Button2Click(Sender: TObject);
var
sFieldName: string;
MBMP: TBitmap;
MJPG: TJpegImage;
begin
sFieldName := 'D:\抓图';
if not DirectoryExists(pchar(sFieldName)) then
CreateDirectory(pchar(sFieldName), nil);
sFieldName := sFieldName + '\' + formatdateTime('yyyyMMddhhnnss', SGetServerDateTime(ADOQuery1));
FileName := ExtractFileName(sFieldName);
if hWndC <> 0 then
begin
SendMessage(hWndC, WM_CAP_SAVEDIB, 0, longint(pchar(sFieldName + '.BMP')));
SendMessage(hWndC, WM_CAP_DRIVER_DISCONNECT, 0, 0);
hWndC := 0;
application.ProcessMessages;
Button1.Enabled := true;
Button2.Enabled := false;
try
MBMP := TBitmap.Create;
MJPG := TJpegImage.Create;
MBMP.LoadFromFile(pchar(sFieldName + '.BMP'));
MJPG.assign(MBMP);
Image1.Picture.Bitmap.Assign(MJPG);
application.ProcessMessages;
MJPG.SaveToFile(pchar(sFieldName + '.JPG'));
CreThumb(240, 180);
finally
MBMP.Free;
MJPG.Free;
if Fileexists(pchar(sFieldName + '.BMP')) then
DeleteFile(pchar(sFieldName + '.BMP'));
FilePath := sFieldName + '.JPG';
FileName := ExtractFileName(FilePath);
end;
SpeedButton2.Enabled := true;
end;
end;
procedure TFormGetPic.SpeedButton4Click(Sender: TObject);
var
MJPG: TJpegImage;
pathFile: string;
begin
if Image1.Picture.Graphic = nil then
exit;
MJPG := TJpegImage.Create;
try
SaveDialog1.FileName := FileName;
if SaveDialog1.Execute then
begin
if SaveDialog1.FileName <> '' then
begin
pathFile := trim(SaveDialog1.FileName);
if (RightStr(UPPERCASE(pathFile), 4) <> '.JPG') and (RightStr(UPPERCASE(pathFile), 5) <> '.JPEG') then
begin
pathFile := pathFile + '.JPG';
end;
MJPG.Assign(Image1.Picture.Graphic);
if fileexists(pathFile) then
begin
if application.MessageBox(pchar('文件[' + trim(pathFile) + ']已存在,是否要替换它?'), '提示信息', MB_YESNO + mb_iconinformation + MB_DEFBUTTON2) = idyes then
MJPG.SaveToFile(pathFile);
end
else
MJPG.SaveToFile(pathFile);
end;
end;
finally
MJPG.Free;
end;
end;
procedure TFormGetPic.SpeedButton5Click(Sender: TObject);
begin
try
with adoqueryImage do
begin
close;
sql.Clear;
sql.Add('select * from TP_File where WBID=' + quotedstr(trim(fkeyNo)));
open;
if RecordCount > 0 then
begin
edit;
fieldByName(pat1).Value := null;
FieldByName(pic1).Value := null;
post;
Image1.Picture.Assign(nil);
Image2.Picture.Assign(nil);
end;
end;
except
end;
end;
end.

View File

@ -0,0 +1,42 @@
-$A8
-$B-
-$C+
-$D+
-$E-
-$F-
-$G+
-$H+
-$I+
-$J-
-$K-
-$L+
-$M-
-$N+
-$O+
-$P+
-$Q-
-$R-
-$S-
-$T-
-$U-
-$V+
-$W-
-$X+
-$YD
-$Z1
-cg
-AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
-H+
-W+
-M
-$M16384,1048576
-K$00400000
-LE"c:\program files (x86)\borland\delphi7\Projects\Bpl"
-LN"c:\program files (x86)\borland\delphi7\Projects\Bpl"
-U"D:\말繫ERP"
-O"D:\말繫ERP"
-I"D:\말繫ERP"
-R"D:\말繫ERP"
-w-UNSAFE_TYPE
-w-UNSAFE_CODE
-w-UNSAFE_CAST

View File

@ -0,0 +1,138 @@
[FileVersion]
Version=7.0
[Compiler]
A=8
B=0
C=1
D=1
E=0
F=0
G=1
H=1
I=1
J=0
K=0
L=1
M=0
N=1
O=1
P=1
Q=0
R=0
S=0
T=0
U=0
V=1
W=0
X=1
Y=1
Z=1
ShowHints=1
ShowWarnings=1
UnitAliases=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
NamespacePrefix=
SymbolDeprecated=1
SymbolLibrary=1
SymbolPlatform=1
UnitLibrary=1
UnitPlatform=1
UnitDeprecated=1
HResultCompat=1
HidingMember=1
HiddenVirtual=1
Garbage=1
BoundsError=1
ZeroNilCompat=1
StringConstTruncated=1
ForLoopVarVarPar=1
TypedConstVarPar=1
AsgToTypedConst=1
CaseLabelRange=1
ForVariable=1
ConstructingAbstract=1
ComparisonFalse=1
ComparisonTrue=1
ComparingSignedUnsigned=1
CombiningSignedUnsigned=1
UnsupportedConstruct=1
FileOpen=1
FileOpenUnitSrc=1
BadGlobalSymbol=1
DuplicateConstructorDestructor=1
InvalidDirective=1
PackageNoLink=1
PackageThreadVar=1
ImplicitImport=1
HPPEMITIgnored=1
NoRetVal=1
UseBeforeDef=1
ForLoopVarUndef=1
UnitNameMismatch=1
NoCFGFileFound=1
MessageDirective=1
ImplicitVariants=1
UnicodeToLocale=1
LocaleToUnicode=1
ImagebaseMultiple=1
SuspiciousTypecast=1
PrivatePropAccessor=1
UnsafeType=0
UnsafeCode=0
UnsafeCast=0
[Linker]
MapFile=0
OutputObjs=0
ConsoleApp=1
DebugInfo=0
RemoteSymbols=0
MinStackSize=16384
MaxStackSize=1048576
ImageBase=4194304
ExeDescription=
[Directories]
OutputDir=
UnitOutputDir=
PackageDLLOutputDir=
PackageDCPOutputDir=
SearchPath=D:\富通ERP
Packages=vcl;rtl;vclx;indy;inet;xmlrtl;vclie;inetdbbde;inetdbxpress;dbrtl;dsnap;dsnapcon;vcldb;soaprtl;VclSmp;dbexpress;dbxcds;bdertl;vcldbx;webdsnap;websnap;adortl;ibxpress;teeui;teedb;tee;dss;visualclx;visualdbclx;vclactnband;vclshlctrls;IntrawebDB_50_70;Intraweb_50_70;dclOffice2k;Rave50CLX;Rave50VCL
Conditionals=
DebugSourceDirs=
UsePackages=0
[Parameters]
RunParams=
HostApplication=D:\凌志超开发代码\项目代码\振永\客户供应商管理(Company.dll)\testDll.exe
Launcher=
UseLauncher=0
DebugCWD=
[Language]
ActiveLang=
ProjectLang=
RootDir=
[Version Info]
IncludeVerInfo=0
AutoIncBuild=0
MajorVer=1
MinorVer=0
Release=0
Build=0
Debug=0
PreRelease=0
Special=0
Private=0
DLL=0
Locale=2052
CodePage=936
[Version Info Keys]
CompanyName=
FileDescription=
FileVersion=1.0.0.0
InternalName=
LegalCopyright=
LegalTrademarks=
OriginalFilename=
ProductName=
ProductVersion=1.0.0.0
Comments=
[Excluded Packages]
c:\program files\borland\delphi7\Bin\DBWEBXPRT.BPL=Borland Web Wizard Package

View File

@ -0,0 +1,62 @@
library Company;
uses
SysUtils,
classes,
forms,
WinTypes,
WinProcs,
midaslib,
U_GetDllForm in 'U_GetDllForm.pas',
U_ModuleNote in 'U_ModuleNote.pas' {frmModuleNote},
U_DataLink in 'U_DataLink.pas' {DataLink_Company: TDataModule},
U_ZDYHelpSel in 'U_ZDYHelpSel.pas' {frmZDYHelpSel},
U_iniParam in 'U_iniParam.pas',
U_BaseInput in '..\..\..\public10\design\U_BaseInput.pas' {frmBaseInput},
U_BaseList in '..\..\..\public10\design\U_BaseList.pas' {frmBaseList},
U_cxGridCustomCss in '..\..\..\public10\design\U_cxGridCustomCss.pas',
U_globalVar in '..\..\..\public10\design\U_globalVar.pas',
U_WindowFormdesign in '..\..\..\public10\design\U_WindowFormdesign.pas',
U_RTFun in '..\..\..\public10\ThreeFun\Fun\U_RTFun.pas',
U_Factory in 'U_Factory.pas' {frmFactory},
U_MGFactory in 'U_MGFactory.pas' {frmMGFactory},
U_CustInput in 'U_CustInput.pas' {frmCustInput},
U_BaseHelp in '..\..\..\public10\design\U_BaseHelp.pas' {frmBaseHelp},
U_EmployeeList in 'U_EmployeeList.pas' {frmEmployeeList},
U_UserSel in '..\A00通用窗体\U_UserSel.pas' {frmUserSel},
U_ClothInfoSel in '..\A00通用窗体\U_ClothInfoSel.pas' {frmClothInfoSel},
U_CompanySel in '..\A00通用窗体\U_CompanySel.pas' {frmCompanySel},
U_AttachmentUpload in '..\A00通用窗体\U_AttachmentUpload.pas' {frmFjList_RZ},
U_CompressionFun in '..\..\..\public10\ThreeFun\Fun\U_CompressionFun.pas',
U_BankList in 'U_BankList.pas' {frmBankList},
U_LabelMapSet in '..\A00通用窗体\U_LabelMapSet.pas' {frmLabelMapSet},
U_LabelPrint in '..\A00通用窗体\U_LabelPrint.pas' {frmLabelPrint},
U_BaseDataLink in '..\..\..\public10\design\U_BaseDataLink.pas' {BaseDataLink: TDataModule},
uSZHN_JSON in '..\..\..\public10\ThreeFun\Fun\uSZHN_JSON.pas';
{$R *.res}
procedure DllEnterPoint(dwReason: DWORD); far; stdcall;
begin
DLLProc := @DLLEnterPoint;
DllEnterPoint(DLL_PROCESS_ATTACH);
end;
procedure DLLUnloadProc(Reason: Integer); register;
begin
// if (Reason = DLL_PROCESS_DETACH) or (Reason=DLL_THREAD_DETACH) then
// Application:=NewDllApp;
end;
exports
GetDllForm;
begin
try
NewDllApp := Application;
DLLProc := @DLLUnloadProc;
except
end;
end.

View File

@ -0,0 +1,942 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{E16427F3-666C-4A0D-9F4B-79271477F72C}</ProjectGuid>
<MainSource>Company.dpr</MainSource>
<Base>True</Base>
<Config Condition="'$(Config)'==''">Debug</Config>
<TargetedPlatforms>38017</TargetedPlatforms>
<AppType>Library</AppType>
<FrameworkType>VCL</FrameworkType>
<ProjectVersion>19.2</ProjectVersion>
<Platform Condition="'$(Platform)'==''">Win32</Platform>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Android64' and '$(Base)'=='true') or '$(Base_Android64)'!=''">
<Base_Android64>true</Base_Android64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSDevice64' and '$(Base)'=='true') or '$(Base_iOSDevice64)'!=''">
<Base_iOSDevice64>true</Base_iOSDevice64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Base)'=='true') or '$(Base_Win32)'!=''">
<Base_Win32>true</Base_Win32>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win64' and '$(Base)'=='true') or '$(Base_Win64)'!=''">
<Base_Win64>true</Base_Win64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Release' or '$(Cfg_1)'!=''">
<Cfg_1>true</Cfg_1>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Debug' or '$(Cfg_2)'!=''">
<Cfg_2>true</Cfg_2>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Android64' and '$(Cfg_2)'=='true') or '$(Cfg_2_Android64)'!=''">
<Cfg_2_Android64>true</Cfg_2_Android64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSDevice64' and '$(Cfg_2)'=='true') or '$(Cfg_2_iOSDevice64)'!=''">
<Cfg_2_iOSDevice64>true</Cfg_2_iOSDevice64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='OSX64' and '$(Cfg_2)'=='true') or '$(Cfg_2_OSX64)'!=''">
<Cfg_2_OSX64>true</Cfg_2_OSX64>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Cfg_2)'=='true') or '$(Cfg_2_Win32)'!=''">
<Cfg_2_Win32>true</Cfg_2_Win32>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Base)'!=''">
<DCC_E>false</DCC_E>
<DCC_F>false</DCC_F>
<DCC_K>false</DCC_K>
<DCC_N>true</DCC_N>
<DCC_S>false</DCC_S>
<DCC_ImageBase>00400000</DCC_ImageBase>
<DCC_DebugInformation>1</DCC_DebugInformation>
<DCC_SymbolReferenceInfo>1</DCC_SymbolReferenceInfo>
<DCC_UnitSearchPath>D:\富通ERP;$(DCC_UnitSearchPath)</DCC_UnitSearchPath>
<DCC_UsePackage>vcl;rtl;vclx;indy;inet;xmlrtl;vclie;inetdbbde;inetdbxpress;dbrtl;dsnap;dsnapcon;vcldb;soaprtl;VclSmp;dbexpress;dbxcds;bdertl;vcldbx;webdsnap;websnap;adortl;ibxpress;teeui;teedb;tee;dss;visualclx;visualdbclx;vclactnband;vclshlctrls;IntrawebDB_50_70;Intraweb_50_70;dclOffice2k;Rave50CLX;Rave50VCL;$(DCC_UsePackage)</DCC_UsePackage>
<GenDll>true</GenDll>
<SanitizedProjectName>Company</SanitizedProjectName>
<DCC_Namespace>Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;System;Xml;Data;Datasnap;Web;Soap;Winapi;Data.Win;$(DCC_Namespace)</DCC_Namespace>
<VerInfo_Locale>2052</VerInfo_Locale>
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Android64)'!=''">
<Android_LauncherIcon192>$(BDS)\bin\Artwork\Android\FM_LauncherIcon_192x192.png</Android_LauncherIcon192>
<EnabledSysJars>android-support-v4.dex.jar;cloud-messaging.dex.jar;com-google-android-gms.play-services-ads-base.17.2.0.dex.jar;com-google-android-gms.play-services-ads-identifier.16.0.0.dex.jar;com-google-android-gms.play-services-ads-lite.17.2.0.dex.jar;com-google-android-gms.play-services-ads.17.2.0.dex.jar;com-google-android-gms.play-services-analytics-impl.16.0.8.dex.jar;com-google-android-gms.play-services-analytics.16.0.8.dex.jar;com-google-android-gms.play-services-base.16.0.1.dex.jar;com-google-android-gms.play-services-basement.16.2.0.dex.jar;com-google-android-gms.play-services-gass.17.2.0.dex.jar;com-google-android-gms.play-services-identity.16.0.0.dex.jar;com-google-android-gms.play-services-maps.16.1.0.dex.jar;com-google-android-gms.play-services-measurement-base.16.4.0.dex.jar;com-google-android-gms.play-services-measurement-sdk-api.16.4.0.dex.jar;com-google-android-gms.play-services-stats.16.0.1.dex.jar;com-google-android-gms.play-services-tagmanager-v4-impl.16.0.8.dex.jar;com-google-android-gms.play-services-tasks.16.0.1.dex.jar;com-google-android-gms.play-services-wallet.16.0.1.dex.jar;com-google-firebase.firebase-analytics.16.4.0.dex.jar;com-google-firebase.firebase-common.16.1.0.dex.jar;com-google-firebase.firebase-iid-interop.16.0.1.dex.jar;com-google-firebase.firebase-iid.17.1.1.dex.jar;com-google-firebase.firebase-measurement-connector.17.0.1.dex.jar;com-google-firebase.firebase-messaging.17.5.0.dex.jar;fmx.dex.jar;google-play-billing.dex.jar;google-play-licensing.dex.jar</EnabledSysJars>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_iOSDevice64)'!=''">
<iOS_AppStore1024>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_1024x1024.png</iOS_AppStore1024>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win32)'!=''">
<DCC_Namespace>System.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace)</DCC_Namespace>
<BT_BuildType>Debug</BT_BuildType>
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
<VerInfo_Keys>CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName)</VerInfo_Keys>
<VerInfo_Locale>1033</VerInfo_Locale>
<Icon_MainIcon>Company_Icon.ico</Icon_MainIcon>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win64)'!=''">
<Icon_MainIcon>Company_Icon.ico</Icon_MainIcon>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1)'!=''">
<DCC_Define>RELEASE;$(DCC_Define)</DCC_Define>
<DCC_DebugInformation>0</DCC_DebugInformation>
<DCC_LocalDebugSymbols>false</DCC_LocalDebugSymbols>
<DCC_SymbolReferenceInfo>0</DCC_SymbolReferenceInfo>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2)'!=''">
<DCC_Define>DEBUG;$(DCC_Define)</DCC_Define>
<DCC_Optimize>false</DCC_Optimize>
<DCC_GenerateStackFrames>true</DCC_GenerateStackFrames>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_Android64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_iOSDevice64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_OSX64)'!=''">
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_Win32)'!=''">
<Debugger_HostApplication>D:\Dp10Repo\项目代码\D10gmbitao\A01基础公司管理\testDll.exe</Debugger_HostApplication>
<VerInfo_Keys>CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName)</VerInfo_Keys>
</PropertyGroup>
<ItemGroup>
<DelphiCompile Include="$(MainSource)">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="U_GetDllForm.pas"/>
<DCCReference Include="U_ModuleNote.pas">
<Form>frmModuleNote</Form>
</DCCReference>
<DCCReference Include="U_DataLink.pas">
<Form>DataLink_Company</Form>
<DesignClass>TDataModule</DesignClass>
</DCCReference>
<DCCReference Include="U_ZDYHelpSel.pas">
<Form>frmZDYHelpSel</Form>
</DCCReference>
<DCCReference Include="U_iniParam.pas"/>
<DCCReference Include="..\..\..\public10\design\U_BaseInput.pas">
<Form>frmBaseInput</Form>
</DCCReference>
<DCCReference Include="..\..\..\public10\design\U_BaseList.pas">
<Form>frmBaseList</Form>
</DCCReference>
<DCCReference Include="..\..\..\public10\design\U_cxGridCustomCss.pas"/>
<DCCReference Include="..\..\..\public10\design\U_globalVar.pas"/>
<DCCReference Include="..\..\..\public10\design\U_WindowFormdesign.pas"/>
<DCCReference Include="..\..\..\public10\ThreeFun\Fun\U_RTFun.pas"/>
<DCCReference Include="U_Factory.pas">
<Form>frmFactory</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="U_MGFactory.pas">
<Form>frmMGFactory</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="U_CustInput.pas">
<Form>frmCustInput</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\..\..\public10\design\U_BaseHelp.pas">
<Form>frmBaseHelp</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="U_EmployeeList.pas">
<Form>frmEmployeeList</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_UserSel.pas">
<Form>frmUserSel</Form>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_ClothInfoSel.pas">
<Form>frmClothInfoSel</Form>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_CompanySel.pas">
<Form>frmCompanySel</Form>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_AttachmentUpload.pas">
<Form>frmFjList_RZ</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\..\..\public10\ThreeFun\Fun\U_CompressionFun.pas"/>
<DCCReference Include="U_BankList.pas">
<Form>frmBankList</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_LabelMapSet.pas">
<Form>frmLabelMapSet</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\A00通用窗体\U_LabelPrint.pas">
<Form>frmLabelPrint</Form>
<FormType>dfm</FormType>
</DCCReference>
<DCCReference Include="..\..\..\public10\design\U_BaseDataLink.pas">
<Form>BaseDataLink</Form>
<FormType>dfm</FormType>
<DesignClass>TDataModule</DesignClass>
</DCCReference>
<DCCReference Include="..\..\..\public10\ThreeFun\Fun\uSZHN_JSON.pas"/>
<BuildConfiguration Include="Debug">
<Key>Cfg_2</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
<BuildConfiguration Include="Base">
<Key>Base</Key>
</BuildConfiguration>
<BuildConfiguration Include="Release">
<Key>Cfg_1</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Delphi.Personality.12</Borland.Personality>
<Borland.ProjectType/>
<BorlandProject>
<Delphi.Personality>
<Source>
<Source Name="MainSource">Company.dpr</Source>
</Source>
</Delphi.Personality>
<Platforms>
<Platform value="Android64">True</Platform>
<Platform value="iOSDevice64">True</Platform>
<Platform value="Linux64">True</Platform>
<Platform value="OSX64">True</Platform>
<Platform value="Win32">True</Platform>
<Platform value="Win64">False</Platform>
</Platforms>
<Deployment Version="3">
<DeployFile LocalName="Company.dll" Configuration="Debug" Class="ProjectOutput">
<Platform Name="Win32">
<RemoteName>Company.dll</RemoteName>
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployClass Name="AdditionalDebugSymbols">
<Platform Name="OSX32">
<Operation>1</Operation>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidClassesDexFile">
<Platform Name="Android">
<RemoteDir>classes</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>classes</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidFileProvider">
<Platform Name="Android">
<RemoteDir>res\xml</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\xml</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidGDBServer">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeArmeabiFile">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>library\lib\armeabi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeArmeabiv7aFile">
<Platform Name="Android64">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeMipsFile">
<Platform Name="Android">
<RemoteDir>library\lib\mips</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>library\lib\mips</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidServiceOutput">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>library\lib\arm64-v8a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidServiceOutput_Android32">
<Platform Name="Android64">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashImageDef">
<Platform Name="Android">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashStyles">
<Platform Name="Android">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashStylesV21">
<Platform Name="Android">
<RemoteDir>res\values-v21</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\values-v21</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_Colors">
<Platform Name="Android">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_DefaultAppIcon">
<Platform Name="Android">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon144">
<Platform Name="Android">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon192">
<Platform Name="Android">
<RemoteDir>res\drawable-xxxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xxxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon36">
<Platform Name="Android">
<RemoteDir>res\drawable-ldpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-ldpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon48">
<Platform Name="Android">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon72">
<Platform Name="Android">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon96">
<Platform Name="Android">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon24">
<Platform Name="Android">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon36">
<Platform Name="Android">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon48">
<Platform Name="Android">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon72">
<Platform Name="Android">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_NotificationIcon96">
<Platform Name="Android">
<RemoteDir>res\drawable-xxxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xxxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage426">
<Platform Name="Android">
<RemoteDir>res\drawable-small</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-small</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage470">
<Platform Name="Android">
<RemoteDir>res\drawable-normal</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-normal</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage640">
<Platform Name="Android">
<RemoteDir>res\drawable-large</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-large</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage960">
<Platform Name="Android">
<RemoteDir>res\drawable-xlarge</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\drawable-xlarge</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_Strings">
<Platform Name="Android">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DebugSymbols">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<Operation>1</Operation>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DependencyFramework">
<Platform Name="OSX32">
<Operation>1</Operation>
<Extensions>.framework</Extensions>
</Platform>
<Platform Name="OSX64">
<Operation>1</Operation>
<Extensions>.framework</Extensions>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DependencyModule">
<Platform Name="OSX32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.dll;.bpl</Extensions>
</Platform>
</DeployClass>
<DeployClass Required="true" Name="DependencyPackage">
<Platform Name="iOSDevice32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.bpl</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="File">
<Platform Name="Android">
<Operation>0</Operation>
</Platform>
<Platform Name="Android64">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>0</Operation>
</Platform>
<Platform Name="OSX32">
<Operation>0</Operation>
</Platform>
<Platform Name="OSX64">
<Operation>0</Operation>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iOS_AppStore1024">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_AppIcon152">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_AppIcon167">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch2x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_LaunchDark2x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Notification40">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Setting58">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_SpotLight80">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_AppIcon120">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_AppIcon180">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch2x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch3x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_LaunchDark2x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_LaunchDark3x">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Notification40">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Notification60">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Setting58">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Setting87">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Spotlight120">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Spotlight80">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectAndroidManifest">
<Platform Name="Android">
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSDeviceDebug">
<Platform Name="iOSDevice32">
<RemoteDir>..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSEntitlements"/>
<DeployClass Name="ProjectiOSInfoPList"/>
<DeployClass Name="ProjectiOSLaunchScreen"/>
<DeployClass Name="ProjectiOSResource">
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOSXDebug"/>
<DeployClass Name="ProjectOSXEntitlements"/>
<DeployClass Name="ProjectOSXInfoPList"/>
<DeployClass Name="ProjectOSXResource">
<Platform Name="OSX32">
<RemoteDir>Contents\Resources</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="OSX64">
<RemoteDir>Contents\Resources</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Required="true" Name="ProjectOutput">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Android64">
<RemoteDir>library\lib\arm64-v8a</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="Linux64">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX64">
<Operation>1</Operation>
</Platform>
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOutput_Android32">
<Platform Name="Android64">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectUWPManifest">
<Platform Name="Win32">
<Operation>1</Operation>
</Platform>
<Platform Name="Win64">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="UWP_DelphiLogo150">
<Platform Name="Win32">
<RemoteDir>Assets</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Win64">
<RemoteDir>Assets</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="UWP_DelphiLogo44">
<Platform Name="Win32">
<RemoteDir>Assets</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="Win64">
<RemoteDir>Assets</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<ProjectRoot Platform="iOSDevice64" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Win64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSDevice32" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Linux64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="Win32" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="OSX32" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="Android" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="OSX64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSSimulator" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Android64" Name="$(PROJECTNAME)"/>
</Deployment>
</BorlandProject>
<ProjectFileVersion>12</ProjectFileVersion>
</ProjectExtensions>
<Import Project="$(BDS)\Bin\CodeGear.Delphi.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Delphi.Targets')"/>
<Import Project="$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj" Condition="Exists('$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj')"/>
<Import Project="$(MSBuildProjectName).deployproj" Condition="Exists('$(MSBuildProjectName).deployproj')"/>
</Project>

View File

@ -0,0 +1,111 @@
<?xml version="1.0" encoding="utf-8"?>
<BorlandProject>
<Transactions>
<Transaction>1899-12-30 00:00:00.000.140,=D:\Dp10Repo\项目代码\阔和\A00通用窗体\U_LabelMapSet.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.449,=D:\Dp10Repo\项目代码\阔和\A00通用窗体\U_LabelMapSet.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.558,=D:\Dp10Repo\项目代码\阔和\A00通用窗体\U_LabelMapSet.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.967,D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_CustInput.pas=D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_FactoryInput.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.853,D:\Dp10Repo\项目代码\阔和\A00通用窗体\U_LabelMapSet.pas=</Transaction>
<Transaction>1899-12-30 00:00:00.000.591,=D:\Dp10Repo\项目代码\阔和\A00通用窗体\U_LabelMapSet.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.744,D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_Company.dfm=D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_Customer.dfm</Transaction>
<Transaction>1899-12-30 00:00:00.000.921,D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_Company.dfm=D:\Dp10Repo\项目代码\鹏华\员工管理(StaffManage.dll)\U_CompanySel.dfm</Transaction>
<Transaction>1899-12-30 00:00:00.000.402,=D:\Dp10Repo\public10\design\U_BaseDataLink.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.441,D:\Dp10Repo\项目代码\阔和\A00通用窗体\U_LabelMapSet.pas=</Transaction>
<Transaction>1899-12-30 00:00:00.000.411,D:\Dp10Repo\项目代码\RTBasics\A01基础公司管理\U_YGSel.pas=</Transaction>
<Transaction>1899-12-30 00:00:00.000.033,D:\Dp10Repo\项目代码\瑜量\客户供应商管理(Company.dll)\U_ZDYHelp.pas=D:\Dp10Repo\项目代码\瑜量\客户供应商管理(Company.dll)\U_YGSel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.033,D:\Dp10Repo\项目代码\瑜量\客户供应商管理(Company.dll)\U_ZDYHelp.dfm=D:\Dp10Repo\项目代码\瑜量\客户供应商管理(Company.dll)\U_YGSel.dfm</Transaction>
<Transaction>1899-12-30 00:00:00.000.967,D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_CustInput.dfm=D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_FactoryInput.dfm</Transaction>
<Transaction>1899-12-30 00:00:00.000.744,D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_Company.pas=D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_Customer.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.531,=D:\Dp10Repo\public10\ThreeFun\Fun\U_CompressionFun.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.294,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_LbaelMapSet.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.342,=D:\Dp10Repo\项目代码\RTBasics\A00通用窗体\U_AttachmentUpload.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.076,D:\Dp10Repo\项目代码\RTBasics\A01基础公司管理\U_ZdyAttachGYS.pas=</Transaction>
<Transaction>1899-12-30 00:00:00.000.525,=D:\Dp10Repo\项目代码\RTBasics\A01基础公司管理\U_BankList.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.169,=D:\Dp10Repo\项目代码\阔和\A00通用窗体\U_LabelPrint.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.333,=D:\Dp10Repo\public10\design\U_BaseHelp.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.921,D:\Dp10Repo\项目代码\鹏华\客户供应商管理(Company.dll)\U_Company.pas=D:\Dp10Repo\项目代码\鹏华\员工管理(StaffManage.dll)\U_CompanySel.pas</Transaction>
<Transaction>1899-12-30 00:00:00.000.956,=D:\Dp10Repo\项目代码\RTBasics\A01基础公司管理\U_EmployeeList.pas</Transaction>
<Transaction>2025-03-20 14:16:07.481,=D:\Dp10Repo\public10\ThreeFun\Fun\uSZHN_JSON.pas</Transaction>
</Transactions>
<ProjectSortOrder AutoSort="0" SortType="0">
<File Path="android-support-v4.dex.jar"/>
<File Path="cloud-messaging.dex.jar"/>
<File Path="com-google-android-gms.play-services-ads-base.17.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-ads-identifier.16.0.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-ads-lite.17.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-ads.17.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-analytics-impl.16.0.8.dex.jar"/>
<File Path="com-google-android-gms.play-services-analytics.16.0.8.dex.jar"/>
<File Path="com-google-android-gms.play-services-base.16.0.1.dex.jar"/>
<File Path="com-google-android-gms.play-services-basement.16.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-gass.17.2.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-identity.16.0.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-maps.16.1.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-measurement-base.16.4.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-measurement-sdk-api.16.4.0.dex.jar"/>
<File Path="com-google-android-gms.play-services-stats.16.0.1.dex.jar"/>
<File Path="com-google-android-gms.play-services-tagmanager-v4-impl.16.0.8.dex.jar"/>
<File Path="com-google-android-gms.play-services-tasks.16.0.1.dex.jar"/>
<File Path="com-google-android-gms.play-services-wallet.16.0.1.dex.jar"/>
<File Path="com-google-firebase.firebase-analytics.16.4.0.dex.jar"/>
<File Path="com-google-firebase.firebase-common.16.1.0.dex.jar"/>
<File Path="com-google-firebase.firebase-iid-interop.16.0.1.dex.jar"/>
<File Path="com-google-firebase.firebase-iid.17.1.1.dex.jar"/>
<File Path="com-google-firebase.firebase-measurement-connector.17.0.1.dex.jar"/>
<File Path="com-google-firebase.firebase-messaging.17.5.0.dex.jar"/>
<File Path="fmx.dex.jar"/>
<File Path="google-play-billing.dex.jar"/>
<File Path="google-play-licensing.dex.jar"/>
<File Path="..\..\D10gmbitao"/>
<File Path="..\A00通用窗体"/>
<File Path="..\A00通用窗体\U_AttachmentUpload.pas"/>
<File Path="..\A00通用窗体\U_AttachmentUpload.dfm"/>
<File Path="..\A00通用窗体\U_ClothInfoSel.pas"/>
<File Path="..\A00通用窗体\U_ClothInfoSel.dfm"/>
<File Path="..\A00通用窗体\U_CompanySel.pas"/>
<File Path="..\A00通用窗体\U_CompanySel.dfm"/>
<File Path="..\A00通用窗体\U_UserSel.pas"/>
<File Path="..\A00通用窗体\U_UserSel.dfm"/>
<File Path="..\A00通用窗体\U_LabelPrint.pas"/>
<File Path="..\A00通用窗体\U_LabelPrint.dfm"/>
<File Path="..\A00通用窗体\U_LabelMapSet.pas"/>
<File Path="..\A00通用窗体\U_LabelMapSet.dfm"/>
<File Path="D:\Dp10Repo"/>
<File Path="..\..\..\public10"/>
<File Path="..\..\..\public10\design"/>
<File Path="..\..\..\public10\design\U_BaseHelp.pas"/>
<File Path="..\..\..\public10\design\U_BaseHelp.dfm"/>
<File Path="..\..\..\public10\design\U_BaseInput.pas"/>
<File Path="..\..\..\public10\design\U_BaseInput.dfm"/>
<File Path="..\..\..\public10\design\U_BaseList.pas"/>
<File Path="..\..\..\public10\design\U_BaseList.dfm"/>
<File Path="..\..\..\public10\design\U_cxGridCustomCss.pas"/>
<File Path="..\..\..\public10\design\U_globalVar.pas"/>
<File Path="..\..\..\public10\design\U_WindowFormdesign.pas"/>
<File Path="..\..\..\public10\design\U_BaseDataLink.pas"/>
<File Path="..\..\..\public10\design\U_BaseDataLink.dfm"/>
<File Path="..\..\..\public10\ThreeFun"/>
<File Path="..\..\..\public10\ThreeFun\Fun"/>
<File Path="..\..\..\public10\ThreeFun\Fun\U_CompressionFun.pas"/>
<File Path="..\..\..\public10\ThreeFun\Fun\U_RTFun.pas"/>
<File Path="..\..\..\public10\ThreeFun\Fun\uSZHN_JSON.pas"/>
<File Path="U_CustInput.pas"/>
<File Path="U_CustInput.dfm"/>
<File Path="U_DataLink.pas"/>
<File Path="U_DataLink.dfm"/>
<File Path="U_EmployeeList.pas"/>
<File Path="U_EmployeeList.dfm"/>
<File Path="U_Factory.pas"/>
<File Path="U_Factory.dfm"/>
<File Path="U_GetDllForm.pas"/>
<File Path="U_iniParam.pas"/>
<File Path="U_MGFactory.pas"/>
<File Path="U_MGFactory.dfm"/>
<File Path="U_ModuleNote.pas"/>
<File Path="U_ModuleNote.dfm"/>
<File Path="U_ZDYHelpSel.pas"/>
<File Path="U_ZDYHelpSel.dfm"/>
<File Path="U_BankList.pas"/>
<File Path="U_BankList.dfm"/>
</ProjectSortOrder>
</BorlandProject>

Binary file not shown.

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 766 B

View File

@ -0,0 +1,2 @@
<?xml version="1.0"?>
<TgConfig Version="3" SubLevelDisabled="False" />

View File

@ -0,0 +1,3 @@
[.ShellClassInfo]
IconFile=C:\Program Files (x86)\360\360WangPan\new_desktop_win7.ico
IconIndex=0

View File

@ -0,0 +1,4 @@
[生产车间配置]
卷条码机台标志=99
成品DLL文件=CYZZ.dll
成品DLL调用号=11

View File

@ -0,0 +1,7 @@
[FILEPATH]
FileClass=YP,AA,BB,HT
YP=D:\YP
AA=D:\AA
BB=D:\BB
HT=D:\HT
OTHER=D:\OTHER

View File

@ -0,0 +1,7 @@
[系统配置]
串口号=com1
波特率=9600
校验位=0
数据位=8
停止位=0
频率=100

View File

@ -0,0 +1,7 @@
[系统配置]
串口号=com2
波特率=1200
校验位=0
数据位=8
停止位=0
频率=100

View File

View File

@ -0,0 +1,23 @@
#------------------------------------------------------------------------------
VERSION = BWS.01
#------------------------------------------------------------------------------
!ifndef ROOT
ROOT = $(MAKEDIR)\..
!endif
#------------------------------------------------------------------------------
MAKE = $(ROOT)\bin\make.exe -$(MAKEFLAGS) -f$**
DCC = $(ROOT)\bin\dcc32.exe $**
BRCC = $(ROOT)\bin\brcc32.exe $**
#------------------------------------------------------------------------------
PROJECTS = testDll.exe ProductPrice.dll
#------------------------------------------------------------------------------
default: $(PROJECTS)
#------------------------------------------------------------------------------
testDll.exe: testDll.dpr
$(DCC)
ProductPrice.dll: ProductPrice.dpr
$(DCC)

View File

@ -0,0 +1,48 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{D9FA124D-0998-4743-82B8-CA82CDC074A3}</ProjectGuid>
</PropertyGroup>
<ItemGroup>
<Projects Include="Company.dproj">
<Dependencies/>
</Projects>
<Projects Include="testDll.dproj">
<Dependencies/>
</Projects>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Default.Personality.12</Borland.Personality>
<Borland.ProjectType/>
<BorlandProject>
<Default.Personality/>
</BorlandProject>
</ProjectExtensions>
<Target Name="Company">
<MSBuild Projects="Company.dproj"/>
</Target>
<Target Name="Company:Clean">
<MSBuild Projects="Company.dproj" Targets="Clean"/>
</Target>
<Target Name="Company:Make">
<MSBuild Projects="Company.dproj" Targets="Make"/>
</Target>
<Target Name="testDll">
<MSBuild Projects="testDll.dproj"/>
</Target>
<Target Name="testDll:Clean">
<MSBuild Projects="testDll.dproj" Targets="Clean"/>
</Target>
<Target Name="testDll:Make">
<MSBuild Projects="testDll.dproj" Targets="Make"/>
</Target>
<Target Name="Build">
<CallTarget Targets="Company;testDll"/>
</Target>
<Target Name="Clean">
<CallTarget Targets="Company:Clean;testDll:Clean"/>
</Target>
<Target Name="Make">
<CallTarget Targets="Company:Make;testDll:Make"/>
</Target>
<Import Project="$(BDS)\Bin\CodeGear.Group.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Group.Targets')"/>
</Project>

View File

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<BorlandProject>
<Transactions/>
<Default.Personality>
<Projects ActiveProject="D:\Dp10Repo\项目代码\D10gmbitao\A01基础公司管理\Company.dproj"/>
</Default.Personality>
</BorlandProject>

View File

@ -0,0 +1,2 @@
<?xml version="1.0"?>
<TgConfig Version="3" SubLevelDisabled="False" />

View File

@ -0,0 +1,6 @@
[SERVER]
服务器地址=101.132.143.144
服务器地址类型=2002
是否自动更新=1
软件名称=睿特版本库
登陆标题=sss

View File

@ -0,0 +1,270 @@
inherited frmBankList: TfrmBankList
Left = 297
Top = 109
Caption = #38134#34892#36134#25143#31649#29702
ClientHeight = 562
ClientWidth = 1183
KeyPreview = True
ExplicitWidth = 1199
ExplicitHeight = 601
PixelsPerInch = 96
TextHeight = 12
object ToolBar1: TToolBar [0]
Tag = 1
Left = 0
Top = 0
Width = 1183
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 91
Caption = 'ToolBar1'
Color = clSkyBlue
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ShowCaptions = True
TabOrder = 0
object TBRafresh: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #21047#26032
ImageIndex = 1
OnClick = TBRafreshClick
end
object ToolButton2: TToolButton
Left = 71
Top = 0
AutoSize = True
Caption = #36807#28388
ImageIndex = 0
OnClick = ToolButton2Click
end
object btnok: TToolButton
Left = 142
Top = 0
AutoSize = True
Caption = #36873#25321
ImageIndex = 12
OnClick = btnokClick
end
object btnadd: TToolButton
Left = 213
Top = 0
AutoSize = True
Caption = #22686#34892
ImageIndex = 2
OnClick = btnaddClick
end
object btndel: TToolButton
Left = 284
Top = 0
AutoSize = True
Caption = #21024#34892
ImageIndex = 6
OnClick = btndelClick
end
object ToolButton1: TToolButton
Left = 355
Top = 0
AutoSize = True
Caption = #20445#23384#26684#24335
ImageIndex = 16
OnClick = ToolButton1Click
end
object TBClose: TToolButton
Left = 450
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object cxGrid2: TcxGrid [1]
Left = 0
Top = 81
Width = 1183
Height = 481
Align = alClient
PopupMenu = PopupMenu1
TabOrder = 2
object Tv2: TcxGridDBTableView
Navigator.Buttons.CustomButtons = <>
Navigator.Buttons.Delete.Enabled = False
Navigator.Buttons.Delete.Visible = False
DataController.DataSource = DS_1
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <
item
Kind = skSum
end
item
Kind = skSum
end
item
Kind = skSum
end
item
Kind = skSum
end
item
Kind = skSum
end
item
Kind = skSum
end>
DataController.Summary.SummaryGroups = <>
OptionsCustomize.ColumnFiltering = False
OptionsData.Deleting = False
OptionsData.DeletingConfirmation = False
OptionsView.Footer = True
OptionsView.GroupByBox = False
Styles.Header = DataLink_Company.Default
object v2Column1: TcxGridDBColumn
Caption = #24207#21495
DataBinding.FieldName = 'SerialNo'
PropertiesClassName = 'TcxTextEditProperties'
Properties.OnEditValueChanged = v2Column1PropertiesEditValueChanged
HeaderAlignmentHorz = taCenter
Width = 50
end
object Tv2Column3: TcxGridDBColumn
Caption = #21517#31216
DataBinding.FieldName = 'BankName'
PropertiesClassName = 'TcxTextEditProperties'
Properties.OnEditValueChanged = v2Column8PropertiesEditValueChanged
HeaderAlignmentHorz = taCenter
Width = 107
end
object Tv2Column4: TcxGridDBColumn
Caption = #21345#21495
DataBinding.FieldName = 'BankCardNo'
PropertiesClassName = 'TcxTextEditProperties'
Properties.OnEditValueChanged = v2Column8PropertiesEditValueChanged
HeaderAlignmentHorz = taCenter
Width = 150
end
object Tv2Column1: TcxGridDBColumn
Caption = #24065#31181
DataBinding.FieldName = 'Currency'
PropertiesClassName = 'TcxComboBoxProperties'
Properties.DropDownListStyle = lsFixedList
Properties.Items.Strings = (
#165
'$'
#8364)
Properties.OnEditValueChanged = v2Column8PropertiesEditValueChanged
HeaderAlignmentHorz = taCenter
Width = 85
end
object Tv2Column5: TcxGridDBColumn
Caption = #24320#25143#34892
DataBinding.FieldName = 'BankDeposit'
PropertiesClassName = 'TcxTextEditProperties'
Properties.OnEditValueChanged = v2Column8PropertiesEditValueChanged
HeaderAlignmentHorz = taCenter
Width = 112
end
object Tv2Column6: TcxGridDBColumn
Caption = #34892#21495
DataBinding.FieldName = 'BankNo'
PropertiesClassName = 'TcxTextEditProperties'
Properties.OnEditValueChanged = v2Column8PropertiesEditValueChanged
HeaderAlignmentHorz = taCenter
Width = 133
end
end
object cxGridLevel1: TcxGridLevel
GridView = Tv2
end
end
object Panel1: TPanel [2]
Left = 0
Top = 38
Width = 1183
Height = 43
Align = alTop
BevelInner = bvRaised
BevelOuter = bvLowered
Color = clSkyBlue
TabOrder = 1
object Label1: TLabel
Left = 66
Top = 15
Width = 24
Height = 12
Caption = #21517#31216
end
object BKName: TEdit
Tag = 2
Left = 96
Top = 11
Width = 89
Height = 20
TabOrder = 0
OnChange = CustomerChange
end
end
inherited ADOQueryBaseCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Left = 233
Top = 208
end
inherited ADOQueryBaseTemp: TADOQuery
Connection = DataLink_Company.ADOLink
Left = 81
Top = 209
end
object ADOQueryTemp: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 347
Top = 385
end
object ADOQueryCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Parameters = <>
Left = 245
Top = 385
end
object ADOQueryMain: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 149
Top = 385
end
object GPM_1: TcxGridPopupMenu
Grid = cxGrid2
PopupMenus = <>
Left = 552
Top = 224
end
object DS_1: TDataSource
DataSet = CDS_1
Left = 467
Top = 211
end
object CDS_1: TClientDataSet
Aggregates = <>
Params = <>
Left = 360
Top = 208
end
object PopupMenu1: TPopupMenu
Left = 512
Top = 424
object N1: TMenuItem
Caption = #20840#36873
OnClick = N1Click
end
object N2: TMenuItem
Caption = #20840#24323
OnClick = N2Click
end
end
end

View File

@ -0,0 +1,322 @@
unit U_BankList;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls,
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
cxTextEdit, cxPC, cxCheckComboBox, cxDropDownEdit, Menus, RM_e_Xls,
cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxSkinsCore,
dxSkinsDefaultPainters, dxDateRanges, dxBarBuiltInMenu, U_BaseList;
type
TfrmBankList = class(TfrmBaseList)
ToolBar1: TToolBar;
TBRafresh: TToolButton;
TBClose: TToolButton;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
ToolButton2: TToolButton;
ADOQueryMain: TADOQuery;
cxGrid2: TcxGrid;
Tv2: TcxGridDBTableView;
cxGridLevel1: TcxGridLevel;
GPM_1: TcxGridPopupMenu;
DS_1: TDataSource;
CDS_1: TClientDataSet;
PopupMenu1: TPopupMenu;
N1: TMenuItem;
N2: TMenuItem;
Panel1: TPanel;
BKName: TEdit;
Label1: TLabel;
btnadd: TToolButton;
btndel: TToolButton;
v2Column1: TcxGridDBColumn;
btnok: TToolButton;
Tv2Column1: TcxGridDBColumn;
Tv2Column3: TcxGridDBColumn;
Tv2Column4: TcxGridDBColumn;
Tv2Column5: TcxGridDBColumn;
Tv2Column6: TcxGridDBColumn;
ToolButton1: TToolButton;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure TBRafreshClick(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
procedure cxTabControl1Change(Sender: TObject);
procedure N1Click(Sender: TObject);
procedure N2Click(Sender: TObject);
procedure CustomerChange(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure v2Column8PropertiesEditValueChanged(Sender: TObject);
procedure btnaddClick(Sender: TObject);
procedure btndelClick(Sender: TObject);
procedure btnokClick(Sender: TObject);
procedure v2Column1PropertiesEditValueChanged(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
private
{ Private declarations }
procedure InitGrid();
public
fFlag: integer;
{ Public declarations }
RKFlag, FCYID, fmanage: string;
end;
var
frmBankList: TfrmBankList;
implementation
uses
U_DataLink, U_RTFun, U_ZDYHelp;
{$R *.dfm}
procedure TfrmBankList.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Close;
SQL.Clear;
sql.Add(' select * from BS_Bank order by SerialNo ');
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
finally
ADOQueryMain.EnableControls;
ToolButton2.Click;
end;
end;
procedure TfrmBankList.FormDestroy(Sender: TObject);
begin
inherited;
frmBankList := nil;
end;
procedure TfrmBankList.FormClose(Sender: TObject; var Action: TCloseAction);
begin
inherited;
Action := caFree;
end;
procedure TfrmBankList.TBCloseClick(Sender: TObject);
begin
Close;
end;
procedure TfrmBankList.FormShow(Sender: TObject);
begin
inherited;
ReadCxGrid(Trim(Self.Caption), Tv2, '财务管理');
InitGrid();
end;
procedure TfrmBankList.TBRafreshClick(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmBankList.btnokClick(Sender: TObject);
begin
if CDS_1.IsEmpty then
exit;
ModalResult := 1;
end;
procedure TfrmBankList.ToolButton1Click(Sender: TObject);
begin
WriteCxGrid(Trim(Self.Caption), Tv2, '财务管理');
end;
procedure TfrmBankList.ToolButton2Click(Sender: TObject);
var
sql: string;
begin
if ADOQueryMain.Active then
begin
sql := SGetFilters(Panel1, 1, 2);
SDofilter(ADOQueryMain, sql);
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmBankList.cxTabControl1Change(Sender: TObject);
begin
InitGrid;
end;
procedure TfrmBankList.N1Click(Sender: TObject);
begin
if CDS_1.IsEmpty then
exit;
with CDS_1 do
begin
DisableControls;
first;
while not eof do
begin
edit;
fieldbyname('ssel').Value := true;
post;
next;
end;
First;
EnableControls;
end;
end;
procedure TfrmBankList.N2Click(Sender: TObject);
begin
if CDS_1.IsEmpty then
exit;
with CDS_1 do
begin
DisableControls;
first;
while not eof do
begin
edit;
fieldbyname('ssel').Value := false;
post;
next;
end;
First;
EnableControls;
end;
end;
procedure TfrmBankList.CustomerChange(Sender: TObject);
begin
ToolButton2.Click;
end;
procedure TfrmBankList.FormCreate(Sender: TObject);
begin
inherited;
fmanage := Trim(DParameters1);
end;
procedure TfrmBankList.v2Column1PropertiesEditValueChanged(Sender: TObject);
var
mvalue, FFieldName: string;
begin
mvalue := TcxTextEdit(Sender).EditingText;
FFieldName := Trim(Tv2.Controller.FocusedColumn.DataBinding.FilterFieldName);
try
ADOQueryCmd.Connection.BeginTrans;
with CDS_1 do
begin
Edit;
FieldByName(FFieldName).Value := Trim(mvalue);
Post;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('UPdate BS_Bank ');
sql.Add(' Set ' + FFieldName + '=' + Trim(mvalue));
sql.Add(' , Editer=''' + Trim(DName) + '''');
sql.Add(' , Edittime=getdate()');
sql.Add(' where BKID=' + quotedstr(CDS_1.fieldbyname('BKID').AsString));
ExecSQL;
end;
ADOQueryCmd.Connection.CommitTrans;
tv2.Controller.EditingController.ShowEdit();
except
tv2.Controller.EditingController.ShowEdit();
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('保存失败!', '提示', 0);
end
end;
procedure TfrmBankList.v2Column8PropertiesEditValueChanged(Sender: TObject);
var
mvalue, FFieldName: string;
begin
mvalue := TcxTextEdit(Sender).EditingText;
FFieldName := Trim(Tv2.Controller.FocusedColumn.DataBinding.FilterFieldName);
try
ADOQueryCmd.Connection.BeginTrans;
with CDS_1 do
begin
Edit;
FieldByName(FFieldName).Value := Trim(mvalue);
Post;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('UPdate BS_Bank ');
sql.Add(' Set ' + FFieldName + '=''' + Trim(mvalue) + '''');
sql.Add(' , Editer=''' + Trim(DName) + '''');
sql.Add(' , Edittime=getdate()');
sql.Add(' where BKID=' + quotedstr(CDS_1.fieldbyname('BKID').AsString));
ExecSQL;
end;
ADOQueryCmd.Connection.CommitTrans;
tv2.Controller.EditingController.ShowEdit();
except
tv2.Controller.EditingController.ShowEdit();
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('保存失败!', '提示', 0);
end
end;
procedure TfrmBankList.btnaddClick(Sender: TObject);
var
maxId: string;
begin
BKName.SetFocus;
if GetLSNo(ADOQueryCmd, maxId, 'BK', 'BS_Bank', 4, 0) = False then
begin
Application.MessageBox('取最大号失败!', '提示', 0);
Exit;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('insert into BS_Bank(BKID,Filler) values(' + quotedstr(Trim(maxId)) + ',' + quotedstr(Trim(dname)) + ')');
ExecSQL;
end;
InitGrid();
end;
procedure TfrmBankList.btndelClick(Sender: TObject);
begin
if CDS_1.IsEmpty then
Exit;
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
Exit;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('delete BS_Bank where BKID=' + QuotedStr(CDS_1.FieldByName('BKID').AsString));
ExecSQL;
end;
CDS_1.Delete;
end;
end.

View File

@ -0,0 +1,247 @@
inherited frmCompany: TfrmCompany
Left = 347
Top = 169
Caption = #20844#21496#31649#29702
ClientHeight = 611
ClientWidth = 1366
FormStyle = fsMDIChild
Position = poScreenCenter
Visible = True
ExplicitWidth = 1382
ExplicitHeight = 650
PixelsPerInch = 96
TextHeight = 12
object ToolBar1: TToolBar [0]
Tag = 1
Left = 0
Top = 0
Width = 1366
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 91
Caption = 'ToolBar1'
Color = clWhite
DisabledImages = DataLink_Company.ImageList_new32
GradientEndColor = 15717318
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ShowCaptions = True
TabOrder = 0
object TBRafresh: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #21047#26032
ImageIndex = 1
OnClick = TBRafreshClick
end
object btnFind: TToolButton
Left = 71
Top = 0
AutoSize = True
Caption = #36807#28388
ImageIndex = 0
OnClick = btnFindClick
end
object btnAdd: TToolButton
Left = 142
Top = 0
AutoSize = True
Caption = #26032#22686
ImageIndex = 9
OnClick = btnAddClick
end
object btnEdit: TToolButton
Left = 213
Top = 0
AutoSize = True
Caption = #20462#25913
ImageIndex = 3
OnClick = btnEditClick
end
object TBDel: TToolButton
Left = 284
Top = 0
AutoSize = True
Caption = #21024#38500
ImageIndex = 5
OnClick = TBDelClick
end
object ToolButton5: TToolButton
Left = 355
Top = 0
AutoSize = True
Caption = #38468#20214
ImageIndex = 22
OnClick = ToolButton5Click
end
object ToolButton2: TToolButton
Left = 426
Top = 0
AutoSize = True
Caption = #20445#23384#26684#24335
ImageIndex = 16
OnClick = ToolButton2Click
end
object TBClose: TToolButton
Left = 521
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object cxGrid1: TcxGrid [1]
Left = 0
Top = 77
Width = 1366
Height = 534
Align = alClient
TabOrder = 1
object Tv1: TcxGridDBTableView
Navigator.Buttons.CustomButtons = <>
Navigator.Buttons.Delete.Enabled = False
Navigator.Buttons.Delete.Visible = False
DataController.DataSource = DS_1
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <>
DataController.Summary.SummaryGroups = <>
OptionsBehavior.GoToNextCellOnEnter = True
OptionsCustomize.ColumnFiltering = False
OptionsData.Deleting = False
OptionsData.DeletingConfirmation = False
OptionsSelection.CellSelect = False
OptionsSelection.MultiSelect = True
OptionsSelection.CheckBoxVisibility = [cbvDataRow, cbvColumnHeader]
OptionsView.GroupByBox = False
Styles.IncSearch = DataLink_Company.SHuangSe
Styles.Footer = DataLink_Company.Default
Styles.Header = DataLink_Company.Default
Styles.Inactive = DataLink_Company.SHuangSe
Styles.Selection = DataLink_Company.SHuangSe
object v2Column2: TcxGridDBColumn
Caption = #20844#21496#32534#21495
DataBinding.FieldName = 'CoCode'
PropertiesClassName = 'TcxTextEditProperties'
HeaderAlignmentHorz = taCenter
Width = 86
end
object v2Column6: TcxGridDBColumn
Caption = #20844#21496#21517#31216
DataBinding.FieldName = 'CoName'
HeaderAlignmentHorz = taCenter
Options.Focusing = False
Width = 127
end
object Tv1Column1: TcxGridDBColumn
Caption = #20844#21496#31616#31216
DataBinding.FieldName = 'CoAbbrName'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 151
end
object v2Column10: TcxGridDBColumn
Caption = #20844#21496#22320#22336
DataBinding.FieldName = 'CoAddress'
HeaderAlignmentHorz = taCenter
Width = 173
end
end
object cxGridLevel1: TcxGridLevel
GridView = Tv1
end
end
object Panel1: TPanel [2]
Left = 0
Top = 38
Width = 1366
Height = 39
Align = alTop
BevelInner = bvRaised
BevelOuter = bvLowered
Color = 16242829
ParentBackground = False
TabOrder = 2
object Label3: TLabel
Left = 202
Top = 13
Width = 48
Height = 12
Caption = #20844#21496#21517#31216
end
object Label1: TLabel
Left = 22
Top = 13
Width = 48
Height = 12
Caption = #20844#21496#32534#21495
end
object CoName: TEdit
Tag = 2
Left = 266
Top = 9
Width = 89
Height = 20
TabOrder = 1
end
object CoCode: TEdit
Tag = 2
Left = 85
Top = 9
Width = 89
Height = 20
TabOrder = 0
end
end
inherited ADOQueryBaseCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Left = 337
Top = 152
end
inherited ADOQueryBaseTemp: TADOQuery
Connection = DataLink_Company.ADOLink
Left = 201
Top = 145
end
object ADOQueryTemp: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 613
Top = 177
end
object ADOQueryCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Parameters = <>
Left = 709
Top = 185
end
object ADOQueryMain: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 533
Top = 137
end
object GPM_1: TcxGridPopupMenu
Grid = cxGrid1
PopupMenus = <>
Left = 312
Top = 296
end
object DS_1: TDataSource
DataSet = CDS_1
Left = 499
Top = 283
end
object CDS_1: TClientDataSet
Aggregates = <>
Params = <>
Left = 424
Top = 264
end
end

View File

@ -0,0 +1,231 @@
unit U_Company;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls,
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
cxTextEdit, cxDBLookupComboBox, ComObj, cxLookAndFeels, cxLookAndFeelPainters,
cxNavigator, U_BaseList, dxSkinsCore, dxSkinsDefaultPainters, dxDateRanges,
dxBarBuiltInMenu;
type
TfrmCompany = class(TfrmBaseList)
ToolBar1: TToolBar;
TBRafresh: TToolButton;
TBDel: TToolButton;
TBClose: TToolButton;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
ADOQueryMain: TADOQuery;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
cxGridLevel1: TcxGridLevel;
GPM_1: TcxGridPopupMenu;
DS_1: TDataSource;
CDS_1: TClientDataSet;
btnAdd: TToolButton;
v2Column6: TcxGridDBColumn;
v2Column2: TcxGridDBColumn;
v2Column10: TcxGridDBColumn;
btnEdit: TToolButton;
Tv1Column1: TcxGridDBColumn;
Panel1: TPanel;
Label3: TLabel;
Label1: TLabel;
CoName: TEdit;
CoCode: TEdit;
btnFind: TToolButton;
ToolButton2: TToolButton;
ToolButton5: TToolButton;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
procedure TBDelClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure TBRafreshClick(Sender: TObject);
procedure btnEditClick(Sender: TObject);
procedure btnAddClick(Sender: TObject);
procedure btnFindClick(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
procedure ToolButton5Click(Sender: TObject);
private
fFlileFlag: string;
{ Private declarations }
procedure InitGrid();
public
FAuthority: string;
end;
var
frmCompany: TfrmCompany;
implementation
uses
U_DataLink, U_RTFun, U_ZDYHelp, U_CustomerInput, U_AttachmentUpload;
{$R *.dfm}
procedure TfrmCompany.InitGrid();
var
FCoCode: string;
begin
if not CDS_1.IsEmpty then
FCoCode := CDS_1.FieldByName('CoCode').AsString;
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Filtered := False;
Close;
SQL.Clear;
sql.Add(' select * from BS_Company where CoType=''我司'' and Valid=''Y'' ');
Open;
end;
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
CDS_1.Locate('CoCode', FCoCode, []);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmCompany.FormDestroy(Sender: TObject);
begin
inherited;
// frmCustomer:=nil;
end;
procedure TfrmCompany.FormClose(Sender: TObject; var Action: TCloseAction);
begin
inherited;
Action := caFree;
end;
procedure TfrmCompany.TBCloseClick(Sender: TObject);
begin
Close;
end;
procedure TfrmCompany.TBDelClick(Sender: TObject);
begin
if CDS_1.IsEmpty then
Exit;
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
Exit;
if Trim(CDS_1.fieldbyname('COID').AsString) <> '' then
begin
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('update BS_Company set Valid=''N'' where COID=''' + Trim(CDS_1.fieldbyname('COID').AsString) + '''');
ExecSQL;
end;
end;
CDS_1.Delete;
end;
procedure TfrmCompany.FormShow(Sender: TObject);
begin
inherited;
ReadCxGrid(trim(self.Caption), Tv1, '客户管理');
InitGrid();
end;
procedure TfrmCompany.TBRafreshClick(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmCompany.btnEditClick(Sender: TObject);
begin
if CDS_1.IsEmpty then
exit;
try
frmCustomerInput := TfrmCustomerInput.Create(Application);
with frmCustomerInput do
begin
fFlileFlag := self.fFlileFlag;
FCOID := Trim(Self.CDS_1.fieldbyname('COID').AsString);
if ShowModal = 1 then
begin
TBRafresh.Click;
end;
end;
finally
frmCustomerInput.Free;
end;
end;
procedure TfrmCompany.ToolButton5Click(Sender: TObject);
begin
if CDS_1.IsEmpty then
Exit;
try
frmAttachmentUpload := TfrmAttachmentUpload.Create(Application);
with frmAttachmentUpload do
begin
// FEditAuthority := True;
if (Trim(FAuthority) = '录入') or (Trim(FAuthority) = '管理') then
FEditAuthority := True;
fkeyNO := Trim(Self.CDS_1.fieldbyname('Coid').AsString);
fType := '客户';
if ShowModal = 1 then
begin
end;
end;
finally
frmAttachmentUpload.Free;
end;
end;
procedure TfrmCompany.btnFindClick(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmCompany.ToolButton2Click(Sender: TObject);
begin
WriteCxGrid(trim(self.caption), Tv1, '客户管理');
end;
procedure TfrmCompany.btnAddClick(Sender: TObject);
begin
try
frmCustomerInput := TfrmCustomerInput.Create(Application);
with frmCustomerInput do
begin
FCOID := '';
fFlileFlag := self.fFlileFlag;
if ShowModal = 1 then
begin
InitGrid();
end;
end;
finally
frmCustomerInput.Free;
end;
end;
end.

View File

@ -0,0 +1,500 @@
object frmCustInput: TfrmCustInput
Left = 261
Top = 149
Caption = #23458#25143#36164#26009#24405#20837
ClientHeight = 643
ClientWidth = 1313
Color = clWhite
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
OldCreateOrder = True
Position = poScreenCenter
OnClose = FormClose
OnDestroy = FormDestroy
OnShow = FormShow
PixelsPerInch = 96
TextHeight = 12
object ToolBar1: TToolBar
Tag = 1
Left = 0
Top = 0
Width = 1313
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 75
Caption = 'ToolBar1'
Color = clWhite
DisabledImages = DataLink_Company.ImageList_new32
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ShowCaptions = True
TabOrder = 0
object ToolButton3: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #20445#23384
ImageIndex = 16
OnClick = ToolButton3Click
end
object TBClose: TToolButton
Left = 71
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object ScrollBox1: TScrollBox
Left = 0
Top = 38
Width = 1313
Height = 227
Align = alTop
BevelInner = bvNone
BevelOuter = bvNone
BorderStyle = bsNone
Color = clWhite
Ctl3D = False
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -14
Font.Name = #23435#20307
Font.Style = []
ParentColor = False
ParentCtl3D = False
ParentFont = False
TabOrder = 1
ExplicitLeft = -1
object Label2: TLabel
Left = 12
Top = 35
Width = 52
Height = 12
Caption = #23458#25143#32534#21495
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label6: TLabel
Left = 236
Top = 35
Width = 52
Height = 12
Caption = #23458#25143#20840#31216
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label7: TLabel
Left = 38
Top = 146
Width = 26
Height = 12
Caption = #22791#27880
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label1: TLabel
Left = 462
Top = 35
Width = 52
Height = 12
Caption = #23458#25143#31616#31216
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label4: TLabel
Left = 38
Top = 75
Width = 26
Height = 12
Caption = #22320#22336
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label8: TLabel
Left = 1119
Top = 35
Width = 26
Height = 12
Caption = #22269#23478
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label10: TLabel
Left = 911
Top = 35
Width = 52
Height = 12
Caption = #23458#25143#31561#32423
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label3: TLabel
Left = 684
Top = 35
Width = 52
Height = 12
Caption = #23458#25143#31867#22411
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label5: TLabel
Left = 1119
Top = 72
Width = 39
Height = 12
Caption = #19994#21153#21592
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object CoName: TEdit
Tag = 2
Left = 294
Top = 31
Width = 140
Height = 20
TabOrder = 1
end
object CoNote: TMemo
Tag = 2
Left = 71
Top = 142
Width = 1037
Height = 57
ScrollBars = ssVertical
TabOrder = 3
end
object CoAbbrName: TEdit
Tag = 2
Left = 520
Top = 31
Width = 140
Height = 20
TabOrder = 2
end
object CoCode: TEdit
Tag = 2
Left = 71
Top = 31
Width = 140
Height = 20
TabOrder = 0
end
object CoAddress: TMemo
Tag = 2
Left = 71
Top = 72
Width = 1036
Height = 57
ScrollBars = ssVertical
TabOrder = 4
end
object CoLevel: TComboBox
Tag = 2
Left = 968
Top = 30
Width = 140
Height = 22
Style = csDropDownList
TabOrder = 5
Items.Strings = (
'A'
'B'
'C')
end
object cocountry: TBtnEditC
Tag = 2
Left = 1163
Top = 31
Width = 140
Height = 20
Hint = 'CoCountry/'#22269#23478
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
ParentFont = False
TabOrder = 6
OnBtnUpClick = cocountryBtnUpClick
OnBtnDnClick = cocountryBtnDnClick
end
object CoBusinessType: TBtnEditC
Tag = 2
Left = 742
Top = 31
Width = 140
Height = 20
Hint = 'CoBusinessType/'#23458#25143#31867#22411
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
ParentFont = False
TabOrder = 7
OnBtnUpClick = cocountryBtnUpClick
OnBtnDnClick = cocountryBtnDnClick
end
object Saleser: TBtnEditC
Tag = 2
Left = 1162
Top = 68
Width = 140
Height = 22
Hint = 'Saleser/'#19994#21153#21592
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
ParentFont = False
ReadOnly = True
TabOrder = 8
OnBtnUpClick = SaleserBtnUpClick
OnBtnDnClick = cocountryBtnDnClick
end
object Salesid: TEdit
Tag = 2
Left = 1161
Top = 102
Width = 140
Height = 20
TabOrder = 9
Visible = False
end
end
object Panel1: TPanel
Left = 0
Top = 265
Width = 1313
Height = 378
Align = alClient
Caption = 'Panel1'
TabOrder = 2
object Panel3: TPanel
Left = 1
Top = 1
Width = 1311
Height = 376
Align = alClient
Caption = 'Panel1'
TabOrder = 0
object ToolBar3: TToolBar
Tag = 1
Left = 1
Top = 1
Width = 1309
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 91
Caption = 'ToolBar1'
Color = clWhite
DisabledImages = DataLink_Company.ImageList_new32
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ShowCaptions = True
TabOrder = 0
object ToolButton2: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #35774#20026#40664#35748
ImageIndex = 15
OnClick = ToolButton2Click
end
object ToolButton6: TToolButton
Left = 95
Top = 0
AutoSize = True
Caption = #22686#34892
ImageIndex = 2
OnClick = ToolButton6Click
end
object ToolButton7: TToolButton
Left = 166
Top = 0
AutoSize = True
Caption = #21024#34892
ImageIndex = 6
OnClick = ToolButton7Click
end
end
object cxGrid2: TcxGrid
Left = 1
Top = 39
Width = 1309
Height = 336
Align = alClient
BorderStyle = cxcbsNone
TabOrder = 1
object TV2: TcxGridDBTableView
Navigator.Buttons.CustomButtons = <>
Navigator.Buttons.Delete.Enabled = False
Navigator.Buttons.Delete.Visible = False
ScrollbarAnnotations.CustomAnnotations = <>
DataController.DataSource = DSLXR
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <
item
Kind = skSum
end
item
Kind = skSum
end
item
Kind = skSum
end>
DataController.Summary.SummaryGroups = <>
OptionsBehavior.GoToNextCellOnEnter = True
OptionsCustomize.ColumnFiltering = False
OptionsData.Deleting = False
OptionsData.DeletingConfirmation = False
OptionsView.Footer = True
OptionsView.GroupByBox = False
Styles.Footer = DataLink_Company.Default
Styles.Header = DataLink_Company.Default
object cxGridDBColumn2: TcxGridDBColumn
Caption = #40664#35748
DataBinding.FieldName = 'IsDefault'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxCheckBoxProperties'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 76
end
object cxGridDBColumn3: TcxGridDBColumn
Caption = #32852#31995#20154
DataBinding.FieldName = 'Contacts'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
Properties.CharCase = ecUpperCase
HeaderAlignmentHorz = taCenter
Width = 77
end
object cxGridDBColumn5: TcxGridDBColumn
Caption = #32844#20301
DataBinding.FieldName = 'position'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Width = 66
end
object cxGridDBColumn6: TcxGridDBColumn
Caption = #32852#31995#30005#35805
DataBinding.FieldName = 'Telephone'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
Properties.CharCase = ecUpperCase
HeaderAlignmentHorz = taCenter
Width = 86
end
object cxGridDBColumn7: TcxGridDBColumn
Caption = #25163#26426#21495
DataBinding.FieldName = 'PhoneNumber'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
Properties.CharCase = ecUpperCase
HeaderAlignmentHorz = taCenter
Width = 109
end
object cxGridDBColumn8: TcxGridDBColumn
DataBinding.FieldName = 'EMAIL'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Width = 66
end
object TV2Column2: TcxGridDBColumn
Caption = #24494#20449#21495
DataBinding.FieldName = 'WeChat'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Width = 66
end
end
object cxGridLevel2: TcxGridLevel
GridView = TV2
end
end
end
end
object ADOQueryTemp: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 971
Top = 192
end
object ADOQueryCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Parameters = <>
Left = 830
Top = 192
end
object ADOQueryMain: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 933
Top = 121
end
object cxGridPopupMenu2: TcxGridPopupMenu
PopupMenus = <>
Left = 294
Top = 502
end
object CDS_LXR: TClientDataSet
Aggregates = <>
Params = <>
Left = 377
Top = 503
end
object DSLXR: TDataSource
DataSet = CDS_LXR
Left = 464
Top = 511
end
end

View File

@ -0,0 +1,521 @@
unit U_CustInput;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls,
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
cxTextEdit, cxDropDownEdit, BtnEdit, cxLookAndFeels, cxLookAndFeelPainters,
cxNavigator, dxSkinsCore, dxSkinsDefaultPainters, dxDateRanges,
dxBarBuiltInMenu, U_BaseList, dxScrollbarAnnotations;
type
TfrmCustInput = class(TForm)
ToolBar1: TToolBar;
TBClose: TToolButton;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
ADOQueryMain: TADOQuery;
cxGridPopupMenu2: TcxGridPopupMenu;
ToolButton3: TToolButton;
CDS_LXR: TClientDataSet;
DSLXR: TDataSource;
ScrollBox1: TScrollBox;
Label2: TLabel;
Label6: TLabel;
Label7: TLabel;
CoName: TEdit;
CoNote: TMemo;
Label1: TLabel;
CoAbbrName: TEdit;
CoCode: TEdit;
Panel1: TPanel;
Label4: TLabel;
Label8: TLabel;
CoAddress: TMemo;
Panel3: TPanel;
ToolBar3: TToolBar;
ToolButton2: TToolButton;
ToolButton6: TToolButton;
ToolButton7: TToolButton;
cxGrid2: TcxGrid;
TV2: TcxGridDBTableView;
cxGridDBColumn2: TcxGridDBColumn;
cxGridDBColumn3: TcxGridDBColumn;
cxGridDBColumn5: TcxGridDBColumn;
cxGridDBColumn6: TcxGridDBColumn;
cxGridDBColumn7: TcxGridDBColumn;
cxGridDBColumn8: TcxGridDBColumn;
cxGridLevel2: TcxGridLevel;
Label10: TLabel;
CoLevel: TComboBox;
TV2Column2: TcxGridDBColumn;
cocountry: TBtnEditC;
Label3: TLabel;
CoBusinessType: TBtnEditC;
Label5: TLabel;
Saleser: TBtnEditC;
Salesid: TEdit;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure TBRafreshClick(Sender: TObject);
procedure ToolButton3Click(Sender: TObject);
procedure ToolButton6Click(Sender: TObject);
procedure ToolButton7Click(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
procedure cocountryBtnDnClick(Sender: TObject);
procedure cocountryBtnUpClick(Sender: TObject);
procedure SaleserBtnUpClick(Sender: TObject);
private
{ Private declarations }
procedure InitGrid();
function SaveData(): Boolean;
public
fkhType: string;
{ Public declarations }
FCOID: string;
end;
var
frmCustInput: TfrmCustInput;
implementation
uses
U_DataLink, U_RTFun, U_ZDYHelp, U_YGSel, U_UserSel;
{$R *.dfm}
procedure TfrmCustInput.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Filtered := False;
Close;
SQL.Clear;
sql.Add(' select * from BS_Company where CoType=''客户'' and COID=''' + Trim(FCOID) + '''');
Open;
end;
SCSHData(ADOQueryMain, ScrollBox1, 2);
// Saleser.Hint := ADOQueryMain.FieldByName('SalesId').AsString;
with ADOQueryMain do
begin
Filtered := False;
Close;
SQL.Clear;
sql.Add(' select * from BS_Company_contact where COID=' + quotedstr(Trim(FCOID)));
Open;
end;
SCreateCDS(ADOQueryMain, CDS_LXR);
SInitCDSData(ADOQueryMain, CDS_LXR);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmCustInput.FormDestroy(Sender: TObject);
begin
frmCustInput := nil;
end;
procedure TfrmCustInput.cocountryBtnDnClick(Sender: TObject);
begin
TBtnEditC(Sender).Text := '';
TBtnEditC(Sender).TxtCode := '';
end;
procedure TfrmCustInput.cocountryBtnUpClick(Sender: TObject);
var
fsj: string;
FWZ: Integer;
begin
fsj := Trim(TEdit(Sender).Hint);
FWZ := Pos('/', fsj);
try
frmZDYHelp := TfrmZDYHelp.Create(Application);
with frmZDYHelp do
begin
flag := Copy(fsj, 1, FWZ - 1);
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
if ShowModal = 1 then
begin
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
end;
end;
finally
frmZDYHelp.Free;
end;
end;
procedure TfrmCustInput.FormClose(Sender: TObject; var Action: TCloseAction);
begin
Action := caFree;
end;
procedure TfrmCustInput.TBCloseClick(Sender: TObject);
begin
WriteCxGrid(trim(self.Caption) + 'TV2', Tv2, '供应商管理');
close;
end;
procedure TfrmCustInput.FormShow(Sender: TObject);
var
i: integer;
a: string;
begin
ReadCxGrid(trim(self.Caption) + 'TV2', Tv2, '供应商管理');
InitGrid();
if trim(FCOID) = '' then
begin
with ADOQueryTemp do
begin
Close;
sql.Clear;
sql.Add(' exec P_BS_Com_Get_No @Str=''K'' ');
Open;
end;
CoCode.Text := trim(ADOQueryTemp.FieldByName('NewCoCode').asstring);
end;
//已审核的也要能修改保存,不能修改主表内容,只能改下面两部分
// with ADOQueryTemp do
// begin
// Close;
// sql.Clear;
// sql.Add(' select * from BS_Company where CoId=' + quotedstr(FCoId));
// Open;
// end;
// if trim(ADOQueryTemp.FieldByName('Status').asstring) = '1' then
// begin
// ScrollBox1.Enabled := False;
// end;
end;
procedure TfrmCustInput.TBRafreshClick(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmCustInput.SaleserBtnUpClick(Sender: TObject);
begin
try
frmUserSel := TfrmUserSel.Create(Application);
with frmUserSel do
begin
Fdept := '业务';
if ShowModal = 1 then
begin
SalesId.Text := Trim(CDS_1.fieldbyname('UserID').AsString);
Saleser.Text := Trim(CDS_1.fieldbyname('UserName').AsString);
end;
end;
finally
frmUserSel.Free;
end;
end;
function TfrmCustInput.SaveData(): Boolean;
var
MaxId, MaxSubId, FCoCode, FCCID: string;
begin
try
ADOQueryCmd.Connection.BeginTrans;
if Trim(FCOID) = '' then
begin
if GetLSNo(ADOQueryCmd, MaxId, 'CO', 'BS_Company', 4, 1) = False then
begin
Result := False;
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('取最大号失败!', '提示', 0);
Exit;
end;
if trim(CoCode.Text) = '' then
begin
with ADOQueryTemp do
begin
Close;
sql.Clear;
sql.Add(' exec P_BS_Com_Get_No @Str=''K'' ');
Open;
end;
CoCode.Text := trim(ADOQueryTemp.FieldByName('NewCoCode').asstring);
end;
end
else
begin
MaxId := Trim(FCOID);
end;
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('select * from BS_Company where COID=''' + Trim(FCOID) + '''');
Open;
end;
with ADOQueryCmd do
begin
if Trim(FCOID) = '' then
begin
Append;
FieldByName('FillId').Value := Trim(DCode);
FieldByName('Filler').Value := Trim(DName);
// FieldByName('Saleser').Value := trim(DName);
// FieldByName('SalesId').Value := trim(DCode);
FieldByName('status').Value := '0';
end
else
begin
Edit;
FieldByName('EditId').Value := Trim(DCode);
FieldByName('Editer').Value := Trim(DName);
FieldByName('Edittime').Value := SGetServerDateTime(ADOQueryTemp);
end;
FieldByName('COID').Value := Trim(MaxId);
RTSetsavedata(ADOQueryCmd, 'BS_Company', ScrollBox1, 2);
FieldByName('CoType').Value := '客户';
FieldByName('status').Value := '1';
// FieldByName('SalesId').Value := Saleser.Hint;
FieldByName('Chktime').Value := SGetServerDateTime(ADOQueryTemp);
FieldByName('Chker').Value := Trim(DName);
Post;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('select * from BS_Company where CoCode=' + quotedstr(trim(CoCode.Text)));
Open;
end;
if ADOQueryCmd.RecordCount > 1 then
begin
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('编号重复!', '提示', 0);
Exit;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('select * from BS_Company where CoName=' + quotedstr(trim(CoName.Text)));
sql.Add(' and CoType=''客户'' ');
Open;
end;
if ADOQueryCmd.RecordCount > 1 then
begin
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('名称重复!', '提示', 0);
Exit;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('select * from BS_Company where CoAbbrName=' + quotedstr(trim(CoAbbrName.Text)));
sql.Add(' and CoType=''客户'' ');
Open;
end;
if ADOQueryCmd.RecordCount > 1 then
begin
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('简称重复!', '提示', 0);
Exit;
end;
////////////// 联系人 ///////////////////
if not CDS_LXR.IsEmpty then
begin
with CDS_LXR do
begin
CDS_LXR.First;
while not Eof do
begin
FCCID := Trim(CDS_LXR.fieldbyname('CCID').AsString);
if Trim(FCCID) = '' then
begin
if GetLSNo(ADOQueryCmd, MaxSubId, 'CCS', 'BS_Company_contact', 4, 1) = False then
begin
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('取系人最大ID失败!', '提示', 0);
Exit;
end;
end
else
begin
MaxSubId := trim(FCCID);
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('select * from BS_Company_contact where CCID=' + quotedstr(Trim(MaxSubId)));
Open;
end;
with ADOQueryCmd do
begin
if Trim(FCCID) = '' then
begin
Append;
end
else
begin
Edit;
end;
FieldByName('CCID').Value := Trim(MaxSubId);
FieldByName('COID').Value := Trim(MaxId);
RTSetSaveDataCDS(ADOQueryCmd, Tv2, CDS_LXR, 'BS_Company_contact', 0);
Post;
end;
with CDS_LXR do
begin
Edit;
FieldByName('CCID').Value := Trim(MaxSubId);
Post;
end;
CDS_LXR.Next;
end;
end;
end;
////////////// 联系人 ///////////////////
//////////////// 更新名称 ////////////////////////
// with ADOQueryCmd do
// begin
// Close;
// sql.Clear;
// sql.Add('exec P_Com_Up_Code @COID=' + quotedstr(Trim(MaxId)));
// ExecSQL;
// end;
//////////////// 更新名称 ////////////////////////
ADOQueryCmd.Connection.CommitTrans;
FCCID := Trim(MaxSubId);
Result := True;
except
Result := false;
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('保存异常!', '提示', 0);
end;
end;
procedure TfrmCustInput.ToolButton3Click(Sender: TObject);
begin
if Trim(CoAbbrName.Text) = '' then
begin
Application.MessageBox('简称不能为空!', '提示', 0);
Exit;
end;
if Trim(CoName.Text) = '' then
begin
Application.MessageBox('名称不能为空!', '提示', 0);
Exit;
end;
if SaveData() then
begin
Application.MessageBox('保存成功!', '提示', 0);
ModalResult := 1;
end;
end;
procedure TfrmCustInput.ToolButton6Click(Sender: TObject);
var
maxno: string;
begin
if GetLSNo(ADOQueryCmd, maxno, 'CC', 'BS_Company_contact', 4, 1) = False then
begin
Application.MessageBox('取系人最大ID失败!', '提示', 0);
Exit;
end;
if CDS_LXR.IsEmpty then
begin
with CDS_LXR do
begin
Append;
fieldbyname('CCID').Value := trim(maxno);
fieldbyname('IsDefault').Value := true;
Post;
end;
end
else
begin
with CDS_LXR do
begin
Append;
fieldbyname('CCID').Value := trim(maxno);
fieldbyname('IsDefault').Value := false;
Post;
end;
end;
end;
procedure TfrmCustInput.ToolButton7Click(Sender: TObject);
begin
if CDS_LXR.IsEmpty then
Exit;
if Trim(CDS_LXR.fieldbyname('CCID').AsString) <> '' then
begin
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
Exit;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('delete from BS_Company_contact where CCID=''' + Trim(CDS_LXR.fieldbyname('CCID').AsString) + '''');
ExecSQL;
end;
end;
CDS_LXR.Delete;
if CDS_LXR.IsEmpty = false then
begin
if CDS_LXR.Locate('IsDefault', true, []) = false then
begin
CDS_LXR.first;
CDS_LXR.edit;
CDS_LXR.FieldByName('IsDefault').value := true;
end;
end;
end;
procedure TfrmCustInput.ToolButton2Click(Sender: TObject);
var
DwFlag: string;
begin
DwFlag := trim(CDS_LXR.FieldByName('CCID').AsString);
if CDS_LXR.Locate('IsDefault', true, []) then
begin
CDS_LXR.edit;
CDS_LXR.FieldByName('IsDefault').value := false;
end;
if CDS_LXR.Locate('CCID', DwFlag, []) then
begin
CDS_LXR.edit;
CDS_LXR.FieldByName('IsDefault').value := true;
end;
end;
end.

View File

@ -0,0 +1,554 @@
inherited frmCustomer: TfrmCustomer
Left = 347
Top = 169
Caption = #23458#25143#36164#26009#31649#29702
ClientHeight = 611
ClientWidth = 1366
FormStyle = fsMDIChild
Position = poScreenCenter
Visible = True
ExplicitWidth = 1382
ExplicitHeight = 650
PixelsPerInch = 96
TextHeight = 12
object ToolBar1: TToolBar [0]
Tag = 1
Left = 0
Top = 0
Width = 1366
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 103
Caption = 'ToolBar1'
Color = clWhite
DisabledImages = DataLink_Company.ImageList_new32
GradientEndColor = 15717318
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ShowCaptions = True
TabOrder = 0
object TBRafresh: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #21047#26032
ImageIndex = 1
OnClick = TBRafreshClick
end
object btnFind: TToolButton
Left = 71
Top = 0
AutoSize = True
Caption = #36807#28388
ImageIndex = 0
OnClick = btnFindClick
end
object btnAdd: TToolButton
Left = 142
Top = 0
AutoSize = True
Caption = #26032#22686
ImageIndex = 9
OnClick = btnAddClick
end
object btnEdit: TToolButton
Left = 213
Top = 0
AutoSize = True
Caption = #20462#25913
ImageIndex = 3
OnClick = btnEditClick
end
object TBDel: TToolButton
Left = 284
Top = 0
AutoSize = True
Caption = #21024#38500
ImageIndex = 5
OnClick = TBDelClick
end
object btnSaleser: TToolButton
Left = 355
Top = 0
AutoSize = True
Caption = #25351#23450#19994#21153#21592
ImageIndex = 15
OnClick = btnSaleserClick
end
object btnTallyer: TToolButton
Left = 462
Top = 0
AutoSize = True
Caption = #25351#23450#29702#21333
ImageIndex = 15
OnClick = btnTallyerClick
end
object btnChk: TToolButton
Left = 557
Top = 0
AutoSize = True
Caption = #23457#26680
ImageIndex = 12
OnClick = btnChkClick
end
object btnReChk: TToolButton
Left = 628
Top = 0
AutoSize = True
Caption = #25764#38144#23457#26680
ImageIndex = 11
OnClick = btnReChkClick
end
object ToolButton3: TToolButton
Left = 723
Top = 0
AutoSize = True
Caption = #38468#20214
ImageIndex = 22
OnClick = ToolButton3Click
end
object ToolButton1: TToolButton
Left = 794
Top = 0
AutoSize = True
Caption = #20445#23384#26684#24335
ImageIndex = 16
OnClick = ToolButton1Click
end
object TBClose: TToolButton
Left = 889
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object Panel1: TPanel [1]
Left = 0
Top = 38
Width = 1366
Height = 39
Align = alTop
BevelInner = bvRaised
BevelOuter = bvLowered
Color = 16242829
ParentBackground = False
TabOrder = 1
object Label3: TLabel
Left = 190
Top = 13
Width = 48
Height = 12
Caption = #23458#25143#20840#31216
end
object Label1: TLabel
Left = 22
Top = 13
Width = 48
Height = 12
Caption = #23458#25143#32534#21495
end
object Label2: TLabel
Left = 350
Top = 13
Width = 36
Height = 12
Caption = #19994#21153#21592
end
object Label4: TLabel
Left = 502
Top = 13
Width = 24
Height = 12
Caption = #22269#23478
end
object CoName: TEdit
Tag = 2
Left = 242
Top = 9
Width = 90
Height = 20
TabOrder = 1
OnChange = CoCodeChange
OnKeyPress = CoCodeKeyPress
end
object CoCode: TEdit
Tag = 2
Left = 73
Top = 9
Width = 90
Height = 20
TabOrder = 0
OnChange = CoCodeChange
OnKeyPress = CoCodeKeyPress
end
object Saleser: TEdit
Tag = 2
Left = 390
Top = 9
Width = 90
Height = 20
TabOrder = 2
OnChange = CoCodeChange
OnKeyPress = CoCodeKeyPress
end
object country: TEdit
Tag = 2
Left = 529
Top = 9
Width = 90
Height = 20
TabOrder = 3
OnChange = CoCodeChange
OnKeyPress = CoCodeKeyPress
end
end
object cxGrid1: TcxGrid [2]
Left = 0
Top = 99
Width = 1366
Height = 309
Align = alClient
TabOrder = 2
object Tv1: TcxGridDBTableView
Navigator.Buttons.CustomButtons = <>
Navigator.Buttons.Delete.Enabled = False
Navigator.Buttons.Delete.Visible = False
ScrollbarAnnotations.CustomAnnotations = <>
OnFocusedRecordChanged = Tv1FocusedRecordChanged
DataController.DataSource = DS_1
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <
item
Kind = skSum
end
item
Kind = skSum
end
item
Kind = skSum
end>
DataController.Summary.SummaryGroups = <>
OptionsBehavior.GoToNextCellOnEnter = True
OptionsCustomize.ColumnFiltering = False
OptionsData.Deleting = False
OptionsData.DeletingConfirmation = False
OptionsView.GroupByBox = False
Styles.IncSearch = DataLink_Company.SHuangSe
Styles.Footer = DataLink_Company.Default
Styles.Header = DataLink_Company.Default
Styles.Inactive = DataLink_Company.SHuangSe
Styles.Selection = DataLink_Company.SHuangSe
object Tv1Column1: TcxGridDBColumn
Caption = #36873#25321
DataBinding.FieldName = 'SSel'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxCheckBoxProperties'
Properties.ImmediatePost = True
HeaderAlignmentHorz = taCenter
Width = 48
end
object v2Column2: TcxGridDBColumn
Caption = #23458#25143#32534#21495
DataBinding.FieldName = 'CoCode'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 86
end
object v2Column6: TcxGridDBColumn
Caption = #23458#25143#20840#31216
DataBinding.FieldName = 'CoName'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Options.Focusing = False
Width = 127
end
object v2Column15: TcxGridDBColumn
Caption = #23458#25143#31616#31216
DataBinding.FieldName = 'CoAbbrName'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 100
end
object v2Column10: TcxGridDBColumn
Caption = #19994#21153#21592
DataBinding.FieldName = 'Saleser'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 84
end
object v2Column7: TcxGridDBColumn
Caption = #20844#21496#22320#22336
DataBinding.FieldName = 'CoAddress'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 80
end
object v2Column1: TcxGridDBColumn
Caption = #22791#27880
DataBinding.FieldName = 'Note'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 163
end
object v2Column3: TcxGridDBColumn
Caption = #22269#23478
DataBinding.FieldName = 'cocountry'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 99
end
object Tv1Column2: TcxGridDBColumn
Caption = #23458#25143#31561#32423
DataBinding.FieldName = 'CoLevel'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 66
end
object Tv1Column3: TcxGridDBColumn
Caption = #30331#35760#26102#38388
DataBinding.FieldName = 'Filltime'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 66
end
object Tv1Column4: TcxGridDBColumn
Caption = #30331#35760#20154
DataBinding.FieldName = 'Filler'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 66
end
object Tv1Column5: TcxGridDBColumn
Caption = #29702#21333
DataBinding.FieldName = 'Tallyer'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 99
end
object Tv1Column6: TcxGridDBColumn
Caption = #23458#25143#31867#22411
DataBinding.FieldName = 'KHType'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 66
end
end
object cxGridLevel1: TcxGridLevel
GridView = Tv1
end
end
object Panel2: TPanel [3]
Left = 0
Top = 408
Width = 1366
Height = 203
Align = alBottom
Caption = 'Panel2'
TabOrder = 3
object cxGrid2: TcxGrid
Left = 1
Top = 1
Width = 1364
Height = 201
Align = alClient
TabOrder = 0
object Tv2: TcxGridDBTableView
Navigator.Buttons.CustomButtons = <>
Navigator.Buttons.Delete.Enabled = False
Navigator.Buttons.Delete.Visible = False
ScrollbarAnnotations.CustomAnnotations = <>
DataController.DataSource = DS_2
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <
item
Kind = skSum
end
item
Kind = skSum
end
item
Kind = skSum
end>
DataController.Summary.SummaryGroups = <>
OptionsBehavior.GoToNextCellOnEnter = True
OptionsCustomize.ColumnFiltering = False
OptionsData.Deleting = False
OptionsData.DeletingConfirmation = False
OptionsView.GroupByBox = False
Styles.Header = DataLink_Company.Default
object v3Column3: TcxGridDBColumn
Caption = #40664#35748
DataBinding.FieldName = 'IsDefault'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxCheckBoxProperties'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 76
end
object cxGridDBColumn1: TcxGridDBColumn
Caption = #32852#31995#20154
DataBinding.FieldName = 'Contacts'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
Properties.CharCase = ecUpperCase
HeaderAlignmentHorz = taCenter
Width = 70
end
object cxGridDBColumn2: TcxGridDBColumn
Caption = #32844#20301
DataBinding.FieldName = 'position'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
Properties.CharCase = ecUpperCase
HeaderAlignmentHorz = taCenter
Width = 70
end
object cxGridDBColumn4: TcxGridDBColumn
Caption = #32852#31995#30005#35805
DataBinding.FieldName = 'Telephone'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
Properties.CharCase = ecUpperCase
HeaderAlignmentHorz = taCenter
Width = 99
end
object cxGridDBColumn5: TcxGridDBColumn
Caption = #25163#26426#21495
DataBinding.FieldName = 'PhoneNumber'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
Properties.CharCase = ecUpperCase
HeaderAlignmentHorz = taCenter
Width = 102
end
object Tv2Column1: TcxGridDBColumn
Caption = 'EMAIL'
DataBinding.FieldName = 'Email'
DataBinding.IsNullValueType = True
PropertiesClassName = 'TcxTextEditProperties'
Properties.CharCase = ecUpperCase
HeaderAlignmentHorz = taCenter
Width = 108
end
object v3Column2: TcxGridDBColumn
Caption = #24494#20449#21495
DataBinding.FieldName = 'WeChat'
DataBinding.IsNullValueType = True
HeaderAlignmentHorz = taCenter
Width = 169
end
end
object cxGridLevel2: TcxGridLevel
GridView = Tv2
end
end
end
object cxTabControl1: TcxTabControl [4]
Left = 0
Top = 77
Width = 1366
Height = 22
Align = alTop
TabOrder = 4
Visible = False
Properties.CustomButtons.Buttons = <>
Properties.Style = 9
Properties.TabIndex = 1
Properties.Tabs.Strings = (
#26410#23457#26680
#24050#23457#26680
#20840#37096)
OnChange = cxTabControl1Change
ClientRectBottom = 22
ClientRectRight = 1366
ClientRectTop = 19
end
inherited ADOQueryBaseCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Left = 177
Top = 240
end
inherited ADOQueryBaseTemp: TADOQuery
Connection = DataLink_Company.ADOLink
Left = 193
Top = 161
end
object ADOQueryTemp: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 613
Top = 145
end
object ADOQueryCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Parameters = <>
Left = 733
Top = 145
end
object ADOQueryMain: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 797
Top = 153
end
object GPM_1: TcxGridPopupMenu
Grid = cxGrid1
PopupMenus = <>
Left = 448
Top = 264
end
object DS_1: TDataSource
DataSet = CDS_1
Left = 579
Top = 267
end
object CDS_1: TClientDataSet
Aggregates = <>
Params = <>
Left = 512
Top = 256
end
object CDS_2: TClientDataSet
Aggregates = <>
Params = <>
Left = 384
Top = 460
end
object DS_2: TDataSource
DataSet = CDS_2
Left = 459
Top = 467
end
object OpenDialog1: TOpenDialog
Left = 430
Top = 186
end
object GPM_2: TcxGridPopupMenu
Grid = cxGrid2
PopupMenus = <>
Left = 320
Top = 456
end
end

View File

@ -0,0 +1,518 @@
unit U_Customer;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls,
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
cxTextEdit, cxDBLookupComboBox, ComObj, cxLookAndFeels, cxLookAndFeelPainters,
cxNavigator, U_BaseList, dxSkinsCore, dxSkinsDefaultPainters, dxDateRanges,
dxBarBuiltInMenu, cxPC, dxScrollbarAnnotations;
type
TfrmCustomer = class(TfrmBaseList)
ToolBar1: TToolBar;
TBRafresh: TToolButton;
TBDel: TToolButton;
TBClose: TToolButton;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
Panel1: TPanel;
btnFind: TToolButton;
ADOQueryMain: TADOQuery;
Label3: TLabel;
CoName: TEdit;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
cxGridLevel1: TcxGridLevel;
GPM_1: TcxGridPopupMenu;
DS_1: TDataSource;
CDS_1: TClientDataSet;
btnAdd: TToolButton;
v2Column6: TcxGridDBColumn;
v2Column1: TcxGridDBColumn;
v2Column2: TcxGridDBColumn;
v2Column7: TcxGridDBColumn;
Label1: TLabel;
CoCode: TEdit;
v2Column10: TcxGridDBColumn;
btnEdit: TToolButton;
Label2: TLabel;
Saleser: TEdit;
country: TEdit;
Label4: TLabel;
v2Column15: TcxGridDBColumn;
CDS_2: TClientDataSet;
DS_2: TDataSource;
btnSaleser: TToolButton;
v2Column3: TcxGridDBColumn;
OpenDialog1: TOpenDialog;
Tv1Column3: TcxGridDBColumn;
Tv1Column4: TcxGridDBColumn;
Tv1Column2: TcxGridDBColumn;
Panel2: TPanel;
cxGrid2: TcxGrid;
Tv2: TcxGridDBTableView;
v3Column3: TcxGridDBColumn;
cxGridDBColumn1: TcxGridDBColumn;
cxGridDBColumn2: TcxGridDBColumn;
cxGridDBColumn4: TcxGridDBColumn;
cxGridDBColumn5: TcxGridDBColumn;
Tv2Column1: TcxGridDBColumn;
v3Column2: TcxGridDBColumn;
cxGridLevel2: TcxGridLevel;
cxTabControl1: TcxTabControl;
btnChk: TToolButton;
btnReChk: TToolButton;
Tv1Column1: TcxGridDBColumn;
btnTallyer: TToolButton;
Tv1Column5: TcxGridDBColumn;
Tv1Column6: TcxGridDBColumn;
ToolButton1: TToolButton;
GPM_2: TcxGridPopupMenu;
ToolButton3: TToolButton;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
procedure TBDelClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure TBRafreshClick(Sender: TObject);
procedure btnFindClick(Sender: TObject);
procedure btnEditClick(Sender: TObject);
procedure btnAddClick(Sender: TObject);
procedure TBuserClick(Sender: TObject);
procedure Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
procedure btnSaleserClick(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure CoCodeKeyPress(Sender: TObject; var Key: Char);
procedure btnChkClick(Sender: TObject);
procedure btnReChkClick(Sender: TObject);
procedure cxTabControl1Change(Sender: TObject);
procedure btnTallyerClick(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure ToolButton3Click(Sender: TObject);
procedure CoCodeChange(Sender: TObject);
private
fFlileFlag: string;
{ Private declarations }
procedure InitGrid();
procedure SetStatus();
public
FAuthority: string;
end;
var
frmCustomer: TfrmCustomer;
implementation
uses
U_DataLink, U_RTFun, U_ZDYHelp, U_CustomerInput, U_CustInput, U_UserSel,
U_AttachmentUpload;
{$R *.dfm}
procedure TfrmCustomer.SetStatus();
begin
btnSaleser.Enabled := false; //指定
btnTallyer.Enabled := false; //指定
btnChk.Visible := false; //审核
btnReChk.Visible := false; //撤销
if Trim(FAuthority) = '管理' then
begin
btnSaleser.Enabled := true;
btnTallyer.Enabled := true;
end;
end;
procedure TfrmCustomer.InitGrid();
var
WSql, FCoCode: string;
begin
WSql := SGetFilters(Panel1, 1, 2);
if trim(WSql) <> '' then
begin
WSql := ' and ' + trim(WSql);
end;
if not CDS_1.IsEmpty then
FCoCode := CDS_1.FieldByName('CoCode').AsString;
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Filtered := False;
Close;
SQL.Clear;
sql.Add(' select * from BS_Company ');
sql.Add(' where 1=1 ' + (WSql));
sql.Add(' and CoType=''客户'' and Valid=''Y'' ');
if Trim(FAuthority) = '录入' then
begin
sql.Add(' and ( SalesId=' + quotedstr(trim(DCode)) + ' or exists (select * from [dbo].[F_Tool_SplitString](TallyId,'','') X where X.RTValue =' + quotedstr(trim(DCode)) + '))');
end;
case cxTabControl1.TabIndex of
0:
begin
sql.Add(' and status=''0''');
end;
1:
begin
sql.Add(' and status=''1''');
end;
end;
SQL.Add(' ORDER BY CoCode ');
// showmessage(sql.Text);
Open;
end;
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
CDS_1.Locate('CoCode', FCoCode, []);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmCustomer.FormDestroy(Sender: TObject);
begin
inherited;
frmCustomer := nil;
end;
procedure TfrmCustomer.FormClose(Sender: TObject; var Action: TCloseAction);
begin
inherited;
Action := caFree;
end;
procedure TfrmCustomer.TBCloseClick(Sender: TObject);
begin
Close;
end;
procedure TfrmCustomer.TBDelClick(Sender: TObject);
begin
if CDS_1.IsEmpty then
Exit;
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
Exit;
if Trim(CDS_1.fieldbyname('COID').AsString) <> '' then
begin
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('exec P_BS_Com_Del @COID=' + quotedstr(trim(CDS_1.fieldbyname('COID').AsString)));
sql.Add(',@DCode=' + quotedstr(trim(DCode)));
sql.Add(',@DName=' + quotedstr(trim(DName)));
ExecSQL;
end;
end;
CDS_1.Delete;
end;
procedure TfrmCustomer.FormShow(Sender: TObject);
begin
inherited;
fFlileFlag := UserDataFlag + 'HX';
FAuthority := self.fParameters1;
ReadCxGrid(trim(self.caption) + 'Tv1', Tv1, '客户管理');
ReadCxGrid(trim(self.caption) + 'Tv2', Tv2, '客户管理');
SetStatus();
InitGrid();
end;
procedure TfrmCustomer.TBRafreshClick(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmCustomer.ToolButton1Click(Sender: TObject);
begin
WriteCxGrid(trim(self.caption) + 'Tv1', Tv1, '客户管理');
WriteCxGrid(trim(self.caption) + 'Tv2', Tv2, '客户管理');
end;
procedure TfrmCustomer.btnFindClick(Sender: TObject);
begin
if ADOQueryMain.Active then
begin
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, CDS_1);
SInitCDSData(ADOQueryMain, CDS_1);
end;
end;
procedure TfrmCustomer.ToolButton3Click(Sender: TObject);
begin
if CDS_1.IsEmpty then
Exit;
try
frmAttachmentUpload := TfrmAttachmentUpload.Create(Application);
with frmAttachmentUpload do
begin
if (Trim(FAuthority) = '录入') or (Trim(FAuthority) = '管理') then
FEditAuthority := True;
fkeyNO := Trim(Self.CDS_1.fieldbyname('Coid').AsString);
fType := '客户';
if ShowModal = 1 then
begin
end;
end;
finally
frmAttachmentUpload.Free;
end;
end;
procedure TfrmCustomer.CoCodeChange(Sender: TObject);
begin
btnFind.Click;
end;
procedure TfrmCustomer.CoCodeKeyPress(Sender: TObject; var Key: Char);
begin
if Key = #13 then
begin
InitGrid();
end;
end;
procedure TfrmCustomer.cxTabControl1Change(Sender: TObject);
begin
SetStatus();
TBRafresh.Click;
end;
procedure TfrmCustomer.btnEditClick(Sender: TObject);
begin
if CDS_1.IsEmpty then
exit;
try
frmCustInput := TfrmCustInput.Create(Application);
with frmCustInput do
begin
fFlileFlag := self.fFlileFlag;
FCOID := Trim(Self.CDS_1.fieldbyname('COID').AsString);
if ShowModal = 1 then
begin
TBRafresh.Click;
end;
end;
finally
frmCustInput.Free;
end;
end;
procedure TfrmCustomer.btnTallyerClick(Sender: TObject);
var
MTallyId, MTallyer: string;
begin
MTallyId := '';
MTallyer := '';
try
frmUserSel := TfrmUserSel.Create(Application);
with frmUserSel do
begin
Fdept := '理单';
FMultiple := True;
if ShowModal = 1 then
begin
while frmUserSel.CDS_1.Locate('SSel', True, []) do
begin
MTallyId := MTallyId + Trim(CDS_1.FieldByName('UserID').AsString) + ',';
MTallyer := MTallyer + Trim(CDS_1.FieldByName('UserName').AsString) + ',';
frmUserSel.CDS_1.Delete;
end;
end;
end;
finally
frmUserSel.Free;
end;
if MTallyId = '' then
Exit;
MTallyId := copy(MTallyId, 1, Length(MTallyId) - 1);
MTallyer := copy(MTallyer, 1, Length(MTallyer) - 1);
while CDS_1.Locate('SSel', True, []) do
begin
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('update BS_Company set TallyId=' + quotedstr(trim(MTallyId)));
sql.Add(' ,Tallyer=' + quotedstr(trim(MTallyer)));
sql.Add(' where COID=''' + Trim(CDS_1.fieldbyname('COID').AsString) + '''');
ExecSQL;
end;
CDS_1.Delete;
end;
InitGrid();
end;
procedure TfrmCustomer.btnChkClick(Sender: TObject);
begin
if CDS_1.IsEmpty then
exit;
try
with CDS_1 do
begin
DisableControls;
First;
while not eof do
begin
if fieldbyname('SSel').AsBoolean then
begin
with ADOQueryCmd do
begin
close;
sql.Clear;
sql.Add('update BS_Company SET status=''1'',Chktime=getdate(),Chker=' + quotedstr(trim(DName)));
sql.Add('where CoID=' + quotedstr(trim(CDS_1.fieldbyname('CoID').AsString)));
execsql;
end;
end;
next;
end;
First;
EnableControls;
end;
application.MessageBox('审核成功!', '提示信息');
TBRafresh.Click;
except
application.MessageBox('审核失败!', '提示信息', 0);
end;
end;
procedure TfrmCustomer.btnReChkClick(Sender: TObject);
begin
if CDS_1.IsEmpty then
exit;
try
with CDS_1 do
begin
DisableControls;
First;
while not eof do
begin
if fieldbyname('SSel').AsBoolean then
begin
with ADOQueryCmd do
begin
close;
sql.Clear;
sql.Add('update BS_Company SET status=''0'',Chktime=null,Chker=null ');
sql.Add('where CoID=' + quotedstr(trim(CDS_1.fieldbyname('CoID').AsString)));
execsql;
end;
end;
next;
end;
First;
EnableControls;
end;
application.MessageBox('撤销审核成功!', '提示信息');
TBRafresh.Click;
except
application.MessageBox('撤销审核失败!', '提示信息', 0);
end;
end;
procedure TfrmCustomer.btnAddClick(Sender: TObject);
begin
try
frmCustInput := TfrmCustInput.Create(Application);
with frmCustInput do
begin
FCOID := '';
fFlileFlag := self.fFlileFlag;
if ShowModal = 1 then
begin
InitGrid();
end;
end;
finally
frmCustInput.Free;
end;
end;
procedure TfrmCustomer.TBuserClick(Sender: TObject);
var
FuserName: string;
begin
end;
procedure TfrmCustomer.Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
begin
with ADOQueryTemp do
begin
Filtered := False;
Close;
SQL.Clear;
sql.Add(' select * from BS_Company_contact where COID=' + quotedstr(Trim(CDS_1.FieldByName('COID').AsString)));
Open;
end;
SCreateCDS(ADOQueryTemp, CDS_2);
SInitCDSData(ADOQueryTemp, CDS_2);
end;
procedure TfrmCustomer.btnSaleserClick(Sender: TObject);
var
MSaleser, MSalesId: string;
begin
try
frmUserSel := TfrmUserSel.Create(Application);
with frmUserSel do
begin
Fdept := '业务';
if ShowModal = 1 then
begin
MSalesId := Trim(CDS_1.fieldbyname('UserID').AsString);
MSaleser := Trim(CDS_1.fieldbyname('UserName').AsString);
end;
end;
finally
frmUserSel.Free;
end;
if MSalesId = '' then
Exit;
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('update BS_Company set Saleser=' + quotedstr(trim(MSaleser)));
sql.Add(' ,SalesId=' + quotedstr(trim(MSalesId)));
sql.Add(' where COID=''' + Trim(CDS_1.fieldbyname('COID').AsString) + '''');
ExecSQL;
end;
initgrid();
end;
procedure TfrmCustomer.FormCreate(Sender: TObject);
begin
inherited;
FAuthority := trim(fParameters1);
end;
end.

View File

@ -0,0 +1,219 @@
object frmCustomerInput: TfrmCustomerInput
Left = 261
Top = 149
Caption = #20844#21496#24405#20837
ClientHeight = 335
ClientWidth = 751
Color = clWhite
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
OldCreateOrder = True
Position = poScreenCenter
OnClose = FormClose
OnDestroy = FormDestroy
OnShow = FormShow
PixelsPerInch = 96
TextHeight = 12
object ToolBar1: TToolBar
Tag = 1
Left = 0
Top = 0
Width = 751
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 75
Caption = 'ToolBar1'
Color = clWhite
DisabledImages = DataLink_Company.ImageList_new32
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ShowCaptions = True
TabOrder = 0
object ToolButton3: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #20445#23384
ImageIndex = 16
OnClick = ToolButton3Click
end
object TBClose: TToolButton
Left = 71
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object ScrollBox1: TScrollBox
Left = 0
Top = 38
Width = 751
Height = 297
Align = alClient
BevelInner = bvNone
BevelOuter = bvNone
BorderStyle = bsNone
Color = clWhite
Ctl3D = False
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -14
Font.Name = #23435#20307
Font.Style = []
ParentColor = False
ParentCtl3D = False
ParentFont = False
TabOrder = 1
object Label2: TLabel
Left = 16
Top = 15
Width = 52
Height = 12
Caption = #20844#21496#32534#21495
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label6: TLabel
Left = 253
Top = 15
Width = 52
Height = 12
Caption = #20844#21496#21517#31216
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label39: TLabel
Left = 16
Top = 57
Width = 52
Height = 12
Caption = #20844#21496#22320#22336
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label7: TLabel
Left = 17
Top = 101
Width = 54
Height = 12
Caption = #22791' '#27880
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object Label3: TLabel
Left = 495
Top = 15
Width = 52
Height = 12
Caption = #20844#21496#31616#31216
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
end
object CoName: TEdit
Tag = 2
Left = 311
Top = 12
Width = 150
Height = 18
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
TabOrder = 1
end
object CoCode: TEdit
Tag = 2
Left = 73
Top = 12
Width = 150
Height = 18
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
TabOrder = 0
end
object CoAddress: TEdit
Tag = 2
Left = 73
Top = 55
Width = 621
Height = 18
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
TabOrder = 2
end
object CoNote: TMemo
Tag = 2
Left = 77
Top = 97
Width = 636
Height = 52
ScrollBars = ssVertical
TabOrder = 3
end
object CoAbbrName: TEdit
Tag = 2
Left = 553
Top = 10
Width = 141
Height = 20
TabOrder = 4
end
end
object ADOQueryTemp: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 331
Top = 200
end
object ADOQueryCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Parameters = <>
Left = 158
Top = 192
end
object ADOQueryMain: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 237
Top = 193
end
end

View File

@ -0,0 +1,276 @@
unit U_CustomerInput;
interface
uses
Windows, Messages, StrUtils, SysUtils, Variants, Classes, Graphics, Controls,
Forms, Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB,
ADODB, cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin,
StdCtrls, cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
cxTextEdit, cxDropDownEdit, BtnEdit, cxLookAndFeels, cxLookAndFeelPainters,
cxNavigator, dxSkinsCore, dxSkinsDefaultPainters, dxDateRanges,
dxBarBuiltInMenu, U_BaseList, cxContainer, dxCore, cxDateUtils, cxImage,
cxDBEdit, IdExplicitTLSClientServerBase;
type
TfrmCustomerInput = class(TForm)
ToolBar1: TToolBar;
TBClose: TToolButton;
ADOQueryTemp: TADOQuery;
ADOQueryCmd: TADOQuery;
ADOQueryMain: TADOQuery;
ToolButton3: TToolButton;
ScrollBox1: TScrollBox;
Label2: TLabel;
Label6: TLabel;
Label39: TLabel;
CoName: TEdit;
CoCode: TEdit;
CoAddress: TEdit;
Label7: TLabel;
CoNote: TMemo;
CoAbbrName: TEdit;
Label3: TLabel;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure TBCloseClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure TBRafreshClick(Sender: TObject);
procedure ToolButton3Click(Sender: TObject);
procedure CoareaBtnDnClick(Sender: TObject);
private
{ Private declarations }
procedure InitGrid();
function SaveData(): Boolean;
public
fFlileFlag: string;
fkhType: string;
{ Public declarations }
FCOID: string;
end;
var
frmCustomerInput: TfrmCustomerInput;
implementation
uses
U_DataLink, U_RTFun, U_ZDYHelp, getpic, U_YWYSel;
{$R *.dfm}
procedure TfrmCustomerInput.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Filtered := False;
Close;
SQL.Clear;
sql.Add(' select * from BS_Company where CoType=''我司'' and COID=''' + Trim(FCOID) + '''');
Open;
end;
SCSHData(ADOQueryMain, ScrollBox1, 2);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmCustomerInput.FormDestroy(Sender: TObject);
begin
frmCustomerInput := nil;
end;
procedure TfrmCustomerInput.FormClose(Sender: TObject; var Action: TCloseAction);
begin
Action := caFree;
end;
procedure TfrmCustomerInput.TBCloseClick(Sender: TObject);
begin
ModalResult := 1;
end;
procedure TfrmCustomerInput.FormShow(Sender: TObject);
begin
InitGrid();
if CoCode.Text <> '' then
exit;
with ADOQueryTemp do
begin
Close;
sql.Clear;
sql.Add(' exec P_BS_Com_Get_No @Str=''W'' ');
Open;
end;
CoCode.Text := trim(ADOQueryTemp.FieldByName('NewCoCode').asstring);
end;
procedure TfrmCustomerInput.TBRafreshClick(Sender: TObject);
begin
InitGrid();
end;
function TfrmCustomerInput.SaveData(): Boolean;
var
MaxId, MaxSubId, FCoCode, FCCID, MaxCFID: string;
begin
try
ADOQueryCmd.Connection.BeginTrans;
if Trim(FCOID) = '' then
begin
if GetLSNo(ADOQueryCmd, MaxId, 'CO', 'BS_Company', 4, 1) = False then
begin
Result := False;
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('取最大号失败!', '提示', 0);
Exit;
end;
if trim(CoCode.Text) = '' then
begin
with ADOQueryTemp do
begin
Close;
sql.Clear;
sql.Add(' exec P_BS_Com_Get_No @Str=''W'' ');
Open;
end;
CoCode.Text := trim(ADOQueryTemp.FieldByName('NewCoCode').asstring);
end;
end
else
begin
MaxId := Trim(FCOID);
end;
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('select * from BS_Company where COID=''' + Trim(FCOID) + '''');
Open;
end;
with ADOQueryCmd do
begin
if Trim(FCOID) = '' then
begin
Append;
FieldByName('Filler').Value := Trim(DName);
end
else
begin
Edit;
FieldByName('Editer').Value := Trim(DName);
FieldByName('Edittime').Value := SGetServerDateTime(ADOQueryTemp);
end;
FieldByName('COID').Value := Trim(MaxId);
RTSetsavedata(ADOQueryCmd, 'BS_Company', ScrollBox1, 2);
FieldByName('CoType').Value := '我司';
Post;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('select * from BS_Company where CoCode=' + quotedstr(trim(CoCode.Text)));
Open;
end;
if ADOQueryCmd.RecordCount > 1 then
begin
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('编号重复!', '提示', 0);
Exit;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('select * from BS_Company where CoName=' + quotedstr(trim(CoName.Text)));
sql.Add(' and CoType=''我司'' ');
Open;
end;
if ADOQueryCmd.RecordCount > 1 then
begin
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('名称重复!', '提示', 0);
Exit;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('select * from BS_Company where CoAbbrName=' + quotedstr(trim(CoAbbrName.Text)));
sql.Add(' and CoType=''我司'' ');
Open;
end;
if ADOQueryCmd.RecordCount > 1 then
begin
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('简称重复!', '提示', 0);
Exit;
end;
//////////////// 更新名称 ////////////////////////
// with ADOQueryCmd do
// begin
// Close;
// sql.Clear;
// sql.Add('exec P_Com_Up_Code @COID=' + quotedstr(Trim(MaxId)));
// ExecSQL;
// end;
//////////////// 更新名称 ////////////////////////
ADOQueryCmd.Connection.CommitTrans;
FCCID := Trim(MaxSubId);
Result := True;
except
Result := false;
ADOQueryCmd.Connection.RollbackTrans;
Application.MessageBox('保存异常!', '提示', 0);
end;
end;
procedure TfrmCustomerInput.ToolButton3Click(Sender: TObject);
begin
if Trim(CoAbbrName.Text) = '' then
begin
Application.MessageBox('简称不能为空!', '提示', 0);
Exit;
end;
if Trim(CoName.Text) = '' then
begin
Application.MessageBox('名称不能为空!', '提示', 0);
Exit;
end;
if SaveData() then
begin
Application.MessageBox('保存成功!', '提示', 0);
end;
end;
procedure TfrmCustomerInput.CoareaBtnDnClick(Sender: TObject);
begin
TBtnEditC(Sender).Text := '';
TBtnEditC(Sender).TxtCode := '';
end;
end.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,128 @@
unit U_DataLink;
interface
uses
SysUtils, Classes, DB, ADODB, ImgList, Controls, cxStyles, cxLookAndFeels,
Windows, Messages, forms, OleCtnrs, DateUtils, cxClasses, dxSkinsCore,
dxSkinsDefaultPainters, System.ImageList, Vcl.ExtCtrls, SyncObjs,
U_BaseDataLink, dxCore, cxLocalization, cxImageList, cxGraphics, dxSkinsForm;
type
TMyThread = class(TThread)
protected
procedure Execute; override;
end;
var
DConString: string; {全局连接字符串}
server, dtbase, user, pswd: string; {数据库连接参数}
DCurHandle: hwnd; //当前窗体句柄
DName: string; //#用户名#//
DCode: string; //#用户编号#//
Ddatabase: string; //#数据库名称#//
DTitCaption: string; //#主窗体名称#//
fDllFileName: string;
DParameters1, DParameters2, DParameters3, DParameters4, DParameters5: string; // 外部参数;
DParameters6, DParameters7, DParameters8, DParameters9, DParameters10: string; //外部参数;
OldDllApp: Tapplication; //保存原有句柄
NewDllApp: Tapplication; //当前句柄
MainApplication: Tapplication;
DFormCode: integer; //当前窗口号
IsDelphiLanguage: integer;
DServerDate: TdateTime; //服务器时间
DCompany: string; //公司
PicSvr: string;
UserDataFlag: string;
type
TDataLink_Company = class(TBaseDataLink)
AdoDataLink: TADOQuery;
ADOLink: TADOConnection;
ThreeImgList: TImageList;
ThreeLookAndFeelCol: TcxLookAndFeelController;
ThreeColorBase: TcxStyleRepository;
SHuangSe: TcxStyle;
SkyBlue: TcxStyle;
Default: TcxStyle;
QHuangSe: TcxStyle;
Red: TcxStyle;
FontBlue: TcxStyle;
TextSHuangSe: TcxStyle;
FonePurple: TcxStyle;
FoneClMaroon: TcxStyle;
FoneRed: TcxStyle;
RowColor: TcxStyle;
handBlack: TcxStyle;
cxBlue: TcxStyle;
SHuangSeCu: TcxStyle;
ImageList_new32: TImageList;
Timer_link: TTimer;
procedure DataModuleDestroy(Sender: TObject);
procedure DataModuleCreate(Sender: TObject);
procedure Timer_linkTimer(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
TMakebar = procedure(ucData: pchar; nDataLen: integer; nErrLevel: integer; nMask: integer; nBarEdition: integer; szBmpFileName: pchar; nScale: integer); stdcall;
TMixtext = procedure(szSrcBmpFileName: PChar; szDstBmpFileName: PChar; sztext: PChar; fontsize, txtheight, hmargin, vmargin, txtcntoneline: integer); stdcall;
var
DataLink_Company: TDataLink_Company;
CriticalSection: TCriticalSection; {声明临界}
implementation
{$R *.dfm}
procedure TMyThread.Execute;
begin
FreeOnTerminate := True;
CriticalSection.Enter;
try
with DataLink_Company.AdoDataLink do
begin
close;
sql.Clear;
sql.Add('select getdate()');
open;
end;
except
try
with DataLink_Company.ADOLink do
begin
Connected := false;
ConnectionString := DConString;
LoginPrompt := false;
Connected := true;
end;
except
end;
end;
CriticalSection.Leave;
end;
procedure TDataLink_Company.DataModuleCreate(Sender: TObject);
begin
inherited;
CriticalSection := TCriticalSection.Create;
end;
procedure TDataLink_Company.DataModuleDestroy(Sender: TObject);
begin
CriticalSection.Free;
DataLink_Company := nil;
end;
procedure TDataLink_Company.Timer_linkTimer(Sender: TObject);
begin
inherited;
TMyThread.Create(False);
end;
end.

View File

@ -0,0 +1,70 @@
object frmDeptTypeHelp: TfrmDeptTypeHelp
Left = 526
Top = 238
Caption = #37096#38376#36873#25321#21015#34920
ClientHeight = 485
ClientWidth = 355
Color = clBtnFace
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
OldCreateOrder = False
Position = poScreenCenter
OnCreate = FormCreate
OnShow = FormShow
PixelsPerInch = 96
TextHeight = 12
object cxDBTreeList1: TcxDBTreeList
Left = 0
Top = 0
Width = 225
Height = 485
Align = alLeft
Bands = <
item
end>
DataController.DataSource = DataSource1
DataController.ParentField = 'DPParent'
DataController.KeyField = 'DPID'
Navigator.Buttons.CustomButtons = <>
OptionsBehavior.CopyCaptionsToClipboard = False
OptionsBehavior.ExpandOnDblClick = False
OptionsSelection.CellSelect = False
OptionsView.CellAutoHeight = True
OptionsView.Headers = False
RootValue = -1
Styles.Inactive = DataLink_StaffManage.Red
Styles.Selection = DataLink_StaffManage.Red
Styles.IncSearch = DataLink_StaffManage.Red
TabOrder = 0
OnDblClick = cxDBTreeList1DblClick
ExplicitHeight = 486
object cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn
DataBinding.FieldName = 'DPName'
Width = 210
Position.ColIndex = 0
Position.RowIndex = 0
Position.BandIndex = 0
Summary.FooterSummaryItems = <>
Summary.GroupFooterSummaryItems = <>
end
end
object ADOConnection1: TADOConnection
LoginPrompt = False
Left = 288
Top = 60
end
object DataSource1: TDataSource
DataSet = ADOQueryHelp
Left = 280
Top = 188
end
object ADOQueryHelp: TADOQuery
Connection = ADOConnection1
Parameters = <>
Left = 288
Top = 136
end
end

View File

@ -0,0 +1,73 @@
unit U_DeptTypeHelp;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit,
cxInplaceContainer, cxDBTL, cxControls, cxTLData, DB, ADODB, cxLookAndFeels,
cxLookAndFeelPainters, cxTLdxBarBuiltInMenu, dxSkinsCore,
dxSkinsDefaultPainters;
type
TfrmDeptTypeHelp = class(TForm)
ADOConnection1: TADOConnection;
DataSource1: TDataSource;
ADOQueryHelp: TADOQuery;
cxDBTreeList1: TcxDBTreeList;
cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn;
procedure FormCreate(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure cxDBTreeList1DblClick(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
frmDeptTypeHelp: TfrmDeptTypeHelp;
implementation
uses
U_DataLink;
{$R *.dfm}
procedure TfrmDeptTypeHelp.FormCreate(Sender: TObject);
begin
cxDBTreeList1.Align := alclient;
try
with ADOConnection1 do
begin
Connected := false;
ConnectionString := DConString;
//ConnectionString:='';
Connected := true;
end;
except
end;
end;
procedure TfrmDeptTypeHelp.FormShow(Sender: TObject);
begin
with ADOQueryHelp do
begin
Close;
SQL.Clear;
SQL.Add('select * from SY_Dept order by DPlevel,DPOrder,DPName');
// SQL.Add('select * from CP_Type order by CPlevel,CPOrder,CPName');
Open;
end;
cxDBTreeList1.Items[0].Expand(false);
end;
procedure TfrmDeptTypeHelp.cxDBTreeList1DblClick(Sender: TObject);
begin
if ADOQueryHelp.IsEmpty then
exit;
ModalResult := 1;
end;
end.

View File

@ -0,0 +1,200 @@
object frmYGInPut: TfrmYGInPut
Left = 191
Top = 31
Caption = #21592#24037#26723#26696#24405#20837
ClientHeight = 532
ClientWidth = 1144
Color = clWhite
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
OldCreateOrder = False
Position = poScreenCenter
OnShow = FormShow
PixelsPerInch = 96
TextHeight = 12
object ToolBar1: TToolBar
Tag = 1
Left = 0
Top = 0
Width = 1144
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 75
Caption = 'ToolBar1'
Color = clBtnFace
DisabledImages = DataLink_Company.ImageList_new32
EdgeInner = esNone
EdgeOuter = esNone
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ParentFont = False
ShowCaptions = True
TabOrder = 0
object TBSave: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #20445#23384
ImageIndex = 16
OnClick = TBSaveClick
end
object ToolButton1: TToolButton
Left = 71
Top = 0
Caption = #22686#34892
ImageIndex = 2
OnClick = ToolButton1Click
end
object ToolButton2: TToolButton
Left = 146
Top = 0
Caption = #21024#34892
ImageIndex = 6
OnClick = ToolButton2Click
end
object TBClose: TToolButton
Left = 221
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object cxGrid1: TcxGrid
Left = 0
Top = 38
Width = 1144
Height = 494
Align = alClient
TabOrder = 1
object Tv1: TcxGridDBTableView
Navigator.Buttons.CustomButtons = <>
DataController.DataSource = DataSource1
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <>
DataController.Summary.SummaryGroups = <>
OptionsCustomize.ColumnFiltering = False
OptionsView.GroupByBox = False
OptionsView.GroupFooters = gfAlwaysVisible
Styles.Header = cxStyle1
object v1RuZhiDate: TcxGridDBColumn
Caption = #20837#32844#26085#26399
DataBinding.FieldName = 'EntryDate'
HeaderAlignmentHorz = taCenter
Width = 70
end
object v1YGNo: TcxGridDBColumn
Caption = #21592#24037#32534#21495
DataBinding.FieldName = 'EECode'
HeaderAlignmentHorz = taCenter
Width = 75
end
object v1YGName: TcxGridDBColumn
Caption = #22995#21517
DataBinding.FieldName = 'EEName'
HeaderAlignmentHorz = taCenter
Width = 88
end
object v1Column1: TcxGridDBColumn
Caption = #37096#38376
DataBinding.FieldName = 'Dept'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 80
end
object v1GangWei: TcxGridDBColumn
Caption = #23703#20301
DataBinding.FieldName = 'Post'
HeaderAlignmentHorz = taCenter
Width = 82
end
object v1SFZNo: TcxGridDBColumn
Caption = #29983#26085
DataBinding.FieldName = 'Birthday'
HeaderAlignmentHorz = taCenter
Width = 70
end
object v1YGSex: TcxGridDBColumn
Caption = #24615#21035
DataBinding.FieldName = 'Sex'
PropertiesClassName = 'TcxComboBoxProperties'
Properties.DropDownListStyle = lsEditFixedList
Properties.Items.Strings = (
#30007
#22899)
HeaderAlignmentHorz = taCenter
Width = 85
end
object v1Phone: TcxGridDBColumn
Caption = #25163#26426
DataBinding.FieldName = 'Phone'
HeaderAlignmentHorz = taCenter
Width = 91
end
object Tv1Column1: TcxGridDBColumn
Caption = #36523#20221#35777
DataBinding.FieldName = 'IdCard'
HeaderAlignmentHorz = taCenter
Width = 73
end
end
object cxGrid1Level1: TcxGridLevel
GridView = Tv1
end
end
object ADOTemp: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 496
Top = 157
end
object ADOCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Parameters = <>
Left = 341
Top = 135
end
object DataSource1: TDataSource
DataSet = Order_Sub
Left = 666
Top = 145
end
object Order_Sub: TClientDataSet
Aggregates = <>
Params = <>
Left = 760
Top = 178
end
object cxStyleRepository1: TcxStyleRepository
Left = 616
Top = 80
PixelsPerInch = 96
object cxStyle1: TcxStyle
AssignedValues = [svFont]
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = 'MS Sans Serif'
Font.Style = [fsBold]
end
end
object cxGridPopupMenu1: TcxGridPopupMenu
Grid = cxGrid1
PopupMenus = <>
Left = 566
Top = 201
end
end

View File

@ -0,0 +1,315 @@
unit U_EmployeeInPut;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
cxEdit, DB, cxDBData, cxGridLevel, cxGridCustomTableView, cxGridTableView,
cxGridDBTableView, cxClasses, cxControls, cxGridCustomView, cxGrid, cxMemo,
cxRichEdit, ComCtrls, cxContainer, cxTextEdit, cxMaskEdit, cxButtonEdit,
StdCtrls, ToolWin, DBClient, ADODB, ExtCtrls, BtnEdit, cxCalendar, StrUtils,
cxDropDownEdit, jpeg, IdBaseComponent, IdComponent, IdTCPConnection,
IdTCPClient, IdFTP, cxPC, cxGridCustomPopupMenu, cxGridPopupMenu, Menus,
ExtDlgs, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxSkinsCore,
dxSkinsDefaultPainters, dxDateRanges, dxBarBuiltInMenu;
type
TfrmYGInPut = class(TForm)
ToolBar1: TToolBar;
TBClose: TToolButton;
ADOTemp: TADOQuery;
ADOCmd: TADOQuery;
TBSave: TToolButton;
DataSource1: TDataSource;
Order_Sub: TClientDataSet;
ToolButton1: TToolButton;
ToolButton2: TToolButton;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
v1YGName: TcxGridDBColumn;
v1Column1: TcxGridDBColumn;
v1GangWei: TcxGridDBColumn;
v1YGSex: TcxGridDBColumn;
v1Phone: TcxGridDBColumn;
cxGrid1Level1: TcxGridLevel;
cxStyleRepository1: TcxStyleRepository;
cxStyle1: TcxStyle;
v1RuZhiDate: TcxGridDBColumn;
cxGridPopupMenu1: TcxGridPopupMenu;
v1SFZNo: TcxGridDBColumn;
v1YGNo: TcxGridDBColumn;
Tv1Column1: TcxGridDBColumn;
procedure TBCloseClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure TBSaveClick(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
procedure v1SYRNamePropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
procedure v1Column2PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
private
TPInt: Integer;
procedure InitData();
function SaveData(): Boolean;
function SaveMXData(Tv11: TcxGridDBTableView; CDS1: TClientDataSet; FMaxNo, FYOType: string): Boolean;
procedure SaveImageOther();
procedure InitImage();
{ Private declarations }
public
canshu1: string;
PState, CopyInt: Integer;
FMainId, FDPID, FDPName: string;
{ Public declarations }
end;
var
frmYGInPut: TfrmYGInPut;
implementation
uses
U_DataLink, U_ZDYHelp, U_RTFun;
{$R *.dfm}
procedure TfrmYGInPut.TBCloseClick(Sender: TObject);
begin
WriteCxGrid('员工档案录入2', Tv1, '管理');
Close;
end;
procedure TfrmYGInPut.InitData();
begin
with ADOCmd do
begin
Close;
sql.Clear;
sql.Add('select * from SY_Employee where EEID=''' + Trim(FMainId) + '''');
Open;
end;
SCreateCDS(ADOCmd, Order_Sub);
SInitCDSData(ADOCmd, Order_Sub);
end;
procedure TfrmYGInPut.FormShow(Sender: TObject);
begin
ReadCxGrid('员工档案录入2', Tv1, '管理');
InitData();
end;
function TfrmYGInPut.SaveData(): Boolean;
var
maxno, FHZStatus: string;
begin
Result := False;
try
ADOCmd.Connection.BeginTrans;
with Order_Sub do
begin
first;
while not eof do
begin
if Trim(Order_Sub.fieldbyname('EEID').AsString) = '' then
begin
if GetLSNo(ADOCmd, maxno, 'OA', 'SY_Employee', 4, 1) = False then
begin
ADOCmd.Connection.RollbackTrans;
Application.MessageBox('取最大号失败!', '提示', 0);
Exit;
end;
end
else
begin
maxno := Trim(Order_Sub.fieldbyname('EEID').AsString);
end;
with ADOCmd do
begin
Close;
sql.Clear;
SQL.Add('select * from SY_Employee where EEID=''' + Trim(maxno) + '''');
Open;
end;
with ADOCmd do
begin
if ADOCmd.IsEmpty then
begin
Append;
FieldByName('Filler').Value := Trim(DName);
end
else
begin
edit;
FieldByName('Editer').Value := Trim(DName);
FieldByName('Edittime').Value := SGetServerDateTime(ADOTemp);
end;
FieldByName('EEID').Value := Trim(maxno);
FieldByName('EEType').Value := '正式';
fieldbyname('DPID').Value := Trim(FDPID);
RTSetSaveDataCDS(ADOCmd, Tv1, Order_Sub, 'SY_Employee', 0);
post;
end;
with ADOCmd do
begin
Close;
SQL.Clear;
sql.Add('select * from SY_Employee where EECode=''' + Trim(Order_Sub.fieldbyname('EECode').AsString) + '''');
Open;
end;
if ADOCmd.RecordCount > 1 then
begin
ADOCmd.Connection.RollbackTrans;
application.MessageBox(PChar('员工编号' + trim(ADOCmd.fieldbyname('EECode').AsString) + '已存在'), '提示');
Exit;
end;
with Order_Sub do
begin
Edit;
FieldByName('EEID').Value := Trim(maxno);
end;
with ADOCmd do
begin
Close;
SQL.Clear;
sql.Add('exec P_EE_in_Account @DataID=''' + Trim(maxno) + '''');
Open;
end;
if ADOCmd.FieldByName('intReturn').AsInteger = -1 then
begin
ADOCmd.Connection.RollbackTrans;
Application.MessageBox(PChar(ADOCmd.fieldbyname('ShowMsg').AsString), '提示', 0);
exit;
end;
next;
end;
end;
ADOCmd.Connection.CommitTrans;
Result := True;
except
;
Result := False;
ADOCmd.Connection.RollbackTrans;
Application.MessageBox('保存失败!', '提示', 0);
end;
end;
function TfrmYGInPut.SaveMXData(Tv11: TcxGridDBTableView; CDS1: TClientDataSet; FMaxNo, FYOType: string): Boolean;
begin
end;
procedure TfrmYGInPut.InitImage();
begin
end;
procedure TfrmYGInPut.TBSaveClick(Sender: TObject);
var
FSFNO: string;
begin
ToolBar1.SetFocus;
if Order_Sub.Locate('IdCard', '', []) = true then
begin
application.MessageBox('身份证不能为空', '提示');
exit;
end;
if SaveData() then
begin
Application.MessageBox('保存成功!', '提示', 0);
ModalResult := 1;
end;
end;
procedure TfrmYGInPut.SaveImageOther();
begin
end;
procedure TfrmYGInPut.ToolButton1Click(Sender: TObject);
begin
with Order_Sub do
begin
Append;
fieldbyname('EntryDate').Value := SGetServerDate(ADOTemp);
FieldByName('Dept').Value := Trim(FDPName);
Post;
end;
end;
procedure TfrmYGInPut.ToolButton2Click(Sender: TObject);
begin
if Order_Sub.IsEmpty then
Exit;
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
Exit;
if Trim(Order_Sub.fieldbyname('EEID').AsString) <> '' then
begin
with ADOCmd do
begin
Close;
sql.Clear;
sql.Add('delete SY_Employee where EEID=''' + Trim(Order_Sub.fieldbyname('EEID').AsString) + '''');
ExecSQL;
end;
with ADOCmd do
begin
Close;
SQL.Clear;
sql.Add('exec P_EE_in_Account @DataID=''' + Trim(Order_Sub.fieldbyname('EEID').AsString) + '''');
Open;
end;
if ADOCmd.FieldByName('intReturn').AsInteger = -1 then
begin
Application.MessageBox(PChar(ADOCmd.fieldbyname('ShowMsg').AsString), '提示', 0);
exit;
end;
end;
Order_Sub.Delete;
end;
procedure TfrmYGInPut.v1SYRNamePropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
begin
frmZDYHelp := TfrmZDYHelp.Create(self);
with frmZDYHelp do
begin
flag := 'SYRName';
flagName := '车间';
if ShowModal = 1 then
begin
with Order_Sub do
begin
edit;
FieldByName('SYRName').Value := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
end;
end;
free;
end;
end;
procedure TfrmYGInPut.v1Column2PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
begin
try
frmZDYHelp := TfrmZDYHelp.Create(Application);
with frmZDYHelp do
begin
flag := 'BZName';
flagname := '班组名称';
if ShowModal = 1 then
begin
with Order_Sub do
begin
Edit;
FieldByName('BZName').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
end;
end;
end;
finally
frmZDYHelp.Free;
end;
end;
end.

View File

@ -0,0 +1,567 @@
inherited frmEmployeeList: TfrmEmployeeList
Top = 39
Caption = #21592#24037#26723#26696#21015#34920
ClientHeight = 660
ClientWidth = 1432
ExplicitWidth = 1448
ExplicitHeight = 699
PixelsPerInch = 96
TextHeight = 12
object ToolBar1: TToolBar [0]
Tag = 1
Left = 0
Top = 0
Width = 1432
Height = 38
AutoSize = True
ButtonHeight = 38
ButtonWidth = 115
Caption = 'ToolBar1'
Color = clSkyBlue
DisabledImages = DataLink_Company.ImageList_new32
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = #23435#20307
Font.Style = []
Images = DataLink_Company.ImageList_new32
List = True
ParentColor = False
ParentFont = False
ShowCaptions = True
TabOrder = 0
object TBRafresh: TToolButton
Left = 0
Top = 0
AutoSize = True
Caption = #21047#26032
ImageIndex = 1
OnClick = TBRafreshClick
end
object TBFind: TToolButton
Left = 71
Top = 0
AutoSize = True
Caption = #36807#28388
ImageIndex = 0
OnClick = TBFindClick
end
object TBAdd: TToolButton
Left = 142
Top = 0
AutoSize = True
Caption = #26032#22686
ImageIndex = 9
OnClick = TBAddClick
end
object TBEdit: TToolButton
Left = 213
Top = 0
AutoSize = True
Caption = #20462#25913
ImageIndex = 3
OnClick = TBEditClick
end
object TBDel: TToolButton
Left = 284
Top = 0
AutoSize = True
Caption = #21024#38500
ImageIndex = 3
OnClick = TBDelClick
end
object ToolButton2: TToolButton
Left = 355
Top = 0
AutoSize = True
Caption = #37096#38376#35843#25972
ImageIndex = 19
OnClick = ToolButton2Click
end
object TLZ: TToolButton
Left = 450
Top = 0
AutoSize = True
Caption = #31163#32844
ImageIndex = 17
OnClick = TLZClick
end
object Panel2: TPanel
Left = 521
Top = 0
Width = 155
Height = 38
BevelInner = bvRaised
BevelOuter = bvLowered
Color = clWhite
ParentBackground = False
TabOrder = 0
DesignSize = (
155
38)
object Label6: TLabel
Left = 10
Top = 11
Width = 48
Height = 12
Anchors = [akLeft]
Caption = #31163#32844#26085#26399
end
object SJLiZhiDate: TDateTimePicker
Left = 60
Top = 7
Width = 90
Height = 20
Anchors = [akLeft]
Date = 43292.000000000000000000
Time = 0.850766331022896300
TabOrder = 0
end
end
object TCXLZ: TToolButton
Left = 676
Top = 0
AutoSize = True
Caption = #25764#38144#31163#32844
ImageIndex = 11
OnClick = TCXLZClick
end
object ToolButton1: TToolButton
Left = 771
Top = 0
AutoSize = True
Caption = #21592#24037#29031#29255#19978#20256
ImageIndex = 15
Visible = False
OnClick = ToolButton1Click
end
object TBView: TToolButton
Left = 890
Top = 0
AutoSize = True
Caption = #26597#30475
ImageIndex = 8
OnClick = TBViewClick
end
object TBExport: TToolButton
Left = 961
Top = 0
AutoSize = True
Caption = #23548#20986
ImageIndex = 20
OnClick = TBExportClick
end
object TBClose: TToolButton
Left = 1032
Top = 0
AutoSize = True
Caption = #20851#38381
ImageIndex = 7
OnClick = TBCloseClick
end
end
object Panel1: TPanel [1]
Left = 0
Top = 38
Width = 1432
Height = 38
Align = alTop
BevelInner = bvRaised
BevelOuter = bvLowered
Color = clWhite
ParentBackground = False
TabOrder = 1
object Label1: TLabel
Left = 224
Top = 12
Width = 24
Height = 12
Caption = #22995#21517
end
object Label2: TLabel
Left = 530
Top = 12
Width = 24
Height = 12
Caption = #24615#21035
end
object Label5: TLabel
Left = 674
Top = 12
Width = 24
Height = 12
Caption = #23703#20301
end
object Label4: TLabel
Left = 381
Top = 12
Width = 24
Height = 12
Caption = #37096#38376
end
object Label3: TLabel
Left = 823
Top = 12
Width = 24
Height = 12
Caption = #36710#38388
end
object Label7: TLabel
Left = 43
Top = 12
Width = 48
Height = 12
Caption = #21592#24037#32534#21495
end
object YGName: TEdit
Tag = 2
Left = 273
Top = 8
Width = 83
Height = 20
TabOrder = 0
OnChange = YGNameChange
end
object YGSex: TComboBox
Tag = 1
Left = 579
Top = 8
Width = 70
Height = 20
Style = csDropDownList
TabOrder = 1
OnChange = YGNameChange
Items.Strings = (
#30007
#22899
'')
end
object GangWei: TEdit
Tag = 2
Left = 723
Top = 8
Width = 75
Height = 20
TabOrder = 2
OnChange = YGNameChange
end
object Dept: TEdit
Tag = 2
Left = 430
Top = 8
Width = 75
Height = 20
TabOrder = 3
OnChange = YGNameChange
end
object SYRName: TEdit
Tag = 2
Left = 872
Top = 8
Width = 75
Height = 20
TabOrder = 4
OnChange = YGNameChange
end
object YGNo: TEdit
Tag = 2
Left = 116
Top = 8
Width = 83
Height = 20
TabOrder = 5
OnChange = YGNameChange
end
end
object cxDBTreeList1: TcxDBTreeList [2]
Left = 0
Top = 76
Width = 225
Height = 584
Align = alLeft
Bands = <
item
end>
DataController.DataSource = DataSource2
DataController.ParentField = 'DPParent'
DataController.KeyField = 'DPID'
Navigator.Buttons.CustomButtons = <>
OptionsBehavior.CopyCaptionsToClipboard = False
OptionsBehavior.ExpandOnDblClick = False
OptionsSelection.CellSelect = False
OptionsView.CellAutoHeight = True
OptionsView.Headers = False
RootValue = -1
Styles.Inactive = DataLink_Company.Red
Styles.Selection = DataLink_Company.Red
Styles.IncSearch = DataLink_Company.Red
TabOrder = 2
OnDblClick = cxDBTreeList1DblClick
object cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn
DataBinding.FieldName = 'DPName'
Width = 210
Position.ColIndex = 0
Position.RowIndex = 0
Position.BandIndex = 0
Summary.FooterSummaryItems = <>
Summary.GroupFooterSummaryItems = <>
end
end
object cxSplitter1: TcxSplitter [3]
Left = 225
Top = 76
Width = 8
Height = 584
HotZoneClassName = 'TcxMediaPlayer9Style'
Control = cxDBTreeList1
end
object TPanel [4]
Left = 233
Top = 76
Width = 1199
Height = 584
Align = alClient
BevelInner = bvRaised
BevelOuter = bvLowered
TabOrder = 4
object cxTabControl1: TcxTabControl
Left = 2
Top = 2
Width = 1195
Height = 25
Align = alTop
Font.Charset = GB2312_CHARSET
Font.Color = clWindowText
Font.Height = -16
Font.Name = #23435#20307
Font.Style = [fsBold]
ParentFont = False
TabOrder = 0
Properties.CustomButtons.Buttons = <>
Properties.Style = 3
Properties.TabIndex = 0
Properties.Tabs.Strings = (
#22312#32844
#31163#32844
#20840#37096)
OnChange = cxTabControl1Change
ClientRectBottom = 28
ClientRectRight = 1195
ClientRectTop = 28
end
object cxGrid1: TcxGrid
Left = 2
Top = 27
Width = 1195
Height = 555
Align = alClient
PopupMenu = PopupMenu1
TabOrder = 1
object Tv1: TcxGridDBTableView
Navigator.Buttons.CustomButtons = <>
DataController.DataSource = DataSource1
DataController.Filter.AutoDataSetFilter = True
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
DataController.Summary.DefaultGroupSummaryItems = <>
DataController.Summary.FooterSummaryItems = <>
DataController.Summary.SummaryGroups = <>
OptionsCustomize.ColumnFiltering = False
OptionsView.Footer = True
OptionsView.GroupByBox = False
OptionsView.GroupFooters = gfAlwaysVisible
Styles.Header = cxStyle1
object v1Column4: TcxGridDBColumn
Caption = #36873#25321
DataBinding.FieldName = 'SSel'
PropertiesClassName = 'TcxCheckBoxProperties'
Properties.ImmediatePost = True
HeaderAlignmentHorz = taCenter
Width = 52
end
object v1RuZhiDate: TcxGridDBColumn
Caption = #20837#32844#26085#26399
DataBinding.FieldName = 'EntryDate'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 84
end
object v1YGNo: TcxGridDBColumn
Caption = #32534#21495
DataBinding.FieldName = 'EECode'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 70
end
object v1YGName: TcxGridDBColumn
Caption = #22995#21517
DataBinding.FieldName = 'EEName'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 88
end
object v1Column1: TcxGridDBColumn
Caption = #37096#38376
DataBinding.FieldName = 'Dept'
PropertiesClassName = 'TcxButtonEditProperties'
Properties.Buttons = <
item
Default = True
Kind = bkEllipsis
end>
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 80
end
object v1Column2: TcxGridDBColumn
Caption = #23703#20301
DataBinding.FieldName = 'Post'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 82
end
object v1Column8: TcxGridDBColumn
Caption = #31867#21035
DataBinding.FieldName = 'EEType'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 78
end
object v1SFZNo: TcxGridDBColumn
Caption = #36523#20221#35777#21495
DataBinding.FieldName = 'IdCard'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 70
end
object v1Column6: TcxGridDBColumn
Caption = #24615#21035
DataBinding.FieldName = 'Sex'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 85
end
object v1Column29: TcxGridDBColumn
Caption = #25163#26426
DataBinding.FieldName = 'Phone'
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 91
end
object v1SJLiZhiDate: TcxGridDBColumn
Caption = #31163#32844#26085#26399
DataBinding.FieldName = 'SJLiZhiDate'
PropertiesClassName = 'TcxDateEditProperties'
Properties.SaveTime = False
Properties.ShowTime = False
Visible = False
HeaderAlignmentHorz = taCenter
Options.Editing = False
Width = 70
end
object Tv1Column1: TcxGridDBColumn
Caption = #31163#32844#26102#38388
DataBinding.FieldName = 'DepartureDate'
HeaderAlignmentHorz = taCenter
Width = 69
end
end
object cxGrid1Level1: TcxGridLevel
GridView = Tv1
end
end
end
inherited ADOQueryBaseCmd: TADOQuery
Connection = DataLink_Company.ADOLink
end
inherited ADOQueryBaseTemp: TADOQuery
Connection = DataLink_Company.ADOLink
Left = 385
Top = 129
end
object cxGridPopupMenu1: TcxGridPopupMenu
Grid = cxGrid1
PopupMenus = <>
Left = 563
Top = 201
end
object ADOQueryCmd: TADOQuery
Connection = DataLink_Company.ADOLink
Parameters = <>
Left = 432
Top = 200
end
object ADOQueryMain: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 392
Top = 200
end
object ADOQueryTemp: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 357
Top = 203
end
object DataSource1: TDataSource
DataSet = Order_Main
Left = 497
Top = 201
end
object Order_Main: TClientDataSet
Aggregates = <>
Params = <>
Left = 531
Top = 200
end
object PopupMenu1: TPopupMenu
Left = 321
Top = 205
object N2: TMenuItem
Caption = #20840#36873
OnClick = N2Click
end
object N1: TMenuItem
Caption = #20840#24323
OnClick = N1Click
end
end
object DataSource2: TDataSource
DataSet = CDS_Tree
Left = 147
Top = 219
end
object CDS_Tree: TClientDataSet
Aggregates = <>
Params = <>
Left = 96
Top = 256
end
object ADOQueryTree: TADOQuery
Connection = DataLink_Company.ADOLink
LockType = ltReadOnly
Parameters = <>
Left = 117
Top = 145
end
object ADOQuery1: TADOQuery
Connection = DataLink_Company.ADOLink
Parameters = <>
Left = 460
Top = 200
end
object cxStyleRepository1: TcxStyleRepository
Left = 48
Top = 96
PixelsPerInch = 96
object cxStyle1: TcxStyle
AssignedValues = [svFont]
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -12
Font.Name = 'MS Sans Serif'
Font.Style = [fsBold]
end
end
end

View File

@ -0,0 +1,617 @@
unit U_EmployeeList;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ExtCtrls, ComCtrls, ToolWin, cxStyles, cxCustomData,
cxGraphics, cxFilter, cxData, cxDataStorage, cxEdit, DB, cxDBData, ADODB,
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxClasses, cxControls,
cxGridCustomView, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
cxGrid, DBClient, cxCheckBox, cxCalendar, cxSplitter, RM_Dataset, RM_System,
RM_Common, RM_Class, RM_GridReport, RM_e_Xls, Menus, cxButtonEdit,
cxDropDownEdit, cxPC, cxTL, cxMaskEdit, cxInplaceContainer, cxDBTL, cxTLData,
cxLookAndFeels, cxLookAndFeelPainters, cxTLdxBarBuiltInMenu, dxBarBuiltInMenu,
cxNavigator, U_BaseList, dxSkinsCore, dxSkinsDefaultPainters, dxDateRanges;
type
TfrmEmployeeList = class(TfrmBaseList)
ToolBar1: TToolBar;
TBRafresh: TToolButton;
TBFind: TToolButton;
TBAdd: TToolButton;
TBEdit: TToolButton;
TBDel: TToolButton;
TBClose: TToolButton;
cxGridPopupMenu1: TcxGridPopupMenu;
ADOQueryCmd: TADOQuery;
ADOQueryMain: TADOQuery;
ADOQueryTemp: TADOQuery;
DataSource1: TDataSource;
TBExport: TToolButton;
Order_Main: TClientDataSet;
TBView: TToolButton;
Panel1: TPanel;
PopupMenu1: TPopupMenu;
N2: TMenuItem;
N1: TMenuItem;
Label1: TLabel;
YGName: TEdit;
Label2: TLabel;
YGSex: TComboBox;
Label5: TLabel;
GangWei: TEdit;
cxDBTreeList1: TcxDBTreeList;
cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn;
DataSource2: TDataSource;
CDS_Tree: TClientDataSet;
ADOQueryTree: TADOQuery;
cxSplitter1: TcxSplitter;
cxTabControl1: TcxTabControl;
TLZ: TToolButton;
ADOQuery1: TADOQuery;
TCXLZ: TToolButton;
cxStyleRepository1: TcxStyleRepository;
cxStyle1: TcxStyle;
cxGrid1: TcxGrid;
Tv1: TcxGridDBTableView;
v1RuZhiDate: TcxGridDBColumn;
v1YGName: TcxGridDBColumn;
v1Column1: TcxGridDBColumn;
v1Column2: TcxGridDBColumn;
v1Column8: TcxGridDBColumn;
v1Column6: TcxGridDBColumn;
v1Column29: TcxGridDBColumn;
v1SJLiZhiDate: TcxGridDBColumn;
cxGrid1Level1: TcxGridLevel;
Label4: TLabel;
Dept: TEdit;
v1SFZNo: TcxGridDBColumn;
Label3: TLabel;
SYRName: TEdit;
Panel2: TPanel;
Label6: TLabel;
SJLiZhiDate: TDateTimePicker;
ToolButton1: TToolButton;
v1YGNo: TcxGridDBColumn;
Label7: TLabel;
YGNo: TEdit;
ToolButton2: TToolButton;
v1Column4: TcxGridDBColumn;
Tv1Column1: TcxGridDBColumn;
procedure FormDestroy(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormCreate(Sender: TObject);
procedure TBCloseClick(Sender: TObject);
procedure TBFindClick(Sender: TObject);
procedure TBEditClick(Sender: TObject);
procedure TBDelClick(Sender: TObject);
procedure TBExportClick(Sender: TObject);
procedure TBRafreshClick(Sender: TObject);
procedure TBAddClick(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure CheckBox1Click(Sender: TObject);
procedure CheckBox2Click(Sender: TObject);
procedure TBViewClick(Sender: TObject);
procedure CustomerNoNameChange(Sender: TObject);
procedure N2Click(Sender: TObject);
procedure N1Click(Sender: TObject);
procedure cxTabControl1Change(Sender: TObject);
procedure Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
procedure YGNameChange(Sender: TObject);
procedure cxDBTreeList1DblClick(Sender: TObject);
procedure Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
procedure TLZClick(Sender: TObject);
procedure TCXLZClick(Sender: TObject);
procedure ToolButton1Click(Sender: TObject);
procedure ToolButton2Click(Sender: TObject);
private
canshu1: string;
DQdate: TDateTime;
procedure InitGrid();
procedure InitForm();
function DelData(): Boolean;
procedure InitTree();
procedure GLAge();
{ Private declarations }
public
FFInt, FCloth: Integer;
{ Public declarations }
end;
var
frmEmployeeList: TfrmEmployeeList;
implementation
uses
U_DataLink, U_RTFun, U_ZDYHelp, U_EmployeeInPut, U_DeptTypeHelp; // U_FjList_RZ,
{$R *.dfm}
procedure TfrmEmployeeList.FormDestroy(Sender: TObject);
begin
inherited;
frmEmployeeList := nil;
end;
procedure TfrmEmployeeList.FormClose(Sender: TObject; var Action: TCloseAction);
begin
inherited;
Action := caFree;
end;
procedure TfrmEmployeeList.FormCreate(Sender: TObject);
begin
inherited;
canshu1 := Trim(DParameters1);
SJLiZhiDate.Date := SGetServerDate(ADOQueryTemp);
cxgrid1.Align := alClient;
end;
procedure TfrmEmployeeList.TBCloseClick(Sender: TObject);
begin
Close;
WriteCxGrid('员工档案列表2', Tv1, 'OA管理');
end;
procedure TfrmEmployeeList.InitGrid();
begin
try
ADOQueryMain.DisableControls;
with ADOQueryMain do
begin
Filtered := False;
Close;
sql.Clear;
sql.Add(' exec P_EE_Get_All :DPID,:LiZhiFlag');
Parameters.ParamByName('DPID').Value := Trim(CDS_Tree.fieldbyname('DPID').AsString);
Parameters.ParamByName('LiZhiFlag').Value := cxTabControl1.TabIndex;
Open;
end;
SCreateCDS(ADOQueryMain, Order_Main);
SInitCDSData(ADOQueryMain, Order_Main);
finally
ADOQueryMain.EnableControls;
end;
end;
procedure TfrmEmployeeList.GLAge();
var
FXTGLNF, FYGGLNF, FGLYF: Double;
begin
FXTGLNF := strtofloat(uppercase(formatdateTime('yyyy', SGetServerDate(ADOQueryTemp))));
with ADOQueryCmd do
begin
close;
sql.Clear;
sql.Add('select RuZhiDate,YGYearGL from SY_Employee where YGType=''正式'' ');
open;
end;
with ADOQueryCmd do
begin
first;
while not eof do
begin
edit;
if ADOQueryCmd.fieldbyname('RuZhiDate').asstring = '' then
begin
fieldbyname('YGYearGL').AsFloat := 0;
end
else
begin
FYGGLNF := strtofloat(uppercase(formatdateTime('yyyy', ADOQueryCmd.fieldbyname('RuZhiDate').AsDateTime)));
FGLYF := strtofloat(uppercase(formatdateTime('MM', ADOQueryCmd.fieldbyname('RuZhiDate').AsDateTime)));
if (FGLYF >= 1) and (FGLYF <= 3) then
fieldbyname('YGYearGL').AsFloat := FXTGLNF - FYGGLNF + 1;
if (FGLYF > 3) and (FGLYF <= 9) then
fieldbyname('YGYearGL').AsFloat := FXTGLNF - FYGGLNF + 0.5;
if (FGLYF > 9) and (FGLYF <= 12) then
fieldbyname('YGYearGL').AsFloat := FXTGLNF - FYGGLNF;
end;
next;
end;
end;
end;
procedure TfrmEmployeeList.InitTree();
var
i: Integer;
begin
try
ADOQueryTree.DisableControls;
with ADOQueryTree do
begin
Close;
SQL.Clear;
SQL.Add('select * from SY_Dept order by DPlevel,DPOrder,DPName');
Open;
end;
SCreateCDS(ADOQueryTree, CDS_Tree);
SInitCDSData(ADOQueryTree, CDS_Tree);
cxDBTreeList1.Items[0].Expand(True);
finally
ADOQueryTree.EnableControls;
end;
end;
procedure TfrmEmployeeList.InitForm();
begin
ReadCxGrid('员工档案列表2', Tv1, 'OA管理');
InitTree();
// GLAge();
InitGrid();
end;
procedure TfrmEmployeeList.TBFindClick(Sender: TObject);
begin
if ADOQueryMain.Active = False then
Exit;
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, Order_Main);
SInitCDSData(ADOQueryMain, Order_Main);
end;
procedure TfrmEmployeeList.TBEditClick(Sender: TObject);
begin
if Order_Main.IsEmpty then
Exit;
try
frmYGInPut := TfrmYGInPut.Create(Application);
with frmYGInPut do
begin
PState := 1;
FMainId := Trim(Self.Order_Main.fieldbyname('EEID').AsString);
FDPID := Trim(CDS_Tree.fieldbyname('DPID').AsString);
FDPName := trim(CDS_Tree.fieldbyname('DPName').AsString);
frmYGInPut.canshu1 := Trim(Self.canshu1);
if ShowModal = 1 then
begin
initgrid();
end;
end;
finally
frmYGInPut.Free;
end;
end;
procedure TfrmEmployeeList.TBDelClick(Sender: TObject);
begin
if Order_Main.IsEmpty then
Exit;
//if cxTabControl1.TabIndex<>0 then Exit;
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
Exit;
if DelData() then
begin
Order_Main.Delete;
end;
end;
function TfrmEmployeeList.DelData(): Boolean;
begin
try
Result := false;
ADOQueryCmd.Connection.BeginTrans;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add('Delete SY_Employee where EEID=''' + Trim(Order_Main.fieldbyname('EEID').AsString) + '''');
ExecSQL;
end;
with ADOQueryCmd do
begin
Close;
sql.Clear;
sql.Add(' Delete TP_File where WBId=''' + Trim(Order_Main.fieldbyname('EEID').AsString) + '''');
sql.Add(' and TFType=''YG'' ');
ExecSQL;
end;
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('exec P_EE_in_Account @DataID=''' + Trim(Order_Main.fieldbyname('EEID').AsString) + '''');
Open;
end;
if ADOQueryCmd.FieldByName('intReturn').AsInteger = -1 then
raise Exception.Create(PChar(ADOQueryCmd.fieldbyname('ShowMsg').AsString));
ADOQueryCmd.Connection.CommitTrans;
Result := True;
except
ADOQueryCmd.Connection.RollbackTrans;
Result := False;
application.MessageBox(PChar(Exception(ExceptObject).Message), '提示信息', 0);
end;
end;
procedure TfrmEmployeeList.TBExportClick(Sender: TObject);
begin
if ADOQueryMain.IsEmpty then
Exit;
TcxGridToExcel('员工档案列表', cxGrid1);
end;
procedure TfrmEmployeeList.TBRafreshClick(Sender: TObject);
begin
InitTree();
InitGrid();
end;
procedure TfrmEmployeeList.TBAddClick(Sender: TObject);
var
maxno: string;
begin
try
frmYGInPut := TfrmYGInPut.Create(Application);
with frmYGInPut do
begin
PState := 0;
FMainId := '';
FDPID := Trim(CDS_Tree.fieldbyname('DPID').AsString);
FDPName := trim(CDS_Tree.fieldbyname('DPName').AsString);
if ShowModal = 1 then
begin
initgrid();
end;
end;
finally
frmYGInPut.Free;
end;
end;
procedure TfrmEmployeeList.FormShow(Sender: TObject);
begin
inherited;
v1SJLiZhiDate.Visible := false;
if cxTabControl1.TabIndex <> 0 then
v1SJLiZhiDate.Visible := true;
InitForm();
end;
procedure TfrmEmployeeList.CheckBox1Click(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmEmployeeList.CheckBox2Click(Sender: TObject);
begin
TBRafresh.Click;
end;
procedure TfrmEmployeeList.TBViewClick(Sender: TObject);
begin
if Order_Main.IsEmpty then
Exit;
try
frmYGInPut := TfrmYGInPut.Create(Application);
with frmYGInPut do
begin
PState := 1;
FMainId := Trim(Self.Order_Main.fieldbyname('EEID').AsString);
FDPID := Trim(CDS_Tree.fieldbyname('DPID').AsString);
TBSave.Visible := False;
ToolButton1.Visible := False;
ToolButton2.Visible := False;
if ShowModal = 1 then
begin
end;
end;
finally
frmYGInPut.Free;
end;
end;
procedure TfrmEmployeeList.CustomerNoNameChange(Sender: TObject);
begin
if ADOQueryMain.Active = False then
Exit;
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
SCreateCDS(ADOQueryMain, Order_Main);
SInitCDSData(ADOQueryMain, Order_Main);
end;
procedure TfrmEmployeeList.N2Click(Sender: TObject);
begin
SelOKNo(Order_Main, True);
end;
procedure TfrmEmployeeList.N1Click(Sender: TObject);
begin
SelOKNo(Order_Main, False);
end;
procedure TfrmEmployeeList.cxTabControl1Change(Sender: TObject);
begin
v1SJLiZhiDate.Visible := false;
if cxTabControl1.TabIndex <> 0 then
v1SJLiZhiDate.Visible := true;
InitGrid();
end;
procedure TfrmEmployeeList.Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
begin
TBView.Click;
end;
procedure TfrmEmployeeList.YGNameChange(Sender: TObject);
begin
TBFind.Click;
end;
procedure TfrmEmployeeList.cxDBTreeList1DblClick(Sender: TObject);
begin
InitGrid();
end;
procedure TfrmEmployeeList.Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
begin
if Order_Main.IsEmpty then
Exit;
CDS_Tree.Locate('DPID', Trim(Order_Main.fieldbyname('DPID').AsString), []);
end;
procedure TfrmEmployeeList.TLZClick(Sender: TObject);
begin
if order_Main.IsEmpty then
exit;
if CxTabConTrol1.TabIndex <> 0 then
exit;
if application.MessageBox('确定要执行此操作', '提示', 1) = 2 then
exit;
try
ADOQueryCmd.Connection.BeginTrans;
with ADOQueryCmd do
begin
close;
sql.Clear;
sql.Add('update SY_Employee set EEType=''离职'',DepartureDate=' + Quotedstr(trim(FormatDateTime('yyyy-MM-dd', SJLiZhiDate.Date))));
sql.Add(' where EEID=''' + trim(Order_Main.fieldbyname('EEID').AsString) + '''');
execsql;
end;
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('exec P_EE_in_Account @DataID=''' + Trim(Order_Main.fieldbyname('EEID').AsString) + '''');
Open;
end;
if ADOQueryCmd.FieldByName('intReturn').AsInteger = -1 then
raise Exception.Create(PChar(ADOQueryCmd.fieldbyname('ShowMsg').AsString));
ADOQueryCmd.Connection.CommitTrans;
except
ADOQueryCmd.Connection.RollbackTrans;
application.MessageBox(PChar(Exception(ExceptObject).Message), '提示信息', 0);
end;
initGrid();
end;
procedure TfrmEmployeeList.TCXLZClick(Sender: TObject);
begin
if order_Main.IsEmpty then
exit;
if cxTabControl1.TabIndex <> 1 then
exit;
if application.MessageBox('确定要撤销离职吗', '提示', 1) = 2 then
exit;
try
ADOQueryCmd.Connection.BeginTrans;
with ADOQueryCmd do
begin
close;
sql.Clear;
sql.Add('update SY_Employee set EEType=''正式'',DepartureDate=NULL');
sql.Add(' where EEID=''' + trim(Order_Main.fieldbyname('EEID').AsString) + '''');
execsql;
end;
with ADOQueryCmd do
begin
Close;
SQL.Clear;
sql.Add('exec P_EE_in_Account @DataID=''' + Trim(Order_Main.fieldbyname('EEID').AsString) + '''');
Open;
end;
if ADOQueryCmd.FieldByName('intReturn').AsInteger = -1 then
raise Exception.Create(PChar(ADOQueryCmd.fieldbyname('ShowMsg').AsString));
ADOQueryCmd.Connection.CommitTrans;
except
ADOQueryCmd.Connection.RollbackTrans;
application.MessageBox(PChar(Exception(ExceptObject).Message), '提示信息', 0);
end;
initGrid();
end;
procedure TfrmEmployeeList.ToolButton1Click(Sender: TObject);
begin
// if Order_Main.IsEmpty then
// Exit;
// try
// frmFjList_RZ := TfrmFjList_RZ.Create(Application);
// with frmFjList_RZ do
// begin
// if Trim(DParameters1) <> '高权限' then
// cxButton1.Visible := false;
// fkeyNO := Trim(Self.Order_Main.fieldbyname('EEID').AsString);
// fType := '员工档案';
// if ShowModal = 1 then
// begin
//
// end;
// end;
// finally
// frmFjList_RZ.Free;
// end;
end;
procedure TfrmEmployeeList.ToolButton2Click(Sender: TObject);
var
FDPID, FName: string;
begin
if Order_Main.IsEmpty then
exit;
if Order_Main.Locate('ssel', true, []) = false then
begin
Application.MessageBox('没有选择数据!', '提示', 0);
Exit;
end;
FDPID := '';
FName := '';
frmDeptTypeHelp := TfrmDeptTypeHelp.create(self);
with frmDeptTypeHelp do
begin
if showmodal = 1 then
begin
FDPID := Trim(ADOQueryHelp.fieldbyname('DPID').AsString);
FName := Trim(ADOQueryHelp.fieldbyname('DPName').AsString);
end;
free;
end;
if trim(FDPID) = '' then
exit;
try
with Order_Main do
begin
DisableControls;
First;
while not eof do
begin
if fieldbyname('ssel').AsBoolean then
begin
with ADOQueryCmd do
begin
close;
sql.Clear;
sql.Add('update SY_Employee SET Dept=''' + trim(FName) + ''' ');
sql.Add(',DPID=''' + trim(FDPID) + ''' ');
sql.Add('where EEID=' + quotedstr(trim(Order_Main.fieldbyname('EEID').AsString)));
execsql;
end;
end;
next;
end;
First;
EnableControls;
end;
application.MessageBox('操作成功!', '提示信息');
initgrid();
except
Order_Main.EnableControls;
application.MessageBox('操作失败!', '提示信息', 0);
end;
end;
end.

Some files were not shown because too many files have changed in this diff Show More