~
This commit is contained in:
parent
8f2f47d8f5
commit
5ad6218a33
42
基础数据/BaseData.cfg
Normal file
42
基础数据/BaseData.cfg
Normal 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
|
138
基础数据/BaseData.dof
Normal file
138
基础数据/BaseData.dof
Normal 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:\Dp7Repo\ÏîÄ¿´úÂë\D7wmhengming\»ù´¡Êý¾Ý\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
|
57
基础数据/BaseData.dpr
Normal file
57
基础数据/BaseData.dpr
Normal file
|
@ -0,0 +1,57 @@
|
||||||
|
library BaseData;
|
||||||
|
|
||||||
|
uses
|
||||||
|
SysUtils,
|
||||||
|
classes,
|
||||||
|
forms,
|
||||||
|
WinTypes,
|
||||||
|
WinProcs,
|
||||||
|
U_DataLink in 'U_DataLink.pas' {BaseData10_DataLink: TDataModule},
|
||||||
|
U_GetDllForm in 'U_GetDllForm.pas',
|
||||||
|
U_getDogServer in '..\..\..\ThreeFun\Fun\U_getDogServer.pas',
|
||||||
|
U_User_bz_List in 'U_User_bz_List.pas' {frmUser_bz_List},
|
||||||
|
U_User10 in 'U_User10.pas' {frmUser10},
|
||||||
|
U_ZDYHelp in '..\..\..\ThreeFun\Form\U_ZDYHelp.pas' {frmZDYHelp},
|
||||||
|
U_UserHelp_Bz in 'U_UserHelp_Bz.pas' {frmUserHelp_Bz},
|
||||||
|
U_UserList in 'U_UserList.pas' {frmUserList},
|
||||||
|
U_Fun10 in '..\..\..\ThreeFun\Fun\U_Fun10.pas',
|
||||||
|
U_PublicFunction in '..\..\..\ThreeFun\Fun\U_PublicFunction.pas',
|
||||||
|
getpic in 'getpic.pas' {FormGetPic},
|
||||||
|
U_Fun in '..\..\..\ThreeFun\Fun\U_Fun.pas',
|
||||||
|
U_SelExportField in '..\..\..\ThreeFun\Fun\U_SelExportField.pas' {frmSelExportField},
|
||||||
|
U_ColumnBandSet in '..\..\..\ThreeFun\Form\U_ColumnBandSet.pas' {frmColumnBandSet},
|
||||||
|
U_ColumnSet in '..\..\..\ThreeFun\Form\U_ColumnSet.pas' {frmColumnSet},
|
||||||
|
U_SelPrintFieldNew in '..\..\..\ThreeFun\Form\U_SelPrintFieldNew.pas' {frmSelPrintFieldNew};
|
||||||
|
|
||||||
|
// U_SelfForm in '..\..\SelfForm\U_SelfForm.pas',
|
||||||
|
// U_SelExportField in '..\..\SelfForm\U_SelExportField.pas' {frmSelExportField},
|
||||||
|
// U_SelPrintField in '..\..\SelfForm\U_SelPrintField.pas' {frmSelPrintField},
|
||||||
|
// U_SelPrintFieldNew in '..\..\SelfForm\U_SelPrintFieldNew.pas' {frmSelPrintFieldNew},
|
||||||
|
//U_FormPas in '..\CommonPas\formPas\U_FormPas.pas',
|
||||||
|
//U_CxGridSet in '..\CommonPas\cxgridPas\U_CxGridSet.pas';
|
||||||
|
|
||||||
|
//U_RSFormPas in '..\CommonPas\RSCommon\U_RSFormPas.pas';
|
||||||
|
|
||||||
|
{$R *.res}
|
||||||
|
|
||||||
|
procedure DllEnterPoint(dwReason: DWORD);far;stdcall;
|
||||||
|
begin
|
||||||
|
DLLProc := @DLLEnterPoint;
|
||||||
|
DllEnterPoint(DLL_PROCESS_ATTACH);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure DLLUnloadProc(Reason: Integer); register;
|
||||||
|
begin
|
||||||
|
|
||||||
|
end;
|
||||||
|
exports
|
||||||
|
GetDllForm;
|
||||||
|
begin
|
||||||
|
try
|
||||||
|
NewDllApp:=Application;
|
||||||
|
DLLProc := @DLLUnloadProc;
|
||||||
|
except
|
||||||
|
|
||||||
|
end;
|
||||||
|
end.
|
||||||
|
|
BIN
基础数据/BaseData.res
Normal file
BIN
基础数据/BaseData.res
Normal file
Binary file not shown.
42
基础数据/Packaged.cfg
Normal file
42
基础数据/Packaged.cfg
Normal 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"d:\program files\borland\delphi7\Projects\Bpl"
|
||||||
|
-LN"d:\program files\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
|
138
基础数据/Packaged.dof
Normal file
138
基础数据/Packaged.dof
Normal 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=E:\自学\李建博开发代码\项目代码10\self10\打包信息\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
|
50
基础数据/Packaged.dpr
Normal file
50
基础数据/Packaged.dpr
Normal file
|
@ -0,0 +1,50 @@
|
||||||
|
library Packaged;
|
||||||
|
|
||||||
|
uses
|
||||||
|
SysUtils,
|
||||||
|
classes,
|
||||||
|
forms,
|
||||||
|
WinTypes,
|
||||||
|
WinProcs,
|
||||||
|
U_DataLink in 'U_DataLink.pas' {Packaged_DataLink: TDataModule},
|
||||||
|
U_GetDllForm in 'U_GetDllForm.pas',
|
||||||
|
U_Fun in '..\..\..\ThreeFun\Fun\U_Fun.pas',
|
||||||
|
U_getDogServer in '..\..\..\ThreeFun\Fun\U_getDogServer.pas',
|
||||||
|
U_SelExportField in '..\..\..\ThreeFun\Fun\U_SelExportField.pas' {frmSelExportField},
|
||||||
|
U_ColumnBandSet in '..\..\..\ThreeFun\Form\U_ColumnBandSet.pas' {frmColumnBandSet},
|
||||||
|
U_ColumnSet in '..\..\..\ThreeFun\Form\U_ColumnSet.pas' {frmColumnSet},
|
||||||
|
U_SelPrintFieldNew in '..\..\..\ThreeFun\Form\U_SelPrintFieldNew.pas' {frmSelPrintFieldNew};
|
||||||
|
|
||||||
|
// U_SelfForm in '..\..\SelfForm\U_SelfForm.pas',
|
||||||
|
// U_SelExportField in '..\..\SelfForm\U_SelExportField.pas' {frmSelExportField},
|
||||||
|
// U_SelPrintField in '..\..\SelfForm\U_SelPrintField.pas' {frmSelPrintField},
|
||||||
|
// U_SelPrintFieldNew in '..\..\SelfForm\U_SelPrintFieldNew.pas' {frmSelPrintFieldNew},
|
||||||
|
//U_FormPas in '..\CommonPas\formPas\U_FormPas.pas',
|
||||||
|
//U_CxGridSet in '..\CommonPas\cxgridPas\U_CxGridSet.pas';
|
||||||
|
|
||||||
|
//U_RSFormPas in '..\CommonPas\RSCommon\U_RSFormPas.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.
|
||||||
|
|
BIN
基础数据/Packaged.res
Normal file
BIN
基础数据/Packaged.res
Normal file
Binary file not shown.
26
基础数据/ProjectGroup1.bpg
Normal file
26
基础数据/ProjectGroup1.bpg
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
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 BaseData.dll
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
default: $(PROJECTS)
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
testDll.exe: testDll.dpr
|
||||||
|
$(DCC)
|
||||||
|
|
||||||
|
BaseData.dll: BaseData.dpr
|
||||||
|
$(DCC)
|
||||||
|
|
||||||
|
: ..\..\..\ThreeFun\Fun\U_Fun10.pas
|
||||||
|
$(DCC)
|
||||||
|
|
||||||
|
|
23
基础数据/ProjectGroup1.~bpg
Normal file
23
基础数据/ProjectGroup1.~bpg
Normal 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 BaseData.dll
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
default: $(PROJECTS)
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
testDll.exe: testDll.dpr
|
||||||
|
$(DCC)
|
||||||
|
|
||||||
|
BaseData.dll: BaseData.dpr
|
||||||
|
$(DCC)
|
||||||
|
|
||||||
|
|
6
基础数据/SYSTEMSET.ini
Normal file
6
基础数据/SYSTEMSET.ini
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
[SERVER]
|
||||||
|
服务器地址=122.226.88.254
|
||||||
|
服务器地址类型=10
|
||||||
|
是否自动更新=1
|
||||||
|
软件名称=华恒管理软件
|
||||||
|
122.226.88.254
|
18108
基础数据/U_DataLink.dfm
Normal file
18108
基础数据/U_DataLink.dfm
Normal file
File diff suppressed because it is too large
Load Diff
87
基础数据/U_DataLink.pas
Normal file
87
基础数据/U_DataLink.pas
Normal file
|
@ -0,0 +1,87 @@
|
||||||
|
unit U_DataLink;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
SysUtils, Classes, DB, ADODB, ImgList, Controls, cxStyles, cxLookAndFeels,
|
||||||
|
Windows,Messages,forms,OleCtnrs,DateUtils, ExtCtrls, AppEvnts, cxClasses;
|
||||||
|
var
|
||||||
|
DConString:String; {全局连接字符串}
|
||||||
|
server, dtbase, user, pswd: String; {数据库连接参数}
|
||||||
|
DCurHandle:hwnd; //当前窗体句柄
|
||||||
|
DName:string ; //#用户名#//
|
||||||
|
DCode:string ; //#用户编号#//
|
||||||
|
Ddatabase:string; //#数据库名称#//
|
||||||
|
DTitCaption:string; //#主窗体名称#//
|
||||||
|
PicSvr: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; //公司
|
||||||
|
type
|
||||||
|
TBaseData10_DataLink = 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;
|
||||||
|
cxStyleRepository1: TcxStyleRepository;
|
||||||
|
cxStyle1: TcxStyle;
|
||||||
|
cxStyle2: TcxStyle;
|
||||||
|
cxStyle_gridRow: TcxStyle;
|
||||||
|
cxStyle_gridFoot: TcxStyle;
|
||||||
|
cxStyle_gridHead: TcxStyle;
|
||||||
|
cxStyle_gridGroupBox: TcxStyle;
|
||||||
|
cxStyle_yellow: TcxStyle;
|
||||||
|
cxStyle_Red: TcxStyle;
|
||||||
|
cxStyle_fontBlack: TcxStyle;
|
||||||
|
cxStyle_fontclFuchsia: TcxStyle;
|
||||||
|
cxStyle_fontclPurple: TcxStyle;
|
||||||
|
cxStyle_fontclGreen: TcxStyle;
|
||||||
|
cxStyle_fontclBlue: TcxStyle;
|
||||||
|
cxStyle_fontclTeal: TcxStyle;
|
||||||
|
cxStyle_fontclOlive: TcxStyle;
|
||||||
|
Timer1: TTimer;
|
||||||
|
procedure DataModuleDestroy(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
|
||||||
|
BaseData10_DataLink: TBaseData10_DataLink;
|
||||||
|
implementation
|
||||||
|
{$R *.dfm}
|
||||||
|
|
||||||
|
|
||||||
|
procedure TBaseData10_DataLink.DataModuleDestroy(Sender: TObject);
|
||||||
|
begin
|
||||||
|
BaseData10_DataLink:=nil;
|
||||||
|
end;
|
||||||
|
|
||||||
|
end.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
215
基础数据/U_GetDllForm.pas
Normal file
215
基础数据/U_GetDllForm.pas
Normal file
|
@ -0,0 +1,215 @@
|
||||||
|
unit U_GetDllForm;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, forms, OleCtnrs, DateUtils, SysUtils, ADODB, IniFiles,
|
||||||
|
dxcore, activeX;
|
||||||
|
|
||||||
|
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_getDogServer, U_UserList, U_User_bz_List;
|
||||||
|
|
||||||
|
/////////////////////////////////////////////////////////////////
|
||||||
|
// 功能说明:取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
|
||||||
|
mnewHandle: hwnd;
|
||||||
|
mstyle: TFormStyle; // 0:子窗口; 1:普通窗口
|
||||||
|
mstate: TWindowState;
|
||||||
|
mborderstyle: TFormBorderStyle;
|
||||||
|
begin
|
||||||
|
mnewHandle := 0;
|
||||||
|
DName := GName;
|
||||||
|
DCode := GName;
|
||||||
|
DdataBase := DataBase;
|
||||||
|
DTitCaption := Title;
|
||||||
|
DParameters1 := Parameters1;
|
||||||
|
DParameters2 := Parameters2;
|
||||||
|
DParameters3 := Parameters3;
|
||||||
|
DParameters4 := Parameters4;
|
||||||
|
DParameters5 := Parameters5;
|
||||||
|
DParameters6 := Parameters6;
|
||||||
|
DParameters7 := Parameters7;
|
||||||
|
DParameters8 := Parameters8;
|
||||||
|
DParameters9 := Parameters9;
|
||||||
|
DParameters10 := Parameters10;
|
||||||
|
|
||||||
|
MainApplication := App;
|
||||||
|
DCurHandle := FormH;
|
||||||
|
IsDelphiLanguage := Language;
|
||||||
|
|
||||||
|
Application := TApplication(App);
|
||||||
|
DCurHandle := 0;
|
||||||
|
|
||||||
|
|
||||||
|
//赋值链接字符串
|
||||||
|
SetLength(server, 255);
|
||||||
|
SetLength(dtbase, 255);
|
||||||
|
SetLength(user, 255);
|
||||||
|
SetLength(pswd, 255);
|
||||||
|
|
||||||
|
// server:='47.102.47.90,7781';
|
||||||
|
// //server:='.';
|
||||||
|
// dtbase:='yongxingdata';
|
||||||
|
// user:='sa';
|
||||||
|
// pswd:='rightsoft@123';
|
||||||
|
server := '101.132.143.144,7781';
|
||||||
|
// server:='.';
|
||||||
|
dtbase := 'hengmingdata';
|
||||||
|
user := 'rtsa';
|
||||||
|
pswd := 'rightsoft@5740';
|
||||||
|
DConString := 'Provider=SQLOLEDB.1;Password=' + pswd + ';Persist Security Info=True;User ID=' + user + ';Initial Catalog=' + dtbase + ';Data Source=' + server;
|
||||||
|
if trim(DataBaseStr) <> '' then
|
||||||
|
DConString := DataBaseStr;
|
||||||
|
// DParameters1:='1';
|
||||||
|
//if GetLinkDog(DCurHandle,DConString)<0 then application.Terminate;
|
||||||
|
if not ConnData() then
|
||||||
|
begin
|
||||||
|
result := 0;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
GetsysParam('', '');
|
||||||
|
// 定义窗口类型 、状态
|
||||||
|
if WinStyle = 0 then
|
||||||
|
begin
|
||||||
|
mstyle := fsMDIChild;
|
||||||
|
mstate := wsMaximized;
|
||||||
|
mborderstyle := bsSizeable;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
mstyle := fsNormal;
|
||||||
|
mstate := wsNormal;
|
||||||
|
mborderstyle := bsSizeable;
|
||||||
|
end;
|
||||||
|
/////////////////////
|
||||||
|
//调用子模块窗口
|
||||||
|
case FormID of
|
||||||
|
1: // 样品类别
|
||||||
|
begin
|
||||||
|
if frmUserList = nil then
|
||||||
|
begin
|
||||||
|
frmUserList := TfrmUserList.Create(application.MainForm);
|
||||||
|
with frmUserList do
|
||||||
|
begin
|
||||||
|
caption := Trim(Title);
|
||||||
|
FormStyle := mstyle;
|
||||||
|
windowState := mstate;
|
||||||
|
BorderStyle := mborderstyle;
|
||||||
|
//show;
|
||||||
|
end;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
frmUserList.BringToFront;
|
||||||
|
//句柄
|
||||||
|
mnewHandle := frmUserList.Handle;
|
||||||
|
|
||||||
|
end;
|
||||||
|
2: // 样品类别
|
||||||
|
begin
|
||||||
|
if frmUser_bz_List = nil then
|
||||||
|
begin
|
||||||
|
frmUser_bz_List := TfrmUser_bz_List.Create(application.MainForm);
|
||||||
|
with frmUser_bz_List do
|
||||||
|
begin
|
||||||
|
caption := Trim(Title);
|
||||||
|
FormStyle := mstyle;
|
||||||
|
windowState := mstate;
|
||||||
|
BorderStyle := mborderstyle;
|
||||||
|
//show;
|
||||||
|
end;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
frmUser_bz_List.BringToFront;
|
||||||
|
//句柄
|
||||||
|
mnewHandle := frmUser_bz_List.Handle;
|
||||||
|
|
||||||
|
end;
|
||||||
|
|
||||||
|
end; // end case
|
||||||
|
|
||||||
|
Result := mnewHandle;
|
||||||
|
// NewDllApp:=Application ;
|
||||||
|
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');
|
||||||
|
finally
|
||||||
|
IniFile.Free;
|
||||||
|
end;
|
||||||
|
if not Assigned(BaseData10_DataLink) then
|
||||||
|
BaseData10_DataLink := TBaseData10_DataLink.Create(Application);
|
||||||
|
try
|
||||||
|
with BaseData10_DataLink.ADOLink do
|
||||||
|
begin
|
||||||
|
if not Connected then
|
||||||
|
begin
|
||||||
|
Connected := false;
|
||||||
|
ConnectionString := DConString;
|
||||||
|
LoginPrompt := false;
|
||||||
|
Connected := true;
|
||||||
|
// BaseData10_DataLink.Timer1.Enabled:=true;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
Result := true;
|
||||||
|
except
|
||||||
|
Result := false;
|
||||||
|
application.MessageBox('数据库连接失败!', '错误', mb_Ok + MB_ICONERROR);
|
||||||
|
end;
|
||||||
|
|
||||||
|
end;
|
||||||
|
//=========================================================
|
||||||
|
//获取系统参数
|
||||||
|
//=========================================================
|
||||||
|
|
||||||
|
function GetsysParam(muserId: pchar; fparam1: pchar): Boolean;
|
||||||
|
begin
|
||||||
|
result := true;
|
||||||
|
//////////////////////////////
|
||||||
|
shortDateFormat := 'yyyy-MM-dd';
|
||||||
|
//服务器日期
|
||||||
|
with BaseData10_DataLink.AdoDataLink do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select getDate()as dt');
|
||||||
|
open;
|
||||||
|
DServerDate := fieldByName('dt').AsDatetime;
|
||||||
|
end;
|
||||||
|
result := true;
|
||||||
|
end;
|
||||||
|
|
||||||
|
initialization
|
||||||
|
CoInitialize(nil);
|
||||||
|
dxUnitsLoader.Initialize;
|
||||||
|
|
||||||
|
|
||||||
|
finalization
|
||||||
|
BaseData10_DataLink.Free;
|
||||||
|
application := NewDllApp;
|
||||||
|
dxUnitsLoader.Finalize;
|
||||||
|
|
||||||
|
end.
|
||||||
|
|
648
基础数据/U_PackList.dfm
Normal file
648
基础数据/U_PackList.dfm
Normal file
|
@ -0,0 +1,648 @@
|
||||||
|
object frmPackList: TfrmPackList
|
||||||
|
Left = 77
|
||||||
|
Top = 101
|
||||||
|
Width = 921
|
||||||
|
Height = 634
|
||||||
|
Caption = #25171#21253#20449#24687
|
||||||
|
Color = clBtnFace
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
OldCreateOrder = False
|
||||||
|
OnClose = FormClose
|
||||||
|
OnCreate = FormCreate
|
||||||
|
OnDestroy = FormDestroy
|
||||||
|
OnShow = FormShow
|
||||||
|
PixelsPerInch = 96
|
||||||
|
TextHeight = 12
|
||||||
|
object ToolBar1: TToolBar
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
Width = 913
|
||||||
|
Height = 33
|
||||||
|
ButtonHeight = 30
|
||||||
|
ButtonWidth = 83
|
||||||
|
Caption = 'ToolBar1'
|
||||||
|
Color = clSkyBlue
|
||||||
|
Flat = True
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
Images = Packaged_DataLink.ThreeImgList
|
||||||
|
List = True
|
||||||
|
ParentColor = False
|
||||||
|
ParentFont = False
|
||||||
|
ShowCaptions = True
|
||||||
|
TabOrder = 0
|
||||||
|
object TBRafresh: TToolButton
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21047#26032
|
||||||
|
ImageIndex = 2
|
||||||
|
OnClick = TBRafreshClick
|
||||||
|
end
|
||||||
|
object TBFind: TToolButton
|
||||||
|
Left = 63
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #36807#28388
|
||||||
|
ImageIndex = 59
|
||||||
|
OnClick = TBFindClick
|
||||||
|
end
|
||||||
|
object ToolButton1: TToolButton
|
||||||
|
Left = 126
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #26032#22686
|
||||||
|
ImageIndex = 47
|
||||||
|
OnClick = ToolButton1Click
|
||||||
|
end
|
||||||
|
object ToolButton2: TToolButton
|
||||||
|
Left = 189
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20462#25913
|
||||||
|
ImageIndex = 49
|
||||||
|
OnClick = ToolButton2Click
|
||||||
|
end
|
||||||
|
object ToolButton3: TToolButton
|
||||||
|
Left = 252
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21024#38500
|
||||||
|
ImageIndex = 48
|
||||||
|
OnClick = ToolButton3Click
|
||||||
|
end
|
||||||
|
object TBExport: TToolButton
|
||||||
|
Left = 315
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #23548#20986#30721#21333
|
||||||
|
ImageIndex = 44
|
||||||
|
OnClick = TBExportClick
|
||||||
|
end
|
||||||
|
object TBClose: TToolButton
|
||||||
|
Left = 402
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20851#38381
|
||||||
|
ImageIndex = 55
|
||||||
|
OnClick = TBCloseClick
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object Panel1: TPanel
|
||||||
|
Left = 0
|
||||||
|
Top = 33
|
||||||
|
Width = 913
|
||||||
|
Height = 56
|
||||||
|
Align = alTop
|
||||||
|
BevelInner = bvRaised
|
||||||
|
BevelOuter = bvLowered
|
||||||
|
Color = clSkyBlue
|
||||||
|
TabOrder = 1
|
||||||
|
object Label3: TLabel
|
||||||
|
Left = 239
|
||||||
|
Top = 12
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #23458#25143#21517#31216
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label1: TLabel
|
||||||
|
Left = 24
|
||||||
|
Top = 12
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #25171#21253#26085#26399
|
||||||
|
end
|
||||||
|
object Label2: TLabel
|
||||||
|
Left = 240
|
||||||
|
Top = 32
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #35745#21010#21333#21495
|
||||||
|
end
|
||||||
|
object Label4: TLabel
|
||||||
|
Left = 444
|
||||||
|
Top = 12
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #20135#21697#21517#31216
|
||||||
|
end
|
||||||
|
object khName: TEdit
|
||||||
|
Left = 292
|
||||||
|
Top = 7
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 0
|
||||||
|
OnChange = khNameChange
|
||||||
|
end
|
||||||
|
object begdate: TDateTimePicker
|
||||||
|
Left = 76
|
||||||
|
Top = 8
|
||||||
|
Width = 97
|
||||||
|
Height = 20
|
||||||
|
Date = 41009.831677152770000000
|
||||||
|
Format = 'yyyy-MM-dd'
|
||||||
|
Time = 41009.831677152770000000
|
||||||
|
TabOrder = 1
|
||||||
|
end
|
||||||
|
object enddate: TDateTimePicker
|
||||||
|
Left = 76
|
||||||
|
Top = 28
|
||||||
|
Width = 97
|
||||||
|
Height = 20
|
||||||
|
Date = 41009.831677152770000000
|
||||||
|
Format = 'yyyy-MM-dd'
|
||||||
|
Time = 41009.831677152770000000
|
||||||
|
TabOrder = 2
|
||||||
|
end
|
||||||
|
object orderNo: TEdit
|
||||||
|
Left = 292
|
||||||
|
Top = 28
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 3
|
||||||
|
OnChange = khNameChange
|
||||||
|
end
|
||||||
|
object cpName: TEdit
|
||||||
|
Left = 500
|
||||||
|
Top = 8
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 4
|
||||||
|
OnChange = khNameChange
|
||||||
|
end
|
||||||
|
object CheckBox1: TCheckBox
|
||||||
|
Left = 444
|
||||||
|
Top = 32
|
||||||
|
Width = 97
|
||||||
|
Height = 17
|
||||||
|
Caption = #20840#36873
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clRed
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
TabOrder = 5
|
||||||
|
OnClick = CheckBox1Click
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object CXGrid1: TcxGrid
|
||||||
|
Left = 4
|
||||||
|
Top = 89
|
||||||
|
Width = 505
|
||||||
|
Height = 316
|
||||||
|
TabOrder = 2
|
||||||
|
LookAndFeel.Kind = lfStandard
|
||||||
|
object TV1: TcxGridDBTableView
|
||||||
|
NavigatorButtons.ConfirmDelete = False
|
||||||
|
OnCellClick = TV1CellClick
|
||||||
|
DataController.DataSource = DataSource1
|
||||||
|
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||||
|
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||||
|
DataController.Summary.FooterSummaryItems = <
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = V1qtyMi
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = V1qtyjz
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = V1qtyMa
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = V1QtyMz
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = V1QtyPZ
|
||||||
|
end>
|
||||||
|
DataController.Summary.SummaryGroups = <>
|
||||||
|
OptionsBehavior.GoToNextCellOnEnter = True
|
||||||
|
OptionsBehavior.FocusCellOnCycle = True
|
||||||
|
OptionsCustomize.ColumnFiltering = False
|
||||||
|
OptionsData.Deleting = False
|
||||||
|
OptionsView.Footer = True
|
||||||
|
OptionsView.GroupByBox = False
|
||||||
|
OptionsView.Indicator = True
|
||||||
|
Styles.ContentOdd = Packaged_DataLink.cxStyle_gridRow
|
||||||
|
Styles.Footer = Packaged_DataLink.cxStyle_gridFoot
|
||||||
|
Styles.GroupByBox = Packaged_DataLink.cxStyle_gridGroupBox
|
||||||
|
Styles.Header = Packaged_DataLink.cxStyle_gridHead
|
||||||
|
object V1SSel: TcxGridDBColumn
|
||||||
|
Caption = #36873#25321
|
||||||
|
DataBinding.FieldName = 'SSel'
|
||||||
|
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||||
|
Properties.ImmediatePost = True
|
||||||
|
Properties.NullStyle = nssUnchecked
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object V1packID: TcxGridDBColumn
|
||||||
|
Caption = #21253#26465#30721
|
||||||
|
DataBinding.FieldName = 'packID'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 74
|
||||||
|
end
|
||||||
|
object V1FillTime: TcxGridDBColumn
|
||||||
|
Caption = #25171#21253#26085#26399
|
||||||
|
DataBinding.FieldName = 'FillTime'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 75
|
||||||
|
end
|
||||||
|
object V1packNo: TcxGridDBColumn
|
||||||
|
Caption = #21253#21495
|
||||||
|
DataBinding.FieldName = 'packNo'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 67
|
||||||
|
end
|
||||||
|
object TV1KHName: TcxGridDBColumn
|
||||||
|
Caption = #23458#25143
|
||||||
|
DataBinding.FieldName = 'KHName'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Options.Focusing = False
|
||||||
|
Width = 80
|
||||||
|
end
|
||||||
|
object TV1OrderNo: TcxGridDBColumn
|
||||||
|
Caption = #35745#21010#21333#21495
|
||||||
|
DataBinding.FieldName = 'OrderNo'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Options.Focusing = False
|
||||||
|
Width = 100
|
||||||
|
end
|
||||||
|
object TV1CPName: TcxGridDBColumn
|
||||||
|
Caption = #20135#21697#21517#31216
|
||||||
|
DataBinding.FieldName = 'CPName'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Options.Focusing = False
|
||||||
|
Width = 109
|
||||||
|
end
|
||||||
|
object V1qtyMi: TcxGridDBColumn
|
||||||
|
Caption = #31859#25968
|
||||||
|
DataBinding.FieldName = 'qtyMi'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Content = Packaged_DataLink.cxStyle_fontclBlue
|
||||||
|
Styles.Footer = Packaged_DataLink.cxStyle_fontclBlue
|
||||||
|
Styles.Header = Packaged_DataLink.cxStyle_fontclBlue
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object V1qtyjz: TcxGridDBColumn
|
||||||
|
Caption = #20844#26020#25968
|
||||||
|
DataBinding.FieldName = 'qtyjz'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Content = Packaged_DataLink.cxStyle_fontclFuchsia
|
||||||
|
Styles.Footer = Packaged_DataLink.cxStyle_fontclFuchsia
|
||||||
|
Styles.Header = Packaged_DataLink.cxStyle_fontclFuchsia
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object V1qtyMa: TcxGridDBColumn
|
||||||
|
Caption = #30721#25968
|
||||||
|
DataBinding.FieldName = 'qtyMa'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object V1QtyMz: TcxGridDBColumn
|
||||||
|
Caption = #27611#37325
|
||||||
|
DataBinding.FieldName = 'QtyMz'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object V1QtyPZ: TcxGridDBColumn
|
||||||
|
Caption = #30382#37325
|
||||||
|
DataBinding.FieldName = 'QtyPZ'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object CXGrid1L1: TcxGridLevel
|
||||||
|
GridView = TV1
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxSplitter1: TcxSplitter
|
||||||
|
Left = 641
|
||||||
|
Top = 89
|
||||||
|
Width = 8
|
||||||
|
Height = 319
|
||||||
|
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||||
|
AlignSplitter = salRight
|
||||||
|
Control = cxGrid2
|
||||||
|
end
|
||||||
|
object cxGrid2: TcxGrid
|
||||||
|
Left = 649
|
||||||
|
Top = 89
|
||||||
|
Width = 264
|
||||||
|
Height = 319
|
||||||
|
Align = alRight
|
||||||
|
TabOrder = 4
|
||||||
|
LookAndFeel.Kind = lfStandard
|
||||||
|
object tv2: TcxGridDBTableView
|
||||||
|
NavigatorButtons.ConfirmDelete = False
|
||||||
|
DataController.DataSource = DataSource2
|
||||||
|
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||||
|
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||||
|
DataController.Summary.FooterSummaryItems = <
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = cxGridDBqtyMi
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = cxGridDBqtyjz
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = cxGridDBqtyMa
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = cxGridDBQtyMz
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = cxGridDBQtyPZ
|
||||||
|
end>
|
||||||
|
DataController.Summary.SummaryGroups = <>
|
||||||
|
OptionsBehavior.GoToNextCellOnEnter = True
|
||||||
|
OptionsBehavior.FocusCellOnCycle = True
|
||||||
|
OptionsCustomize.ColumnFiltering = False
|
||||||
|
OptionsData.Deleting = False
|
||||||
|
OptionsData.Editing = False
|
||||||
|
OptionsView.Footer = True
|
||||||
|
OptionsView.GroupByBox = False
|
||||||
|
OptionsView.Indicator = True
|
||||||
|
Styles.ContentOdd = Packaged_DataLink.cxStyle_gridRow
|
||||||
|
Styles.Footer = Packaged_DataLink.cxStyle_gridFoot
|
||||||
|
Styles.GroupByBox = Packaged_DataLink.cxStyle_gridGroupBox
|
||||||
|
Styles.Header = Packaged_DataLink.cxStyle_gridHead
|
||||||
|
object cxGridDBTMID: TcxGridDBColumn
|
||||||
|
Caption = #21367#26465#30721
|
||||||
|
DataBinding.FieldName = 'TMID'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 75
|
||||||
|
end
|
||||||
|
object cxGridDBJH: TcxGridDBColumn
|
||||||
|
Caption = #21367#21495
|
||||||
|
DataBinding.FieldName = 'JH'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object cxGridDBColor: TcxGridDBColumn
|
||||||
|
Caption = #39068#33394
|
||||||
|
DataBinding.FieldName = 'Color'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Options.Focusing = False
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object cxGridDBHX: TcxGridDBColumn
|
||||||
|
Caption = #33457#22411
|
||||||
|
DataBinding.FieldName = 'HX'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Focusing = False
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object cxGridDBqtyMi: TcxGridDBColumn
|
||||||
|
Caption = #31859#25968
|
||||||
|
DataBinding.FieldName = 'qtyMi'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Styles.Content = Packaged_DataLink.cxStyle_fontclBlue
|
||||||
|
Styles.Footer = Packaged_DataLink.cxStyle_fontclBlue
|
||||||
|
Styles.Header = Packaged_DataLink.cxStyle_fontclBlue
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object cxGridDBqtyjz: TcxGridDBColumn
|
||||||
|
Caption = #20844#26020#25968
|
||||||
|
DataBinding.FieldName = 'qtyjz'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Styles.Content = Packaged_DataLink.cxStyle_fontclFuchsia
|
||||||
|
Styles.Footer = Packaged_DataLink.cxStyle_fontclFuchsia
|
||||||
|
Styles.Header = Packaged_DataLink.cxStyle_fontclFuchsia
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object cxGridDBqtyMa: TcxGridDBColumn
|
||||||
|
Caption = #30721#25968
|
||||||
|
DataBinding.FieldName = 'qtyMa'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object cxGridDBQtyMz: TcxGridDBColumn
|
||||||
|
Caption = #27611#37325
|
||||||
|
DataBinding.FieldName = 'QtyMz'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object cxGridDBQtyPZ: TcxGridDBColumn
|
||||||
|
Caption = #30382#37325
|
||||||
|
DataBinding.FieldName = 'QtyPZ'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGridLevel1: TcxGridLevel
|
||||||
|
GridView = tv2
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid3: TcxGrid
|
||||||
|
Left = 0
|
||||||
|
Top = 408
|
||||||
|
Width = 913
|
||||||
|
Height = 194
|
||||||
|
Align = alBottom
|
||||||
|
TabOrder = 5
|
||||||
|
Visible = False
|
||||||
|
object TV3: TcxGridDBTableView
|
||||||
|
NavigatorButtons.ConfirmDelete = False
|
||||||
|
DataController.DataSource = DataSource3
|
||||||
|
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 TV3ORDERNO: TcxGridDBColumn
|
||||||
|
Caption = 'ORDER NO'
|
||||||
|
DataBinding.FieldName = 'ORDERNO'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.CellMerging = True
|
||||||
|
Width = 70
|
||||||
|
end
|
||||||
|
object TV3BALNO: TcxGridDBColumn
|
||||||
|
Caption = 'BAL NO'
|
||||||
|
DataBinding.FieldName = 'PackNo'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.CellMerging = True
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object TV3TYpe: TcxGridDBColumn
|
||||||
|
DataBinding.FieldName = 'TYPE'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.CellMerging = True
|
||||||
|
Width = 60
|
||||||
|
IsCaptionAssigned = True
|
||||||
|
end
|
||||||
|
object TV3DESNO: TcxGridDBColumn
|
||||||
|
Caption = 'DES NO'
|
||||||
|
DataBinding.FieldName = 'HX'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.CellMerging = True
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object TV31: TcxGridDBColumn
|
||||||
|
Caption = '1'
|
||||||
|
DataBinding.FieldName = 'ROW1'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV32: TcxGridDBColumn
|
||||||
|
Caption = '2'
|
||||||
|
DataBinding.FieldName = 'ROW2'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV33: TcxGridDBColumn
|
||||||
|
Caption = '3'
|
||||||
|
DataBinding.FieldName = 'ROW3'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV34: TcxGridDBColumn
|
||||||
|
Caption = '4'
|
||||||
|
DataBinding.FieldName = 'ROW4'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV35: TcxGridDBColumn
|
||||||
|
Caption = '5'
|
||||||
|
DataBinding.FieldName = 'ROW5'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV36: TcxGridDBColumn
|
||||||
|
Caption = '6'
|
||||||
|
DataBinding.FieldName = 'ROW6'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV37: TcxGridDBColumn
|
||||||
|
Caption = '7'
|
||||||
|
DataBinding.FieldName = 'ROW7'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV38: TcxGridDBColumn
|
||||||
|
Caption = '8'
|
||||||
|
DataBinding.FieldName = 'ROW8'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV39: TcxGridDBColumn
|
||||||
|
Caption = '9'
|
||||||
|
DataBinding.FieldName = 'ROW9'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV310: TcxGridDBColumn
|
||||||
|
Caption = '10'
|
||||||
|
DataBinding.FieldName = 'ROW10'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object TV3TTL: TcxGridDBColumn
|
||||||
|
Caption = 'TTL'
|
||||||
|
DataBinding.FieldName = 'ROWSUM'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid3Level1: TcxGridLevel
|
||||||
|
GridView = TV3
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object DataSource1: TDataSource
|
||||||
|
DataSet = CDS_Main
|
||||||
|
Left = 356
|
||||||
|
Top = 181
|
||||||
|
end
|
||||||
|
object ADOQuerymain: TADOQuery
|
||||||
|
Connection = Packaged_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
SQL.Strings = (
|
||||||
|
'SELECT * FROM JD_Pack A'
|
||||||
|
''
|
||||||
|
''
|
||||||
|
''
|
||||||
|
''
|
||||||
|
'')
|
||||||
|
Left = 412
|
||||||
|
Top = 164
|
||||||
|
end
|
||||||
|
object ADOQuerysub: TADOQuery
|
||||||
|
Connection = Packaged_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 684
|
||||||
|
Top = 188
|
||||||
|
end
|
||||||
|
object DataSource2: TDataSource
|
||||||
|
DataSet = ADOQuerysub
|
||||||
|
Left = 720
|
||||||
|
Top = 248
|
||||||
|
end
|
||||||
|
object ADOQueryPrint: TADOQuery
|
||||||
|
Connection = Packaged_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 292
|
||||||
|
Top = 408
|
||||||
|
end
|
||||||
|
object DataSource3: TDataSource
|
||||||
|
DataSet = ADOQueryPrint
|
||||||
|
Left = 324
|
||||||
|
Top = 408
|
||||||
|
end
|
||||||
|
object ADOQueryCMD: TADOQuery
|
||||||
|
Connection = Packaged_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 644
|
||||||
|
Top = 45
|
||||||
|
end
|
||||||
|
object CDS_Main: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 468
|
||||||
|
Top = 216
|
||||||
|
end
|
||||||
|
end
|
172
基础数据/U_User.dfm
Normal file
172
基础数据/U_User.dfm
Normal file
|
@ -0,0 +1,172 @@
|
||||||
|
object frmUser: TfrmUser
|
||||||
|
Left = 330
|
||||||
|
Top = 222
|
||||||
|
Width = 331
|
||||||
|
Height = 274
|
||||||
|
BorderIcons = [biSystemMenu, biHelp]
|
||||||
|
Caption = #25805#20316#21592
|
||||||
|
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 Label1: TLabel
|
||||||
|
Left = 48
|
||||||
|
Top = 36
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #32534' '#21495
|
||||||
|
end
|
||||||
|
object Label2: TLabel
|
||||||
|
Left = 48
|
||||||
|
Top = 60
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #21517' '#31216
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clBlue
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label3: TLabel
|
||||||
|
Left = 48
|
||||||
|
Top = 84
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #23494' '#30721
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clFuchsia
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label4: TLabel
|
||||||
|
Left = 48
|
||||||
|
Top = 108
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #37325#36755#23494#30721
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clFuchsia
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label5: TLabel
|
||||||
|
Left = 48
|
||||||
|
Top = 132
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #37096' '#38376
|
||||||
|
end
|
||||||
|
object Label6: TLabel
|
||||||
|
Left = 48
|
||||||
|
Top = 156
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #20998' '#31867
|
||||||
|
end
|
||||||
|
object userID: TEdit
|
||||||
|
Left = 112
|
||||||
|
Top = 32
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
CharCase = ecUpperCase
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clRed
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
TabOrder = 0
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object userName: TEdit
|
||||||
|
Left = 112
|
||||||
|
Top = 56
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
CharCase = ecUpperCase
|
||||||
|
TabOrder = 1
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object newPassword: TEdit
|
||||||
|
Left = 112
|
||||||
|
Top = 80
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
CharCase = ecUpperCase
|
||||||
|
PasswordChar = '*'
|
||||||
|
TabOrder = 2
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object DnewPassword: TEdit
|
||||||
|
Left = 112
|
||||||
|
Top = 104
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
CharCase = ecUpperCase
|
||||||
|
PasswordChar = '*'
|
||||||
|
TabOrder = 3
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object cxOK: TcxButton
|
||||||
|
Left = 40
|
||||||
|
Top = 192
|
||||||
|
Width = 75
|
||||||
|
Height = 25
|
||||||
|
Caption = #25552#20132
|
||||||
|
TabOrder = 6
|
||||||
|
OnClick = cxOKClick
|
||||||
|
LookAndFeel.Kind = lfOffice11
|
||||||
|
LookAndFeel.NativeStyle = False
|
||||||
|
end
|
||||||
|
object cxClose: TcxButton
|
||||||
|
Left = 188
|
||||||
|
Top = 192
|
||||||
|
Width = 75
|
||||||
|
Height = 25
|
||||||
|
Caption = #20851#38381
|
||||||
|
TabOrder = 7
|
||||||
|
OnClick = cxCloseClick
|
||||||
|
LookAndFeel.Kind = lfOffice11
|
||||||
|
LookAndFeel.NativeStyle = False
|
||||||
|
end
|
||||||
|
object Udept: TEdit
|
||||||
|
Left = 112
|
||||||
|
Top = 128
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 4
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object UType: TEdit
|
||||||
|
Left = 112
|
||||||
|
Top = 156
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 5
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object ADOQueryTmp: TADOQuery
|
||||||
|
Parameters = <>
|
||||||
|
Left = 292
|
||||||
|
Top = 64
|
||||||
|
end
|
||||||
|
object ADO_Cmd: TADOQuery
|
||||||
|
Parameters = <>
|
||||||
|
Left = 280
|
||||||
|
Top = 108
|
||||||
|
end
|
||||||
|
end
|
213
基础数据/U_User.pas
Normal file
213
基础数据/U_User.pas
Normal file
|
@ -0,0 +1,213 @@
|
||||||
|
unit U_User;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, Menus, cxLookAndFeelPainters, StdCtrls, cxButtons, DB, ADODB;
|
||||||
|
|
||||||
|
type
|
||||||
|
TfrmUser = class(TForm)
|
||||||
|
userID: TEdit;
|
||||||
|
Label1: TLabel;
|
||||||
|
Label2: TLabel;
|
||||||
|
userName: TEdit;
|
||||||
|
newPassword: TEdit;
|
||||||
|
Label3: TLabel;
|
||||||
|
Label4: TLabel;
|
||||||
|
DnewPassword: TEdit;
|
||||||
|
cxOK: TcxButton;
|
||||||
|
cxClose: TcxButton;
|
||||||
|
ADOQueryTmp: TADOQuery;
|
||||||
|
ADO_Cmd: TADOQuery;
|
||||||
|
Label5: TLabel;
|
||||||
|
Udept: TEdit;
|
||||||
|
Label6: TLabel;
|
||||||
|
UType: TEdit;
|
||||||
|
procedure cxCloseClick(Sender: TObject);
|
||||||
|
procedure FormCreate(Sender: TObject);
|
||||||
|
procedure cxOKClick(Sender: TObject);
|
||||||
|
procedure userIDKeyPress(Sender: TObject; var Key: Char);
|
||||||
|
procedure FormShow(Sender: TObject);
|
||||||
|
private
|
||||||
|
fPassWord:string;
|
||||||
|
fIsYGCodezdsc:Boolean;
|
||||||
|
procedure DoQuery();
|
||||||
|
function SaveData():Boolean;
|
||||||
|
{ Private declarations }
|
||||||
|
public
|
||||||
|
formId:integer;
|
||||||
|
fuserID:string;
|
||||||
|
{ Public declarations }
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
frmUser: TfrmUser;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
uses ElAES,AES,U_PublicFunction;
|
||||||
|
{$R *.dfm}
|
||||||
|
function TfrmUser.SaveData():Boolean;
|
||||||
|
begin
|
||||||
|
result:=false;
|
||||||
|
ADO_Cmd.Connection.BeginTrans;
|
||||||
|
try
|
||||||
|
if trim(newPassword.Text)<>'' then
|
||||||
|
fPassWord:=trim(EncryptString(trim(newPassword.text),keys))
|
||||||
|
else
|
||||||
|
fPassWord:='';
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' select * from SY_User ');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(fuserID)));
|
||||||
|
open;
|
||||||
|
|
||||||
|
if ADO_Cmd.IsEmpty then ADO_Cmd.Append
|
||||||
|
else ADO_Cmd.Edit;
|
||||||
|
ADO_Cmd.FieldByName('userID').Value:=trim(fuserID);
|
||||||
|
ADO_Cmd.FieldByName('username').Value:=trim(username.Text);
|
||||||
|
ADO_Cmd.FieldByName('passWord').Value:=trim(fPassWord);
|
||||||
|
ADO_Cmd.FieldByName('Udept').Value:=trim(Udept.Text);
|
||||||
|
ADO_Cmd.FieldByName('UType').Value:=trim(UType.Text);
|
||||||
|
ADO_Cmd.FieldByName('valid').Value:='Y';
|
||||||
|
ADO_Cmd.Post;
|
||||||
|
end;
|
||||||
|
|
||||||
|
ADO_Cmd.Connection.CommitTrans;
|
||||||
|
result:=true;
|
||||||
|
except
|
||||||
|
ADO_Cmd.Connection.RollbackTrans;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
procedure TfrmUser.DoQuery();
|
||||||
|
begin
|
||||||
|
with adoqueryTmp do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' select * from SY_User A ');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(fuserID)));
|
||||||
|
open;
|
||||||
|
if not IsEmpty then
|
||||||
|
begin
|
||||||
|
userID.Text:=trim(fieldbyname('userID').AsString);
|
||||||
|
userName.Text:=trim(fieldbyname('userName').AsString);
|
||||||
|
Udept.Text:=trim(fieldbyname('Udept').AsString);
|
||||||
|
UType.Text:=trim(fieldbyname('UType').AsString);
|
||||||
|
if trim(fieldbyname('passWord').AsString)<>'' then
|
||||||
|
fPassWord:=trim(DecryptString(trim(fieldbyname('passWord').AsString),keys))
|
||||||
|
else
|
||||||
|
fPassWord:='';
|
||||||
|
newPassword.Text:=trim(fPassWord);
|
||||||
|
DnewPassword.Text:=trim(fPassWord);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser.cxCloseClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select * from SY_SET');
|
||||||
|
open;
|
||||||
|
if not IsEmpty then
|
||||||
|
begin
|
||||||
|
fIsYGCodezdsc:=fieldbyname('IsYGCodezdsc').AsBoolean;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser.cxOKClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if trim(userID.Text)='' then
|
||||||
|
begin
|
||||||
|
application.MessageBox('编号不能为空!','错误信息',MB_ICONERROR);
|
||||||
|
userName.Text;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
if trim(userName.Text)='' then
|
||||||
|
begin
|
||||||
|
application.MessageBox('名称不能为空!','错误信息',MB_ICONERROR);
|
||||||
|
userName.Text;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
if trim(newPassword.Text)<> trim(dnewPassword.Text) then
|
||||||
|
begin
|
||||||
|
application.MessageBox('新密码两次输入不一致!','错误信息',MB_ICONERROR);
|
||||||
|
newPassword.Text:='';
|
||||||
|
dnewPassword.Text:='';
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
if formId=0 then
|
||||||
|
begin
|
||||||
|
if fIsYGCodezdsc then
|
||||||
|
begin
|
||||||
|
if not GetMaxBh(ADO_Cmd,fuserID,'SY_USER','YG','0',3) then exit;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
fuserID:=trim(userID.Text);
|
||||||
|
end;
|
||||||
|
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' select * from SY_user');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(fuserID))) ;
|
||||||
|
open;
|
||||||
|
if not isempty then
|
||||||
|
begin
|
||||||
|
application.MessageBox('编号重复!','错误信息',MB_ICONERROR);
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
if SaveData() then
|
||||||
|
begin
|
||||||
|
application.MessageBox('数据保存成功!','提示信息');
|
||||||
|
ModalResult:=1;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
application.MessageBox('数据保存失败!','提示信息',MB_ICONERROR);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser.userIDKeyPress(Sender: TObject; var Key: Char);
|
||||||
|
begin
|
||||||
|
Key:=UpCase(Key);
|
||||||
|
if key=#13 then
|
||||||
|
begin
|
||||||
|
perform(WM_NEXTDLGCTL,0,0);
|
||||||
|
Key := #0;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser.FormShow(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if formId=0 then
|
||||||
|
begin
|
||||||
|
if fIsYGCodezdsc then
|
||||||
|
begin
|
||||||
|
userID.Enabled:=false;
|
||||||
|
userID.Text:='自动生成';
|
||||||
|
end;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
userID.Enabled:=false;
|
||||||
|
end;
|
||||||
|
DoQuery();
|
||||||
|
end;
|
||||||
|
|
||||||
|
end.
|
450
基础数据/U_User10.dfm
Normal file
450
基础数据/U_User10.dfm
Normal file
|
@ -0,0 +1,450 @@
|
||||||
|
object frmUser10: TfrmUser10
|
||||||
|
Left = 295
|
||||||
|
Top = 133
|
||||||
|
Width = 607
|
||||||
|
Height = 376
|
||||||
|
BorderIcons = [biSystemMenu, biHelp]
|
||||||
|
Caption = #25805#20316#21592
|
||||||
|
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 Panel1: TPanel
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
Width = 574
|
||||||
|
Height = 369
|
||||||
|
Align = alTop
|
||||||
|
TabOrder = 0
|
||||||
|
object Label1: TLabel
|
||||||
|
Left = 40
|
||||||
|
Top = 36
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #32534' '#21495
|
||||||
|
end
|
||||||
|
object Label7: TLabel
|
||||||
|
Left = 40
|
||||||
|
Top = 64
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #24615' '#21035
|
||||||
|
end
|
||||||
|
object Label9: TLabel
|
||||||
|
Left = 40
|
||||||
|
Top = 92
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #24405#29992#26085#26399
|
||||||
|
end
|
||||||
|
object Label10: TLabel
|
||||||
|
Left = 284
|
||||||
|
Top = 92
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #36523' '#20221' '#35777
|
||||||
|
end
|
||||||
|
object Label8: TLabel
|
||||||
|
Left = 284
|
||||||
|
Top = 64
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #23398' '#21382
|
||||||
|
end
|
||||||
|
object Label2: TLabel
|
||||||
|
Left = 284
|
||||||
|
Top = 36
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #21517' '#31216
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clBlue
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label5: TLabel
|
||||||
|
Left = 40
|
||||||
|
Top = 172
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #37096' '#38376
|
||||||
|
end
|
||||||
|
object Label6: TLabel
|
||||||
|
Left = 40
|
||||||
|
Top = 200
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #20998' '#31867
|
||||||
|
end
|
||||||
|
object Label3: TLabel
|
||||||
|
Left = 164
|
||||||
|
Top = 469
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #23494' '#30721
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clFuchsia
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object Label4: TLabel
|
||||||
|
Left = 168
|
||||||
|
Top = 473
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #37325#36755#23494#30721
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clFuchsia
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object Label11: TLabel
|
||||||
|
Left = 40
|
||||||
|
Top = 120
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #23478#24237#22320#22336
|
||||||
|
end
|
||||||
|
object Label12: TLabel
|
||||||
|
Left = 40
|
||||||
|
Top = 148
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #32852#31995#30005#35805
|
||||||
|
end
|
||||||
|
object Label13: TLabel
|
||||||
|
Left = 284
|
||||||
|
Top = 144
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #24037' '#31181
|
||||||
|
end
|
||||||
|
object Label14: TLabel
|
||||||
|
Left = 284
|
||||||
|
Top = 172
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #30331' '#35760' '#21495
|
||||||
|
end
|
||||||
|
object Label15: TLabel
|
||||||
|
Left = 40
|
||||||
|
Top = 224
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #22791' '#27880
|
||||||
|
end
|
||||||
|
object Label16: TLabel
|
||||||
|
Left = 284
|
||||||
|
Top = 200
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #26159#21542#22312#32844
|
||||||
|
end
|
||||||
|
object userID: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 112
|
||||||
|
Top = 32
|
||||||
|
Width = 120
|
||||||
|
Height = 20
|
||||||
|
CharCase = ecUpperCase
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clRed
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
ParentFont = False
|
||||||
|
TabOrder = 0
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object sex: TComboBox
|
||||||
|
Tag = 2
|
||||||
|
Left = 112
|
||||||
|
Top = 60
|
||||||
|
Width = 120
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
ItemIndex = 0
|
||||||
|
TabOrder = 1
|
||||||
|
Text = #30007
|
||||||
|
Items.Strings = (
|
||||||
|
#30007
|
||||||
|
#22899)
|
||||||
|
end
|
||||||
|
object InTime: TDateTimePicker
|
||||||
|
Tag = 2
|
||||||
|
Left = 112
|
||||||
|
Top = 88
|
||||||
|
Width = 120
|
||||||
|
Height = 20
|
||||||
|
Date = 41484.000000000000000000
|
||||||
|
Format = 'yyyy-MM-dd'
|
||||||
|
Time = 41484.000000000000000000
|
||||||
|
ShowCheckbox = True
|
||||||
|
TabOrder = 2
|
||||||
|
end
|
||||||
|
object idNo: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 348
|
||||||
|
Top = 88
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 3
|
||||||
|
end
|
||||||
|
object edu: TComboBox
|
||||||
|
Tag = 2
|
||||||
|
Left = 348
|
||||||
|
Top = 60
|
||||||
|
Width = 120
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
ItemIndex = 0
|
||||||
|
TabOrder = 4
|
||||||
|
Items.Strings = (
|
||||||
|
''
|
||||||
|
#23567#23398
|
||||||
|
#20013#23398
|
||||||
|
#39640#20013
|
||||||
|
#20013#19987
|
||||||
|
#22823#19987
|
||||||
|
#26412#31185
|
||||||
|
#30805#22763
|
||||||
|
#21338#22763)
|
||||||
|
end
|
||||||
|
object userName: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 348
|
||||||
|
Top = 32
|
||||||
|
Width = 120
|
||||||
|
Height = 20
|
||||||
|
CharCase = ecUpperCase
|
||||||
|
TabOrder = 5
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object Udept: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 112
|
||||||
|
Top = 168
|
||||||
|
Width = 120
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 6
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object UType: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 112
|
||||||
|
Top = 196
|
||||||
|
Width = 120
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 7
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object cxOK: TcxButton
|
||||||
|
Left = 48
|
||||||
|
Top = 292
|
||||||
|
Width = 75
|
||||||
|
Height = 25
|
||||||
|
Caption = #25552#20132
|
||||||
|
TabOrder = 8
|
||||||
|
OnClick = cxOKClick
|
||||||
|
LookAndFeel.Kind = lfOffice11
|
||||||
|
LookAndFeel.NativeStyle = False
|
||||||
|
end
|
||||||
|
object cxClose: TcxButton
|
||||||
|
Left = 384
|
||||||
|
Top = 292
|
||||||
|
Width = 75
|
||||||
|
Height = 25
|
||||||
|
Caption = #20851#38381
|
||||||
|
TabOrder = 9
|
||||||
|
OnClick = cxCloseClick
|
||||||
|
LookAndFeel.Kind = lfOffice11
|
||||||
|
LookAndFeel.NativeStyle = False
|
||||||
|
end
|
||||||
|
object newPassword: TEdit
|
||||||
|
Left = 228
|
||||||
|
Top = 461
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
CharCase = ecUpperCase
|
||||||
|
PasswordChar = '*'
|
||||||
|
TabOrder = 10
|
||||||
|
Visible = False
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object DnewPassword: TEdit
|
||||||
|
Left = 356
|
||||||
|
Top = 473
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
CharCase = ecUpperCase
|
||||||
|
PasswordChar = '*'
|
||||||
|
TabOrder = 11
|
||||||
|
Visible = False
|
||||||
|
OnKeyPress = userIDKeyPress
|
||||||
|
end
|
||||||
|
object Address: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 112
|
||||||
|
Top = 116
|
||||||
|
Width = 357
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 12
|
||||||
|
end
|
||||||
|
object phone: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 112
|
||||||
|
Top = 144
|
||||||
|
Width = 120
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 13
|
||||||
|
end
|
||||||
|
object position: TBtnEditC
|
||||||
|
Tag = 2
|
||||||
|
Left = 348
|
||||||
|
Top = 140
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
Hint = 'position/'#24037#31181
|
||||||
|
ReadOnly = True
|
||||||
|
TabOrder = 14
|
||||||
|
OnBtnUpClick = positionBtnUpClick
|
||||||
|
OnBtnDnClick = positionBtnDnClick
|
||||||
|
end
|
||||||
|
object fstr1: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 348
|
||||||
|
Top = 168
|
||||||
|
Width = 121
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 15
|
||||||
|
end
|
||||||
|
object note: TMemo
|
||||||
|
Tag = 2
|
||||||
|
Left = 112
|
||||||
|
Top = 220
|
||||||
|
Width = 357
|
||||||
|
Height = 61
|
||||||
|
ScrollBars = ssVertical
|
||||||
|
TabOrder = 16
|
||||||
|
end
|
||||||
|
object valid: TComboBox
|
||||||
|
Left = 348
|
||||||
|
Top = 196
|
||||||
|
Width = 125
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
ItemIndex = 0
|
||||||
|
TabOrder = 17
|
||||||
|
Text = #26159
|
||||||
|
Items.Strings = (
|
||||||
|
#26159
|
||||||
|
#21542)
|
||||||
|
end
|
||||||
|
object Picture4: TcxDBImage
|
||||||
|
Left = 632
|
||||||
|
Top = 29
|
||||||
|
Hint = 'FileName'
|
||||||
|
DataBinding.DataField = 'FilesOther'
|
||||||
|
DataBinding.DataSource = DataSource1
|
||||||
|
Properties.GraphicClassName = 'TJPEGImage'
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
Properties.ShowFocusRect = False
|
||||||
|
Style.BorderStyle = ebsSingle
|
||||||
|
TabOrder = 18
|
||||||
|
Visible = False
|
||||||
|
OnDblClick = Picture4DblClick
|
||||||
|
Height = 220
|
||||||
|
Width = 316
|
||||||
|
end
|
||||||
|
object FileName: TcxButton
|
||||||
|
Left = 544
|
||||||
|
Top = 32
|
||||||
|
Width = 86
|
||||||
|
Height = 25
|
||||||
|
Hint = 'Filesother'
|
||||||
|
Caption = #36523#20221#35777#27491#38754
|
||||||
|
TabOrder = 19
|
||||||
|
Visible = False
|
||||||
|
OnClick = FileNameClick
|
||||||
|
LookAndFeel.Kind = lfOffice11
|
||||||
|
end
|
||||||
|
object cxDBImage1: TcxDBImage
|
||||||
|
Left = 632
|
||||||
|
Top = 252
|
||||||
|
Hint = 'FileName1'
|
||||||
|
DataBinding.DataField = 'FilesOther1'
|
||||||
|
DataBinding.DataSource = DataSource1
|
||||||
|
Properties.GraphicClassName = 'TJPEGImage'
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
Properties.ShowFocusRect = False
|
||||||
|
Style.BorderStyle = ebsSingle
|
||||||
|
TabOrder = 20
|
||||||
|
Visible = False
|
||||||
|
OnDblClick = Picture4DblClick
|
||||||
|
Height = 220
|
||||||
|
Width = 316
|
||||||
|
end
|
||||||
|
object FileName1: TcxButton
|
||||||
|
Left = 544
|
||||||
|
Top = 251
|
||||||
|
Width = 86
|
||||||
|
Height = 25
|
||||||
|
Hint = 'Filesother1'
|
||||||
|
Caption = #36523#20221#35777#32972#38754
|
||||||
|
TabOrder = 21
|
||||||
|
Visible = False
|
||||||
|
OnClick = FileNameClick
|
||||||
|
LookAndFeel.Kind = lfOffice11
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object ADOQueryTmp: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 500
|
||||||
|
Top = 200
|
||||||
|
end
|
||||||
|
object ADO_Cmd: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 456
|
||||||
|
Top = 268
|
||||||
|
end
|
||||||
|
object DataSource1: TDataSource
|
||||||
|
DataSet = ADOQueryImage
|
||||||
|
Left = 580
|
||||||
|
Top = 180
|
||||||
|
end
|
||||||
|
object ADOQueryImage: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 572
|
||||||
|
Top = 112
|
||||||
|
end
|
||||||
|
object IdFTP1: TIdFTP
|
||||||
|
MaxLineAction = maException
|
||||||
|
ReadTimeout = 0
|
||||||
|
ProxySettings.ProxyType = fpcmNone
|
||||||
|
ProxySettings.Port = 0
|
||||||
|
Left = 784
|
||||||
|
Top = 178
|
||||||
|
end
|
||||||
|
end
|
408
基础数据/U_User10.pas
Normal file
408
基础数据/U_User10.pas
Normal file
|
@ -0,0 +1,408 @@
|
||||||
|
unit U_User10;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, strUtils,Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, Menus, cxLookAndFeelPainters, StdCtrls, cxButtons, DB, ADODB,
|
||||||
|
BtnEdit, ComCtrls, ExtCtrls, cxControls, cxContainer, cxEdit, cxImage,
|
||||||
|
cxDBEdit, IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient,ShellAPI,
|
||||||
|
IdFTP, cxGraphics, cxLookAndFeels, dxSkinsCore, dxSkinBlack, dxSkinBlue,
|
||||||
|
dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom,
|
||||||
|
dxSkinDarkSide, dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle,
|
||||||
|
dxSkinFoggy, dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary,
|
||||||
|
dxSkinLilian, dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin,
|
||||||
|
dxSkinMetropolis, dxSkinMetropolisDark, dxSkinMoneyTwins,
|
||||||
|
dxSkinOffice2007Black, dxSkinOffice2007Blue, dxSkinOffice2007Green,
|
||||||
|
dxSkinOffice2007Pink, dxSkinOffice2007Silver, dxSkinOffice2010Black,
|
||||||
|
dxSkinOffice2010Blue, dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
|
||||||
|
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin,
|
||||||
|
dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
|
||||||
|
dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
|
||||||
|
dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine,
|
||||||
|
dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue;
|
||||||
|
|
||||||
|
type
|
||||||
|
TfrmUser10 = class(TForm)
|
||||||
|
ADOQueryTmp: TADOQuery;
|
||||||
|
ADO_Cmd: TADOQuery;
|
||||||
|
Panel1: TPanel;
|
||||||
|
userID: TEdit;
|
||||||
|
Label1: TLabel;
|
||||||
|
sex: TComboBox;
|
||||||
|
Label7: TLabel;
|
||||||
|
Label9: TLabel;
|
||||||
|
InTime: TDateTimePicker;
|
||||||
|
Label10: TLabel;
|
||||||
|
idNo: TEdit;
|
||||||
|
edu: TComboBox;
|
||||||
|
Label8: TLabel;
|
||||||
|
Label2: TLabel;
|
||||||
|
userName: TEdit;
|
||||||
|
Udept: TEdit;
|
||||||
|
Label5: TLabel;
|
||||||
|
Label6: TLabel;
|
||||||
|
UType: TEdit;
|
||||||
|
cxOK: TcxButton;
|
||||||
|
cxClose: TcxButton;
|
||||||
|
newPassword: TEdit;
|
||||||
|
Label3: TLabel;
|
||||||
|
Label4: TLabel;
|
||||||
|
DnewPassword: TEdit;
|
||||||
|
Label11: TLabel;
|
||||||
|
Address: TEdit;
|
||||||
|
Label12: TLabel;
|
||||||
|
phone: TEdit;
|
||||||
|
Label13: TLabel;
|
||||||
|
position: TBtnEditC;
|
||||||
|
Label14: TLabel;
|
||||||
|
fstr1: TEdit;
|
||||||
|
Label15: TLabel;
|
||||||
|
note: TMemo;
|
||||||
|
Label16: TLabel;
|
||||||
|
valid: TComboBox;
|
||||||
|
Picture4: TcxDBImage;
|
||||||
|
FileName: TcxButton;
|
||||||
|
cxDBImage1: TcxDBImage;
|
||||||
|
FileName1: TcxButton;
|
||||||
|
DataSource1: TDataSource;
|
||||||
|
ADOQueryImage: TADOQuery;
|
||||||
|
IdFTP1: TIdFTP;
|
||||||
|
procedure cxCloseClick(Sender: TObject);
|
||||||
|
procedure FormCreate(Sender: TObject);
|
||||||
|
procedure cxOKClick(Sender: TObject);
|
||||||
|
procedure userIDKeyPress(Sender: TObject; var Key: Char);
|
||||||
|
procedure FormShow(Sender: TObject);
|
||||||
|
procedure positionBtnUpClick(Sender: TObject);
|
||||||
|
procedure positionBtnDnClick(Sender: TObject);
|
||||||
|
procedure FileNameClick(Sender: TObject);
|
||||||
|
procedure Picture4DblClick(Sender: TObject);
|
||||||
|
private
|
||||||
|
fPassWord:string;
|
||||||
|
fIsYGCodezdsc:Boolean;
|
||||||
|
procedure DoQuery();
|
||||||
|
function SaveData():Boolean;
|
||||||
|
// procedure InitImage();
|
||||||
|
{ Private declarations }
|
||||||
|
public
|
||||||
|
formId:integer;
|
||||||
|
fuserID:string;
|
||||||
|
{ Public declarations }
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
frmUser10: TfrmUser10;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
uses U_DataLink,U_Fun10,U_ZDYHelp,U_PublicFunction, getpic;
|
||||||
|
{$R *.dfm}
|
||||||
|
{procedure TfrmUser10.InitImage();
|
||||||
|
begin
|
||||||
|
with ADOQueryImage do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select * from TP_File A');
|
||||||
|
sql.Add('where TFid='+quotedstr(trim(userID.Text)));
|
||||||
|
open;
|
||||||
|
end;
|
||||||
|
end;}
|
||||||
|
function TfrmUser10.SaveData():Boolean;
|
||||||
|
begin
|
||||||
|
result:=false;
|
||||||
|
ADO_Cmd.Connection.BeginTrans;
|
||||||
|
try
|
||||||
|
{ if trim(newPassword.Text)<>'' then
|
||||||
|
fPassWord:=trim(EncryptString(trim(newPassword.text),keys))
|
||||||
|
else }
|
||||||
|
fPassWord:='';
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' select * from BD_Staff ');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(fuserID)));
|
||||||
|
open;
|
||||||
|
|
||||||
|
if ADO_Cmd.IsEmpty then ADO_Cmd.Append
|
||||||
|
else ADO_Cmd.Edit;
|
||||||
|
SSetsaveSqlNew(ADO_Cmd,'BD_Staff',Panel1,2);
|
||||||
|
ADO_Cmd.FieldByName('userID').Value:=trim(fuserID);
|
||||||
|
// ADO_Cmd.FieldByName('username').Value:=trim(username.Text);
|
||||||
|
ADO_Cmd.FieldByName('passWord').Value:=trim(fPassWord);
|
||||||
|
// ADO_Cmd.FieldByName('Udept').Value:=trim(Udept.Text);
|
||||||
|
// ADO_Cmd.FieldByName('UType').Value:=trim(UType.Text);
|
||||||
|
if trim(valid.Text)='否' then
|
||||||
|
ADO_Cmd.FieldByName('valid').Value:='N'
|
||||||
|
else
|
||||||
|
ADO_Cmd.FieldByName('valid').Value:='Y';
|
||||||
|
ADO_Cmd.FieldByName('isywy').Value:=false;
|
||||||
|
ADO_Cmd.Post;
|
||||||
|
end;
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' update SY_user SET ');
|
||||||
|
if trim(valid.Text)='否' then
|
||||||
|
sql.Add(' valid=''N'' ')
|
||||||
|
else
|
||||||
|
sql.Add(' valid=''Y'' ');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(fuserID)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
|
||||||
|
ADO_Cmd.Connection.CommitTrans;
|
||||||
|
result:=true;
|
||||||
|
except
|
||||||
|
ADO_Cmd.Connection.RollbackTrans;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
procedure TfrmUser10.DoQuery();
|
||||||
|
begin
|
||||||
|
with adoqueryTmp do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' select * from BD_Staff A ');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(fuserID)));
|
||||||
|
open;
|
||||||
|
if not IsEmpty then
|
||||||
|
begin
|
||||||
|
SCSHDataNew(adoqueryTmp,Panel1,2);
|
||||||
|
// userID.Text:=trim(fieldbyname('userID').AsString);
|
||||||
|
// userName.Text:=trim(fieldbyname('userName').AsString);
|
||||||
|
// Udept.Text:=trim(fieldbyname('Udept').AsString);
|
||||||
|
// UType.Text:=trim(fieldbyname('UType').AsString);
|
||||||
|
{ if trim(fieldbyname('passWord').AsString)<>'' then
|
||||||
|
fPassWord:=trim(DecryptString(trim(fieldbyname('passWord').AsString),keys))
|
||||||
|
else }
|
||||||
|
fPassWord:='';
|
||||||
|
// newPassword.Text:=trim(fPassWord);
|
||||||
|
// DnewPassword.Text:=trim(fPassWord);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.cxCloseClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
Panel1.Align:=alclient;
|
||||||
|
{ with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select * from SY_SET');
|
||||||
|
open;
|
||||||
|
if not IsEmpty then
|
||||||
|
begin
|
||||||
|
fIsYGCodezdsc:=fieldbyname('IsYGCodezdsc').AsBoolean;
|
||||||
|
end;
|
||||||
|
end; }
|
||||||
|
fIsYGCodezdsc:=true;
|
||||||
|
InTime.Date:=strtodate(formatdateTime('yyyy-MM-dd',DServerDate));
|
||||||
|
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.cxOKClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if trim(userID.Text)='' then
|
||||||
|
begin
|
||||||
|
application.MessageBox('编号不能为空!','错误信息',MB_ICONERROR);
|
||||||
|
userName.Text;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
if trim(userName.Text)='' then
|
||||||
|
begin
|
||||||
|
application.MessageBox('名称不能为空!','错误信息',MB_ICONERROR);
|
||||||
|
userName.Text;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
if trim(newPassword.Text)<> trim(dnewPassword.Text) then
|
||||||
|
begin
|
||||||
|
application.MessageBox('新密码两次输入不一致!','错误信息',MB_ICONERROR);
|
||||||
|
newPassword.Text:='';
|
||||||
|
dnewPassword.Text:='';
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
if formId=0 then
|
||||||
|
begin
|
||||||
|
if fIsYGCodezdsc then
|
||||||
|
begin
|
||||||
|
if not GetMaxBh(ADO_Cmd,fuserID,'BD_Staff','YG','0',3) then exit;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
fuserID:=trim(userID.Text);
|
||||||
|
end;
|
||||||
|
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' select * from BD_Staff');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(fuserID))) ;
|
||||||
|
open;
|
||||||
|
if not isempty then
|
||||||
|
begin
|
||||||
|
application.MessageBox('编号重复!','错误信息',MB_ICONERROR);
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
if SaveData() then
|
||||||
|
begin
|
||||||
|
application.MessageBox('数据保存成功!','提示信息');
|
||||||
|
ModalResult:=1;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
application.MessageBox('数据保存失败!','提示信息',MB_ICONERROR);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.userIDKeyPress(Sender: TObject; var Key: Char);
|
||||||
|
begin
|
||||||
|
Key:=UpCase(Key);
|
||||||
|
if key=#13 then
|
||||||
|
begin
|
||||||
|
perform(WM_NEXTDLGCTL,0,0);
|
||||||
|
Key := #0;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.FormShow(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if formId=0 then
|
||||||
|
begin
|
||||||
|
if fIsYGCodezdsc then
|
||||||
|
begin
|
||||||
|
userID.Enabled:=false;
|
||||||
|
userID.Text:='自动生成';
|
||||||
|
end;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
userID.Enabled:=false;
|
||||||
|
end;
|
||||||
|
DoQuery();
|
||||||
|
// InitImage();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.positionBtnUpClick(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 Trim(flag)='OrdDefStr2' then
|
||||||
|
begin
|
||||||
|
V1Name.Caption:='中文名称';
|
||||||
|
V1Note.Caption:='备注信息';
|
||||||
|
fnote:=true;
|
||||||
|
end;
|
||||||
|
if ShowModal=1 then
|
||||||
|
begin
|
||||||
|
TEdit(Sender).Text:=Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
finally
|
||||||
|
frmZDYHelp.Free;
|
||||||
|
end;
|
||||||
|
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.positionBtnDnClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
TBtnEditC(Sender).Text:='';
|
||||||
|
TBtnEditC(Sender).TxtCode:='';
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.FileNameClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
IF trim(userID.Text)='' then
|
||||||
|
begin
|
||||||
|
application.MessageBox('产品编号不能为空!','提示信息',MB_ICONERROR);
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
|
||||||
|
try
|
||||||
|
FormGetPic := TFormGetPic.Create(Application);
|
||||||
|
with FormGetPic do
|
||||||
|
begin
|
||||||
|
fkeyNO:=trim(userID.Text);
|
||||||
|
pat1:=TCXbutton(Sender).Name;
|
||||||
|
pic1:=TCXbutton(Sender).Hint;
|
||||||
|
FTFType:='员工信息';
|
||||||
|
// pat1:='PatFile1';
|
||||||
|
// pic1:='Picture1';
|
||||||
|
IF ShowModal = 1 then
|
||||||
|
begin
|
||||||
|
// self.Timage(Tbutton(Sender).Hint).Picture.Assign(FormGetPic.Image2.Picture.Bitmap);
|
||||||
|
userID.Enabled:=false;
|
||||||
|
end;
|
||||||
|
|
||||||
|
Release;
|
||||||
|
end;
|
||||||
|
// Initimage();
|
||||||
|
except
|
||||||
|
if FormGetPic<>nil then FormGetPic.Release;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser10.Picture4DblClick(Sender: TObject);
|
||||||
|
var
|
||||||
|
sFieldName:string;
|
||||||
|
fileName:string;
|
||||||
|
begin
|
||||||
|
|
||||||
|
IF TcxDBImage(Sender).Picture.Height=0 then exit;
|
||||||
|
|
||||||
|
sFieldName:=LeftBstr(ExtractFilePath(Application.ExeName),1)+':\图片查看';
|
||||||
|
|
||||||
|
if not DirectoryExists(pchar(sFieldName)) then
|
||||||
|
CreateDirectory(pchar(sFieldName),nil);
|
||||||
|
|
||||||
|
fileName:=adoqueryImage.fieldbyname(TcxDBImage(Sender).Hint).asstring;
|
||||||
|
|
||||||
|
sFieldName:=sFieldName+'\'+trim(fileName);
|
||||||
|
try
|
||||||
|
IdFTP1.Host := PicSvr;
|
||||||
|
IdFTP1.Username := 'three';
|
||||||
|
IdFTP1.Password := '641010';
|
||||||
|
IdFTP1.Connect();
|
||||||
|
except
|
||||||
|
;
|
||||||
|
end;
|
||||||
|
|
||||||
|
if IdFTP1.Connected then
|
||||||
|
begin
|
||||||
|
try
|
||||||
|
IdFTP1.Get('TP\'+ Trim(fileName), sFieldName,false, true);
|
||||||
|
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;
|
||||||
|
ShellExecute(Handle, 'open',PChar(sFieldName),'', '', SW_SHOWNORMAL);
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
end.
|
23911
基础数据/U_UserHelp_Bz.dfm
Normal file
23911
基础数据/U_UserHelp_Bz.dfm
Normal file
File diff suppressed because it is too large
Load Diff
282
基础数据/U_UserHelp_Bz.pas
Normal file
282
基础数据/U_UserHelp_Bz.pas
Normal file
|
@ -0,0 +1,282 @@
|
||||||
|
unit U_UserHelp_Bz;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, cxFilter,
|
||||||
|
cxData, cxDataStorage, cxEdit, DB, cxDBData, StdCtrls, cxGridLevel,
|
||||||
|
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, cxClasses,
|
||||||
|
cxControls, cxGridCustomView, cxGrid, cxInplaceContainer, cxDBTL,
|
||||||
|
cxTLData, ComCtrls, ToolWin, ADODB, ImgList,StrUtils, ExtCtrls, DBClient;
|
||||||
|
|
||||||
|
type
|
||||||
|
TfrmUserHelp_Bz = class(TForm)
|
||||||
|
ToolBar2: TToolBar;
|
||||||
|
TOk: TToolButton;
|
||||||
|
TBClose: TToolButton;
|
||||||
|
cxGrid1: TcxGrid;
|
||||||
|
tv1: TcxGridDBTableView;
|
||||||
|
tv1Code: TcxGridDBColumn;
|
||||||
|
tv1Name: TcxGridDBColumn;
|
||||||
|
DBGrid1Level1: TcxGridLevel;
|
||||||
|
GroupBox1: TGroupBox;
|
||||||
|
ADOQueryDept: TADOQuery;
|
||||||
|
DataSource1: TDataSource;
|
||||||
|
ADOConnection1: TADOConnection;
|
||||||
|
tv1Column1: TcxGridDBColumn;
|
||||||
|
cxStyleRepository1: TcxStyleRepository;
|
||||||
|
cxStyle1: TcxStyle;
|
||||||
|
cxStyle2: TcxStyle;
|
||||||
|
cxStyle_gridRow: TcxStyle;
|
||||||
|
cxStyle_gridFoot: TcxStyle;
|
||||||
|
cxStyle_gridHead: TcxStyle;
|
||||||
|
cxStyle_gridGroupBox: TcxStyle;
|
||||||
|
cxStyle_yellow: TcxStyle;
|
||||||
|
cxStyle_Red: TcxStyle;
|
||||||
|
ADOQueryHelp: TADOQuery;
|
||||||
|
DataSource2: TDataSource;
|
||||||
|
Label1: TLabel;
|
||||||
|
Edt_name: TEdit;
|
||||||
|
ImageList1: TImageList;
|
||||||
|
cxStyleTree: TcxStyle;
|
||||||
|
Label2: TLabel;
|
||||||
|
Edt_Code: TEdit;
|
||||||
|
ThreeImgList: TImageList;
|
||||||
|
cxGrid2: TcxGrid;
|
||||||
|
Tv2: TcxGridDBTableView;
|
||||||
|
cxGridDBColumn1: TcxGridDBColumn;
|
||||||
|
cxGridDBColumn2: TcxGridDBColumn;
|
||||||
|
cxGridDBColumn3: TcxGridDBColumn;
|
||||||
|
cxGridLevel1: TcxGridLevel;
|
||||||
|
GroupBox2: TGroupBox;
|
||||||
|
CDS_sel: TClientDataSet;
|
||||||
|
DataSourceSel: TDataSource;
|
||||||
|
cxDBTreeList1: TcxDBTreeList;
|
||||||
|
cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn;
|
||||||
|
Splitter1: TSplitter;
|
||||||
|
Label3: TLabel;
|
||||||
|
banzu: TComboBox;
|
||||||
|
ADO_Cmd: TADOQuery;
|
||||||
|
procedure FormShow(Sender: TObject);
|
||||||
|
procedure FormCreate(Sender: TObject);
|
||||||
|
procedure TBCloseClick(Sender: TObject);
|
||||||
|
procedure TOkClick(Sender: TObject);
|
||||||
|
procedure tv1DblClick(Sender: TObject);
|
||||||
|
procedure Edt_nameChange(Sender: TObject);
|
||||||
|
procedure cxDBTreeList1Click(Sender: TObject);
|
||||||
|
private
|
||||||
|
procedure InitTree();
|
||||||
|
procedure DoQuery();
|
||||||
|
procedure FilterData(strdepotno,strcode,strname:string);
|
||||||
|
public
|
||||||
|
fFrameNo:string;
|
||||||
|
fFrameName:string;
|
||||||
|
fIsYwy:boolean;
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
frmUserHelp_Bz: TfrmUserHelp_Bz;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
uses
|
||||||
|
U_DataLink,U_Fun10;
|
||||||
|
{$R *.dfm}
|
||||||
|
///////////////////////////////////////////////////////////
|
||||||
|
//////功能:过滤数据
|
||||||
|
///////////////////////////////////////////////////////////
|
||||||
|
procedure TfrmUserHelp_Bz.FilterData(strdepotno,strcode,strname:string);
|
||||||
|
var
|
||||||
|
filterStr:string;
|
||||||
|
begin
|
||||||
|
filterStr:='';
|
||||||
|
if trim(strdepotno)<>'' then
|
||||||
|
filterStr:=filterStr+' and dept like '+quotedstr('%'+trim(strdepotno)+'%');
|
||||||
|
if trim(strcode)<>'' then
|
||||||
|
filterStr:=filterStr+' and userID like '+quotedstr('%'+trim(strcode)+'%');
|
||||||
|
if trim(strname)<>'' then
|
||||||
|
filterStr:=filterStr+' and userName like '+quotedstr('%'+trim(strname)+'%');
|
||||||
|
|
||||||
|
try
|
||||||
|
ADOQueryHelp.DisableControls ;
|
||||||
|
if trim(filterStr)='' then
|
||||||
|
begin
|
||||||
|
ADOQueryHelp.Filtered:=false;
|
||||||
|
ADOQueryHelp.EnableControls;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
filterStr:=trim(RightBStr(filterStr,length(filterStr)-5));
|
||||||
|
// showmessage(filterStr);
|
||||||
|
with ADOQueryHelp do
|
||||||
|
begin
|
||||||
|
filtered:=false;
|
||||||
|
filter:=filterStr;
|
||||||
|
filtered:=true;
|
||||||
|
end;
|
||||||
|
finally
|
||||||
|
ADOQueryHelp.EnableControls;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
//////////////////////////////////////////////////////
|
||||||
|
procedure TfrmUserHelp_Bz.InitTree();
|
||||||
|
var
|
||||||
|
strsql,strwhere:string;
|
||||||
|
begin
|
||||||
|
strsql:=' SELECT distinct UDept=''ALL'',UDeptTop='''',UDeptName=''所有部门'',Framelevel=0 '+
|
||||||
|
' union '+
|
||||||
|
' SELECT distinct UDept,UDeptTop=''ALL'',UDept,Framelevel=1 '+
|
||||||
|
' FROM BD_staff A '+
|
||||||
|
' WHERE USERID<>''ADMIN'' and ISNULL(UDept,'''')<>'''' ';
|
||||||
|
|
||||||
|
strwhere:=' where A.Valid=''Y'' ';
|
||||||
|
{ if fIsYwy then
|
||||||
|
strwhere:=strwhere+' and A.YWYFlag=''Y'' ';
|
||||||
|
if trim(fFrameNo)<>'' then
|
||||||
|
strwhere:=strwhere+' and A.dept='+quotedstr(trim(fFrameNo));
|
||||||
|
if trim(fFrameName)<>'' then
|
||||||
|
strwhere:=strwhere+' and B.frameName like '+quotedstr('%'+trim(fFrameName)+'%');
|
||||||
|
strsql:=strsql+ strwhere; }
|
||||||
|
|
||||||
|
with ADOQueryDept do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear ;
|
||||||
|
sql.Add( strsql);
|
||||||
|
Open;
|
||||||
|
end;
|
||||||
|
cxDBTreeList1.FullExpand;
|
||||||
|
|
||||||
|
DoQuery();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Bz.FormShow(Sender: TObject);
|
||||||
|
begin
|
||||||
|
InitTree();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Bz.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
GroupBox2.Align :=alclient;
|
||||||
|
with ADOConnection1 do
|
||||||
|
begin
|
||||||
|
Connected:=false;
|
||||||
|
ConnectionString:=DConString;
|
||||||
|
Connected:=true;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
//////////////////////////////////////////////////
|
||||||
|
//
|
||||||
|
//////////////////////////////////////////////////
|
||||||
|
procedure TfrmUserHelp_Bz.DoQuery();
|
||||||
|
var
|
||||||
|
strsql,strwhere:string;
|
||||||
|
begin
|
||||||
|
strsql:=' select * '+
|
||||||
|
' from BD_staff A '+
|
||||||
|
' where isnull(UserID,'''')<>''ADMIN'' '+
|
||||||
|
' and not exists(select userID from BD_staff_Banzu X where X.userID=A.UserID) ';
|
||||||
|
strwhere:=' and A.Valid=''Y'' ';
|
||||||
|
if fIsYwy then
|
||||||
|
strwhere:=strwhere+' and A.Isywy=1 ';
|
||||||
|
|
||||||
|
|
||||||
|
strsql:=strsql+ strwhere +' order by A.userID ';
|
||||||
|
|
||||||
|
with ADOQueryHelp do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear ;
|
||||||
|
sql.Add( strsql);
|
||||||
|
Open;
|
||||||
|
end;
|
||||||
|
|
||||||
|
sCreateCDS20(ADOQueryHelp,cds_sel);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Bz.TBCloseClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Bz.TOkClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if ADOQueryHelp.IsEmpty then
|
||||||
|
begin
|
||||||
|
application.MessageBox('没有选择员工!','提示信息',MB_ICONERROR);
|
||||||
|
exit;
|
||||||
|
|
||||||
|
end;
|
||||||
|
if trim(banzu.text)='' then
|
||||||
|
begin
|
||||||
|
application.MessageBox('没有选择班组!','提示信息',MB_ICONERROR);
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
|
||||||
|
ADO_Cmd.Connection.BeginTrans;
|
||||||
|
try
|
||||||
|
with CDS_sel do
|
||||||
|
begin
|
||||||
|
DisableControls;
|
||||||
|
First;
|
||||||
|
while not eof do
|
||||||
|
begin
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select * from BD_Staff_banzu');
|
||||||
|
sql.Add('where userID='+quotedstr(trim(CDS_sel.fieldbyname('userID').AsString)));
|
||||||
|
open;
|
||||||
|
if ADO_Cmd.IsEmpty then ADO_Cmd.Append
|
||||||
|
else ADO_Cmd.Edit;
|
||||||
|
ADO_Cmd.fieldbyname('userID').Value:=trim(CDS_sel.fieldbyname('userID').AsString);
|
||||||
|
ADO_Cmd.fieldbyname('banzu').Value:=trim(banzu.Text);
|
||||||
|
ADO_Cmd.Post;
|
||||||
|
end;
|
||||||
|
next;
|
||||||
|
end;
|
||||||
|
EnableControls;
|
||||||
|
end;
|
||||||
|
ADO_Cmd.Connection.CommitTrans;
|
||||||
|
except
|
||||||
|
CDS_sel.EnableControls;
|
||||||
|
ADO_Cmd.Connection.RollbackTrans;
|
||||||
|
application.MessageBox('数据保存失败!','提示信息',MB_ICONERROR);
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
ModalResult:=1;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Bz.tv1DblClick(Sender: TObject);
|
||||||
|
var
|
||||||
|
i:integer;
|
||||||
|
begin
|
||||||
|
if ADOQueryHelp.IsEmpty then exit;
|
||||||
|
|
||||||
|
if CDS_Sel.Locate('userID',trim(adoqueryHelp.fieldbyname('userID').AsString),[]) then exit;
|
||||||
|
with CDS_Sel do
|
||||||
|
begin
|
||||||
|
CDS_Sel.append;
|
||||||
|
for i:=0 to ADOQueryHelp.FieldCount-1 do
|
||||||
|
begin
|
||||||
|
fields[i].Value:=ADOQueryHelp.Fields[i].Value;
|
||||||
|
end;
|
||||||
|
CDS_Sel.Post;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Bz.Edt_nameChange(Sender: TObject);
|
||||||
|
begin
|
||||||
|
FilterData('',edt_code.Text,Edt_name.Text);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Bz.cxDBTreeList1Click(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if ADOQueryDept.IsEmpty then exit;
|
||||||
|
if trim(ADOQueryDept.FieldByName('Framelevel').AsString)='0' then
|
||||||
|
FilterData('','','')
|
||||||
|
else
|
||||||
|
FilterData(ADOQueryDept.FieldByName('UDept').AsString,'','');
|
||||||
|
end;
|
||||||
|
|
||||||
|
end.
|
23877
基础数据/U_UserHelp_Dx.dfm
Normal file
23877
基础数据/U_UserHelp_Dx.dfm
Normal file
File diff suppressed because it is too large
Load Diff
238
基础数据/U_UserHelp_Dx.pas
Normal file
238
基础数据/U_UserHelp_Dx.pas
Normal file
|
@ -0,0 +1,238 @@
|
||||||
|
unit U_UserHelp_Dx;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, cxFilter,
|
||||||
|
cxData, cxDataStorage, cxEdit, DB, cxDBData, StdCtrls, cxGridLevel,
|
||||||
|
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, cxClasses,
|
||||||
|
cxControls, cxGridCustomView, cxGrid, cxInplaceContainer, cxDBTL,
|
||||||
|
cxTLData, ComCtrls, ToolWin, ADODB, ImgList,StrUtils, ExtCtrls, DBClient;
|
||||||
|
|
||||||
|
type
|
||||||
|
TfrmUserHelp_Dx = class(TForm)
|
||||||
|
ToolBar2: TToolBar;
|
||||||
|
TOk: TToolButton;
|
||||||
|
TBClose: TToolButton;
|
||||||
|
cxGrid1: TcxGrid;
|
||||||
|
tv1: TcxGridDBTableView;
|
||||||
|
tv1Code: TcxGridDBColumn;
|
||||||
|
tv1Name: TcxGridDBColumn;
|
||||||
|
DBGrid1Level1: TcxGridLevel;
|
||||||
|
GroupBox1: TGroupBox;
|
||||||
|
ADOQueryDept: TADOQuery;
|
||||||
|
DataSource1: TDataSource;
|
||||||
|
ADOConnection1: TADOConnection;
|
||||||
|
tv1Column1: TcxGridDBColumn;
|
||||||
|
cxStyleRepository1: TcxStyleRepository;
|
||||||
|
cxStyle1: TcxStyle;
|
||||||
|
cxStyle2: TcxStyle;
|
||||||
|
cxStyle_gridRow: TcxStyle;
|
||||||
|
cxStyle_gridFoot: TcxStyle;
|
||||||
|
cxStyle_gridHead: TcxStyle;
|
||||||
|
cxStyle_gridGroupBox: TcxStyle;
|
||||||
|
cxStyle_yellow: TcxStyle;
|
||||||
|
cxStyle_Red: TcxStyle;
|
||||||
|
ADOQueryHelp: TADOQuery;
|
||||||
|
DataSource2: TDataSource;
|
||||||
|
Label1: TLabel;
|
||||||
|
Edt_name: TEdit;
|
||||||
|
ImageList1: TImageList;
|
||||||
|
cxStyleTree: TcxStyle;
|
||||||
|
Label2: TLabel;
|
||||||
|
Edt_Code: TEdit;
|
||||||
|
ThreeImgList: TImageList;
|
||||||
|
cxGrid2: TcxGrid;
|
||||||
|
Tv2: TcxGridDBTableView;
|
||||||
|
cxGridDBColumn1: TcxGridDBColumn;
|
||||||
|
cxGridDBColumn2: TcxGridDBColumn;
|
||||||
|
cxGridDBColumn3: TcxGridDBColumn;
|
||||||
|
cxGridLevel1: TcxGridLevel;
|
||||||
|
GroupBox2: TGroupBox;
|
||||||
|
CDS_sel: TClientDataSet;
|
||||||
|
DataSourceSel: TDataSource;
|
||||||
|
cxDBTreeList1: TcxDBTreeList;
|
||||||
|
cxDBTreeList1cxDBTreeListColumn2: TcxDBTreeListColumn;
|
||||||
|
Splitter1: TSplitter;
|
||||||
|
procedure FormShow(Sender: TObject);
|
||||||
|
procedure FormCreate(Sender: TObject);
|
||||||
|
procedure TBCloseClick(Sender: TObject);
|
||||||
|
procedure TOkClick(Sender: TObject);
|
||||||
|
procedure tv1DblClick(Sender: TObject);
|
||||||
|
procedure Edt_nameChange(Sender: TObject);
|
||||||
|
procedure cxDBTreeList1Click(Sender: TObject);
|
||||||
|
private
|
||||||
|
procedure InitTree();
|
||||||
|
procedure DoQuery();
|
||||||
|
procedure FilterData(strdepotno,strcode,strname:string);
|
||||||
|
public
|
||||||
|
fFrameNo:string;
|
||||||
|
fFrameName:string;
|
||||||
|
fIsYwy:boolean;
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
frmUserHelp_Dx: TfrmUserHelp_Dx;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
uses
|
||||||
|
U_DataLink,U_Fun;
|
||||||
|
{$R *.dfm}
|
||||||
|
///////////////////////////////////////////////////////////
|
||||||
|
//////功能:过滤数据
|
||||||
|
///////////////////////////////////////////////////////////
|
||||||
|
procedure TfrmUserHelp_Dx.FilterData(strdepotno,strcode,strname:string);
|
||||||
|
var
|
||||||
|
filterStr:string;
|
||||||
|
begin
|
||||||
|
filterStr:='';
|
||||||
|
if trim(strdepotno)<>'' then
|
||||||
|
filterStr:=filterStr+' and dept like '+quotedstr('%'+trim(strdepotno)+'%');
|
||||||
|
if trim(strcode)<>'' then
|
||||||
|
filterStr:=filterStr+' and userID like '+quotedstr('%'+trim(strcode)+'%');
|
||||||
|
if trim(strname)<>'' then
|
||||||
|
filterStr:=filterStr+' and userName like '+quotedstr('%'+trim(strname)+'%');
|
||||||
|
|
||||||
|
try
|
||||||
|
ADOQueryHelp.DisableControls ;
|
||||||
|
if trim(filterStr)='' then
|
||||||
|
begin
|
||||||
|
ADOQueryHelp.Filtered:=false;
|
||||||
|
ADOQueryHelp.EnableControls;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
filterStr:=trim(RightBStr(filterStr,length(filterStr)-5));
|
||||||
|
// showmessage(filterStr);
|
||||||
|
with ADOQueryHelp do
|
||||||
|
begin
|
||||||
|
filtered:=false;
|
||||||
|
filter:=filterStr;
|
||||||
|
filtered:=true;
|
||||||
|
end;
|
||||||
|
finally
|
||||||
|
ADOQueryHelp.EnableControls;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
//////////////////////////////////////////////////////
|
||||||
|
procedure TfrmUserHelp_Dx.InitTree();
|
||||||
|
var
|
||||||
|
strsql,strwhere:string;
|
||||||
|
begin
|
||||||
|
strsql:=' SELECT distinct UDept=''ALL'',UDeptTop='''',UDeptName=''所有部门'',Framelevel=0 '+
|
||||||
|
' union '+
|
||||||
|
' SELECT distinct UDept,UDeptTop=''ALL'',UDept,Framelevel=1 '+
|
||||||
|
' FROM BD_staff A '+
|
||||||
|
' WHERE USERID<>''ADMIN'' and ISNULL(UDept,'''')<>'''' ';
|
||||||
|
|
||||||
|
strwhere:=' where A.Valid=''Y'' ';
|
||||||
|
{ if fIsYwy then
|
||||||
|
strwhere:=strwhere+' and A.YWYFlag=''Y'' ';
|
||||||
|
if trim(fFrameNo)<>'' then
|
||||||
|
strwhere:=strwhere+' and A.dept='+quotedstr(trim(fFrameNo));
|
||||||
|
if trim(fFrameName)<>'' then
|
||||||
|
strwhere:=strwhere+' and B.frameName like '+quotedstr('%'+trim(fFrameName)+'%');
|
||||||
|
strsql:=strsql+ strwhere; }
|
||||||
|
|
||||||
|
with ADOQueryDept do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear ;
|
||||||
|
sql.Add( strsql);
|
||||||
|
Open;
|
||||||
|
end;
|
||||||
|
cxDBTreeList1.FullExpand;
|
||||||
|
|
||||||
|
DoQuery();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Dx.FormShow(Sender: TObject);
|
||||||
|
begin
|
||||||
|
InitTree();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Dx.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
GroupBox2.Align :=alclient;
|
||||||
|
with ADOConnection1 do
|
||||||
|
begin
|
||||||
|
Connected:=false;
|
||||||
|
ConnectionString:=DConString;
|
||||||
|
Connected:=true;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
//////////////////////////////////////////////////
|
||||||
|
//
|
||||||
|
//////////////////////////////////////////////////
|
||||||
|
procedure TfrmUserHelp_Dx.DoQuery();
|
||||||
|
var
|
||||||
|
strsql,strwhere:string;
|
||||||
|
begin
|
||||||
|
strsql:=' select * '+
|
||||||
|
' from BD_staff A '+
|
||||||
|
' where isnull(UserID,'''')<>''ADMIN'' ';
|
||||||
|
strwhere:=' and A.Valid=''Y'' ';
|
||||||
|
if fIsYwy then
|
||||||
|
strwhere:=strwhere+' and A.Isywy=1 ';
|
||||||
|
|
||||||
|
strsql:=strsql+ strwhere +' order by A.userID ';
|
||||||
|
|
||||||
|
with ADOQueryHelp do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear ;
|
||||||
|
sql.Add( strsql);
|
||||||
|
Open;
|
||||||
|
end;
|
||||||
|
|
||||||
|
sCreateCDS20(ADOQueryHelp,cds_sel);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Dx.TBCloseClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Dx.TOkClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if ADOQueryHelp.IsEmpty then
|
||||||
|
begin
|
||||||
|
ModalResult:=-1
|
||||||
|
end
|
||||||
|
else
|
||||||
|
ModalResult:=1;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Dx.tv1DblClick(Sender: TObject);
|
||||||
|
var
|
||||||
|
i:integer;
|
||||||
|
begin
|
||||||
|
if ADOQueryHelp.IsEmpty then exit;
|
||||||
|
|
||||||
|
if CDS_Sel.Locate('userID',trim(adoqueryHelp.fieldbyname('userID').AsString),[]) then exit;
|
||||||
|
with CDS_Sel do
|
||||||
|
begin
|
||||||
|
CDS_Sel.append;
|
||||||
|
for i:=0 to ADOQueryHelp.FieldCount-1 do
|
||||||
|
begin
|
||||||
|
fields[i].Value:=ADOQueryHelp.Fields[i].Value;
|
||||||
|
end;
|
||||||
|
CDS_Sel.Post;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Dx.Edt_nameChange(Sender: TObject);
|
||||||
|
begin
|
||||||
|
FilterData('',edt_code.Text,Edt_name.Text);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserHelp_Dx.cxDBTreeList1Click(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if ADOQueryDept.IsEmpty then exit;
|
||||||
|
if trim(ADOQueryDept.FieldByName('Framelevel').AsString)='0' then
|
||||||
|
FilterData('','','')
|
||||||
|
else
|
||||||
|
FilterData(ADOQueryDept.FieldByName('UDept').AsString,'','');
|
||||||
|
end;
|
||||||
|
|
||||||
|
end.
|
428
基础数据/U_UserList.dfm
Normal file
428
基础数据/U_UserList.dfm
Normal file
|
@ -0,0 +1,428 @@
|
||||||
|
object frmUserList: TfrmUserList
|
||||||
|
Left = 413
|
||||||
|
Top = 338
|
||||||
|
Width = 1053
|
||||||
|
Height = 602
|
||||||
|
Caption = #21592#24037#32500#25252
|
||||||
|
Color = clBtnFace
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
OldCreateOrder = False
|
||||||
|
OnClose = FormClose
|
||||||
|
OnCreate = FormCreate
|
||||||
|
OnDestroy = FormDestroy
|
||||||
|
OnShow = FormShow
|
||||||
|
PixelsPerInch = 96
|
||||||
|
TextHeight = 12
|
||||||
|
object ToolBar1: TToolBar
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
Width = 1037
|
||||||
|
AutoSize = True
|
||||||
|
ButtonHeight = 30
|
||||||
|
ButtonWidth = 89
|
||||||
|
Caption = 'ToolBar1'
|
||||||
|
Color = clSkyBlue
|
||||||
|
Flat = True
|
||||||
|
Images = BaseData10_DataLink.ThreeImgList
|
||||||
|
List = True
|
||||||
|
ParentColor = False
|
||||||
|
ShowCaptions = True
|
||||||
|
TabOrder = 0
|
||||||
|
object ToolButton1: TToolButton
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21047#26032
|
||||||
|
ImageIndex = 2
|
||||||
|
OnClick = ToolButton1Click
|
||||||
|
end
|
||||||
|
object tbyhadd: TToolButton
|
||||||
|
Left = 63
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #26032#22686
|
||||||
|
ImageIndex = 3
|
||||||
|
OnClick = tbyhaddClick
|
||||||
|
end
|
||||||
|
object tbyhup: TToolButton
|
||||||
|
Left = 126
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20462#25913
|
||||||
|
ImageIndex = 54
|
||||||
|
OnClick = tbyhupClick
|
||||||
|
end
|
||||||
|
object tbyhdelete: TToolButton
|
||||||
|
Left = 189
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21024#38500
|
||||||
|
ImageIndex = 17
|
||||||
|
OnClick = tbyhdeleteClick
|
||||||
|
end
|
||||||
|
object tbqx: TToolButton
|
||||||
|
Left = 252
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #23548#20986'Excel'
|
||||||
|
ImageIndex = 75
|
||||||
|
OnClick = tbqxClick
|
||||||
|
end
|
||||||
|
object ToolButton2: TToolButton
|
||||||
|
Left = 345
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #25171#21360
|
||||||
|
ImageIndex = 12
|
||||||
|
OnClick = ToolButton2Click
|
||||||
|
end
|
||||||
|
object tbclose: TToolButton
|
||||||
|
Left = 408
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20851#38381
|
||||||
|
ImageIndex = 55
|
||||||
|
OnClick = tbcloseClick
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid1: TcxGrid
|
||||||
|
Left = 0
|
||||||
|
Top = 97
|
||||||
|
Width = 1037
|
||||||
|
Height = 385
|
||||||
|
Align = alTop
|
||||||
|
TabOrder = 1
|
||||||
|
object tv1: TcxGridDBTableView
|
||||||
|
Navigator.Buttons.CustomButtons = <>
|
||||||
|
OnCellDblClick = tv1CellDblClick
|
||||||
|
DataController.DataSource = DataSource2
|
||||||
|
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||||
|
DataController.Summary.FooterSummaryItems = <
|
||||||
|
item
|
||||||
|
Format = #20849' 0 '#26465
|
||||||
|
Kind = skCount
|
||||||
|
Column = tv1Name1
|
||||||
|
end>
|
||||||
|
DataController.Summary.SummaryGroups = <>
|
||||||
|
OptionsBehavior.FocusCellOnTab = True
|
||||||
|
OptionsCustomize.ColumnFiltering = False
|
||||||
|
OptionsData.Editing = False
|
||||||
|
OptionsSelection.CellSelect = False
|
||||||
|
OptionsSelection.HideSelection = True
|
||||||
|
OptionsView.Footer = True
|
||||||
|
OptionsView.GroupByBox = False
|
||||||
|
OptionsView.Indicator = True
|
||||||
|
Styles.ContentOdd = BaseData10_DataLink.cxStyle_gridRow
|
||||||
|
Styles.Footer = BaseData10_DataLink.cxStyle_gridFoot
|
||||||
|
Styles.GroupByBox = BaseData10_DataLink.cxStyle_gridGroupBox
|
||||||
|
Styles.Header = BaseData10_DataLink.cxStyle_gridHead
|
||||||
|
object tv1Code1: TcxGridDBColumn
|
||||||
|
Caption = #32534#21495
|
||||||
|
DataBinding.FieldName = 'userid'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.Alignment.Horz = taLeftJustify
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 75
|
||||||
|
end
|
||||||
|
object tv1Name1: TcxGridDBColumn
|
||||||
|
Caption = #21517#31216
|
||||||
|
DataBinding.FieldName = 'userName'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.Alignment.Horz = taLeftJustify
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 84
|
||||||
|
end
|
||||||
|
object tv1edu: TcxGridDBColumn
|
||||||
|
Caption = #23398#21382
|
||||||
|
DataBinding.FieldName = 'edu'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object tv1Sex1: TcxGridDBColumn
|
||||||
|
Caption = #24615#21035
|
||||||
|
DataBinding.FieldName = 'Sex'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.Alignment.Horz = taLeftJustify
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
end
|
||||||
|
object tv1Phone1: TcxGridDBColumn
|
||||||
|
Caption = #32852#31995#30005#35805
|
||||||
|
DataBinding.FieldName = 'Phone'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.Alignment.Horz = taLeftJustify
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 68
|
||||||
|
end
|
||||||
|
object tv1IdNo1: TcxGridDBColumn
|
||||||
|
Caption = #36523#20221#35777#21495
|
||||||
|
DataBinding.FieldName = 'IdNo'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 81
|
||||||
|
end
|
||||||
|
object tv1Dept1: TcxGridDBColumn
|
||||||
|
Caption = #25152#23646#37096#38376
|
||||||
|
DataBinding.FieldName = 'UDept'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.Alignment.Horz = taLeftJustify
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 71
|
||||||
|
end
|
||||||
|
object tv1position: TcxGridDBColumn
|
||||||
|
Caption = #24037#31181
|
||||||
|
DataBinding.FieldName = 'position'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object tv1InTime: TcxGridDBColumn
|
||||||
|
Caption = #24405#29992#26085#26399
|
||||||
|
DataBinding.FieldName = 'InTime'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 71
|
||||||
|
end
|
||||||
|
object tv1fstr1: TcxGridDBColumn
|
||||||
|
Caption = #30331#35760#21495
|
||||||
|
DataBinding.FieldName = 'fstr1'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object tv1Address: TcxGridDBColumn
|
||||||
|
Caption = #23478#24237#22320#22336
|
||||||
|
DataBinding.FieldName = 'Address'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 120
|
||||||
|
end
|
||||||
|
object tv1Valid1: TcxGridDBColumn
|
||||||
|
Caption = #26159#21542#22312#32844
|
||||||
|
DataBinding.FieldName = 'ValidName'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.Alignment.Horz = taLeftJustify
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
end
|
||||||
|
object tv1Column1: TcxGridDBColumn
|
||||||
|
Caption = #26159#21542#30331#35760#20135#37327
|
||||||
|
DataBinding.FieldName = 'fstr2'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 86
|
||||||
|
end
|
||||||
|
object tv1note: TcxGridDBColumn
|
||||||
|
Caption = #22791#27880
|
||||||
|
DataBinding.FieldName = 'note'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 120
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid1Level1: TcxGridLevel
|
||||||
|
GridView = tv1
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object Panel1: TPanel
|
||||||
|
Left = 0
|
||||||
|
Top = 32
|
||||||
|
Width = 1037
|
||||||
|
Height = 65
|
||||||
|
Align = alTop
|
||||||
|
BevelInner = bvRaised
|
||||||
|
BevelOuter = bvLowered
|
||||||
|
Color = clSkyBlue
|
||||||
|
TabOrder = 2
|
||||||
|
object Label1: TLabel
|
||||||
|
Left = 36
|
||||||
|
Top = 16
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #32534' '#21495
|
||||||
|
end
|
||||||
|
object Label2: TLabel
|
||||||
|
Left = 36
|
||||||
|
Top = 40
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #21517' '#31216
|
||||||
|
end
|
||||||
|
object Label7: TLabel
|
||||||
|
Left = 272
|
||||||
|
Top = 16
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #24615' '#21035
|
||||||
|
end
|
||||||
|
object Label8: TLabel
|
||||||
|
Left = 272
|
||||||
|
Top = 40
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #23398' '#21382
|
||||||
|
end
|
||||||
|
object Label3: TLabel
|
||||||
|
Left = 508
|
||||||
|
Top = 16
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #26159#21542#22312#32844
|
||||||
|
end
|
||||||
|
object Label4: TLabel
|
||||||
|
Left = 508
|
||||||
|
Top = 40
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #24037' '#31181
|
||||||
|
end
|
||||||
|
object Label5: TLabel
|
||||||
|
Left = 732
|
||||||
|
Top = 16
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #30331' '#35760' '#21495
|
||||||
|
end
|
||||||
|
object userID: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 88
|
||||||
|
Top = 12
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 0
|
||||||
|
OnChange = userIDChange
|
||||||
|
end
|
||||||
|
object USERName: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 88
|
||||||
|
Top = 36
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 1
|
||||||
|
OnChange = userIDChange
|
||||||
|
end
|
||||||
|
object sex: TComboBox
|
||||||
|
Tag = 2
|
||||||
|
Left = 328
|
||||||
|
Top = 12
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
ItemIndex = 0
|
||||||
|
TabOrder = 2
|
||||||
|
OnChange = userIDChange
|
||||||
|
Items.Strings = (
|
||||||
|
''
|
||||||
|
#30007
|
||||||
|
#22899)
|
||||||
|
end
|
||||||
|
object edu: TComboBox
|
||||||
|
Tag = 2
|
||||||
|
Left = 328
|
||||||
|
Top = 36
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
ItemIndex = 0
|
||||||
|
TabOrder = 3
|
||||||
|
OnChange = userIDChange
|
||||||
|
Items.Strings = (
|
||||||
|
''
|
||||||
|
#23567#23398
|
||||||
|
#20013#23398
|
||||||
|
#39640#20013
|
||||||
|
#20013#19987
|
||||||
|
#22823#19987
|
||||||
|
#26412#31185
|
||||||
|
#30805#22763
|
||||||
|
#21338#22763)
|
||||||
|
end
|
||||||
|
object validName: TComboBox
|
||||||
|
Tag = 2
|
||||||
|
Left = 564
|
||||||
|
Top = 12
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
ItemIndex = 0
|
||||||
|
TabOrder = 4
|
||||||
|
OnChange = userIDChange
|
||||||
|
Items.Strings = (
|
||||||
|
''
|
||||||
|
#26159
|
||||||
|
#21542)
|
||||||
|
end
|
||||||
|
object position: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 564
|
||||||
|
Top = 36
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 5
|
||||||
|
OnChange = userIDChange
|
||||||
|
end
|
||||||
|
object fstr1: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 788
|
||||||
|
Top = 12
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 6
|
||||||
|
OnChange = userIDChange
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object ADO_user: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 104
|
||||||
|
Top = 100
|
||||||
|
end
|
||||||
|
object ADO_Cmd: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 332
|
||||||
|
Top = 104
|
||||||
|
end
|
||||||
|
object DataSource2: TDataSource
|
||||||
|
DataSet = CDS_User
|
||||||
|
Left = 148
|
||||||
|
Top = 144
|
||||||
|
end
|
||||||
|
object CDS_User: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 160
|
||||||
|
Top = 100
|
||||||
|
end
|
||||||
|
object RMDBMain: TRMDBDataSet
|
||||||
|
Visible = True
|
||||||
|
DataSet = CDS_User
|
||||||
|
Left = 392
|
||||||
|
Top = 200
|
||||||
|
end
|
||||||
|
object RM1: TRMGridReport
|
||||||
|
ThreadPrepareReport = True
|
||||||
|
InitialZoom = pzDefault
|
||||||
|
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbExport, pbNavigator]
|
||||||
|
DefaultCollate = False
|
||||||
|
SaveReportOptions.RegistryPath = 'Software\ReportMachine\ReportSettings\'
|
||||||
|
PreviewOptions.RulerUnit = rmutScreenPixels
|
||||||
|
PreviewOptions.RulerVisible = False
|
||||||
|
PreviewOptions.DrawBorder = False
|
||||||
|
PreviewOptions.BorderPen.Color = clGray
|
||||||
|
PreviewOptions.BorderPen.Style = psDash
|
||||||
|
Dataset = RMDBMain
|
||||||
|
CompressLevel = rmzcFastest
|
||||||
|
CompressThread = False
|
||||||
|
LaterBuildEvents = True
|
||||||
|
OnlyOwnerDataSet = False
|
||||||
|
Left = 336
|
||||||
|
Top = 200
|
||||||
|
ReportData = {}
|
||||||
|
end
|
||||||
|
end
|
273
基础数据/U_UserList.pas
Normal file
273
基础数据/U_UserList.pas
Normal file
|
@ -0,0 +1,273 @@
|
||||||
|
unit U_UserList;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, ComCtrls, ToolWin, cxStyles, cxCustomData, cxGraphics, cxFilter,
|
||||||
|
cxData, cxDataStorage, cxEdit, DB, cxDBData, cxTextEdit, ExtCtrls,
|
||||||
|
cxGridLevel, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||||
|
cxClasses, cxControls, cxGridCustomView, cxGrid, ADODB, DBClient,
|
||||||
|
StdCtrls, RM_Common, RM_Class, RM_GridReport, RM_System, RM_Dataset,
|
||||||
|
cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxSkinsCore,
|
||||||
|
dxSkinBlack, dxSkinBlue, dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee,
|
||||||
|
dxSkinDarkRoom, dxSkinDarkSide, dxSkinDevExpressDarkStyle,
|
||||||
|
dxSkinDevExpressStyle, dxSkinFoggy, dxSkinGlassOceans,
|
||||||
|
dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian, dxSkinLiquidSky,
|
||||||
|
dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis,
|
||||||
|
dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black,
|
||||||
|
dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
|
||||||
|
dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue,
|
||||||
|
dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
|
||||||
|
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin,
|
||||||
|
dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
|
||||||
|
dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
|
||||||
|
dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine,
|
||||||
|
dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue, dxSkinscxPCPainter;
|
||||||
|
|
||||||
|
type
|
||||||
|
TfrmUserList = class(TForm)
|
||||||
|
ToolBar1: TToolBar;
|
||||||
|
tbyhadd: TToolButton;
|
||||||
|
tbyhup: TToolButton;
|
||||||
|
tbyhdelete: TToolButton;
|
||||||
|
tbqx: TToolButton;
|
||||||
|
tbclose: TToolButton;
|
||||||
|
ToolButton1: TToolButton;
|
||||||
|
cxGrid1: TcxGrid;
|
||||||
|
tv1: TcxGridDBTableView;
|
||||||
|
tv1Code1: TcxGridDBColumn;
|
||||||
|
tv1Name1: TcxGridDBColumn;
|
||||||
|
tv1Sex1: TcxGridDBColumn;
|
||||||
|
tv1Phone1: TcxGridDBColumn;
|
||||||
|
tv1IdNo1: TcxGridDBColumn;
|
||||||
|
tv1Dept1: TcxGridDBColumn;
|
||||||
|
tv1InTime: TcxGridDBColumn;
|
||||||
|
tv1Address: TcxGridDBColumn;
|
||||||
|
tv1Valid1: TcxGridDBColumn;
|
||||||
|
cxGrid1Level1: TcxGridLevel;
|
||||||
|
Panel1: TPanel;
|
||||||
|
tv1edu: TcxGridDBColumn;
|
||||||
|
tv1position: TcxGridDBColumn;
|
||||||
|
tv1fstr1: TcxGridDBColumn;
|
||||||
|
ADO_user: TADOQuery;
|
||||||
|
ADO_Cmd: TADOQuery;
|
||||||
|
DataSource2: TDataSource;
|
||||||
|
CDS_User: TClientDataSet;
|
||||||
|
Label1: TLabel;
|
||||||
|
userID: TEdit;
|
||||||
|
Label2: TLabel;
|
||||||
|
USERName: TEdit;
|
||||||
|
Label7: TLabel;
|
||||||
|
sex: TComboBox;
|
||||||
|
edu: TComboBox;
|
||||||
|
Label8: TLabel;
|
||||||
|
tv1note: TcxGridDBColumn;
|
||||||
|
Label3: TLabel;
|
||||||
|
validName: TComboBox;
|
||||||
|
Label4: TLabel;
|
||||||
|
position: TEdit;
|
||||||
|
Label5: TLabel;
|
||||||
|
fstr1: TEdit;
|
||||||
|
tv1Column1: TcxGridDBColumn;
|
||||||
|
ToolButton2: TToolButton;
|
||||||
|
RMDBMain: TRMDBDataSet;
|
||||||
|
RM1: TRMGridReport;
|
||||||
|
procedure FormDestroy(Sender: TObject);
|
||||||
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
|
procedure tbyhaddClick(Sender: TObject);
|
||||||
|
procedure tbcloseClick(Sender: TObject);
|
||||||
|
procedure FormShow(Sender: TObject);
|
||||||
|
procedure FormCreate(Sender: TObject);
|
||||||
|
procedure ToolButton1Click(Sender: TObject);
|
||||||
|
procedure tbyhupClick(Sender: TObject);
|
||||||
|
procedure tbyhdeleteClick(Sender: TObject);
|
||||||
|
procedure tbqxClick(Sender: TObject);
|
||||||
|
procedure userIDChange(Sender: TObject);
|
||||||
|
procedure tv1CellDblClick(Sender: TcxCustomGridTableView;
|
||||||
|
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||||
|
AShift: TShiftState; var AHandled: Boolean);
|
||||||
|
procedure ToolButton2Click(Sender: TObject);
|
||||||
|
|
||||||
|
private
|
||||||
|
Procedure InitUser();
|
||||||
|
{ Private declarations }
|
||||||
|
public
|
||||||
|
{ Public declarations }
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
frmUserList: TfrmUserList;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
uses U_DataLink,U_Fun10,U_User10,U_PublicFunction;
|
||||||
|
{$R *.dfm}
|
||||||
|
Procedure TfrmUserList.InitUser();
|
||||||
|
begin
|
||||||
|
with ADO_user do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' select A.*,case when valid=''Y'' then ''是'' else ''否'' end as validName ');
|
||||||
|
sql.Add(' from BD_Staff A ');
|
||||||
|
sql.Add(' where userId<>''ADMIN'' ');
|
||||||
|
open;
|
||||||
|
end;
|
||||||
|
CreateAdoToCds(ADO_user,CDS_User);
|
||||||
|
InitAdoToCds(ADO_user,CDS_User);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.FormDestroy(Sender: TObject);
|
||||||
|
begin
|
||||||
|
frmUserList:=nil;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.FormClose(Sender: TObject;
|
||||||
|
var Action: TCloseAction);
|
||||||
|
begin
|
||||||
|
writeCxGrid(self.Caption,Tv1,'基础数据');
|
||||||
|
Action:=cafree;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.tbyhaddClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
frmUser10:=TfrmUser10.Create(self);
|
||||||
|
with frmUser10 do
|
||||||
|
begin
|
||||||
|
formId:=0;
|
||||||
|
fuserID:='';
|
||||||
|
if showmodal=1 then
|
||||||
|
begin
|
||||||
|
InitUser();
|
||||||
|
CDS_User.Locate('UserID',trim(fuserID),[]);
|
||||||
|
end;
|
||||||
|
free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.tbcloseClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.FormShow(Sender: TObject);
|
||||||
|
begin
|
||||||
|
ReadCxGrid(self.Caption,Tv1,'基础数据');
|
||||||
|
InitUser();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
cxGrid1.Align:=alclient;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.ToolButton1Click(Sender: TObject);
|
||||||
|
begin
|
||||||
|
InitUser();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.tbyhupClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if CDS_User.IsEmpty then exit;
|
||||||
|
if trim(CDS_User.FieldByName('userID').AsString)='ADMIN' then exit;
|
||||||
|
frmUser10:=TfrmUser10.create(self);
|
||||||
|
with frmUser10 do
|
||||||
|
begin
|
||||||
|
formId:=1;
|
||||||
|
fuserID:=trim(CDS_User.fieldByName('UserID').asstring);
|
||||||
|
if showmodal=1 then
|
||||||
|
begin
|
||||||
|
InitUser();
|
||||||
|
CDS_User.Locate('UserID',trim(fuserID),[]);
|
||||||
|
end;
|
||||||
|
free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.tbyhdeleteClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if CDS_User.IsEmpty then exit;
|
||||||
|
if trim(CDS_User.FieldByName('userID').AsString)='ADMIN' then exit;
|
||||||
|
if application.MessageBox('请确定要删除此用户吗?','警告信息!',1)=2 then exit;
|
||||||
|
try
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' delete BD_Staff ');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(CDS_User.fieldbyname('USerID').AsString)));
|
||||||
|
sql.Add(' delete TP_File ');
|
||||||
|
sql.Add(' where WBID='+quotedstr(trim(CDS_User.fieldbyname('USerID').AsString)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
InitUser();
|
||||||
|
except
|
||||||
|
application.MessageBox('删除失败!','错误信息',MB_ICONERROR);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.tbqxClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if CDS_User.IsEmpty then exit;
|
||||||
|
TcxGridToExcel(self.Caption,cxgrid1);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.userIDChange(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if not CDS_User.Active then exit;
|
||||||
|
SDofilter(ADO_user,SGetFilters(Panel1,1,2));
|
||||||
|
CreateAdoToCds(ADO_user,CDS_User);
|
||||||
|
InitAdoToCds(ADO_user,CDS_User);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.tv1CellDblClick(Sender: TcxCustomGridTableView;
|
||||||
|
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||||
|
AShift: TShiftState; var AHandled: Boolean);
|
||||||
|
begin
|
||||||
|
tbyhup.Click;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUserList.ToolButton2Click(Sender: TObject);
|
||||||
|
var
|
||||||
|
fPrintFile:string;
|
||||||
|
Porderno,PRTCodeName,funit:string;
|
||||||
|
i,j,k:Integer;
|
||||||
|
Txt,fImagePath:string;
|
||||||
|
Moudle: THandle;
|
||||||
|
Makebar:TMakebar;
|
||||||
|
Mixtext:TMixtext;
|
||||||
|
begin
|
||||||
|
IF CDS_User.IsEmpty then exit;
|
||||||
|
|
||||||
|
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\员工信息.rmf' ;
|
||||||
|
|
||||||
|
try
|
||||||
|
Moudle:=LoadLibrary('MakeQRBarcode.dll');
|
||||||
|
@Makebar:=GetProcAddress(Moudle,'Make');
|
||||||
|
@Mixtext:=GetProcAddress(Moudle,'MixText');
|
||||||
|
Txt:=Trim(CDS_User.fieldbyname('userID').AsString);
|
||||||
|
fImagePath:=ExtractFilePath(Application.ExeName)+'image\temp.bmp';
|
||||||
|
if not DirectoryExists(pchar(ExtractFilePath(Application.ExeName)+'image')) then
|
||||||
|
CreateDirectory(pchar(ExtractFilePath(Application.ExeName)+'image'),nil);
|
||||||
|
if FileExists(fImagePath) then DeleteFile(fImagePath);
|
||||||
|
Makebar(pchar(Txt),Length(Txt),3,3,0,PChar(fImagePath),3);
|
||||||
|
except
|
||||||
|
application.MessageBox('条形码生成失败!','提示信息',MB_ICONERROR);
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
|
||||||
|
if FileExists(fPrintFile) then
|
||||||
|
begin
|
||||||
|
RMVariables['QRBARCODE']:=fImagePath;
|
||||||
|
RM1.LoadFromFile(fPrintFile);
|
||||||
|
RM1.ShowReport;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
Application.MessageBox(PChar('没有找到'+trim(fPrintFile)),'提示',0);
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
|
||||||
|
end;
|
||||||
|
|
||||||
|
end.
|
332
基础数据/U_User_bz_List.dfm
Normal file
332
基础数据/U_User_bz_List.dfm
Normal file
|
@ -0,0 +1,332 @@
|
||||||
|
object frmUser_bz_List: TfrmUser_bz_List
|
||||||
|
Left = 138
|
||||||
|
Top = 111
|
||||||
|
Width = 1076
|
||||||
|
Height = 602
|
||||||
|
Caption = #21592#24037#32500#25252
|
||||||
|
Color = clBtnFace
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
OldCreateOrder = False
|
||||||
|
OnClose = FormClose
|
||||||
|
OnCreate = FormCreate
|
||||||
|
OnDestroy = FormDestroy
|
||||||
|
OnShow = FormShow
|
||||||
|
PixelsPerInch = 96
|
||||||
|
TextHeight = 12
|
||||||
|
object ToolBar1: TToolBar
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
Width = 1060
|
||||||
|
AutoSize = True
|
||||||
|
ButtonHeight = 30
|
||||||
|
ButtonWidth = 89
|
||||||
|
Caption = 'ToolBar1'
|
||||||
|
Color = clSkyBlue
|
||||||
|
Flat = True
|
||||||
|
Images = BaseData10_DataLink.ThreeImgList
|
||||||
|
List = True
|
||||||
|
ParentColor = False
|
||||||
|
ShowCaptions = True
|
||||||
|
TabOrder = 0
|
||||||
|
object ToolButton1: TToolButton
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21047#26032
|
||||||
|
ImageIndex = 2
|
||||||
|
OnClick = ToolButton1Click
|
||||||
|
end
|
||||||
|
object tbyhadd: TToolButton
|
||||||
|
Left = 63
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #22686#21152
|
||||||
|
ImageIndex = 3
|
||||||
|
OnClick = tbyhaddClick
|
||||||
|
end
|
||||||
|
object tbyhdelete: TToolButton
|
||||||
|
Left = 126
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21024#38500
|
||||||
|
ImageIndex = 17
|
||||||
|
OnClick = tbyhdeleteClick
|
||||||
|
end
|
||||||
|
object tbyhup: TToolButton
|
||||||
|
Left = 189
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20445#23384
|
||||||
|
ImageIndex = 54
|
||||||
|
OnClick = tbyhupClick
|
||||||
|
end
|
||||||
|
object ToolButton6: TToolButton
|
||||||
|
Left = 252
|
||||||
|
Top = 0
|
||||||
|
Width = 8
|
||||||
|
Caption = 'ToolButton6'
|
||||||
|
ImageIndex = 2
|
||||||
|
Style = tbsSeparator
|
||||||
|
end
|
||||||
|
object tbqx: TToolButton
|
||||||
|
Left = 260
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #23548#20986'Excel'
|
||||||
|
ImageIndex = 75
|
||||||
|
OnClick = tbqxClick
|
||||||
|
end
|
||||||
|
object ToolButton7: TToolButton
|
||||||
|
Left = 353
|
||||||
|
Top = 0
|
||||||
|
Width = 8
|
||||||
|
Caption = 'ToolButton7'
|
||||||
|
ImageIndex = 2
|
||||||
|
Style = tbsSeparator
|
||||||
|
end
|
||||||
|
object tbclose: TToolButton
|
||||||
|
Left = 361
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20851#38381
|
||||||
|
ImageIndex = 55
|
||||||
|
OnClick = tbcloseClick
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid1: TcxGrid
|
||||||
|
Left = 0
|
||||||
|
Top = 77
|
||||||
|
Width = 1060
|
||||||
|
Height = 424
|
||||||
|
Align = alTop
|
||||||
|
TabOrder = 1
|
||||||
|
object tv1: TcxGridDBTableView
|
||||||
|
NavigatorButtons.ConfirmDelete = False
|
||||||
|
DataController.DataSource = DataSource2
|
||||||
|
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||||
|
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||||
|
DataController.Summary.FooterSummaryItems = <
|
||||||
|
item
|
||||||
|
Format = #20849' 0 '#26465
|
||||||
|
Kind = skCount
|
||||||
|
Column = tv1Name1
|
||||||
|
end>
|
||||||
|
DataController.Summary.SummaryGroups = <>
|
||||||
|
OptionsBehavior.FocusCellOnTab = True
|
||||||
|
OptionsCustomize.ColumnFiltering = False
|
||||||
|
OptionsView.Footer = True
|
||||||
|
OptionsView.GroupByBox = False
|
||||||
|
OptionsView.Indicator = True
|
||||||
|
Styles.ContentOdd = BaseData10_DataLink.cxStyle_gridRow
|
||||||
|
Styles.Footer = BaseData10_DataLink.cxStyle_gridFoot
|
||||||
|
Styles.GroupByBox = BaseData10_DataLink.cxStyle_gridGroupBox
|
||||||
|
Styles.Header = BaseData10_DataLink.cxStyle_gridHead
|
||||||
|
object tv1Code1: TcxGridDBColumn
|
||||||
|
Caption = #32534#21495
|
||||||
|
DataBinding.FieldName = 'userid'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.Alignment.Horz = taLeftJustify
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 150
|
||||||
|
end
|
||||||
|
object tv1Name1: TcxGridDBColumn
|
||||||
|
Caption = #21517#31216
|
||||||
|
DataBinding.FieldName = 'userName'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.Alignment.Horz = taLeftJustify
|
||||||
|
Properties.ReadOnly = True
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 138
|
||||||
|
end
|
||||||
|
object tv1banzu: TcxGridDBColumn
|
||||||
|
Caption = #29677#32452
|
||||||
|
DataBinding.FieldName = 'banzu'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 140
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid1Level1: TcxGridLevel
|
||||||
|
GridView = tv1
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object Panel1: TPanel
|
||||||
|
Left = 0
|
||||||
|
Top = 32
|
||||||
|
Width = 1060
|
||||||
|
Height = 45
|
||||||
|
Align = alTop
|
||||||
|
BevelInner = bvRaised
|
||||||
|
BevelOuter = bvLowered
|
||||||
|
Color = clSkyBlue
|
||||||
|
TabOrder = 2
|
||||||
|
object Label1: TLabel
|
||||||
|
Left = 36
|
||||||
|
Top = 16
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #32534' '#21495
|
||||||
|
end
|
||||||
|
object Label2: TLabel
|
||||||
|
Left = 284
|
||||||
|
Top = 16
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #21517' '#31216
|
||||||
|
end
|
||||||
|
object Label7: TLabel
|
||||||
|
Left = 516
|
||||||
|
Top = 16
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #29677' '#32452
|
||||||
|
end
|
||||||
|
object Label8: TLabel
|
||||||
|
Left = 268
|
||||||
|
Top = 96
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #23398' '#21382
|
||||||
|
end
|
||||||
|
object Label3: TLabel
|
||||||
|
Left = 504
|
||||||
|
Top = 72
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #26159#21542#22312#32844
|
||||||
|
end
|
||||||
|
object Label4: TLabel
|
||||||
|
Left = 504
|
||||||
|
Top = 96
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #24037' '#31181
|
||||||
|
end
|
||||||
|
object Label5: TLabel
|
||||||
|
Left = 728
|
||||||
|
Top = 72
|
||||||
|
Width = 48
|
||||||
|
Height = 12
|
||||||
|
Caption = #30331' '#26426' '#21495
|
||||||
|
end
|
||||||
|
object userID: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 88
|
||||||
|
Top = 12
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 0
|
||||||
|
OnChange = userIDChange
|
||||||
|
end
|
||||||
|
object USERName: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 332
|
||||||
|
Top = 12
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 1
|
||||||
|
OnChange = userIDChange
|
||||||
|
end
|
||||||
|
object banzu: TComboBox
|
||||||
|
Tag = 2
|
||||||
|
Left = 572
|
||||||
|
Top = 12
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
TabOrder = 2
|
||||||
|
OnChange = userIDChange
|
||||||
|
Items.Strings = (
|
||||||
|
''
|
||||||
|
#30002
|
||||||
|
#20057
|
||||||
|
#19993)
|
||||||
|
end
|
||||||
|
object edu: TComboBox
|
||||||
|
Tag = 2
|
||||||
|
Left = 324
|
||||||
|
Top = 92
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
ItemIndex = 0
|
||||||
|
TabOrder = 3
|
||||||
|
OnChange = userIDChange
|
||||||
|
Items.Strings = (
|
||||||
|
''
|
||||||
|
#23567#23398
|
||||||
|
#20013#23398
|
||||||
|
#39640#20013
|
||||||
|
#20013#19987
|
||||||
|
#22823#19987
|
||||||
|
#26412#31185
|
||||||
|
#30805#22763
|
||||||
|
#21338#22763)
|
||||||
|
end
|
||||||
|
object validName: TComboBox
|
||||||
|
Tag = 2
|
||||||
|
Left = 560
|
||||||
|
Top = 68
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
Style = csDropDownList
|
||||||
|
ItemHeight = 12
|
||||||
|
ItemIndex = 0
|
||||||
|
TabOrder = 4
|
||||||
|
OnChange = userIDChange
|
||||||
|
Items.Strings = (
|
||||||
|
''
|
||||||
|
#26159
|
||||||
|
#21542)
|
||||||
|
end
|
||||||
|
object position: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 560
|
||||||
|
Top = 92
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 5
|
||||||
|
OnChange = userIDChange
|
||||||
|
end
|
||||||
|
object fstr1: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 784
|
||||||
|
Top = 68
|
||||||
|
Width = 100
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 6
|
||||||
|
OnChange = userIDChange
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object ADO_user: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 104
|
||||||
|
Top = 160
|
||||||
|
end
|
||||||
|
object ADO_Cmd: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 340
|
||||||
|
Top = 160
|
||||||
|
end
|
||||||
|
object DataSource2: TDataSource
|
||||||
|
DataSet = CDS_User
|
||||||
|
Left = 148
|
||||||
|
Top = 168
|
||||||
|
end
|
||||||
|
object CDS_User: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 196
|
||||||
|
Top = 176
|
||||||
|
end
|
||||||
|
end
|
210
基础数据/U_User_bz_List.pas
Normal file
210
基础数据/U_User_bz_List.pas
Normal file
|
@ -0,0 +1,210 @@
|
||||||
|
unit U_User_bz_List;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, ComCtrls, ToolWin, cxStyles, cxCustomData, cxGraphics, cxFilter,
|
||||||
|
cxData, cxDataStorage, cxEdit, DB, cxDBData, cxTextEdit, ExtCtrls,
|
||||||
|
cxGridLevel, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||||
|
cxClasses, cxControls, cxGridCustomView, cxGrid, ADODB, DBClient,
|
||||||
|
StdCtrls;
|
||||||
|
|
||||||
|
type
|
||||||
|
TfrmUser_bz_List = class(TForm)
|
||||||
|
ToolBar1: TToolBar;
|
||||||
|
tbyhadd: TToolButton;
|
||||||
|
tbyhup: TToolButton;
|
||||||
|
tbyhdelete: TToolButton;
|
||||||
|
ToolButton6: TToolButton;
|
||||||
|
tbqx: TToolButton;
|
||||||
|
ToolButton7: TToolButton;
|
||||||
|
tbclose: TToolButton;
|
||||||
|
ToolButton1: TToolButton;
|
||||||
|
cxGrid1: TcxGrid;
|
||||||
|
tv1: TcxGridDBTableView;
|
||||||
|
tv1Code1: TcxGridDBColumn;
|
||||||
|
tv1Name1: TcxGridDBColumn;
|
||||||
|
cxGrid1Level1: TcxGridLevel;
|
||||||
|
Panel1: TPanel;
|
||||||
|
ADO_user: TADOQuery;
|
||||||
|
ADO_Cmd: TADOQuery;
|
||||||
|
DataSource2: TDataSource;
|
||||||
|
CDS_User: TClientDataSet;
|
||||||
|
Label1: TLabel;
|
||||||
|
userID: TEdit;
|
||||||
|
Label2: TLabel;
|
||||||
|
USERName: TEdit;
|
||||||
|
Label7: TLabel;
|
||||||
|
banzu: TComboBox;
|
||||||
|
edu: TComboBox;
|
||||||
|
Label8: TLabel;
|
||||||
|
Label3: TLabel;
|
||||||
|
validName: TComboBox;
|
||||||
|
Label4: TLabel;
|
||||||
|
position: TEdit;
|
||||||
|
Label5: TLabel;
|
||||||
|
fstr1: TEdit;
|
||||||
|
tv1banzu: TcxGridDBColumn;
|
||||||
|
procedure FormDestroy(Sender: TObject);
|
||||||
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
|
procedure tbyhaddClick(Sender: TObject);
|
||||||
|
procedure tbcloseClick(Sender: TObject);
|
||||||
|
procedure FormShow(Sender: TObject);
|
||||||
|
procedure FormCreate(Sender: TObject);
|
||||||
|
procedure ToolButton1Click(Sender: TObject);
|
||||||
|
procedure tbyhupClick(Sender: TObject);
|
||||||
|
procedure tbyhdeleteClick(Sender: TObject);
|
||||||
|
procedure tbqxClick(Sender: TObject);
|
||||||
|
procedure userIDChange(Sender: TObject);
|
||||||
|
|
||||||
|
private
|
||||||
|
Procedure InitUser();
|
||||||
|
{ Private declarations }
|
||||||
|
public
|
||||||
|
{ Public declarations }
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
frmUser_bz_List: TfrmUser_bz_List;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
uses U_DataLink, U_Fun10,U_PublicFunction, U_UserHelp_Bz, U_User10;
|
||||||
|
{$R *.dfm}
|
||||||
|
Procedure TfrmUser_bz_List.InitUser();
|
||||||
|
begin
|
||||||
|
with ADO_user do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' select A.*,B.userName ');
|
||||||
|
sql.Add(' from BD_Staff_banzu A ');
|
||||||
|
sql.Add(' inner join BD_Staff B on B.userID=A.userID ');
|
||||||
|
sql.Add(' where B.userId<>''ADMIN'' ');
|
||||||
|
open;
|
||||||
|
end;
|
||||||
|
CreateAdoToCds(ADO_user,CDS_User);
|
||||||
|
InitAdoToCds(ADO_user,CDS_User);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.FormDestroy(Sender: TObject);
|
||||||
|
begin
|
||||||
|
frmUser_bz_List:=nil;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.FormClose(Sender: TObject;
|
||||||
|
var Action: TCloseAction);
|
||||||
|
begin
|
||||||
|
writeCxGrid(self.Caption,Tv1,'基础数据');
|
||||||
|
Action:=cafree;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.tbyhaddClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
frmUserHelp_Bz:=TfrmUserHelp_Bz.Create(self);
|
||||||
|
with frmUserHelp_Bz do
|
||||||
|
begin
|
||||||
|
// formId:=0;
|
||||||
|
// fuserID:='';
|
||||||
|
if showmodal=1 then
|
||||||
|
begin
|
||||||
|
InitUser();
|
||||||
|
// CDS_User.Locate('UserID',trim(fuserID),[]);
|
||||||
|
end;
|
||||||
|
free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.tbcloseClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.FormShow(Sender: TObject);
|
||||||
|
begin
|
||||||
|
ReadCxGrid(self.Caption,Tv1,'基础数据');
|
||||||
|
InitUser();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
cxGrid1.Align:=alclient;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.ToolButton1Click(Sender: TObject);
|
||||||
|
begin
|
||||||
|
InitUser();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.tbyhupClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
userID.SetFocus;
|
||||||
|
if CDS_User.IsEmpty then exit;
|
||||||
|
ADO_Cmd.Connection.BeginTrans;
|
||||||
|
try
|
||||||
|
with CDS_User do
|
||||||
|
begin
|
||||||
|
DisableControls;
|
||||||
|
First;
|
||||||
|
while not eof do
|
||||||
|
begin
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select * from BD_Staff_banzu');
|
||||||
|
sql.Add('where userID='+quotedstr(trim(CDS_User.fieldbyname('userID').AsString)));
|
||||||
|
open;
|
||||||
|
if ADO_Cmd.IsEmpty then ADO_Cmd.Append
|
||||||
|
else ADO_Cmd.Edit;
|
||||||
|
ADO_Cmd.fieldbyname('userID').Value:=trim(CDS_User.fieldbyname('userID').AsString);
|
||||||
|
ADO_Cmd.fieldbyname('banzu').Value:=trim(CDS_User.fieldbyname('banzu').AsString);
|
||||||
|
ADO_Cmd.Post;
|
||||||
|
end;
|
||||||
|
next;
|
||||||
|
end;
|
||||||
|
EnableControls;
|
||||||
|
end;
|
||||||
|
ADO_Cmd.Connection.CommitTrans;
|
||||||
|
except
|
||||||
|
CDS_User.EnableControls;
|
||||||
|
ADO_Cmd.Connection.RollbackTrans;
|
||||||
|
application.MessageBox('数据保存失败!','提示信息',MB_ICONERROR);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.tbyhdeleteClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if CDS_User.IsEmpty then exit;
|
||||||
|
if trim(CDS_User.FieldByName('userID').AsString)='ADMIN' then exit;
|
||||||
|
if application.MessageBox('请确定要删除此员工班组吗?','警告信息!',1)=2 then exit;
|
||||||
|
try
|
||||||
|
with ADO_Cmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add(' delete BD_Staff_banzu ');
|
||||||
|
sql.Add(' where userID='+quotedstr(trim(CDS_User.fieldbyname('USerID').AsString)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
InitUser();
|
||||||
|
except
|
||||||
|
application.MessageBox('删除失败!','错误信息',MB_ICONERROR);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.tbqxClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if CDS_User.IsEmpty then exit;
|
||||||
|
TcxGridToExcel(self.Caption,cxgrid1);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmUser_bz_List.userIDChange(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if not CDS_User.Active then exit;
|
||||||
|
SDofilter(ADO_user,SGetFilters(Panel1,1,2));
|
||||||
|
CreateAdoToCds(ADO_user,CDS_User);
|
||||||
|
InitAdoToCds(ADO_user,CDS_User);
|
||||||
|
end;
|
||||||
|
|
||||||
|
end.
|
221
基础数据/U_testdll.dfm
Normal file
221
基础数据/U_testdll.dfm
Normal file
|
@ -0,0 +1,221 @@
|
||||||
|
object Form1: TForm1
|
||||||
|
Left = 97
|
||||||
|
Top = 122
|
||||||
|
Width = 791
|
||||||
|
Height = 554
|
||||||
|
Caption = 'Form1'
|
||||||
|
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 = 783
|
||||||
|
Height = 25
|
||||||
|
ButtonWidth = 57
|
||||||
|
Caption = 'ToolBar1'
|
||||||
|
Flat = True
|
||||||
|
Images = ImageList1
|
||||||
|
TabOrder = 0
|
||||||
|
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
|
106
基础数据/U_testdll.pas
Normal file
106
基础数据/U_testdll.pas
Normal file
|
@ -0,0 +1,106 @@
|
||||||
|
unit U_testdll;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, ExtCtrls, StdCtrls, Menus, ToolWin, ComCtrls, ImgList, DB, ADODB;
|
||||||
|
|
||||||
|
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('baseData.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('sa'),
|
||||||
|
PChar('dsa'),
|
||||||
|
PChar('bsa'),
|
||||||
|
PChar('tsa'),
|
||||||
|
PChar('d1sa'),
|
||||||
|
PChar('d2sa'),
|
||||||
|
'','','','','','','','',''
|
||||||
|
);
|
||||||
|
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.
|
||||||
|
|
2
基础数据/consvr.ini
Normal file
2
基础数据/consvr.ini
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
[SERVER]
|
||||||
|
SERVER=192.168.88.254
|
157
基础数据/getpic.dfm
Normal file
157
基础数据/getpic.dfm
Normal file
|
@ -0,0 +1,157 @@
|
||||||
|
object FormGetPic: TFormGetPic
|
||||||
|
Left = 313
|
||||||
|
Top = 115
|
||||||
|
BorderIcons = [biSystemMenu]
|
||||||
|
BorderStyle = bsSingle
|
||||||
|
Caption = #33719#21462#22270#29255
|
||||||
|
ClientHeight = 452
|
||||||
|
ClientWidth = 665
|
||||||
|
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 = 440
|
||||||
|
Height = 440
|
||||||
|
HorzScrollBar.Visible = False
|
||||||
|
VertScrollBar.Visible = False
|
||||||
|
TabOrder = 0
|
||||||
|
object Image1: TImage
|
||||||
|
Left = 0
|
||||||
|
Top = -4
|
||||||
|
Width = 437
|
||||||
|
Height = 441
|
||||||
|
Cursor = crSizeAll
|
||||||
|
AutoSize = True
|
||||||
|
Center = True
|
||||||
|
IncrementalDisplay = True
|
||||||
|
OnMouseDown = Image1MouseDown
|
||||||
|
OnMouseMove = Image1MouseMove
|
||||||
|
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 Twain: TDelphiTwain
|
||||||
|
OnTwainAcquire = TwainTwainAcquire
|
||||||
|
TransferMode = ttmMemory
|
||||||
|
SourceCount = 0
|
||||||
|
Info.MajorVersion = 1
|
||||||
|
Info.MinorVersion = 0
|
||||||
|
Info.Language = tlUserLocale
|
||||||
|
Info.CountryCode = 1
|
||||||
|
Info.Groups = [tgControl, tgImage]
|
||||||
|
Info.VersionInfo = 'Application name'
|
||||||
|
Info.Manufacturer = 'Application manufacturer'
|
||||||
|
Info.ProductFamily = 'App product family'
|
||||||
|
Info.ProductName = 'App product name'
|
||||||
|
LibraryLoaded = False
|
||||||
|
SourceManagerLoaded = False
|
||||||
|
Left = 518
|
||||||
|
Top = 160
|
||||||
|
end
|
||||||
|
object OpenPictureDialog1: TOpenPictureDialog
|
||||||
|
DefaultExt = 'jpg'
|
||||||
|
Filter = 'JPEG '#22270#24418#25991#20214' (*.jpg)|*.jpg'
|
||||||
|
Left = 568
|
||||||
|
Top = 152
|
||||||
|
end
|
||||||
|
object ADOQuery1: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 504
|
||||||
|
Top = 280
|
||||||
|
end
|
||||||
|
object SaveDialog1: TSavePictureDialog
|
||||||
|
Filter = 'JPG'#22270#29255#26684#24335' (*.JPG)|*.JPG'
|
||||||
|
Left = 568
|
||||||
|
Top = 299
|
||||||
|
end
|
||||||
|
object adoqueryImage: TADOQuery
|
||||||
|
Connection = BaseData10_DataLink.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 488
|
||||||
|
Top = 184
|
||||||
|
end
|
||||||
|
object IdFTP1: TIdFTP
|
||||||
|
MaxLineAction = maException
|
||||||
|
ReadTimeout = 0
|
||||||
|
ProxySettings.ProxyType = fpcmNone
|
||||||
|
ProxySettings.Port = 0
|
||||||
|
Left = 500
|
||||||
|
Top = 198
|
||||||
|
end
|
||||||
|
end
|
586
基础数据/getpic.pas
Normal file
586
基础数据/getpic.pas
Normal file
|
@ -0,0 +1,586 @@
|
||||||
|
unit getpic;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, strUtils,Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, ComCtrls, ToolWin, ExtCtrls, jpeg, IniFiles, ExtDlgs,
|
||||||
|
DelphiTwain, Buttons, StdCtrls, DB, ADODB, IdBaseComponent, IdComponent,
|
||||||
|
IdTCPConnection, IdTCPClient, IdFTP;
|
||||||
|
|
||||||
|
type
|
||||||
|
TFormGetPic = class(TForm)
|
||||||
|
Twain: TDelphiTwain;
|
||||||
|
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;
|
||||||
|
public
|
||||||
|
FilePath:string;
|
||||||
|
FileName:string;
|
||||||
|
FTFType:string;
|
||||||
|
pat1:string;
|
||||||
|
pic1:string;
|
||||||
|
fkeyNo:string;
|
||||||
|
{ Public declarations }
|
||||||
|
MyJpeg: TJPEGImage;
|
||||||
|
// JPStream: TMemoryStream;
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
FormGetPic: TFormGetPic;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
uses U_DataLink,U_Fun10;
|
||||||
|
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.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(fkeyNo)));
|
||||||
|
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;
|
||||||
|
|
||||||
|
|
||||||
|
sFieldName:='D:\图片查看'+'\'+trim(pat1);
|
||||||
|
try
|
||||||
|
IdFTP1.Host := PicSvr;
|
||||||
|
IdFTP1.Username := 'three';
|
||||||
|
IdFTP1.Password := '641010';
|
||||||
|
IdFTP1.Connect();
|
||||||
|
except
|
||||||
|
;
|
||||||
|
end;
|
||||||
|
|
||||||
|
JPStream.Clear;
|
||||||
|
if IdFTP1.Connected then
|
||||||
|
begin
|
||||||
|
try
|
||||||
|
IdFTP1.Get('TP\'+ 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;
|
||||||
|
begin
|
||||||
|
|
||||||
|
result:=false;
|
||||||
|
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
|
||||||
|
Append;
|
||||||
|
fieldByName('WBID').AsString := fkeyNo;
|
||||||
|
fieldByName('TFID').AsString := fkeyNo;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
edit;
|
||||||
|
end;
|
||||||
|
fieldByName(pat1).AsString :=trim(FileName);
|
||||||
|
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 := PicSvr;
|
||||||
|
IdFTP1.Username := 'three';
|
||||||
|
IdFTP1.Password := '641010';
|
||||||
|
IdFTP1.Connect();
|
||||||
|
IdFTP1.Put(FilePath, 'TP\' + Trim(FileName));
|
||||||
|
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 > 1.333 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;
|
||||||
|
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);
|
||||||
|
begin
|
||||||
|
if OpenPictureDialog1.Execute then
|
||||||
|
begin
|
||||||
|
Image1.Top := 0;
|
||||||
|
Image1.Left := 0;
|
||||||
|
Image1.Picture.LoadFromFile(OpenPictureDialog1.FileName);
|
||||||
|
FilePath:=OpenPictureDialog1.FileName;
|
||||||
|
FileName:=ExtractFileName(FilePath);
|
||||||
|
CreThumb(240, 180);
|
||||||
|
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.
|
38
基础数据/testDll.cfg
Normal file
38
基础数据/testDll.cfg
Normal 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"d:\program files (x86)\borland\delphi7\Projects\Bpl"
|
||||||
|
-LN"d:\program files (x86)\borland\delphi7\Projects\Bpl"
|
||||||
|
-w-UNSAFE_TYPE
|
||||||
|
-w-UNSAFE_CODE
|
||||||
|
-w-UNSAFE_CAST
|
136
基础数据/testDll.dof
Normal file
136
基础数据/testDll.dof
Normal 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=F:\selfware_83398\selfware\马国钢开发代码\项目代码\self\基础信息设置\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=
|
14
基础数据/testDll.dpr
Normal file
14
基础数据/testDll.dpr
Normal 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.
|
||||||
|
|
BIN
基础数据/testDll.res
Normal file
BIN
基础数据/testDll.res
Normal file
Binary file not shown.
|
@ -53,7 +53,7 @@ object frmZdyAttInputCP: TfrmZdyAttInputCP
|
||||||
Left = 0
|
Left = 0
|
||||||
Top = 31
|
Top = 31
|
||||||
Width = 1052
|
Width = 1052
|
||||||
Height = 300
|
Height = 498
|
||||||
Align = alTop
|
Align = alTop
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
object Tv2: TcxGridDBTableView
|
object Tv2: TcxGridDBTableView
|
||||||
|
@ -146,12 +146,6 @@ object frmZdyAttInputCP: TfrmZdyAttInputCP
|
||||||
HeaderAlignmentHorz = taCenter
|
HeaderAlignmentHorz = taCenter
|
||||||
Width = 79
|
Width = 79
|
||||||
end
|
end
|
||||||
object v2Column2: TcxGridDBColumn
|
|
||||||
Caption = #20013#25991#39068#33394
|
|
||||||
DataBinding.FieldName = 'DEFstr6'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Width = 115
|
|
||||||
end
|
|
||||||
object v2Column8: TcxGridDBColumn
|
object v2Column8: TcxGridDBColumn
|
||||||
Caption = #33457#21495
|
Caption = #33457#21495
|
||||||
DataBinding.FieldName = 'DEFstr4'
|
DataBinding.FieldName = 'DEFstr4'
|
||||||
|
@ -177,14 +171,6 @@ object frmZdyAttInputCP: TfrmZdyAttInputCP
|
||||||
VisibleForCustomization = False
|
VisibleForCustomization = False
|
||||||
Width = 61
|
Width = 61
|
||||||
end
|
end
|
||||||
object v2Column15: TcxGridDBColumn
|
|
||||||
Caption = #20215#26684#22686#24133
|
|
||||||
DataBinding.FieldName = 'defflt1'
|
|
||||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
|
||||||
Properties.DisplayFormat = '0.##;-,0.##'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Width = 92
|
|
||||||
end
|
|
||||||
object v2Column1: TcxGridDBColumn
|
object v2Column1: TcxGridDBColumn
|
||||||
Caption = #22791#27880
|
Caption = #22791#27880
|
||||||
DataBinding.FieldName = 'Note'
|
DataBinding.FieldName = 'Note'
|
||||||
|
@ -192,6 +178,36 @@ object frmZdyAttInputCP: TfrmZdyAttInputCP
|
||||||
HeaderAlignmentHorz = taCenter
|
HeaderAlignmentHorz = taCenter
|
||||||
Width = 114
|
Width = 114
|
||||||
end
|
end
|
||||||
|
object Tv2Column1: TcxGridDBColumn
|
||||||
|
Caption = #20135#21697#32534#21495
|
||||||
|
DataBinding.FieldName = 'ZdyCode'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object Tv2Column2: TcxGridDBColumn
|
||||||
|
Caption = #38376#24133'(cm)'
|
||||||
|
DataBinding.FieldName = 'DEFstr1'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object Tv2Column3: TcxGridDBColumn
|
||||||
|
Caption = #20811#37325'(g/'#13217')'
|
||||||
|
DataBinding.FieldName = 'DEFstr2'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object Tv2Column4: TcxGridDBColumn
|
||||||
|
Caption = #35268#26684
|
||||||
|
DataBinding.FieldName = 'DEFstr4'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object Tv2Column5: TcxGridDBColumn
|
||||||
|
Caption = #33394#21495
|
||||||
|
DataBinding.FieldName = 'DEFstr10'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
end
|
end
|
||||||
object cxGridLevel1: TcxGridLevel
|
object cxGridLevel1: TcxGridLevel
|
||||||
GridView = Tv2
|
GridView = Tv2
|
||||||
|
@ -199,7 +215,7 @@ object frmZdyAttInputCP: TfrmZdyAttInputCP
|
||||||
end
|
end
|
||||||
object ToolBar2: TToolBar
|
object ToolBar2: TToolBar
|
||||||
Left = 0
|
Left = 0
|
||||||
Top = 331
|
Top = 529
|
||||||
Width = 1052
|
Width = 1052
|
||||||
Height = 29
|
Height = 29
|
||||||
ButtonHeight = 30
|
ButtonHeight = 30
|
||||||
|
@ -249,7 +265,7 @@ object frmZdyAttInputCP: TfrmZdyAttInputCP
|
||||||
end
|
end
|
||||||
object cxGrid1: TcxGrid
|
object cxGrid1: TcxGrid
|
||||||
Left = 0
|
Left = 0
|
||||||
Top = 360
|
Top = 558
|
||||||
Width = 1052
|
Width = 1052
|
||||||
Height = 183
|
Height = 183
|
||||||
Align = alClient
|
Align = alClient
|
||||||
|
|
|
@ -14,22 +14,22 @@ uses
|
||||||
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
||||||
cxTextEdit, cxDropDownEdit, strutils, cxCurrencyEdit, cxLookAndFeels,
|
cxTextEdit, cxDropDownEdit, strutils, cxCurrencyEdit, cxLookAndFeels,
|
||||||
cxLookAndFeelPainters, cxNavigator, dxSkinsCore, dxSkinBlack, dxSkinBlue,
|
cxLookAndFeelPainters, cxNavigator, dxSkinsCore, dxSkinBlack, dxSkinBlue,
|
||||||
dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom,
|
dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom, dxSkinDarkSide,
|
||||||
dxSkinDarkSide, dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle,
|
dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle, dxSkinFoggy,
|
||||||
dxSkinFoggy, dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary,
|
dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian,
|
||||||
dxSkinLilian, dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin,
|
dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis,
|
||||||
dxSkinMetropolis, dxSkinMetropolisDark, dxSkinMoneyTwins,
|
dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black,
|
||||||
dxSkinOffice2007Black, dxSkinOffice2007Blue, dxSkinOffice2007Green,
|
dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
|
||||||
dxSkinOffice2007Pink, dxSkinOffice2007Silver, dxSkinOffice2010Black,
|
dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue,
|
||||||
dxSkinOffice2010Blue, dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
|
dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, dxSkinOffice2013LightGray,
|
||||||
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin,
|
dxSkinOffice2013White, dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic,
|
||||||
dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
|
dxSkinSharp, dxSkinSharpPlus, dxSkinSilver, dxSkinSpringTime, dxSkinStardust,
|
||||||
dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
|
dxSkinSummer2008, dxSkinTheAsphaltWorld, dxSkinsDefaultPainters,
|
||||||
dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine,
|
dxSkinValentine, dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue,
|
||||||
dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue, dxSkinscxPCPainter;
|
dxSkinscxPCPainter;
|
||||||
|
|
||||||
type
|
type
|
||||||
TfrmZdyAttInputCP = class(TForm)
|
TfrmZdyAttInputCP = class(TForm)
|
||||||
ToolBar1: TToolBar;
|
ToolBar1: TToolBar;
|
||||||
TBClose: TToolButton;
|
TBClose: TToolButton;
|
||||||
ADOQueryTemp: TADOQuery;
|
ADOQueryTemp: TADOQuery;
|
||||||
|
@ -56,8 +56,6 @@ type
|
||||||
v2defstr9: TcxGridDBColumn;
|
v2defstr9: TcxGridDBColumn;
|
||||||
v2Column13: TcxGridDBColumn;
|
v2Column13: TcxGridDBColumn;
|
||||||
v2Mrate: TcxGridDBColumn;
|
v2Mrate: TcxGridDBColumn;
|
||||||
v2Column15: TcxGridDBColumn;
|
|
||||||
v2Column2: TcxGridDBColumn;
|
|
||||||
ToolBar2: TToolBar;
|
ToolBar2: TToolBar;
|
||||||
ToolButton1: TToolButton;
|
ToolButton1: TToolButton;
|
||||||
ToolButton2: TToolButton;
|
ToolButton2: TToolButton;
|
||||||
|
@ -70,6 +68,11 @@ type
|
||||||
ADOQueryGC: TADOQuery;
|
ADOQueryGC: TADOQuery;
|
||||||
Tv1Column1: TcxGridDBColumn;
|
Tv1Column1: TcxGridDBColumn;
|
||||||
Tv1Column2: TcxGridDBColumn;
|
Tv1Column2: TcxGridDBColumn;
|
||||||
|
Tv2Column1: TcxGridDBColumn;
|
||||||
|
Tv2Column2: TcxGridDBColumn;
|
||||||
|
Tv2Column3: TcxGridDBColumn;
|
||||||
|
Tv2Column4: TcxGridDBColumn;
|
||||||
|
Tv2Column5: TcxGridDBColumn;
|
||||||
procedure FormDestroy(Sender: TObject);
|
procedure FormDestroy(Sender: TObject);
|
||||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
procedure TBCloseClick(Sender: TObject);
|
procedure TBCloseClick(Sender: TObject);
|
||||||
|
@ -157,7 +160,7 @@ procedure TfrmZdyAttInputCP.TBCloseClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
WriteCxGrid('产品资料录入1', Tv2, '客户自定义');
|
WriteCxGrid('产品资料录入1', Tv2, '客户自定义');
|
||||||
Close;
|
Close;
|
||||||
ModalResult := 1;
|
ModalResult := 1;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfrmZdyAttInputCP.FormShow(Sender: TObject);
|
procedure TfrmZdyAttInputCP.FormShow(Sender: TObject);
|
||||||
|
@ -229,7 +232,7 @@ begin
|
||||||
|
|
||||||
RTSetSaveDataCDS(ADOQueryCmd, Tv2, CDS_HZ, 'KH_Zdy_Attachment', 0);
|
RTSetSaveDataCDS(ADOQueryCmd, Tv2, CDS_HZ, 'KH_Zdy_Attachment', 0);
|
||||||
FieldByName('ZdyName').Value := Trim(CDS_HZ.fieldbyname('ZdyName').AsString);
|
FieldByName('ZdyName').Value := Trim(CDS_HZ.fieldbyname('ZdyName').AsString);
|
||||||
FieldByName('ZdyCode').Value := Trim(maxId);
|
FieldByName('ZdyCode').Value := Trim(CDS_HZ.fieldbyname('ZdyCode').AsString); // Trim(maxId);
|
||||||
FieldByName('Mrate').Value := CDS_HZ.fieldbyname('Mrate').AsFloat;
|
FieldByName('Mrate').Value := CDS_HZ.fieldbyname('Mrate').AsFloat;
|
||||||
FieldByName('defflt1').Value := CDS_HZ.fieldbyname('defflt1').AsFloat;
|
FieldByName('defflt1').Value := CDS_HZ.fieldbyname('defflt1').AsFloat;
|
||||||
FieldByName('Type').Value := 'CP';
|
FieldByName('Type').Value := 'CP';
|
||||||
|
@ -401,11 +404,11 @@ begin
|
||||||
if trim(mvalue) = '' then
|
if trim(mvalue) = '' then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
if rightBstr(trim(mvalue), 1) <> '#' then
|
// if rightBstr(trim(mvalue), 1) <> '#' then
|
||||||
begin
|
// begin
|
||||||
mvalue := trim(mvalue) + '#';
|
// mvalue := trim(mvalue) + '#';
|
||||||
end;
|
// end;
|
||||||
|
mvalue := trim(mvalue);
|
||||||
with CDS_HZ do
|
with CDS_HZ do
|
||||||
begin
|
begin
|
||||||
Edit;
|
Edit;
|
||||||
|
@ -425,11 +428,11 @@ begin
|
||||||
if trim(mvalue) = '' then
|
if trim(mvalue) = '' then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
if rightBstr(trim(mvalue), 1) <> '#' then
|
// if rightBstr(trim(mvalue), 1) <> '#' then
|
||||||
begin
|
// begin
|
||||||
mvalue := trim(mvalue) + '#';
|
// mvalue := trim(mvalue) + '#';
|
||||||
end;
|
// end;
|
||||||
|
mvalue := trim(mvalue);
|
||||||
with CDS_HZ do
|
with CDS_HZ do
|
||||||
begin
|
begin
|
||||||
Edit;
|
Edit;
|
||||||
|
@ -449,11 +452,11 @@ begin
|
||||||
if trim(mvalue) = '' then
|
if trim(mvalue) = '' then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
if rightBstr(trim(mvalue), 1) <> '#' then
|
// if rightBstr(trim(mvalue), 1) <> '#' then
|
||||||
begin
|
// begin
|
||||||
mvalue := trim(mvalue) + '#';
|
// mvalue := trim(mvalue) + '#';
|
||||||
end;
|
// end;
|
||||||
|
mvalue := trim(mvalue);
|
||||||
with CDS_HZ do
|
with CDS_HZ do
|
||||||
begin
|
begin
|
||||||
Edit;
|
Edit;
|
||||||
|
|
|
@ -11,6 +11,7 @@ object frmZdyAttInputGYS: TfrmZdyAttInputGYS
|
||||||
Font.Name = #23435#20307
|
Font.Name = #23435#20307
|
||||||
Font.Style = []
|
Font.Style = []
|
||||||
OldCreateOrder = False
|
OldCreateOrder = False
|
||||||
|
Position = poScreenCenter
|
||||||
OnClose = FormClose
|
OnClose = FormClose
|
||||||
OnDestroy = FormDestroy
|
OnDestroy = FormDestroy
|
||||||
OnShow = FormShow
|
OnShow = FormShow
|
||||||
|
|
|
@ -12,7 +12,21 @@ uses
|
||||||
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
|
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
|
||||||
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
||||||
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
||||||
cxTextEdit, cxDropDownEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator;
|
cxTextEdit, cxDropDownEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator,
|
||||||
|
dxSkinsCore, dxSkinBlack, dxSkinBlue, dxSkinBlueprint, dxSkinCaramel,
|
||||||
|
dxSkinCoffee, dxSkinDarkRoom, dxSkinDarkSide, dxSkinDevExpressDarkStyle,
|
||||||
|
dxSkinDevExpressStyle, dxSkinFoggy, dxSkinGlassOceans,
|
||||||
|
dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian, dxSkinLiquidSky,
|
||||||
|
dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis,
|
||||||
|
dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black,
|
||||||
|
dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
|
||||||
|
dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue,
|
||||||
|
dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
|
||||||
|
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin,
|
||||||
|
dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
|
||||||
|
dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
|
||||||
|
dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine,
|
||||||
|
dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue, dxSkinscxPCPainter;
|
||||||
|
|
||||||
type
|
type
|
||||||
TfrmZdyAttInputGYS = class(TForm)
|
TfrmZdyAttInputGYS = class(TForm)
|
||||||
|
|
|
@ -138,20 +138,6 @@ object frmZdyAttInputPB: TfrmZdyAttInputPB
|
||||||
VisibleForCustomization = False
|
VisibleForCustomization = False
|
||||||
Width = 100
|
Width = 100
|
||||||
end
|
end
|
||||||
object v2Column5: TcxGridDBColumn
|
|
||||||
Caption = #39068#33394
|
|
||||||
DataBinding.FieldName = 'DEFstr3'
|
|
||||||
PropertiesClassName = 'TcxTextEditProperties'
|
|
||||||
Properties.OnEditValueChanged = v2Column5PropertiesEditValueChanged
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Width = 79
|
|
||||||
end
|
|
||||||
object v2Column2: TcxGridDBColumn
|
|
||||||
Caption = #20013#25991#39068#33394
|
|
||||||
DataBinding.FieldName = 'DEFstr6'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Width = 115
|
|
||||||
end
|
|
||||||
object v2Column8: TcxGridDBColumn
|
object v2Column8: TcxGridDBColumn
|
||||||
Caption = #33457#21495
|
Caption = #33457#21495
|
||||||
DataBinding.FieldName = 'DEFstr4'
|
DataBinding.FieldName = 'DEFstr4'
|
||||||
|
|
|
@ -13,7 +13,20 @@ uses
|
||||||
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
||||||
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
||||||
cxTextEdit, cxDropDownEdit, strutils, cxCurrencyEdit, cxLookAndFeels,
|
cxTextEdit, cxDropDownEdit, strutils, cxCurrencyEdit, cxLookAndFeels,
|
||||||
cxLookAndFeelPainters, cxNavigator;
|
cxLookAndFeelPainters, cxNavigator, dxSkinsCore, dxSkinBlack, dxSkinBlue,
|
||||||
|
dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom,
|
||||||
|
dxSkinDarkSide, dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle,
|
||||||
|
dxSkinFoggy, dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary,
|
||||||
|
dxSkinLilian, dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin,
|
||||||
|
dxSkinMetropolis, dxSkinMetropolisDark, dxSkinMoneyTwins,
|
||||||
|
dxSkinOffice2007Black, dxSkinOffice2007Blue, dxSkinOffice2007Green,
|
||||||
|
dxSkinOffice2007Pink, dxSkinOffice2007Silver, dxSkinOffice2010Black,
|
||||||
|
dxSkinOffice2010Blue, dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
|
||||||
|
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin,
|
||||||
|
dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
|
||||||
|
dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
|
||||||
|
dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine,
|
||||||
|
dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue, dxSkinscxPCPainter;
|
||||||
|
|
||||||
type
|
type
|
||||||
TfrmZdyAttInputPB = class(TForm)
|
TfrmZdyAttInputPB = class(TForm)
|
||||||
|
@ -33,7 +46,6 @@ type
|
||||||
v2Column6: TcxGridDBColumn;
|
v2Column6: TcxGridDBColumn;
|
||||||
v2Column3: TcxGridDBColumn;
|
v2Column3: TcxGridDBColumn;
|
||||||
v2Column4: TcxGridDBColumn;
|
v2Column4: TcxGridDBColumn;
|
||||||
v2Column5: TcxGridDBColumn;
|
|
||||||
v2Column8: TcxGridDBColumn;
|
v2Column8: TcxGridDBColumn;
|
||||||
v2Column9: TcxGridDBColumn;
|
v2Column9: TcxGridDBColumn;
|
||||||
v2Column7: TcxGridDBColumn;
|
v2Column7: TcxGridDBColumn;
|
||||||
|
@ -44,7 +56,6 @@ type
|
||||||
v2Column13: TcxGridDBColumn;
|
v2Column13: TcxGridDBColumn;
|
||||||
v2Mrate: TcxGridDBColumn;
|
v2Mrate: TcxGridDBColumn;
|
||||||
v2Column15: TcxGridDBColumn;
|
v2Column15: TcxGridDBColumn;
|
||||||
v2Column2: TcxGridDBColumn;
|
|
||||||
Tv2Column1: TcxGridDBColumn;
|
Tv2Column1: TcxGridDBColumn;
|
||||||
procedure FormDestroy(Sender: TObject);
|
procedure FormDestroy(Sender: TObject);
|
||||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
|
|
|
@ -248,12 +248,6 @@ object frmZdyAttachCP: TfrmZdyAttachCP
|
||||||
Options.Sorting = False
|
Options.Sorting = False
|
||||||
Width = 88
|
Width = 88
|
||||||
end
|
end
|
||||||
object v2Column16: TcxGridDBColumn
|
|
||||||
Caption = #20013#25991#39068#33394
|
|
||||||
DataBinding.FieldName = 'DEFstr6'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Width = 80
|
|
||||||
end
|
|
||||||
object v2Column11: TcxGridDBColumn
|
object v2Column11: TcxGridDBColumn
|
||||||
Caption = #31867#22411
|
Caption = #31867#22411
|
||||||
DataBinding.FieldName = 'DEFstr5'
|
DataBinding.FieldName = 'DEFstr5'
|
||||||
|
@ -318,13 +312,6 @@ object frmZdyAttachCP: TfrmZdyAttachCP
|
||||||
VisibleForCustomization = False
|
VisibleForCustomization = False
|
||||||
Width = 61
|
Width = 61
|
||||||
end
|
end
|
||||||
object v2defflt1: TcxGridDBColumn
|
|
||||||
Caption = #20215#26684#22686#24133
|
|
||||||
DataBinding.FieldName = 'defflt1'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Options.Editing = False
|
|
||||||
Width = 60
|
|
||||||
end
|
|
||||||
object v2Column1: TcxGridDBColumn
|
object v2Column1: TcxGridDBColumn
|
||||||
Caption = #22791#27880
|
Caption = #22791#27880
|
||||||
DataBinding.FieldName = 'Note'
|
DataBinding.FieldName = 'Note'
|
||||||
|
@ -347,6 +334,36 @@ object frmZdyAttachCP: TfrmZdyAttachCP
|
||||||
Options.Sorting = False
|
Options.Sorting = False
|
||||||
Width = 188
|
Width = 188
|
||||||
end
|
end
|
||||||
|
object Tv2Column1: TcxGridDBColumn
|
||||||
|
Caption = #20135#21697#32534#21495
|
||||||
|
DataBinding.FieldName = 'ZdyCode'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object Tv2Column2: TcxGridDBColumn
|
||||||
|
Caption = #38376#24133'(cm)'
|
||||||
|
DataBinding.FieldName = 'DEFstr1'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object Tv2Column3: TcxGridDBColumn
|
||||||
|
Caption = #20811#37325'(g/'#13217')'
|
||||||
|
DataBinding.FieldName = 'DEFstr2'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object Tv2Column4: TcxGridDBColumn
|
||||||
|
Caption = #35268#26684
|
||||||
|
DataBinding.FieldName = 'DEFstr4'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object Tv2Column5: TcxGridDBColumn
|
||||||
|
Caption = #33394#21495
|
||||||
|
DataBinding.FieldName = 'DEFstr10'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
end
|
end
|
||||||
object cxGridLevel1: TcxGridLevel
|
object cxGridLevel1: TcxGridLevel
|
||||||
GridView = Tv2
|
GridView = Tv2
|
||||||
|
|
|
@ -78,14 +78,12 @@ type
|
||||||
v2Mrate: TcxGridDBColumn;
|
v2Mrate: TcxGridDBColumn;
|
||||||
v2Column14: TcxGridDBColumn;
|
v2Column14: TcxGridDBColumn;
|
||||||
v2Column15: TcxGridDBColumn;
|
v2Column15: TcxGridDBColumn;
|
||||||
v2defflt1: TcxGridDBColumn;
|
|
||||||
ToolButton6: TToolButton;
|
ToolButton6: TToolButton;
|
||||||
Panel2: TPanel;
|
Panel2: TPanel;
|
||||||
RadioGroup1: TRadioGroup;
|
RadioGroup1: TRadioGroup;
|
||||||
Label4: TLabel;
|
Label4: TLabel;
|
||||||
cxButton1: TcxButton;
|
cxButton1: TcxButton;
|
||||||
cxButton2: TcxButton;
|
cxButton2: TcxButton;
|
||||||
v2Column16: TcxGridDBColumn;
|
|
||||||
cxGrid1: TcxGrid;
|
cxGrid1: TcxGrid;
|
||||||
Tv1: TcxGridDBTableView;
|
Tv1: TcxGridDBTableView;
|
||||||
cxGridLevel2: TcxGridLevel;
|
cxGridLevel2: TcxGridLevel;
|
||||||
|
@ -94,6 +92,11 @@ type
|
||||||
DS_GC: TDataSource;
|
DS_GC: TDataSource;
|
||||||
Tv1Column1: TcxGridDBColumn;
|
Tv1Column1: TcxGridDBColumn;
|
||||||
Tv1Column2: TcxGridDBColumn;
|
Tv1Column2: TcxGridDBColumn;
|
||||||
|
Tv2Column1: TcxGridDBColumn;
|
||||||
|
Tv2Column2: TcxGridDBColumn;
|
||||||
|
Tv2Column3: TcxGridDBColumn;
|
||||||
|
Tv2Column4: TcxGridDBColumn;
|
||||||
|
Tv2Column5: TcxGridDBColumn;
|
||||||
procedure FormDestroy(Sender: TObject);
|
procedure FormDestroy(Sender: TObject);
|
||||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
procedure TBCloseClick(Sender: TObject);
|
procedure TBCloseClick(Sender: TObject);
|
||||||
|
@ -135,9 +138,9 @@ begin
|
||||||
with ADOQueryMain do
|
with ADOQueryMain do
|
||||||
begin
|
begin
|
||||||
Filtered := False;
|
Filtered := False;
|
||||||
Close;
|
Close;
|
||||||
SQL.Clear;
|
SQL.Clear;
|
||||||
sql.Add(' select ATID,ZdyName,ZdyCode,DEFstr1,DEFstr2,defNote1,Mrate,defNote2,defNote3,DEFstr3,DEFstr5,DEFstr4,');
|
sql.Add(' select ATID,ZdyName,ZdyCode,DEFstr1,DEFstr2,defNote1,Mrate,defNote2,defNote3,DEFstr3,DEFstr5,DEFstr4,DEFstr10,');
|
||||||
sql.Add(' DEFstr6,DEFstr7,DEFstr8,Note,DEFstr4,DEFstr5,defflt1,Filler,FillTime ');
|
sql.Add(' DEFstr6,DEFstr7,DEFstr8,Note,DEFstr4,DEFstr5,defflt1,Filler,FillTime ');
|
||||||
sql.Add(' from KH_Zdy_Attachment where Type=''CP'' and isnull(DEFstr5,'''')<>''Å÷²¼'' ');
|
sql.Add(' from KH_Zdy_Attachment where Type=''CP'' and isnull(DEFstr5,'''')<>''Å÷²¼'' ');
|
||||||
// sql.Add(' and isnull(khType,'''')=' + quotedstr(trim(fkhType)));
|
// sql.Add(' and isnull(khType,'''')=' + quotedstr(trim(fkhType)));
|
||||||
|
|
|
@ -13,7 +13,20 @@ uses
|
||||||
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
||||||
IdTCPClient, IdFTP,ShellAPI,IniFiles, cxCheckBox, cxCalendar,
|
IdTCPClient, IdFTP,ShellAPI,IniFiles, cxCheckBox, cxCalendar,
|
||||||
cxButtonEdit, cxTextEdit, cxLookAndFeels, cxLookAndFeelPainters,
|
cxButtonEdit, cxTextEdit, cxLookAndFeels, cxLookAndFeelPainters,
|
||||||
cxNavigator;
|
cxNavigator, dxSkinsCore, dxSkinBlack, dxSkinBlue, dxSkinBlueprint,
|
||||||
|
dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom, dxSkinDarkSide,
|
||||||
|
dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle, dxSkinFoggy,
|
||||||
|
dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian,
|
||||||
|
dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis,
|
||||||
|
dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black,
|
||||||
|
dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
|
||||||
|
dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue,
|
||||||
|
dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
|
||||||
|
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin,
|
||||||
|
dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
|
||||||
|
dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
|
||||||
|
dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine,
|
||||||
|
dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue, dxSkinscxPCPainter;
|
||||||
|
|
||||||
type
|
type
|
||||||
TfrmZdyAttachGYS = class(TForm)
|
TfrmZdyAttachGYS = class(TForm)
|
||||||
|
|
|
@ -239,20 +239,6 @@ object frmZdyAttachPB: TfrmZdyAttachPB
|
||||||
Options.Sorting = False
|
Options.Sorting = False
|
||||||
Width = 100
|
Width = 100
|
||||||
end
|
end
|
||||||
object v2Column5: TcxGridDBColumn
|
|
||||||
Caption = #39068#33394
|
|
||||||
DataBinding.FieldName = 'DEFstr3'
|
|
||||||
PropertiesClassName = 'TcxTextEditProperties'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Options.Sorting = False
|
|
||||||
Width = 88
|
|
||||||
end
|
|
||||||
object v2Column16: TcxGridDBColumn
|
|
||||||
Caption = #20013#25991#39068#33394
|
|
||||||
DataBinding.FieldName = 'DEFstr6'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Width = 80
|
|
||||||
end
|
|
||||||
object v2Column11: TcxGridDBColumn
|
object v2Column11: TcxGridDBColumn
|
||||||
Caption = #31867#22411
|
Caption = #31867#22411
|
||||||
DataBinding.FieldName = 'DEFstr5'
|
DataBinding.FieldName = 'DEFstr5'
|
||||||
|
|
|
@ -13,7 +13,20 @@ uses
|
||||||
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
||||||
IdTCPClient, IdFTP,ShellAPI,IniFiles, cxCheckBox, cxCalendar,
|
IdTCPClient, IdFTP,ShellAPI,IniFiles, cxCheckBox, cxCalendar,
|
||||||
cxButtonEdit, cxTextEdit, Menus, cxLookAndFeelPainters, cxButtons,
|
cxButtonEdit, cxTextEdit, Menus, cxLookAndFeelPainters, cxButtons,
|
||||||
cxLookAndFeels, cxNavigator;
|
cxLookAndFeels, cxNavigator, dxSkinsCore, dxSkinBlack, dxSkinBlue,
|
||||||
|
dxSkinBlueprint, dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom,
|
||||||
|
dxSkinDarkSide, dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle,
|
||||||
|
dxSkinFoggy, dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary,
|
||||||
|
dxSkinLilian, dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin,
|
||||||
|
dxSkinMetropolis, dxSkinMetropolisDark, dxSkinMoneyTwins,
|
||||||
|
dxSkinOffice2007Black, dxSkinOffice2007Blue, dxSkinOffice2007Green,
|
||||||
|
dxSkinOffice2007Pink, dxSkinOffice2007Silver, dxSkinOffice2010Black,
|
||||||
|
dxSkinOffice2010Blue, dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
|
||||||
|
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin,
|
||||||
|
dxSkinSeven, dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus,
|
||||||
|
dxSkinSilver, dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008,
|
||||||
|
dxSkinTheAsphaltWorld, dxSkinsDefaultPainters, dxSkinValentine,
|
||||||
|
dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue, dxSkinscxPCPainter;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
|
@ -49,7 +62,6 @@ type
|
||||||
v2Column2: TcxGridDBColumn;
|
v2Column2: TcxGridDBColumn;
|
||||||
v2Column3: TcxGridDBColumn;
|
v2Column3: TcxGridDBColumn;
|
||||||
v2Column4: TcxGridDBColumn;
|
v2Column4: TcxGridDBColumn;
|
||||||
v2Column5: TcxGridDBColumn;
|
|
||||||
v2Column9: TcxGridDBColumn;
|
v2Column9: TcxGridDBColumn;
|
||||||
Label1: TLabel;
|
Label1: TLabel;
|
||||||
ZdyCode: TEdit;
|
ZdyCode: TEdit;
|
||||||
|
@ -72,7 +84,6 @@ type
|
||||||
Label4: TLabel;
|
Label4: TLabel;
|
||||||
cxButton1: TcxButton;
|
cxButton1: TcxButton;
|
||||||
cxButton2: TcxButton;
|
cxButton2: TcxButton;
|
||||||
v2Column16: TcxGridDBColumn;
|
|
||||||
Tv2Column1: TcxGridDBColumn;
|
Tv2Column1: TcxGridDBColumn;
|
||||||
procedure FormDestroy(Sender: TObject);
|
procedure FormDestroy(Sender: TObject);
|
||||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
|
@ -233,7 +244,7 @@ begin
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
finally
|
finally
|
||||||
frmZdyAttInputPB.Free;
|
frmZdyAttInputPB.Free;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
670
管理系统/U_ClothContractInPut_Dp.dfm
Normal file
670
管理系统/U_ClothContractInPut_Dp.dfm
Normal file
|
@ -0,0 +1,670 @@
|
||||||
|
object frmClothContractInPut_Dp: TfrmClothContractInPut_Dp
|
||||||
|
Left = 213
|
||||||
|
Top = 163
|
||||||
|
Width = 1030
|
||||||
|
Height = 478
|
||||||
|
Caption = #22383#24067#35843#25320
|
||||||
|
Color = clBtnFace
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
OldCreateOrder = False
|
||||||
|
Position = poScreenCenter
|
||||||
|
OnClose = FormClose
|
||||||
|
OnCreate = FormCreate
|
||||||
|
OnShow = FormShow
|
||||||
|
PixelsPerInch = 96
|
||||||
|
TextHeight = 12
|
||||||
|
object ToolBar1: TToolBar
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
Width = 1014
|
||||||
|
Height = 29
|
||||||
|
ButtonHeight = 30
|
||||||
|
ButtonWidth = 59
|
||||||
|
Caption = 'ToolBar1'
|
||||||
|
EdgeInner = esNone
|
||||||
|
EdgeOuter = esNone
|
||||||
|
Flat = True
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
Images = DataLink_TradeManage.ThreeImgList
|
||||||
|
List = True
|
||||||
|
ParentFont = False
|
||||||
|
ShowCaptions = True
|
||||||
|
TabOrder = 0
|
||||||
|
object TBSave: TToolButton
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20445#23384
|
||||||
|
ImageIndex = 14
|
||||||
|
OnClick = TBSaveClick
|
||||||
|
end
|
||||||
|
object TBClose: TToolButton
|
||||||
|
Left = 63
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20851#38381
|
||||||
|
ImageIndex = 55
|
||||||
|
OnClick = TBCloseClick
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object ScrollBox1: TScrollBox
|
||||||
|
Left = 0
|
||||||
|
Top = 29
|
||||||
|
Width = 1014
|
||||||
|
Height = 108
|
||||||
|
Align = alTop
|
||||||
|
BevelInner = bvNone
|
||||||
|
BevelOuter = bvNone
|
||||||
|
Ctl3D = False
|
||||||
|
ParentCtl3D = False
|
||||||
|
TabOrder = 1
|
||||||
|
object Label1: TLabel
|
||||||
|
Left = 20
|
||||||
|
Top = 14
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #25237#22383#21333#21495#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label4: TLabel
|
||||||
|
Left = 290
|
||||||
|
Top = 14
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #25237#22383#26085#26399#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label5: TLabel
|
||||||
|
Left = 502
|
||||||
|
Top = 14
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #35843#20986#24037#21378#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label2: TLabel
|
||||||
|
Left = 28
|
||||||
|
Top = 166
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #31614#35746#26085#26399#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object Label3: TLabel
|
||||||
|
Left = 268
|
||||||
|
Top = 150
|
||||||
|
Width = 67
|
||||||
|
Height = 12
|
||||||
|
Caption = #38656' '#26041#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object Label6: TLabel
|
||||||
|
Left = 231
|
||||||
|
Top = 270
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #31614#35746#22320#28857#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object Label7: TLabel
|
||||||
|
Left = 20
|
||||||
|
Top = 38
|
||||||
|
Width = 66
|
||||||
|
Height = 12
|
||||||
|
Caption = #32852' '#31995' '#20154#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label8: TLabel
|
||||||
|
Left = 274
|
||||||
|
Top = 178
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #20132#36135#22320#28857#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object Label9: TLabel
|
||||||
|
Left = 292
|
||||||
|
Top = 38
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #32852#31995#26041#24335#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label10: TLabel
|
||||||
|
Left = 510
|
||||||
|
Top = 146
|
||||||
|
Width = 91
|
||||||
|
Height = 12
|
||||||
|
Caption = #37319#36141#35745#21010#21333#21495#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object Label11: TLabel
|
||||||
|
Left = 20
|
||||||
|
Top = 62
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #24037#33402#35828#26126#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label12: TLabel
|
||||||
|
Left = 503
|
||||||
|
Top = 37
|
||||||
|
Width = 65
|
||||||
|
Height = 12
|
||||||
|
Caption = #35843#20837#24037#21378#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object ConNo: TEdit
|
||||||
|
Left = 86
|
||||||
|
Top = 11
|
||||||
|
Width = 137
|
||||||
|
Height = 18
|
||||||
|
Enabled = False
|
||||||
|
TabOrder = 0
|
||||||
|
end
|
||||||
|
object DeliveryDate: TDateTimePicker
|
||||||
|
Left = 353
|
||||||
|
Top = 10
|
||||||
|
Width = 134
|
||||||
|
Height = 20
|
||||||
|
BevelInner = bvNone
|
||||||
|
Date = 40916.000000000000000000
|
||||||
|
Format = 'yyyy-MM-dd'
|
||||||
|
Time = 40916.000000000000000000
|
||||||
|
TabOrder = 1
|
||||||
|
end
|
||||||
|
object FactoryNoName: TcxButtonEdit
|
||||||
|
Left = 574
|
||||||
|
Top = 10
|
||||||
|
Hint = 'FactoryNo'
|
||||||
|
BeepOnEnter = False
|
||||||
|
Properties.Buttons = <
|
||||||
|
item
|
||||||
|
Default = True
|
||||||
|
Kind = bkEllipsis
|
||||||
|
end>
|
||||||
|
Properties.OnButtonClick = FactoryNoNamePropertiesButtonClick
|
||||||
|
Properties.OnChange = FactoryNoNamePropertiesChange
|
||||||
|
Style.BorderStyle = ebsSingle
|
||||||
|
TabOrder = 2
|
||||||
|
Width = 134
|
||||||
|
end
|
||||||
|
object PanZDY: TPanel
|
||||||
|
Left = 861
|
||||||
|
Top = 128
|
||||||
|
Width = 202
|
||||||
|
Height = 153
|
||||||
|
TabOrder = 3
|
||||||
|
Visible = False
|
||||||
|
object CXGridZDY: TcxGrid
|
||||||
|
Left = 3
|
||||||
|
Top = 4
|
||||||
|
Width = 197
|
||||||
|
Height = 113
|
||||||
|
TabOrder = 0
|
||||||
|
object TVZDY: TcxGridDBTableView
|
||||||
|
OnKeyPress = TVZDYKeyPress
|
||||||
|
Navigator.Buttons.CustomButtons = <>
|
||||||
|
OnCellDblClick = TVZDYCellDblClick
|
||||||
|
DataController.DataSource = DataSource2
|
||||||
|
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||||
|
DataController.Summary.FooterSummaryItems = <>
|
||||||
|
DataController.Summary.SummaryGroups = <>
|
||||||
|
OptionsCustomize.ColumnFiltering = False
|
||||||
|
OptionsSelection.CellSelect = False
|
||||||
|
OptionsView.GroupByBox = False
|
||||||
|
object VHelpZDYName: TcxGridDBColumn
|
||||||
|
DataBinding.FieldName = 'ZDYName'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Styles.Header = DataLink_TradeManage.handBlack
|
||||||
|
Width = 163
|
||||||
|
IsCaptionAssigned = True
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object CXGridZDYLevel1: TcxGridLevel
|
||||||
|
GridView = TVZDY
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object Button1: TButton
|
||||||
|
Left = 64
|
||||||
|
Top = 120
|
||||||
|
Width = 65
|
||||||
|
Height = 25
|
||||||
|
Caption = #20851#38381
|
||||||
|
TabOrder = 1
|
||||||
|
OnClick = Button1Click
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object QDTime: TDateTimePicker
|
||||||
|
Left = 90
|
||||||
|
Top = 162
|
||||||
|
Width = 140
|
||||||
|
Height = 20
|
||||||
|
BevelInner = bvNone
|
||||||
|
Date = 40916.670856296290000000
|
||||||
|
Format = 'yyyy-MM-dd'
|
||||||
|
Time = 40916.670856296290000000
|
||||||
|
ShowCheckbox = True
|
||||||
|
TabOrder = 4
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object CompanyName: TcxButtonEdit
|
||||||
|
Left = 333
|
||||||
|
Top = 146
|
||||||
|
BeepOnEnter = False
|
||||||
|
Properties.Buttons = <
|
||||||
|
item
|
||||||
|
Default = True
|
||||||
|
Kind = bkEllipsis
|
||||||
|
end>
|
||||||
|
Properties.OnButtonClick = CompanyNamePropertiesButtonClick
|
||||||
|
Style.BorderStyle = ebsSingle
|
||||||
|
TabOrder = 5
|
||||||
|
Visible = False
|
||||||
|
Width = 132
|
||||||
|
end
|
||||||
|
object QDPalce: TEdit
|
||||||
|
Left = 311
|
||||||
|
Top = 271
|
||||||
|
Width = 131
|
||||||
|
Height = 18
|
||||||
|
TabOrder = 6
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object LXPerson: TEdit
|
||||||
|
Left = 85
|
||||||
|
Top = 35
|
||||||
|
Width = 134
|
||||||
|
Height = 18
|
||||||
|
TabOrder = 7
|
||||||
|
end
|
||||||
|
object LXTel: TEdit
|
||||||
|
Left = 354
|
||||||
|
Top = 35
|
||||||
|
Width = 135
|
||||||
|
Height = 18
|
||||||
|
TabOrder = 8
|
||||||
|
end
|
||||||
|
object JHPlace: TcxButtonEdit
|
||||||
|
Left = 341
|
||||||
|
Top = 174
|
||||||
|
BeepOnEnter = False
|
||||||
|
Properties.Buttons = <
|
||||||
|
item
|
||||||
|
Default = True
|
||||||
|
Kind = bkEllipsis
|
||||||
|
end>
|
||||||
|
Properties.OnButtonClick = JHPlacePropertiesButtonClick
|
||||||
|
TabOrder = 9
|
||||||
|
Visible = False
|
||||||
|
Width = 388
|
||||||
|
end
|
||||||
|
object fromConNo: TcxButtonEdit
|
||||||
|
Tag = 1
|
||||||
|
Left = 605
|
||||||
|
Top = 142
|
||||||
|
BeepOnEnter = False
|
||||||
|
Properties.Buttons = <
|
||||||
|
item
|
||||||
|
Default = True
|
||||||
|
Kind = bkEllipsis
|
||||||
|
end>
|
||||||
|
Properties.OnButtonClick = fromConNoPropertiesButtonClick
|
||||||
|
Style.BorderStyle = ebsSingle
|
||||||
|
TabOrder = 10
|
||||||
|
Visible = False
|
||||||
|
OnKeyPress = fromConNoKeyPress
|
||||||
|
Width = 116
|
||||||
|
end
|
||||||
|
object GxNote1: TEdit
|
||||||
|
Left = 86
|
||||||
|
Top = 59
|
||||||
|
Width = 627
|
||||||
|
Height = 18
|
||||||
|
TabOrder = 11
|
||||||
|
end
|
||||||
|
object ToFactoryName: TcxButtonEdit
|
||||||
|
Left = 575
|
||||||
|
Top = 33
|
||||||
|
Hint = 'ToFactoryNo'
|
||||||
|
BeepOnEnter = False
|
||||||
|
Properties.Buttons = <
|
||||||
|
item
|
||||||
|
Default = True
|
||||||
|
Kind = bkEllipsis
|
||||||
|
end>
|
||||||
|
Properties.OnButtonClick = ToFactoryNoNamePropertiesButtonClick
|
||||||
|
Properties.OnChange = FactoryNoNamePropertiesChange
|
||||||
|
Style.BorderStyle = ebsSingle
|
||||||
|
TabOrder = 12
|
||||||
|
Width = 134
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object ToolBar2: TToolBar
|
||||||
|
Left = 0
|
||||||
|
Top = 137
|
||||||
|
Width = 1014
|
||||||
|
Height = 29
|
||||||
|
ButtonHeight = 30
|
||||||
|
ButtonWidth = 59
|
||||||
|
Caption = 'ToolBar1'
|
||||||
|
EdgeInner = esNone
|
||||||
|
EdgeOuter = esNone
|
||||||
|
Flat = True
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
Images = DataLink_TradeManage.ThreeImgList
|
||||||
|
List = True
|
||||||
|
ParentFont = False
|
||||||
|
ShowCaptions = True
|
||||||
|
TabOrder = 2
|
||||||
|
object ToolButton1: TToolButton
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #22686#34892
|
||||||
|
ImageIndex = 103
|
||||||
|
OnClick = ToolButton1Click
|
||||||
|
end
|
||||||
|
object ToolButton2: TToolButton
|
||||||
|
Left = 63
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21024#34892
|
||||||
|
ImageIndex = 107
|
||||||
|
OnClick = ToolButton2Click
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid1: TcxGrid
|
||||||
|
Left = 0
|
||||||
|
Top = 166
|
||||||
|
Width = 1014
|
||||||
|
Height = 179
|
||||||
|
Align = alTop
|
||||||
|
TabOrder = 3
|
||||||
|
object Tv1: TcxGridDBTableView
|
||||||
|
Navigator.Buttons.CustomButtons = <>
|
||||||
|
DataController.DataSource = DataSource1
|
||||||
|
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||||
|
DataController.Summary.DefaultGroupSummaryItems = <
|
||||||
|
item
|
||||||
|
Format = 'C_Code'
|
||||||
|
Column = v1Column1
|
||||||
|
end>
|
||||||
|
DataController.Summary.FooterSummaryItems = <>
|
||||||
|
DataController.Summary.SummaryGroups = <>
|
||||||
|
OptionsBehavior.FocusCellOnTab = True
|
||||||
|
OptionsBehavior.GoToNextCellOnEnter = True
|
||||||
|
OptionsBehavior.FocusCellOnCycle = True
|
||||||
|
OptionsCustomize.ColumnFiltering = False
|
||||||
|
OptionsCustomize.ColumnSorting = False
|
||||||
|
OptionsView.GroupByBox = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
object v1Column1: TcxGridDBColumn
|
||||||
|
Caption = #20135#21697#21517#31216
|
||||||
|
DataBinding.FieldName = 'C_CodeName'
|
||||||
|
PropertiesClassName = 'TcxButtonEditProperties'
|
||||||
|
Properties.Buttons = <
|
||||||
|
item
|
||||||
|
Default = True
|
||||||
|
Kind = bkEllipsis
|
||||||
|
end>
|
||||||
|
Properties.OnButtonClick = v1Column1PropertiesButtonClick
|
||||||
|
Properties.OnEditValueChanged = v1Column1PropertiesEditValueChanged
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 100
|
||||||
|
end
|
||||||
|
object v1PRTSpec: TcxGridDBColumn
|
||||||
|
Caption = #35268#26684#22411#21495
|
||||||
|
DataBinding.FieldName = 'C_Spec'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Options.Focusing = False
|
||||||
|
Options.Sorting = False
|
||||||
|
Styles.Header = DataLink_TradeManage.handBlack
|
||||||
|
Width = 103
|
||||||
|
end
|
||||||
|
object v1C_Color: TcxGridDBColumn
|
||||||
|
Caption = #39068#33394
|
||||||
|
DataBinding.FieldName = 'C_Color'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.OnEditValueChanged = v1C_ColorPropertiesEditValueChanged
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object v1PRTColor: TcxGridDBColumn
|
||||||
|
Caption = #20811#37325'(g/'#13217')'
|
||||||
|
DataBinding.FieldName = 'KZQty'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Options.Focusing = False
|
||||||
|
Options.Sorting = False
|
||||||
|
Styles.Header = DataLink_TradeManage.handBlack
|
||||||
|
Width = 78
|
||||||
|
end
|
||||||
|
object v1PRTKZ: TcxGridDBColumn
|
||||||
|
Caption = #38376#24133'(cm)'
|
||||||
|
DataBinding.FieldName = 'MFQty'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Options.Focusing = False
|
||||||
|
Options.Sorting = False
|
||||||
|
Styles.Header = DataLink_TradeManage.handBlack
|
||||||
|
Width = 90
|
||||||
|
end
|
||||||
|
object v1Qty2: TcxGridDBColumn
|
||||||
|
Caption = #32568#25968
|
||||||
|
DataBinding.FieldName = 'Qty2'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object v1Column5: TcxGridDBColumn
|
||||||
|
Caption = #21305#25968
|
||||||
|
DataBinding.FieldName = 'Qty1'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 65
|
||||||
|
end
|
||||||
|
object v1ClothUnit: TcxGridDBColumn
|
||||||
|
Caption = #25968#37327
|
||||||
|
DataBinding.FieldName = 'C_Qty'
|
||||||
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
|
Properties.OnEditValueChanged = v1ClothUnitPropertiesEditValueChanged
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Styles.Header = DataLink_TradeManage.handBlack
|
||||||
|
Width = 69
|
||||||
|
end
|
||||||
|
object v1Column2: TcxGridDBColumn
|
||||||
|
Caption = #25968#37327#21333#20301
|
||||||
|
DataBinding.FieldName = 'C_Unit'
|
||||||
|
PropertiesClassName = 'TcxComboBoxProperties'
|
||||||
|
Properties.DropDownListStyle = lsFixedList
|
||||||
|
Properties.Items.Strings = (
|
||||||
|
'M'
|
||||||
|
'Kg')
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Options.Focusing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 77
|
||||||
|
end
|
||||||
|
object v1Column3: TcxGridDBColumn
|
||||||
|
Caption = #21305#25968
|
||||||
|
DataBinding.FieldName = 'Qty1'
|
||||||
|
Visible = False
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 46
|
||||||
|
end
|
||||||
|
object v1Column4: TcxGridDBColumn
|
||||||
|
Caption = #22791#27880
|
||||||
|
DataBinding.FieldName = 'C_Note'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 137
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid1Level1: TcxGridLevel
|
||||||
|
GridView = Tv1
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object Panel1: TPanel
|
||||||
|
Left = 716
|
||||||
|
Top = 141
|
||||||
|
Width = 289
|
||||||
|
Height = 25
|
||||||
|
BevelOuter = bvNone
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clRed
|
||||||
|
Font.Height = -14
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
TabOrder = 4
|
||||||
|
object Label22: TLabel
|
||||||
|
Left = 32
|
||||||
|
Top = 4
|
||||||
|
Width = 45
|
||||||
|
Height = 14
|
||||||
|
Caption = #21305#25968#65306
|
||||||
|
end
|
||||||
|
object Label23: TLabel
|
||||||
|
Left = 144
|
||||||
|
Top = 4
|
||||||
|
Width = 45
|
||||||
|
Height = 14
|
||||||
|
Caption = #25968#37327#65306
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object ADOTemp: TADOQuery
|
||||||
|
Connection = DataLink_TradeManage.ADOLink
|
||||||
|
LockType = ltReadOnly
|
||||||
|
Parameters = <>
|
||||||
|
Left = 816
|
||||||
|
Top = 85
|
||||||
|
end
|
||||||
|
object ADOCmd: TADOQuery
|
||||||
|
Connection = DataLink_TradeManage.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 800
|
||||||
|
Top = 109
|
||||||
|
end
|
||||||
|
object DataSource1: TDataSource
|
||||||
|
DataSet = Order_Sub
|
||||||
|
Left = 356
|
||||||
|
Top = 192
|
||||||
|
end
|
||||||
|
object Order_Sub: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 424
|
||||||
|
Top = 192
|
||||||
|
end
|
||||||
|
object DataSource2: TDataSource
|
||||||
|
DataSet = ADOZDY
|
||||||
|
Left = 240
|
||||||
|
Top = 8
|
||||||
|
end
|
||||||
|
object ADOZDY: TADOQuery
|
||||||
|
Connection = DataLink_TradeManage.ADOLink
|
||||||
|
LockType = ltReadOnly
|
||||||
|
Parameters = <>
|
||||||
|
Left = 280
|
||||||
|
Top = 5
|
||||||
|
end
|
||||||
|
object CDS_ZDY: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 208
|
||||||
|
Top = 16
|
||||||
|
end
|
||||||
|
object ADOQueryTmp: TADOQuery
|
||||||
|
Connection = DataLink_TradeManage.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 744
|
||||||
|
Top = 129
|
||||||
|
end
|
||||||
|
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||||
|
Grid = cxGrid1
|
||||||
|
PopupMenus = <>
|
||||||
|
Left = 528
|
||||||
|
Top = 97
|
||||||
|
end
|
||||||
|
end
|
1266
管理系统/U_ClothContractInPut_Dp.pas
Normal file
1266
管理系统/U_ClothContractInPut_Dp.pas
Normal file
File diff suppressed because it is too large
Load Diff
|
@ -1,6 +1,6 @@
|
||||||
object frmClothContractInPut_Tp: TfrmClothContractInPut_Tp
|
object frmClothContractInPut_Tp: TfrmClothContractInPut_Tp
|
||||||
Left = 213
|
Left = 265
|
||||||
Top = 163
|
Top = 346
|
||||||
Width = 1030
|
Width = 1030
|
||||||
Height = 478
|
Height = 478
|
||||||
Caption = #22383#24067#25237#22383
|
Caption = #22383#24067#25237#22383
|
||||||
|
@ -214,6 +214,32 @@ object frmClothContractInPut_Tp: TfrmClothContractInPut_Tp
|
||||||
Font.Style = [fsBold]
|
Font.Style = [fsBold]
|
||||||
ParentFont = False
|
ParentFont = False
|
||||||
end
|
end
|
||||||
|
object Label12: TLabel
|
||||||
|
Left = 506
|
||||||
|
Top = 35
|
||||||
|
Width = 66
|
||||||
|
Height = 12
|
||||||
|
Caption = #19994' '#21153' '#21592#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label14: TLabel
|
||||||
|
Left = 723
|
||||||
|
Top = 13
|
||||||
|
Width = 67
|
||||||
|
Height = 12
|
||||||
|
Caption = #23458' '#25143#65306
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
object ConNo: TEdit
|
object ConNo: TEdit
|
||||||
Left = 86
|
Left = 86
|
||||||
Top = 11
|
Top = 11
|
||||||
|
@ -383,6 +409,25 @@ object frmClothContractInPut_Tp: TfrmClothContractInPut_Tp
|
||||||
Height = 18
|
Height = 18
|
||||||
TabOrder = 11
|
TabOrder = 11
|
||||||
end
|
end
|
||||||
|
object OrdPerson1: TBtnEditA
|
||||||
|
Tag = 2
|
||||||
|
Left = 572
|
||||||
|
Top = 34
|
||||||
|
Width = 137
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 12
|
||||||
|
OnBtnClick = OrdPerson1BtnClick
|
||||||
|
end
|
||||||
|
object CustomerNoName: TBtnEditC
|
||||||
|
Tag = 2
|
||||||
|
Left = 786
|
||||||
|
Top = 9
|
||||||
|
Width = 140
|
||||||
|
Height = 20
|
||||||
|
Hint = 'CustomerNo'
|
||||||
|
TabOrder = 13
|
||||||
|
OnBtnUpClick = CustomerNoNameBtnUpClick
|
||||||
|
end
|
||||||
end
|
end
|
||||||
object ToolBar2: TToolBar
|
object ToolBar2: TToolBar
|
||||||
Left = 0
|
Left = 0
|
||||||
|
@ -472,12 +517,20 @@ object frmClothContractInPut_Tp: TfrmClothContractInPut_Tp
|
||||||
Styles.Header = DataLink_TradeManage.handBlack
|
Styles.Header = DataLink_TradeManage.handBlack
|
||||||
Width = 103
|
Width = 103
|
||||||
end
|
end
|
||||||
|
object Tv1Column3: TcxGridDBColumn
|
||||||
|
Caption = #33394#21495
|
||||||
|
DataBinding.FieldName = 'C_ColorNo'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
object v1C_Color: TcxGridDBColumn
|
object v1C_Color: TcxGridDBColumn
|
||||||
Caption = #39068#33394
|
Caption = #39068#33394
|
||||||
DataBinding.FieldName = 'C_Color'
|
DataBinding.FieldName = 'C_Color'
|
||||||
PropertiesClassName = 'TcxTextEditProperties'
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
Properties.OnEditValueChanged = v1C_ColorPropertiesEditValueChanged
|
Properties.OnEditValueChanged = v1C_ColorPropertiesEditValueChanged
|
||||||
HeaderAlignmentHorz = taCenter
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
Width = 60
|
Width = 60
|
||||||
end
|
end
|
||||||
object v1PRTColor: TcxGridDBColumn
|
object v1PRTColor: TcxGridDBColumn
|
||||||
|
@ -551,6 +604,18 @@ object frmClothContractInPut_Tp: TfrmClothContractInPut_Tp
|
||||||
Styles.Header = DataLink_TradeManage.Default
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
Width = 137
|
Width = 137
|
||||||
end
|
end
|
||||||
|
object Tv1Column1: TcxGridDBColumn
|
||||||
|
Caption = #21152#24037#35201#27714
|
||||||
|
DataBinding.FieldName = 'JGnote'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 80
|
||||||
|
end
|
||||||
|
object Tv1Column2: TcxGridDBColumn
|
||||||
|
Caption = #21518#22788#29702#26041#24335
|
||||||
|
DataBinding.FieldName = 'HCL'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 80
|
||||||
|
end
|
||||||
end
|
end
|
||||||
object cxGrid1Level1: TcxGridLevel
|
object cxGrid1Level1: TcxGridLevel
|
||||||
GridView = Tv1
|
GridView = Tv1
|
||||||
|
|
|
@ -10,7 +10,20 @@ uses
|
||||||
cxGrid, cxMemo, cxRichEdit, ComCtrls, cxContainer, cxMaskEdit, cxButtonEdit,
|
cxGrid, cxMemo, cxRichEdit, ComCtrls, cxContainer, cxMaskEdit, cxButtonEdit,
|
||||||
StdCtrls, ToolWin, DBClient, ADODB, ExtCtrls, BtnEdit, cxDropDownEdit,
|
StdCtrls, ToolWin, DBClient, ADODB, ExtCtrls, BtnEdit, cxDropDownEdit,
|
||||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels, cxLookAndFeelPainters,
|
cxGridCustomPopupMenu, cxGridPopupMenu, cxLookAndFeels, cxLookAndFeelPainters,
|
||||||
cxNavigator;
|
cxNavigator, dxSkinsCore, dxSkinBlack, dxSkinBlue, dxSkinBlueprint,
|
||||||
|
dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom, dxSkinDarkSide,
|
||||||
|
dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle, dxSkinFoggy,
|
||||||
|
dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian,
|
||||||
|
dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis,
|
||||||
|
dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black,
|
||||||
|
dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
|
||||||
|
dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue,
|
||||||
|
dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, dxSkinOffice2013LightGray,
|
||||||
|
dxSkinOffice2013White, dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic,
|
||||||
|
dxSkinSharp, dxSkinSharpPlus, dxSkinSilver, dxSkinSpringTime, dxSkinStardust,
|
||||||
|
dxSkinSummer2008, dxSkinTheAsphaltWorld, dxSkinsDefaultPainters,
|
||||||
|
dxSkinValentine, dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue,
|
||||||
|
dxSkinscxPCPainter;
|
||||||
|
|
||||||
type
|
type
|
||||||
TfrmClothContractInPut_Tp = class(TForm)
|
TfrmClothContractInPut_Tp = class(TForm)
|
||||||
|
@ -75,6 +88,13 @@ type
|
||||||
Label22: TLabel;
|
Label22: TLabel;
|
||||||
Label23: TLabel;
|
Label23: TLabel;
|
||||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||||
|
Label12: TLabel;
|
||||||
|
OrdPerson1: TBtnEditA;
|
||||||
|
Label14: TLabel;
|
||||||
|
CustomerNoName: TBtnEditC;
|
||||||
|
Tv1Column1: TcxGridDBColumn;
|
||||||
|
Tv1Column2: TcxGridDBColumn;
|
||||||
|
Tv1Column3: TcxGridDBColumn;
|
||||||
procedure TBCloseClick(Sender: TObject);
|
procedure TBCloseClick(Sender: TObject);
|
||||||
procedure TVZDYCellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
procedure TVZDYCellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||||
procedure Button1Click(Sender: TObject);
|
procedure Button1Click(Sender: TObject);
|
||||||
|
@ -103,6 +123,8 @@ type
|
||||||
procedure v1C_ColorPropertiesEditValueChanged(Sender: TObject);
|
procedure v1C_ColorPropertiesEditValueChanged(Sender: TObject);
|
||||||
procedure FormCreate(Sender: TObject);
|
procedure FormCreate(Sender: TObject);
|
||||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
|
procedure OrdPerson1BtnClick(Sender: TObject);
|
||||||
|
procedure CustomerNoNameBtnUpClick(Sender: TObject);
|
||||||
private
|
private
|
||||||
FXS: Integer;
|
FXS: Integer;
|
||||||
procedure InitData();
|
procedure InitData();
|
||||||
|
@ -126,7 +148,7 @@ implementation
|
||||||
|
|
||||||
uses
|
uses
|
||||||
U_DataLink, U_ZDYHelp, U_Fun, U_ZdyAttachGYS, U_ClothContractList_help,
|
U_DataLink, U_ZDYHelp, U_Fun, U_ZdyAttachGYS, U_ClothContractList_help,
|
||||||
U_ZdyAttachCP;
|
U_UserHelp, U_ZdyAttachCP;
|
||||||
|
|
||||||
{$R *.dfm}
|
{$R *.dfm}
|
||||||
procedure TfrmClothContractInPut_Tp.DoKc();
|
procedure TfrmClothContractInPut_Tp.DoKc();
|
||||||
|
@ -691,7 +713,7 @@ begin
|
||||||
end; }
|
end; }
|
||||||
with ADOTemp do
|
with ADOTemp do
|
||||||
begin
|
begin
|
||||||
close;
|
close;
|
||||||
sql.Clear;
|
sql.Clear;
|
||||||
sql.Add('select * from KH_Zdy_Attachment A where Type=''GYS''');
|
sql.Add('select * from KH_Zdy_Attachment A where Type=''GYS''');
|
||||||
sql.Add('and zdyName=''' + trim(FactoryNoName.text) + ''' ');
|
sql.Add('and zdyName=''' + trim(FactoryNoName.text) + ''' ');
|
||||||
|
@ -859,7 +881,7 @@ begin
|
||||||
Self.Order_Sub.FieldByName('C_Code').Value := Trim(CDS_HZ.fieldbyname('ZdyCode').AsString);
|
Self.Order_Sub.FieldByName('C_Code').Value := Trim(CDS_HZ.fieldbyname('ZdyCode').AsString);
|
||||||
Self.Order_Sub.FieldByName('C_CodeName').Value := Trim(CDS_HZ.fieldbyname('ZDYName').AsString);
|
Self.Order_Sub.FieldByName('C_CodeName').Value := Trim(CDS_HZ.fieldbyname('ZDYName').AsString);
|
||||||
Self.Order_Sub.FieldByName('C_Color').Value := Trim(CDS_HZ.fieldbyname('DEFstr3').AsString);
|
Self.Order_Sub.FieldByName('C_Color').Value := Trim(CDS_HZ.fieldbyname('DEFstr3').AsString);
|
||||||
// Self.Order_Sub.FieldByName('SOrddefstr4').Value:=Trim(ClientDataSet1.fieldbyname('Note').AsString);
|
Self.Order_Sub.FieldByName('C_ColorNo').Value := Trim(CDS_HZ.fieldbyname('DEFstr10').AsString);
|
||||||
Self.Order_Sub.Post;
|
Self.Order_Sub.Post;
|
||||||
|
|
||||||
end;
|
end;
|
||||||
|
@ -1231,5 +1253,39 @@ begin
|
||||||
writeCXgrid(self.Caption, tv1);
|
writeCXgrid(self.Caption, tv1);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractInPut_Tp.OrdPerson1BtnClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
frmUserHelp := TfrmUserHelp.create(self);
|
||||||
|
with frmUserHelp do
|
||||||
|
begin
|
||||||
|
if showmodal = 1 then
|
||||||
|
begin
|
||||||
|
OrdPerson1.Text := trim(ADOQueryHelp.fieldbyname('UserName').AsString);
|
||||||
|
end;
|
||||||
|
free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractInPut_Tp.CustomerNoNameBtnUpClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
try
|
||||||
|
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||||
|
with frmZDYHelp do
|
||||||
|
begin
|
||||||
|
flag := 'KHName';
|
||||||
|
flagname := '¿Í»§Ãû³Æ';
|
||||||
|
if Trim(DParameters1) <> '¸ßȨÏÞ' then
|
||||||
|
MainType := Trim(DName);
|
||||||
|
if ShowModal = 1 then
|
||||||
|
begin
|
||||||
|
CustomerNoName.Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||||
|
CustomerNoName.TxtCode := Trim(ClientDataSet1.fieldbyname('ZDYNo').AsString);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
finally
|
||||||
|
frmZDYHelp.Free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
|
|
|
@ -68,6 +68,7 @@ object frmClothContractList: TfrmClothContractList
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #20462#25913
|
Caption = #20462#25913
|
||||||
ImageIndex = 54
|
ImageIndex = 54
|
||||||
|
Visible = False
|
||||||
OnClick = TBEditClick
|
OnClick = TBEditClick
|
||||||
end
|
end
|
||||||
object TBDel: TToolButton
|
object TBDel: TToolButton
|
||||||
|
|
|
@ -11,7 +11,20 @@ uses
|
||||||
cxGrid, DBClient, cxCalendar, cxButtonEdit, cxSplitter, RM_Common, RM_Class,
|
cxGrid, DBClient, cxCalendar, cxButtonEdit, cxSplitter, RM_Common, RM_Class,
|
||||||
RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, cxTextEdit, cxPC, cxCheckBox,
|
RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, cxTextEdit, cxPC, cxCheckBox,
|
||||||
cxCurrencyEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator,
|
cxCurrencyEdit, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator,
|
||||||
dxBarBuiltInMenu;
|
dxBarBuiltInMenu, dxSkinsCore, dxSkinBlack, dxSkinBlue, dxSkinBlueprint,
|
||||||
|
dxSkinCaramel, dxSkinCoffee, dxSkinDarkRoom, dxSkinDarkSide,
|
||||||
|
dxSkinDevExpressDarkStyle, dxSkinDevExpressStyle, dxSkinFoggy,
|
||||||
|
dxSkinGlassOceans, dxSkinHighContrast, dxSkiniMaginary, dxSkinLilian,
|
||||||
|
dxSkinLiquidSky, dxSkinLondonLiquidSky, dxSkinMcSkin, dxSkinMetropolis,
|
||||||
|
dxSkinMetropolisDark, dxSkinMoneyTwins, dxSkinOffice2007Black,
|
||||||
|
dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
|
||||||
|
dxSkinOffice2007Silver, dxSkinOffice2010Black, dxSkinOffice2010Blue,
|
||||||
|
dxSkinOffice2010Silver, dxSkinOffice2013DarkGray, dxSkinOffice2013LightGray,
|
||||||
|
dxSkinOffice2013White, dxSkinPumpkin, dxSkinSeven, dxSkinSevenClassic,
|
||||||
|
dxSkinSharp, dxSkinSharpPlus, dxSkinSilver, dxSkinSpringTime, dxSkinStardust,
|
||||||
|
dxSkinSummer2008, dxSkinTheAsphaltWorld, dxSkinsDefaultPainters,
|
||||||
|
dxSkinValentine, dxSkinVS2010, dxSkinWhiteprint, dxSkinXmas2008Blue,
|
||||||
|
dxSkinscxPCPainter;
|
||||||
|
|
||||||
type
|
type
|
||||||
TfrmClothContractList = class(TForm)
|
TfrmClothContractList = class(TForm)
|
||||||
|
@ -188,7 +201,7 @@ begin
|
||||||
with ADOQueryMain do
|
with ADOQueryMain do
|
||||||
begin
|
begin
|
||||||
Filtered := False;
|
Filtered := False;
|
||||||
Close;
|
Close;
|
||||||
sql.Clear;
|
sql.Clear;
|
||||||
sql.Add('exec P_Get_Contract');
|
sql.Add('exec P_Get_Contract');
|
||||||
sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||||
|
@ -196,7 +209,6 @@ begin
|
||||||
sql.Add(',@conType=''Å÷²¼µ½»õ'' ');
|
sql.Add(',@conType=''Å÷²¼µ½»õ'' ');
|
||||||
sql.Add(',@status=''' + inttostr(cxTabControl1.TabIndex) + ''' ');
|
sql.Add(',@status=''' + inttostr(cxTabControl1.TabIndex) + ''' ');
|
||||||
// ShowMessage(SQL.text);
|
// ShowMessage(SQL.text);
|
||||||
|
|
||||||
{ sql.Add('select *,fromConNo=(select Top 1 conNo from Contract_Main X where X.MainID=A.fromMainID) ');
|
{ sql.Add('select *,fromConNo=(select Top 1 conNo from Contract_Main X where X.MainID=A.fromMainID) ');
|
||||||
sql.Add('from Contract_Main A');
|
sql.Add('from Contract_Main A');
|
||||||
sql.Add('inner join Contract_sub B on B.MainID=A.mainID ');
|
sql.Add('inner join Contract_sub B on B.MainID=A.mainID ');
|
||||||
|
@ -241,7 +253,7 @@ begin
|
||||||
Tth.Enabled := false;
|
Tth.Enabled := false;
|
||||||
if cxTabControl1.TabIndex = 0 then
|
if cxTabControl1.TabIndex = 0 then
|
||||||
begin
|
begin
|
||||||
TBEdit.Enabled := true;
|
// TBEdit.Enabled := true;
|
||||||
TBDel.Enabled := true;
|
TBDel.Enabled := true;
|
||||||
Tchk.Enabled := true;
|
Tchk.Enabled := true;
|
||||||
Tth.Enabled := true;
|
Tth.Enabled := true;
|
||||||
|
@ -282,7 +294,7 @@ begin
|
||||||
exit;
|
exit;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
// with ADOQueryTemp do
|
// with ADOQueryTemp do
|
||||||
// begin
|
// begin
|
||||||
// close;
|
// close;
|
||||||
// sql.Clear;
|
// sql.Clear;
|
||||||
|
@ -804,7 +816,7 @@ begin
|
||||||
if Order_Main.IsEmpty then
|
if Order_Main.IsEmpty then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
try
|
{ try
|
||||||
frmClothContractInPut := TfrmClothContractInPut.Create(Application);
|
frmClothContractInPut := TfrmClothContractInPut.Create(Application);
|
||||||
with frmClothContractInPut do
|
with frmClothContractInPut do
|
||||||
begin
|
begin
|
||||||
|
@ -830,33 +842,31 @@ begin
|
||||||
finally
|
finally
|
||||||
frmClothContractInPut.Free;
|
frmClothContractInPut.Free;
|
||||||
// TBRafresh.Click;
|
// TBRafresh.Click;
|
||||||
end;
|
end; }
|
||||||
|
|
||||||
{ if Order_Main.Locate('ssel',true,[])=false then
|
if Order_Main.Locate('ssel', true, []) = false then
|
||||||
begin
|
begin
|
||||||
Application.MessageBox('没有选择数据!','提示',0);
|
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||||
Exit;
|
Exit;
|
||||||
end;
|
end;
|
||||||
try
|
try
|
||||||
ADOQueryCmd.Connection.BeginTrans;
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
|
||||||
|
with Order_Main do
|
||||||
|
|
||||||
{ with Order_Main do
|
|
||||||
begin
|
begin
|
||||||
DisableControls;
|
DisableControls;
|
||||||
First;
|
First;
|
||||||
while not eof do
|
while not eof do
|
||||||
begin
|
begin
|
||||||
IF Fieldbyname('ssel').AsBoolean then
|
if Fieldbyname('ssel').AsBoolean then
|
||||||
begin
|
begin
|
||||||
with ADOQueryCmd do
|
with ADOQueryCmd do
|
||||||
begin
|
begin
|
||||||
close;
|
close;
|
||||||
sql.Clear;
|
sql.Clear;
|
||||||
sql.Add('update Contract_sub SET C_status=''1'' ');
|
sql.Add('update Contract_sub SET C_status=''1'' ');
|
||||||
sql.Add('where mainID ='+quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
sql.Add('and subID ='+quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
execsql;
|
execsql;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
@ -870,22 +880,22 @@ begin
|
||||||
ADOQueryCmd.Connection.CommitTrans;
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
except
|
except
|
||||||
ADOQueryCmd.Connection.RollbackTrans;
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
application.MessageBox('操作失败!','提示信息',0);
|
application.MessageBox('操作失败!', '提示信息', 0);
|
||||||
end; }
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfrmClothContractList.TnochkClick(Sender: TObject);
|
procedure TfrmClothContractList.TnochkClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
if Order_Main.IsEmpty then
|
if Order_Main.IsEmpty then
|
||||||
exit;
|
exit;
|
||||||
{ if Order_Main.Locate('ssel',true,[])=false then
|
if Order_Main.Locate('ssel', true, []) = false then
|
||||||
begin
|
begin
|
||||||
Application.MessageBox('没有选择数据!','提示',0);
|
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||||
Exit;
|
Exit;
|
||||||
end; }
|
end;
|
||||||
try
|
try
|
||||||
ADOQueryCmd.Connection.BeginTrans;
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
with ADOQueryCmd do
|
{with ADOQueryCmd do
|
||||||
begin
|
begin
|
||||||
close;
|
close;
|
||||||
sql.Clear;
|
sql.Clear;
|
||||||
|
@ -893,22 +903,22 @@ begin
|
||||||
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
execsql;
|
execsql;
|
||||||
end;
|
end; }
|
||||||
{ with Order_Main do
|
with Order_Main do
|
||||||
begin
|
begin
|
||||||
DisableControls;
|
DisableControls;
|
||||||
First;
|
First;
|
||||||
while not eof do
|
while not eof do
|
||||||
begin
|
begin
|
||||||
IF Fieldbyname('ssel').AsBoolean then
|
if Fieldbyname('ssel').AsBoolean then
|
||||||
begin
|
begin
|
||||||
with ADOQueryCmd do
|
with ADOQueryCmd do
|
||||||
begin
|
begin
|
||||||
close;
|
close;
|
||||||
sql.Clear;
|
sql.Clear;
|
||||||
sql.Add('update Contract_sub SET C_status=''0'' ');
|
sql.Add('update Contract_sub SET C_status=''0'' ');
|
||||||
sql.Add('where mainID ='+quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
sql.Add('and subID ='+quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
execsql;
|
execsql;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
@ -916,7 +926,7 @@ begin
|
||||||
end;
|
end;
|
||||||
First;
|
First;
|
||||||
EnableControls;
|
EnableControls;
|
||||||
end; }
|
end;
|
||||||
|
|
||||||
InitGrid();
|
InitGrid();
|
||||||
ADOQueryCmd.Connection.CommitTrans;
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
|
823
管理系统/U_ClothContractList_Dp.dfm
Normal file
823
管理系统/U_ClothContractList_Dp.dfm
Normal file
|
@ -0,0 +1,823 @@
|
||||||
|
object frmClothContractList_Dp: TfrmClothContractList_Dp
|
||||||
|
Left = 417
|
||||||
|
Top = 396
|
||||||
|
Width = 1222
|
||||||
|
Height = 663
|
||||||
|
Caption = #22383#24067#35843#25320#20449#24687
|
||||||
|
Color = clBtnFace
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
OldCreateOrder = False
|
||||||
|
OnClose = FormClose
|
||||||
|
OnCreate = FormCreate
|
||||||
|
OnDestroy = FormDestroy
|
||||||
|
OnShow = FormShow
|
||||||
|
PixelsPerInch = 96
|
||||||
|
TextHeight = 12
|
||||||
|
object ToolBar1: TToolBar
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
Width = 1206
|
||||||
|
AutoSize = True
|
||||||
|
ButtonHeight = 30
|
||||||
|
ButtonWidth = 83
|
||||||
|
Caption = 'ToolBar1'
|
||||||
|
Color = clSkyBlue
|
||||||
|
Flat = True
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
Images = DataLink_TradeManage.ThreeImgList
|
||||||
|
List = True
|
||||||
|
ParentColor = False
|
||||||
|
ParentFont = False
|
||||||
|
ShowCaptions = True
|
||||||
|
TabOrder = 0
|
||||||
|
object TBRafresh: TToolButton
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21047#26032
|
||||||
|
ImageIndex = 2
|
||||||
|
OnClick = TBRafreshClick
|
||||||
|
end
|
||||||
|
object TBFind: TToolButton
|
||||||
|
Left = 63
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #36807#28388
|
||||||
|
ImageIndex = 59
|
||||||
|
OnClick = TBFindClick
|
||||||
|
end
|
||||||
|
object TBAdd: TToolButton
|
||||||
|
Left = 126
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #26032#22686
|
||||||
|
ImageIndex = 3
|
||||||
|
OnClick = TBAddClick
|
||||||
|
end
|
||||||
|
object TJj: TToolButton
|
||||||
|
Left = 189
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21152#24613
|
||||||
|
ImageIndex = 60
|
||||||
|
OnClick = TJjClick
|
||||||
|
end
|
||||||
|
object TnoJj: TToolButton
|
||||||
|
Left = 252
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #25764#38144#21152#24613
|
||||||
|
ImageIndex = 99
|
||||||
|
OnClick = TnoJjClick
|
||||||
|
end
|
||||||
|
object ToolButton2: TToolButton
|
||||||
|
Left = 339
|
||||||
|
Top = 0
|
||||||
|
Caption = #22238#20462#26032#22686
|
||||||
|
ImageIndex = 57
|
||||||
|
Visible = False
|
||||||
|
OnClick = ToolButton2Click
|
||||||
|
end
|
||||||
|
object TBEdit: TToolButton
|
||||||
|
Left = 422
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20462#25913
|
||||||
|
ImageIndex = 54
|
||||||
|
OnClick = TBEditClick
|
||||||
|
end
|
||||||
|
object TBDel: TToolButton
|
||||||
|
Left = 485
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21024#38500
|
||||||
|
ImageIndex = 17
|
||||||
|
OnClick = TBDelClick
|
||||||
|
end
|
||||||
|
object Tchk: TToolButton
|
||||||
|
Left = 548
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #30830#35748#23436#25104
|
||||||
|
ImageIndex = 41
|
||||||
|
OnClick = TchkClick
|
||||||
|
end
|
||||||
|
object TNochk: TToolButton
|
||||||
|
Left = 635
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #25764#38144#23436#25104
|
||||||
|
ImageIndex = 48
|
||||||
|
OnClick = TNochkClick
|
||||||
|
end
|
||||||
|
object ToolButton1: TToolButton
|
||||||
|
Left = 722
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #26597#30475
|
||||||
|
ImageIndex = 58
|
||||||
|
OnClick = ToolButton1Click
|
||||||
|
end
|
||||||
|
object TBExport: TToolButton
|
||||||
|
Left = 785
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #23548#20986
|
||||||
|
ImageIndex = 75
|
||||||
|
OnClick = TBExportClick
|
||||||
|
end
|
||||||
|
object TBPrint: TToolButton
|
||||||
|
Left = 848
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #25171#21360
|
||||||
|
ImageIndex = 12
|
||||||
|
OnClick = TBPrintClick
|
||||||
|
end
|
||||||
|
object TBClose: TToolButton
|
||||||
|
Left = 911
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #20851#38381
|
||||||
|
ImageIndex = 55
|
||||||
|
OnClick = TBCloseClick
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object Panel1: TPanel
|
||||||
|
Left = 0
|
||||||
|
Top = 32
|
||||||
|
Width = 1206
|
||||||
|
Height = 53
|
||||||
|
Align = alTop
|
||||||
|
BevelInner = bvRaised
|
||||||
|
BevelOuter = bvLowered
|
||||||
|
Color = clSkyBlue
|
||||||
|
TabOrder = 1
|
||||||
|
object Label1: TLabel
|
||||||
|
Left = 23
|
||||||
|
Top = 22
|
||||||
|
Width = 52
|
||||||
|
Height = 12
|
||||||
|
Caption = #30331#35760#26085#26399
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label2: TLabel
|
||||||
|
Left = 161
|
||||||
|
Top = 22
|
||||||
|
Width = 6
|
||||||
|
Height = 12
|
||||||
|
Caption = '-'
|
||||||
|
end
|
||||||
|
object Label3: TLabel
|
||||||
|
Left = 271
|
||||||
|
Top = 22
|
||||||
|
Width = 52
|
||||||
|
Height = 12
|
||||||
|
Caption = #25237#22383#21333#21495
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label5: TLabel
|
||||||
|
Left = 420
|
||||||
|
Top = 22
|
||||||
|
Width = 52
|
||||||
|
Height = 12
|
||||||
|
Caption = #20135#21697#21517#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 = 572
|
||||||
|
Top = 22
|
||||||
|
Width = 26
|
||||||
|
Height = 12
|
||||||
|
Caption = #39068#33394
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object Label6: TLabel
|
||||||
|
Left = 704
|
||||||
|
Top = 22
|
||||||
|
Width = 39
|
||||||
|
Height = 12
|
||||||
|
Caption = #21152#24037#21378
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
ParentFont = False
|
||||||
|
end
|
||||||
|
object BegDate: TDateTimePicker
|
||||||
|
Left = 76
|
||||||
|
Top = 18
|
||||||
|
Width = 85
|
||||||
|
Height = 20
|
||||||
|
Date = 40675.464742650460000000
|
||||||
|
Format = 'yyyy-MM-dd'
|
||||||
|
Time = 40675.464742650460000000
|
||||||
|
TabOrder = 0
|
||||||
|
end
|
||||||
|
object EndDate: TDateTimePicker
|
||||||
|
Left = 167
|
||||||
|
Top = 18
|
||||||
|
Width = 86
|
||||||
|
Height = 20
|
||||||
|
Date = 40675.464761099540000000
|
||||||
|
Format = 'yyyy-MM-dd'
|
||||||
|
Time = 40675.464761099540000000
|
||||||
|
TabOrder = 1
|
||||||
|
end
|
||||||
|
object ConNo: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 329
|
||||||
|
Top = 18
|
||||||
|
Width = 81
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 2
|
||||||
|
OnChange = ConNoChange
|
||||||
|
end
|
||||||
|
object C_CodeName: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 473
|
||||||
|
Top = 18
|
||||||
|
Width = 83
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 3
|
||||||
|
OnChange = ConNoChange
|
||||||
|
end
|
||||||
|
object C_Color: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 600
|
||||||
|
Top = 18
|
||||||
|
Width = 83
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 4
|
||||||
|
OnChange = ConNoChange
|
||||||
|
end
|
||||||
|
object FactoryNoName: TEdit
|
||||||
|
Tag = 2
|
||||||
|
Left = 748
|
||||||
|
Top = 18
|
||||||
|
Width = 80
|
||||||
|
Height = 20
|
||||||
|
TabOrder = 5
|
||||||
|
OnChange = ConNoChange
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object ScrollBox1: TScrollBox
|
||||||
|
Left = 0
|
||||||
|
Top = 107
|
||||||
|
Width = 1206
|
||||||
|
Height = 497
|
||||||
|
Align = alTop
|
||||||
|
BorderStyle = bsNone
|
||||||
|
TabOrder = 2
|
||||||
|
object cxGrid1: TcxGrid
|
||||||
|
Left = 0
|
||||||
|
Top = 0
|
||||||
|
Width = 1206
|
||||||
|
Height = 497
|
||||||
|
Align = alClient
|
||||||
|
TabOrder = 0
|
||||||
|
object Tv1: TcxGridDBTableView
|
||||||
|
OnMouseDown = Tv1MouseDown
|
||||||
|
Navigator.Buttons.CustomButtons = <>
|
||||||
|
OnCellDblClick = Tv1CellDblClick
|
||||||
|
OnCustomDrawCell = Tv1CustomDrawCell
|
||||||
|
DataController.DataSource = DataSource1
|
||||||
|
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||||
|
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||||
|
DataController.Summary.FooterSummaryItems = <
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = v1PRTOrderQty
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = v1Column9
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = v1Qty2
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
Column = v1Qty1
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Kind = skSum
|
||||||
|
end>
|
||||||
|
DataController.Summary.SummaryGroups = <>
|
||||||
|
OptionsCustomize.ColumnFiltering = False
|
||||||
|
OptionsData.Deleting = False
|
||||||
|
OptionsView.Footer = True
|
||||||
|
OptionsView.GroupByBox = False
|
||||||
|
OptionsView.Indicator = True
|
||||||
|
OptionsView.IndicatorWidth = 20
|
||||||
|
Styles.Inactive = DataLink_TradeManage.SHuangSe
|
||||||
|
Styles.IncSearch = DataLink_TradeManage.SHuangSe
|
||||||
|
Styles.Selection = DataLink_TradeManage.SHuangSe
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
OnCustomDrawIndicatorCell = Tv1CustomDrawIndicatorCell
|
||||||
|
object v1Ssel: TcxGridDBColumn
|
||||||
|
Caption = #36873#25321
|
||||||
|
DataBinding.FieldName = 'Ssel'
|
||||||
|
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||||
|
Properties.ImmediatePost = True
|
||||||
|
Properties.NullStyle = nssUnchecked
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 50
|
||||||
|
end
|
||||||
|
object v1OrderNo: TcxGridDBColumn
|
||||||
|
Caption = #25237#22383#21333#21495
|
||||||
|
DataBinding.FieldName = 'ConNo'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 65
|
||||||
|
end
|
||||||
|
object v1DeliveryDate: TcxGridDBColumn
|
||||||
|
Caption = #25237#22383#26085#26399
|
||||||
|
DataBinding.FieldName = 'DeliveryDate'
|
||||||
|
PropertiesClassName = 'TcxDateEditProperties'
|
||||||
|
Properties.SaveTime = False
|
||||||
|
Properties.ShowTime = False
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 70
|
||||||
|
end
|
||||||
|
object v1Column2: TcxGridDBColumn
|
||||||
|
Caption = #20135#21697#21517#31216
|
||||||
|
DataBinding.FieldName = 'C_CodeName'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 73
|
||||||
|
end
|
||||||
|
object v1Column5: TcxGridDBColumn
|
||||||
|
Caption = #31614#35746#26085#26399
|
||||||
|
DataBinding.FieldName = 'QDTime'
|
||||||
|
Visible = False
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 70
|
||||||
|
end
|
||||||
|
object v1FactoryNo1Name: TcxGridDBColumn
|
||||||
|
Caption = #21152#24037#21378
|
||||||
|
DataBinding.FieldName = 'FactoryNoName'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object v1PRTSpec: TcxGridDBColumn
|
||||||
|
Caption = #35268#26684
|
||||||
|
DataBinding.FieldName = 'C_Spec'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 66
|
||||||
|
end
|
||||||
|
object v1C_Color: TcxGridDBColumn
|
||||||
|
Caption = #39068#33394
|
||||||
|
DataBinding.FieldName = 'C_Color'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object v1PRTMF: TcxGridDBColumn
|
||||||
|
Caption = #38376#24133'(cm)'
|
||||||
|
DataBinding.FieldName = 'MFQty'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 61
|
||||||
|
end
|
||||||
|
object v1PRTKZ: TcxGridDBColumn
|
||||||
|
Caption = #20811#37325'(g/'#13217')'
|
||||||
|
DataBinding.FieldName = 'KZQty'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 83
|
||||||
|
end
|
||||||
|
object v1Qty2: TcxGridDBColumn
|
||||||
|
Caption = #32568#25968
|
||||||
|
DataBinding.FieldName = 'Qty2'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Content = cxStyle_fontclBlue
|
||||||
|
Styles.Footer = cxStyle_fontclBlue
|
||||||
|
Styles.Header = cxStyle_fontclBlue
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object v1Qty1: TcxGridDBColumn
|
||||||
|
Caption = #21305#25968
|
||||||
|
DataBinding.FieldName = 'Qty1'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Content = cxStyle_fontclBlue
|
||||||
|
Styles.Footer = cxStyle_fontclBlue
|
||||||
|
Styles.Header = cxStyle_fontclBlue
|
||||||
|
Width = 46
|
||||||
|
end
|
||||||
|
object v1PRTOrderQty: TcxGridDBColumn
|
||||||
|
Caption = #25968#37327
|
||||||
|
DataBinding.FieldName = 'C_Qty'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Content = cxStyle_fontclBlue
|
||||||
|
Styles.Footer = cxStyle_fontclBlue
|
||||||
|
Styles.Header = cxStyle_fontclBlue
|
||||||
|
Width = 58
|
||||||
|
end
|
||||||
|
object v1OrderUnit: TcxGridDBColumn
|
||||||
|
Caption = #21333#20301
|
||||||
|
DataBinding.FieldName = 'C_Unit'
|
||||||
|
Visible = False
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 47
|
||||||
|
end
|
||||||
|
object v1C_Unit: TcxGridDBColumn
|
||||||
|
Caption = #25968#37327#21333#20301
|
||||||
|
DataBinding.FieldName = 'C_Unit'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object v1Column4: TcxGridDBColumn
|
||||||
|
Caption = #22791#27880
|
||||||
|
DataBinding.FieldName = 'C_Note'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 68
|
||||||
|
end
|
||||||
|
object v1Column3: TcxGridDBColumn
|
||||||
|
Caption = #32852#31995#20154
|
||||||
|
DataBinding.FieldName = 'LXPerson'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 63
|
||||||
|
end
|
||||||
|
object v1Column6: TcxGridDBColumn
|
||||||
|
Caption = #32852#31995#26041#24335
|
||||||
|
DataBinding.FieldName = 'LXTel'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
|
Width = 63
|
||||||
|
end
|
||||||
|
object v1Column9: TcxGridDBColumn
|
||||||
|
Caption = #26410#23436#25104#25968#37327
|
||||||
|
DataBinding.FieldName = 'N_Qty'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Styles.Content = cxStyle_fontclFuchsia
|
||||||
|
Styles.Footer = cxStyle_fontclFuchsia
|
||||||
|
Styles.Header = cxStyle_fontclFuchsia
|
||||||
|
Width = 70
|
||||||
|
end
|
||||||
|
object v1Column10: TcxGridDBColumn
|
||||||
|
Caption = #21046#21333#20154
|
||||||
|
DataBinding.FieldName = 'Filler'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object v1Column11: TcxGridDBColumn
|
||||||
|
Caption = #21046#21333#26102#38388
|
||||||
|
DataBinding.FieldName = 'FillTime'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 80
|
||||||
|
end
|
||||||
|
object v1Column12: TcxGridDBColumn
|
||||||
|
Caption = #20462#25913#20154
|
||||||
|
DataBinding.FieldName = 'editer'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
object v1Column13: TcxGridDBColumn
|
||||||
|
Caption = #20462#25913#26102#38388
|
||||||
|
DataBinding.FieldName = 'editTime'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Options.Editing = False
|
||||||
|
Width = 80
|
||||||
|
end
|
||||||
|
object v1Column1: TcxGridDBColumn
|
||||||
|
DataBinding.FieldName = 'IsZt'
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
|
object Tv1Column1: TcxGridDBColumn
|
||||||
|
Caption = #21152#24613
|
||||||
|
DataBinding.FieldName = 'Jiaji'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxGrid1Level1: TcxGridLevel
|
||||||
|
GridView = Tv1
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
object cxTabControl1: TcxTabControl
|
||||||
|
Left = 0
|
||||||
|
Top = 85
|
||||||
|
Width = 1206
|
||||||
|
Height = 22
|
||||||
|
Align = alTop
|
||||||
|
TabOrder = 3
|
||||||
|
Properties.CustomButtons.Buttons = <>
|
||||||
|
Properties.Style = 9
|
||||||
|
Properties.TabIndex = 0
|
||||||
|
Properties.Tabs.Strings = (
|
||||||
|
#26410#23436#25104
|
||||||
|
#24050#23436#25104
|
||||||
|
#20840#37096)
|
||||||
|
OnChange = cxTabControl1Change
|
||||||
|
ClientRectBottom = 22
|
||||||
|
ClientRectRight = 1206
|
||||||
|
ClientRectTop = 19
|
||||||
|
end
|
||||||
|
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||||
|
Grid = cxGrid1
|
||||||
|
PopupMenus = <>
|
||||||
|
Left = 1128
|
||||||
|
end
|
||||||
|
object ADOQueryCmd: TADOQuery
|
||||||
|
Connection = DataLink_TradeManage.ADOLink
|
||||||
|
Parameters = <>
|
||||||
|
Left = 936
|
||||||
|
end
|
||||||
|
object ADOQueryMain: TADOQuery
|
||||||
|
Connection = DataLink_TradeManage.ADOLink
|
||||||
|
LockType = ltReadOnly
|
||||||
|
Parameters = <>
|
||||||
|
Left = 1000
|
||||||
|
end
|
||||||
|
object ADOQueryTemp: TADOQuery
|
||||||
|
Connection = DataLink_TradeManage.ADOLink
|
||||||
|
LockType = ltReadOnly
|
||||||
|
Parameters = <>
|
||||||
|
Left = 1040
|
||||||
|
Top = 8
|
||||||
|
end
|
||||||
|
object DataSource1: TDataSource
|
||||||
|
DataSet = Order_Main
|
||||||
|
Left = 1168
|
||||||
|
Top = 8
|
||||||
|
end
|
||||||
|
object Order_Main: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 624
|
||||||
|
Top = 248
|
||||||
|
end
|
||||||
|
object ClientDataSet3: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 944
|
||||||
|
Top = 240
|
||||||
|
end
|
||||||
|
object DataSource2: TDataSource
|
||||||
|
DataSet = ClientDataSet2
|
||||||
|
Left = 888
|
||||||
|
Top = 176
|
||||||
|
end
|
||||||
|
object DataSource3: TDataSource
|
||||||
|
DataSet = ClientDataSet3
|
||||||
|
Left = 1112
|
||||||
|
Top = 216
|
||||||
|
end
|
||||||
|
object ClientDataSet2: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 924
|
||||||
|
Top = 212
|
||||||
|
end
|
||||||
|
object RM1: TRMGridReport
|
||||||
|
ThreadPrepareReport = True
|
||||||
|
InitialZoom = pzDefault
|
||||||
|
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbExport, pbNavigator]
|
||||||
|
DefaultCollate = False
|
||||||
|
SaveReportOptions.RegistryPath = 'Software\ReportMachine\ReportSettings\'
|
||||||
|
PreviewOptions.RulerUnit = rmutScreenPixels
|
||||||
|
PreviewOptions.RulerVisible = False
|
||||||
|
PreviewOptions.DrawBorder = False
|
||||||
|
PreviewOptions.BorderPen.Color = clGray
|
||||||
|
PreviewOptions.BorderPen.Style = psDash
|
||||||
|
Dataset = RMDBMain
|
||||||
|
CompressLevel = rmzcFastest
|
||||||
|
CompressThread = False
|
||||||
|
LaterBuildEvents = True
|
||||||
|
OnlyOwnerDataSet = False
|
||||||
|
Left = 352
|
||||||
|
Top = 192
|
||||||
|
ReportData = {}
|
||||||
|
end
|
||||||
|
object RMDBMain: TRMDBDataSet
|
||||||
|
Visible = True
|
||||||
|
DataSet = CDS_PRT
|
||||||
|
Left = 400
|
||||||
|
Top = 192
|
||||||
|
end
|
||||||
|
object RMXLSExport1: TRMXLSExport
|
||||||
|
ShowAfterExport = True
|
||||||
|
ExportPrecision = 1
|
||||||
|
PagesOfSheet = 1
|
||||||
|
ExportImages = True
|
||||||
|
ExportFrames = True
|
||||||
|
ExportImageFormat = ifBMP
|
||||||
|
JPEGQuality = 0
|
||||||
|
ScaleX = 1.000000000000000000
|
||||||
|
ScaleY = 1.000000000000000000
|
||||||
|
CompressFile = False
|
||||||
|
Left = 416
|
||||||
|
Top = 248
|
||||||
|
end
|
||||||
|
object CDS_PRT: TClientDataSet
|
||||||
|
Aggregates = <>
|
||||||
|
Params = <>
|
||||||
|
Left = 804
|
||||||
|
Top = 44
|
||||||
|
end
|
||||||
|
object cxStyleRepository1: TcxStyleRepository
|
||||||
|
Left = 69
|
||||||
|
Top = 130
|
||||||
|
PixelsPerInch = 96
|
||||||
|
object cxStyle1: TcxStyle
|
||||||
|
AssignedValues = [svColor]
|
||||||
|
Color = clInactiveCaption
|
||||||
|
end
|
||||||
|
object cxStyle2: TcxStyle
|
||||||
|
AssignedValues = [svColor, svTextColor]
|
||||||
|
Color = 4707838
|
||||||
|
TextColor = clBtnText
|
||||||
|
end
|
||||||
|
object cxStyle_gridRow: TcxStyle
|
||||||
|
AssignedValues = [svColor, svFont]
|
||||||
|
Color = 16311512
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
end
|
||||||
|
object cxStyle_gridFoot: TcxStyle
|
||||||
|
AssignedValues = [svFont]
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clBlack
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
end
|
||||||
|
object cxStyle_gridHead: TcxStyle
|
||||||
|
AssignedValues = [svFont]
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
end
|
||||||
|
object cxStyle_gridGroupBox: TcxStyle
|
||||||
|
AssignedValues = [svColor, svFont]
|
||||||
|
Color = clMoneyGreen
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clBlue
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
end
|
||||||
|
object cxStyle_yellow: TcxStyle
|
||||||
|
AssignedValues = [svColor, svFont]
|
||||||
|
Color = 8454143
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = []
|
||||||
|
end
|
||||||
|
object cxStyle_Red: TcxStyle
|
||||||
|
AssignedValues = [svColor, svFont]
|
||||||
|
Color = clRed
|
||||||
|
Font.Charset = DEFAULT_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -11
|
||||||
|
Font.Name = 'MS Sans Serif'
|
||||||
|
Font.Style = []
|
||||||
|
end
|
||||||
|
object cxStyle_fontBlack: TcxStyle
|
||||||
|
AssignedValues = [svFont]
|
||||||
|
Font.Charset = ANSI_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
end
|
||||||
|
object cxStyle_fontclFuchsia: TcxStyle
|
||||||
|
AssignedValues = [svFont, svTextColor]
|
||||||
|
Font.Charset = ANSI_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
TextColor = clFuchsia
|
||||||
|
end
|
||||||
|
object cxStyle_fontclPurple: TcxStyle
|
||||||
|
AssignedValues = [svFont, svTextColor]
|
||||||
|
Font.Charset = ANSI_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
TextColor = clPurple
|
||||||
|
end
|
||||||
|
object cxStyle_fontclGreen: TcxStyle
|
||||||
|
AssignedValues = [svFont, svTextColor]
|
||||||
|
Font.Charset = GB2312_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
TextColor = clGreen
|
||||||
|
end
|
||||||
|
object cxStyle_fontclBlue: TcxStyle
|
||||||
|
AssignedValues = [svFont, svTextColor]
|
||||||
|
Font.Charset = ANSI_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -12
|
||||||
|
Font.Name = #23435#20307
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
TextColor = clBlue
|
||||||
|
end
|
||||||
|
object cxStyle_fontclTeal: TcxStyle
|
||||||
|
AssignedValues = [svFont, svTextColor]
|
||||||
|
Font.Charset = DEFAULT_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -11
|
||||||
|
Font.Name = 'MS Sans Serif'
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
TextColor = clTeal
|
||||||
|
end
|
||||||
|
object cxStyle_fontclOlive: TcxStyle
|
||||||
|
AssignedValues = [svFont, svTextColor]
|
||||||
|
Font.Charset = DEFAULT_CHARSET
|
||||||
|
Font.Color = clWindowText
|
||||||
|
Font.Height = -11
|
||||||
|
Font.Name = 'MS Sans Serif'
|
||||||
|
Font.Style = [fsBold]
|
||||||
|
TextColor = clOlive
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
899
管理系统/U_ClothContractList_Dp.pas
Normal file
899
管理系统/U_ClothContractList_Dp.pas
Normal file
|
@ -0,0 +1,899 @@
|
||||||
|
unit U_ClothContractList_Dp;
|
||||||
|
|
||||||
|
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, cxCalendar, cxButtonEdit, cxSplitter, RM_Common, RM_Class,
|
||||||
|
RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, cxTextEdit, cxPC, cxCheckBox,
|
||||||
|
cxLookAndFeels, cxLookAndFeelPainters, cxNavigator, dxBarBuiltInMenu,
|
||||||
|
dxSkinsCore, dxSkinBlack, dxSkinBlue, dxSkinBlueprint, dxSkinCaramel,
|
||||||
|
dxSkinCoffee, dxSkinDarkRoom, dxSkinDarkSide, dxSkinDevExpressDarkStyle,
|
||||||
|
dxSkinDevExpressStyle, dxSkinFoggy, dxSkinGlassOceans, dxSkinHighContrast,
|
||||||
|
dxSkiniMaginary, dxSkinLilian, dxSkinLiquidSky, dxSkinLondonLiquidSky,
|
||||||
|
dxSkinMcSkin, dxSkinMetropolis, dxSkinMetropolisDark, dxSkinMoneyTwins,
|
||||||
|
dxSkinOffice2007Black, dxSkinOffice2007Blue, dxSkinOffice2007Green,
|
||||||
|
dxSkinOffice2007Pink, dxSkinOffice2007Silver, dxSkinOffice2010Black,
|
||||||
|
dxSkinOffice2010Blue, dxSkinOffice2010Silver, dxSkinOffice2013DarkGray,
|
||||||
|
dxSkinOffice2013LightGray, dxSkinOffice2013White, dxSkinPumpkin, dxSkinSeven,
|
||||||
|
dxSkinSevenClassic, dxSkinSharp, dxSkinSharpPlus, dxSkinSilver,
|
||||||
|
dxSkinSpringTime, dxSkinStardust, dxSkinSummer2008, dxSkinTheAsphaltWorld,
|
||||||
|
dxSkinsDefaultPainters, dxSkinValentine, dxSkinVS2010, dxSkinWhiteprint,
|
||||||
|
dxSkinXmas2008Blue, dxSkinscxPCPainter;
|
||||||
|
|
||||||
|
type
|
||||||
|
TfrmClothContractList_Dp = class(TForm)
|
||||||
|
ToolBar1: TToolBar;
|
||||||
|
TBRafresh: TToolButton;
|
||||||
|
TBFind: TToolButton;
|
||||||
|
TBAdd: TToolButton;
|
||||||
|
TBEdit: TToolButton;
|
||||||
|
TBDel: TToolButton;
|
||||||
|
TBPrint: TToolButton;
|
||||||
|
TBClose: TToolButton;
|
||||||
|
Panel1: TPanel;
|
||||||
|
BegDate: TDateTimePicker;
|
||||||
|
EndDate: TDateTimePicker;
|
||||||
|
Label1: TLabel;
|
||||||
|
Label2: TLabel;
|
||||||
|
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||||
|
ADOQueryCmd: TADOQuery;
|
||||||
|
ADOQueryMain: TADOQuery;
|
||||||
|
ADOQueryTemp: TADOQuery;
|
||||||
|
DataSource1: TDataSource;
|
||||||
|
Label3: TLabel;
|
||||||
|
ConNo: TEdit;
|
||||||
|
Label5: TLabel;
|
||||||
|
C_CodeName: TEdit;
|
||||||
|
TBExport: TToolButton;
|
||||||
|
Order_Main: TClientDataSet;
|
||||||
|
Label4: TLabel;
|
||||||
|
C_Color: TEdit;
|
||||||
|
ScrollBox1: TScrollBox;
|
||||||
|
cxGrid1: TcxGrid;
|
||||||
|
Tv1: TcxGridDBTableView;
|
||||||
|
v1OrderNo: TcxGridDBColumn;
|
||||||
|
v1Column2: TcxGridDBColumn;
|
||||||
|
v1DeliveryDate: TcxGridDBColumn;
|
||||||
|
v1FactoryNo1Name: TcxGridDBColumn;
|
||||||
|
v1PRTSpec: TcxGridDBColumn;
|
||||||
|
v1PRTMF: TcxGridDBColumn;
|
||||||
|
v1PRTKZ: TcxGridDBColumn;
|
||||||
|
v1PRTOrderQty: TcxGridDBColumn;
|
||||||
|
v1OrderUnit: TcxGridDBColumn;
|
||||||
|
cxGrid1Level1: TcxGridLevel;
|
||||||
|
ClientDataSet3: TClientDataSet;
|
||||||
|
DataSource2: TDataSource;
|
||||||
|
DataSource3: TDataSource;
|
||||||
|
ClientDataSet2: TClientDataSet;
|
||||||
|
v1Qty1: TcxGridDBColumn;
|
||||||
|
RM1: TRMGridReport;
|
||||||
|
RMDBMain: TRMDBDataSet;
|
||||||
|
RMXLSExport1: TRMXLSExport;
|
||||||
|
v1Column4: TcxGridDBColumn;
|
||||||
|
v1Column5: TcxGridDBColumn;
|
||||||
|
v1Column3: TcxGridDBColumn;
|
||||||
|
v1Column6: TcxGridDBColumn;
|
||||||
|
CDS_PRT: TClientDataSet;
|
||||||
|
Label6: TLabel;
|
||||||
|
FactoryNoName: TEdit;
|
||||||
|
cxTabControl1: TcxTabControl;
|
||||||
|
v1C_Unit: TcxGridDBColumn;
|
||||||
|
Tchk: TToolButton;
|
||||||
|
TNochk: TToolButton;
|
||||||
|
ToolButton1: TToolButton;
|
||||||
|
v1Qty2: TcxGridDBColumn;
|
||||||
|
v1C_Color: TcxGridDBColumn;
|
||||||
|
v1Column9: TcxGridDBColumn;
|
||||||
|
cxStyleRepository1: TcxStyleRepository;
|
||||||
|
cxStyle1: TcxStyle;
|
||||||
|
cxStyle2: TcxStyle;
|
||||||
|
cxStyle_gridRow: TcxStyle;
|
||||||
|
cxStyle_gridFoot: TcxStyle;
|
||||||
|
cxStyle_gridHead: TcxStyle;
|
||||||
|
cxStyle_gridGroupBox: TcxStyle;
|
||||||
|
cxStyle_yellow: TcxStyle;
|
||||||
|
cxStyle_Red: TcxStyle;
|
||||||
|
cxStyle_fontBlack: TcxStyle;
|
||||||
|
cxStyle_fontclFuchsia: TcxStyle;
|
||||||
|
cxStyle_fontclPurple: TcxStyle;
|
||||||
|
cxStyle_fontclGreen: TcxStyle;
|
||||||
|
cxStyle_fontclBlue: TcxStyle;
|
||||||
|
cxStyle_fontclTeal: TcxStyle;
|
||||||
|
cxStyle_fontclOlive: TcxStyle;
|
||||||
|
v1Ssel: TcxGridDBColumn;
|
||||||
|
v1Column10: TcxGridDBColumn;
|
||||||
|
v1Column11: TcxGridDBColumn;
|
||||||
|
v1Column12: TcxGridDBColumn;
|
||||||
|
v1Column13: TcxGridDBColumn;
|
||||||
|
v1Column1: TcxGridDBColumn;
|
||||||
|
ToolButton2: TToolButton;
|
||||||
|
TJj: TToolButton;
|
||||||
|
TnoJj: TToolButton;
|
||||||
|
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 TBPrintClick(Sender: TObject);
|
||||||
|
procedure TBRafreshClick(Sender: TObject);
|
||||||
|
procedure TBAddClick(Sender: TObject);
|
||||||
|
procedure ConNoChange(Sender: TObject);
|
||||||
|
procedure FormShow(Sender: TObject);
|
||||||
|
procedure Tv2MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||||
|
procedure Tv1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||||
|
procedure ToolButton5Click(Sender: TObject);
|
||||||
|
procedure ToolButton3Click(Sender: TObject);
|
||||||
|
procedure v2Column3PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||||
|
procedure cxTabControl1Change(Sender: TObject);
|
||||||
|
procedure TchkClick(Sender: TObject);
|
||||||
|
procedure TNochkClick(Sender: TObject);
|
||||||
|
procedure Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||||
|
procedure ToolButton1Click(Sender: TObject);
|
||||||
|
procedure Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||||
|
procedure Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||||
|
procedure ToolButton2Click(Sender: TObject);
|
||||||
|
procedure TJjClick(Sender: TObject);
|
||||||
|
procedure TnoJjClick(Sender: TObject);
|
||||||
|
private
|
||||||
|
FInt, PFInt: Integer;
|
||||||
|
procedure InitGrid();
|
||||||
|
procedure InitForm();
|
||||||
|
function DelData(): Boolean;
|
||||||
|
{ Private declarations }
|
||||||
|
public
|
||||||
|
fDParameters1: string;
|
||||||
|
{ Public declarations }
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
frmClothContractList_Dp: TfrmClothContractList_Dp;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
|
||||||
|
uses
|
||||||
|
U_DataLink, U_ClothContractInPut_Dp, U_Fun, U_ProductOrderList, U_ZDYHelp;
|
||||||
|
|
||||||
|
{$R *.dfm}
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.FormDestroy(Sender: TObject);
|
||||||
|
begin
|
||||||
|
frmClothContractList_Dp := nil;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
|
begin
|
||||||
|
Action := caFree;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
ScrollBox1.Align := alClient;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TBCloseClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
WriteCxGrid(self.Caption, Tv1, '指示单管理');
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.InitGrid();
|
||||||
|
var
|
||||||
|
strwhere: string;
|
||||||
|
begin
|
||||||
|
strwhere := '';
|
||||||
|
if cxTabControl1.TabIndex < 2 then
|
||||||
|
// strwhere := strwhere + ' and isnull(A.status,''''0'''')=''''' + inttostr(cxTabControl1.TabIndex) + '''''';
|
||||||
|
strwhere := strwhere + ' and isnull(B.C_status,''''0'''')=''''' + inttostr(cxTabControl1.TabIndex) + '''''';
|
||||||
|
if (trim(fDParameters1) = '查询') then
|
||||||
|
strwhere := strwhere + ' and A.Filler=''''' + Trim(DName) + ''''' ';
|
||||||
|
try
|
||||||
|
ADOQueryMain.DisableControls;
|
||||||
|
with ADOQueryMain do
|
||||||
|
begin
|
||||||
|
Filtered := False;
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('exec P_Get_Contract');
|
||||||
|
sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||||
|
sql.Add(',@enddate=''' + Trim(FormatDateTime('yyyy-MM-dd', enddate.DateTime + 1)) + ''' ');
|
||||||
|
sql.Add(',@conType=''坯布调拨计划'' ');
|
||||||
|
sql.Add(',@status=''' + inttostr(cxTabControl1.TabIndex) + ''' ');
|
||||||
|
Open;
|
||||||
|
end;
|
||||||
|
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||||
|
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||||
|
finally
|
||||||
|
ADOQueryMain.EnableControls;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.InitForm();
|
||||||
|
begin
|
||||||
|
// if fDParameters1 = '查询' then
|
||||||
|
// begin
|
||||||
|
// TBADD.Visible := false;
|
||||||
|
// TBEdit.Visible := false;
|
||||||
|
// TBDel.Visible := false;
|
||||||
|
// Tchk.Visible := false;
|
||||||
|
// TNochk.Visible := false;
|
||||||
|
// // Tth.Visible:=false;
|
||||||
|
// //ToolButton1.Visible:=false;
|
||||||
|
// end;
|
||||||
|
|
||||||
|
TBEdit.Enabled := false;
|
||||||
|
TBDel.Enabled := false;
|
||||||
|
Tchk.Enabled := false;
|
||||||
|
TNochk.Enabled := false;
|
||||||
|
if cxTabControl1.TabIndex = 0 then
|
||||||
|
begin
|
||||||
|
TBEdit.Enabled := true;
|
||||||
|
TBDel.Enabled := true;
|
||||||
|
Tchk.Enabled := true;
|
||||||
|
end;
|
||||||
|
if cxTabControl1.TabIndex = 1 then
|
||||||
|
begin
|
||||||
|
TNochk.Enabled := true;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TBFindClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if ADOQueryMain.Active = False then
|
||||||
|
Exit;
|
||||||
|
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||||
|
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||||
|
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TBEditClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
try
|
||||||
|
frmClothContractInPut_Dp := TfrmClothContractInPut_Dp.Create(Application);
|
||||||
|
with frmClothContractInPut_Dp do
|
||||||
|
begin
|
||||||
|
PState := 1;
|
||||||
|
FMainId := Trim(Self.Order_Main.fieldbyname('MainId').AsString);
|
||||||
|
FConType := Trim(Self.Order_Main.fieldbyname('ConType').AsString);
|
||||||
|
if ShowModal = 1 then
|
||||||
|
begin
|
||||||
|
TBRafresh.Click;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
finally
|
||||||
|
frmClothContractInPut_Dp.Free;
|
||||||
|
TBRafresh.Click;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TBDelClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select * from JYOrder_Sub_AnPai ');
|
||||||
|
sql.Add('where MainId=''' + Trim(Order_Main.fieldbyname('MainId').AsString) + '''');
|
||||||
|
open;
|
||||||
|
end;
|
||||||
|
if not ADOQueryCmd.IsEmpty then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('已回仓,不能删除投坯计划!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||||
|
Exit;
|
||||||
|
if trim(Order_Main.FieldByName('mainID').AsString) = 'CM001' then
|
||||||
|
exit;
|
||||||
|
if DelData() then
|
||||||
|
begin
|
||||||
|
Order_Main.Delete;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
function TfrmClothContractList_Dp.DelData(): Boolean;
|
||||||
|
begin
|
||||||
|
try
|
||||||
|
Result := false;
|
||||||
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('delete YF_Money_CR where MainID=''' + Trim(Order_Main.fieldbyname('MainID').AsString) + '''');
|
||||||
|
ExecSQL;
|
||||||
|
end;
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('Update YF_Money_KC Set KCMoney=(select isnull(Sum(Money*QtyFlag),0) from YF_Money_CR A where A.CRID=YF_Money_KC.CRID)');
|
||||||
|
sql.Add(',KCBBMoney=(select isnull(Sum(BBMoney*QtyFlag),0) from YF_Money_CR A where A.CRID=YF_Money_KC.CRID)');
|
||||||
|
// sql.Add(' where CRID='+CRID);
|
||||||
|
ExecSQL;
|
||||||
|
end;
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('delete Contract_Sub where SubId=''' + Trim(Order_Main.fieldbyname('SubId').AsString) + '''');
|
||||||
|
ExecSQL;
|
||||||
|
end;
|
||||||
|
with ADOQueryTemp do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select * from Contract_Sub where MainId=''' + Trim(Order_Main.fieldbyname('MainId').AsString) + '''');
|
||||||
|
Open;
|
||||||
|
end;
|
||||||
|
if ADOQueryTemp.IsEmpty then
|
||||||
|
begin
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('delete Contract_Main where MainId=''' + Trim(Order_Main.fieldbyname('MainId').AsString) + '''');
|
||||||
|
ExecSQL;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
if Trim(Order_Main.fieldbyname('SubId').AsString) = '' then
|
||||||
|
begin
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('delete Contract_Main where MainId=''' + Trim(Order_Main.fieldbyname('MainId').AsString) + '''');
|
||||||
|
ExecSQL;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
Result := True;
|
||||||
|
except
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
Result := False;
|
||||||
|
Application.MessageBox('数据删除异常!', '提示', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TBExportClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if ADOQueryMain.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
TcxGridToExcel('坯布点色计划列表', cxGrid1);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TBPrintClick(Sender: TObject);
|
||||||
|
var
|
||||||
|
fPrintFile, FConNoM: string;
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\坯布投坯单.rmf';
|
||||||
|
with ADOQueryTemp do
|
||||||
|
begin
|
||||||
|
Filtered := False;
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select *,fromConNo=(select Top 1 conNo from Contract_Main X where X.MainID=A.fromMainID) ');
|
||||||
|
sql.Add('from Contract_Main A');
|
||||||
|
sql.Add('inner join Contract_sub B on B.MainID=A.mainID ');
|
||||||
|
sql.Add('where A.FillTime>= ''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||||
|
sql.Add('and A.FillTime< ''' + Trim(FormatDateTime('yyyy-MM-dd', endDate.DateTime + 1)) + ''' ');
|
||||||
|
sql.Add('and A.mainID=' + quotedstr(trim(Order_Main.fieldbyname('MainID').AsString)));
|
||||||
|
Open;
|
||||||
|
end;
|
||||||
|
SCreateCDS20(ADOQueryTemp, CDS_PRT);
|
||||||
|
SInitCDSData20(ADOQueryTemp, CDS_PRT);
|
||||||
|
if FileExists(fPrintFile) then
|
||||||
|
begin
|
||||||
|
RMVariables['dtxz'] := formatdateTime('yyyy-MM-dd', Now);
|
||||||
|
RMVariables['zdr'] := Trim(dName);
|
||||||
|
RM1.LoadFromFile(fPrintFile);
|
||||||
|
RM1.ShowReport;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\坯布投坯单.rmf'), '提示', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TBRafreshClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
InitGrid();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TBAddClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
try
|
||||||
|
frmClothContractInPut_Dp := TfrmClothContractInPut_Dp.Create(Application);
|
||||||
|
with frmClothContractInPut_Dp do
|
||||||
|
begin
|
||||||
|
PState := 0;
|
||||||
|
FMainId := '';
|
||||||
|
FConType := '坯布调拨计划';
|
||||||
|
if ShowModal = 1 then
|
||||||
|
begin
|
||||||
|
TBRafresh.Click;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
finally
|
||||||
|
frmClothContractInPut_Dp.Free;
|
||||||
|
TBRafresh.Click;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.ConNoChange(Sender: TObject);
|
||||||
|
var
|
||||||
|
str1: string;
|
||||||
|
begin
|
||||||
|
if ADOQueryMain.Active = False then
|
||||||
|
Exit;
|
||||||
|
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||||
|
|
||||||
|
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||||
|
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.FormShow(Sender: TObject);
|
||||||
|
begin
|
||||||
|
InitForm();
|
||||||
|
ReadCxGrid(self.Caption, Tv1, '指示单管理');
|
||||||
|
BegDate.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||||
|
EndDate.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||||
|
InitGrid();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.Tv2MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||||
|
begin
|
||||||
|
FInt := 2;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.Tv1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||||
|
begin
|
||||||
|
FInt := 1;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.ToolButton5Click(Sender: TObject);
|
||||||
|
var
|
||||||
|
maxno: string;
|
||||||
|
begin
|
||||||
|
if ClientDataSet3.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
if ClientDataSet2.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
if Trim(ClientDataSet2.fieldbyname('MXId').AsString) = '' then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('到货数量未确定!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
if ClientDataSet3.Locate('OrderNo', null, []) then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('指定订单编号不能为空!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
BegDate.SetFocus;
|
||||||
|
try
|
||||||
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
//保存去向表
|
||||||
|
with ClientDataSet3 do
|
||||||
|
begin
|
||||||
|
First;
|
||||||
|
while not eof do
|
||||||
|
begin
|
||||||
|
if Trim(ClientDataSet3.fieldbyname('ToId').AsString) = '' then
|
||||||
|
begin
|
||||||
|
if GetLSNo(ADOQueryCmd, maxno, 'To', 'Contract_Sub_MxTo', 4, 1) = False then
|
||||||
|
begin
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
Application.MessageBox('取去向流水号失败!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
maxno := Trim(ClientDataSet3.fieldbyname('ToId').AsString);
|
||||||
|
end;
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('select * from Contract_Sub_MxTo where ToId=''' + Trim(ClientDataSet3.fieldbyname('ToId').AsString) + '''');
|
||||||
|
Open;
|
||||||
|
end;
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
if Trim(ClientDataSet3.fieldbyname('ToId').AsString) = '' then
|
||||||
|
Append
|
||||||
|
else
|
||||||
|
Edit;
|
||||||
|
FieldByName('MxId').Value := Trim(ClientDataSet2.fieldbyname('MxId').AsString);
|
||||||
|
FieldByName('ToId').Value := Trim(maxno);
|
||||||
|
FieldByName('OrdSubId').Value := Trim(ClientDataSet3.fieldbyname('OrdSubId').AsString);
|
||||||
|
FieldByName('TPDate').Value := ClientDataSet3.fieldbyname('TPDate').Value;
|
||||||
|
FieldByName('TPPerson').Value := ClientDataSet3.fieldbyname('TPPerson').Value;
|
||||||
|
FieldByName('TPNote').Value := ClientDataSet3.fieldbyname('TPNote').Value;
|
||||||
|
if Trim(ClientDataSet3.fieldbyname('TPQty').AsString) <> '' then
|
||||||
|
FieldByName('TPQty').Value := ClientDataSet3.fieldbyname('TPQty').Value
|
||||||
|
else
|
||||||
|
FieldByName('TPQty').Value := 0;
|
||||||
|
if Trim(ClientDataSet3.fieldbyname('Qty1').AsString) <> '' then
|
||||||
|
FieldByName('Qty1').Value := ClientDataSet3.fieldbyname('Qty1').Value
|
||||||
|
else
|
||||||
|
FieldByName('Qty1').Value := 0;
|
||||||
|
if Trim(ClientDataSet3.fieldbyname('Qty2').AsString) <> '' then
|
||||||
|
FieldByName('Qty2').Value := ClientDataSet3.fieldbyname('Qty2').Value
|
||||||
|
else
|
||||||
|
FieldByName('Qty2').Value := 0;
|
||||||
|
if Trim(ClientDataSet3.fieldbyname('Qty3').AsString) <> '' then
|
||||||
|
FieldByName('Qty3').Value := ClientDataSet3.fieldbyname('Qty3').Value
|
||||||
|
else
|
||||||
|
FieldByName('Qty3').Value := 0;
|
||||||
|
Post;
|
||||||
|
end;
|
||||||
|
with ClientDataSet3 do
|
||||||
|
begin
|
||||||
|
Edit;
|
||||||
|
FieldByName('ToId').Value := Trim(maxno);
|
||||||
|
Post;
|
||||||
|
end;
|
||||||
|
Next;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
Application.MessageBox('操作成功!', '提示', 0);
|
||||||
|
except
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
Application.MessageBox('操作异常!', '提示', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.ToolButton3Click(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if FInt = 2 then
|
||||||
|
begin
|
||||||
|
if ClientDataSet2.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
if ClientDataSet3.IsEmpty = false then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('已产生坯布领料数据,不能删除到坯记录!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
if Trim(ClientDataSet2.fieldbyname('MxId').AsString) <> '' then
|
||||||
|
begin
|
||||||
|
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('delete Contract_Sub_Mx where MxId=''' + Trim(ClientDataSet2.fieldbyname('MxId').AsString) + '''');
|
||||||
|
ExecSQL;
|
||||||
|
end;
|
||||||
|
ClientDataSet2.Delete;
|
||||||
|
end
|
||||||
|
else if FInt = 3 then
|
||||||
|
begin
|
||||||
|
if ClientDataSet3.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
if Trim(ClientDataSet3.fieldbyname('ToId').AsString) <> '' then
|
||||||
|
begin
|
||||||
|
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
with ADOQueryCmd do
|
||||||
|
begin
|
||||||
|
Close;
|
||||||
|
sql.Clear;
|
||||||
|
sql.Add('delete Contract_Sub_MxTo where ToId=''' + Trim(ClientDataSet3.fieldbyname('ToId').AsString) + '''');
|
||||||
|
ExecSQL;
|
||||||
|
end;
|
||||||
|
ClientDataSet3.Delete;
|
||||||
|
with ClientDataSet2 do
|
||||||
|
begin
|
||||||
|
Edit;
|
||||||
|
if ClientDataSet3.IsEmpty = False then
|
||||||
|
// FieldByName('KCSL').Value:=ClientDataSet2.fieldbyname('MxQty').Value-tv3.DataController.Summary.FooterSummaryValues[0]
|
||||||
|
|
||||||
|
else
|
||||||
|
FieldByName('KCSL').Value := ClientDataSet2.fieldbyname('MxQty').Value;
|
||||||
|
Post;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.v2Column3PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||||
|
begin
|
||||||
|
try
|
||||||
|
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||||
|
with frmZDYHelp do
|
||||||
|
begin
|
||||||
|
flag := 'RKPlace';
|
||||||
|
flagname := '入库地点';
|
||||||
|
if ShowModal = 1 then
|
||||||
|
begin
|
||||||
|
with ClientDataSet2 do
|
||||||
|
begin
|
||||||
|
Edit;
|
||||||
|
FieldByName('RKPlace').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
finally
|
||||||
|
frmZDYHelp.Free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.cxTabControl1Change(Sender: TObject);
|
||||||
|
begin
|
||||||
|
initForm();
|
||||||
|
InitGrid();
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TchkClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
exit;
|
||||||
|
|
||||||
|
if Order_Main.Locate('ssel', true, []) = false then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
try
|
||||||
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
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 Contract_sub SET C_status=''1'' ');
|
||||||
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
|
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
next;
|
||||||
|
end;
|
||||||
|
First;
|
||||||
|
EnableControls;
|
||||||
|
end;
|
||||||
|
|
||||||
|
InitGrid();
|
||||||
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
except
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
application.MessageBox('操作失败!', '提示信息', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TNochkClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
exit;
|
||||||
|
if Order_Main.Locate('ssel', true, []) = false then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
try
|
||||||
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
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 Contract_sub SET C_status=''0'' ');
|
||||||
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
|
sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
next;
|
||||||
|
end;
|
||||||
|
First;
|
||||||
|
EnableControls;
|
||||||
|
end;
|
||||||
|
|
||||||
|
InitGrid();
|
||||||
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
except
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
application.MessageBox('操作失败!', '提示信息', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.Tv1CellDblClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||||
|
begin
|
||||||
|
ToolButton1.Click;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.ToolButton1Click(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
Exit;
|
||||||
|
try
|
||||||
|
frmClothContractInPut_Dp := TfrmClothContractInPut_Dp.Create(Application);
|
||||||
|
with frmClothContractInPut_Dp do
|
||||||
|
begin
|
||||||
|
PState := 1;
|
||||||
|
tbsave.Enabled := false;
|
||||||
|
FMainId := Trim(Self.Order_Main.fieldbyname('MainId').AsString);
|
||||||
|
if ShowModal = 1 then
|
||||||
|
begin
|
||||||
|
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
finally
|
||||||
|
frmClothContractInPut_Dp.Free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||||
|
begin
|
||||||
|
{ IF AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('N_Qty').Index]=0 then
|
||||||
|
begin
|
||||||
|
ACanvas.Brush.Color:=clSkyBlue;
|
||||||
|
end; }
|
||||||
|
if AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('Jiaji').Index] = '加急' then
|
||||||
|
begin
|
||||||
|
ACanvas.Brush.Color := Clred;
|
||||||
|
end;
|
||||||
|
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||||
|
var
|
||||||
|
FValue: string;
|
||||||
|
FBounds: TRect;
|
||||||
|
begin
|
||||||
|
FBounds := AViewInfo.Bounds;
|
||||||
|
if (AViewInfo is TcxGridIndicatorRowItemViewInfo) then
|
||||||
|
begin
|
||||||
|
ACanvas.FillRect(FBounds);
|
||||||
|
ACanvas.DrawComplexFrame(FBounds, clBtnHighlight, clBtnShadow, [bBottom, bLeft, bRight], 1);
|
||||||
|
FValue := IntToStr(TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Index + 1);
|
||||||
|
InflateRect(FBounds, -1, -1);
|
||||||
|
ACanvas.Font.Color := clBlack;
|
||||||
|
ACanvas.Brush.Style := bsClear;
|
||||||
|
ACanvas.DrawText(FValue, FBounds, cxAlignCenter or cxAlignTop);
|
||||||
|
ADone := True;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.ToolButton2Click(Sender: TObject);
|
||||||
|
begin
|
||||||
|
// try
|
||||||
|
// frmClothContractInPut_Tp := TfrmClothContractInPut_Tp.Create(Application);
|
||||||
|
// with frmClothContractInPut_Tp do
|
||||||
|
// begin
|
||||||
|
// PState := 0;
|
||||||
|
// FMainId := '';
|
||||||
|
// FConType := '改色计划';
|
||||||
|
// if ShowModal = 1 then
|
||||||
|
// begin
|
||||||
|
// TBRafresh.Click;
|
||||||
|
// end;
|
||||||
|
// end;
|
||||||
|
// finally
|
||||||
|
// frmClothContractInPut_Tp.Free;
|
||||||
|
// TBRafresh.Click;
|
||||||
|
// end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TJjClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
exit;
|
||||||
|
|
||||||
|
if Order_Main.Locate('ssel', true, []) = false then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
try
|
||||||
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
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 Contract_main SET Jiaji=''加急'' ');
|
||||||
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
|
// sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
next;
|
||||||
|
end;
|
||||||
|
First;
|
||||||
|
EnableControls;
|
||||||
|
end;
|
||||||
|
|
||||||
|
InitGrid();
|
||||||
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
except
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
application.MessageBox('操作失败!', '提示信息', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Dp.TnoJjClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
exit;
|
||||||
|
if Order_Main.Locate('ssel', true, []) = false then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
try
|
||||||
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
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 Contract_main SET Jiaji='''' ');
|
||||||
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
|
// sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
next;
|
||||||
|
end;
|
||||||
|
First;
|
||||||
|
EnableControls;
|
||||||
|
end;
|
||||||
|
|
||||||
|
InitGrid();
|
||||||
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
except
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
application.MessageBox('操作失败!', '提示信息', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
end.
|
||||||
|
|
|
@ -62,15 +62,32 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
ImageIndex = 3
|
ImageIndex = 3
|
||||||
OnClick = TBAddClick
|
OnClick = TBAddClick
|
||||||
end
|
end
|
||||||
object ToolButton2: TToolButton
|
object TJj: TToolButton
|
||||||
Left = 189
|
Left = 189
|
||||||
Top = 0
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #21152#24613
|
||||||
|
ImageIndex = 60
|
||||||
|
OnClick = TJjClick
|
||||||
|
end
|
||||||
|
object TnoJj: TToolButton
|
||||||
|
Left = 252
|
||||||
|
Top = 0
|
||||||
|
AutoSize = True
|
||||||
|
Caption = #25764#38144#21152#24613
|
||||||
|
ImageIndex = 99
|
||||||
|
OnClick = TnoJjClick
|
||||||
|
end
|
||||||
|
object ToolButton2: TToolButton
|
||||||
|
Left = 339
|
||||||
|
Top = 0
|
||||||
Caption = #22238#20462#26032#22686
|
Caption = #22238#20462#26032#22686
|
||||||
ImageIndex = 57
|
ImageIndex = 57
|
||||||
|
Visible = False
|
||||||
OnClick = ToolButton2Click
|
OnClick = ToolButton2Click
|
||||||
end
|
end
|
||||||
object TBEdit: TToolButton
|
object TBEdit: TToolButton
|
||||||
Left = 272
|
Left = 422
|
||||||
Top = 0
|
Top = 0
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #20462#25913
|
Caption = #20462#25913
|
||||||
|
@ -78,7 +95,7 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
OnClick = TBEditClick
|
OnClick = TBEditClick
|
||||||
end
|
end
|
||||||
object TBDel: TToolButton
|
object TBDel: TToolButton
|
||||||
Left = 335
|
Left = 485
|
||||||
Top = 0
|
Top = 0
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #21024#38500
|
Caption = #21024#38500
|
||||||
|
@ -86,7 +103,7 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
OnClick = TBDelClick
|
OnClick = TBDelClick
|
||||||
end
|
end
|
||||||
object Tchk: TToolButton
|
object Tchk: TToolButton
|
||||||
Left = 398
|
Left = 548
|
||||||
Top = 0
|
Top = 0
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #30830#35748#23436#25104
|
Caption = #30830#35748#23436#25104
|
||||||
|
@ -94,7 +111,7 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
OnClick = TchkClick
|
OnClick = TchkClick
|
||||||
end
|
end
|
||||||
object TNochk: TToolButton
|
object TNochk: TToolButton
|
||||||
Left = 485
|
Left = 635
|
||||||
Top = 0
|
Top = 0
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #25764#38144#23436#25104
|
Caption = #25764#38144#23436#25104
|
||||||
|
@ -102,7 +119,7 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
OnClick = TNochkClick
|
OnClick = TNochkClick
|
||||||
end
|
end
|
||||||
object ToolButton1: TToolButton
|
object ToolButton1: TToolButton
|
||||||
Left = 572
|
Left = 722
|
||||||
Top = 0
|
Top = 0
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #26597#30475
|
Caption = #26597#30475
|
||||||
|
@ -110,7 +127,7 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
OnClick = ToolButton1Click
|
OnClick = ToolButton1Click
|
||||||
end
|
end
|
||||||
object TBExport: TToolButton
|
object TBExport: TToolButton
|
||||||
Left = 635
|
Left = 785
|
||||||
Top = 0
|
Top = 0
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #23548#20986
|
Caption = #23548#20986
|
||||||
|
@ -118,7 +135,7 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
OnClick = TBExportClick
|
OnClick = TBExportClick
|
||||||
end
|
end
|
||||||
object TBPrint: TToolButton
|
object TBPrint: TToolButton
|
||||||
Left = 698
|
Left = 848
|
||||||
Top = 0
|
Top = 0
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #25171#21360
|
Caption = #25171#21360
|
||||||
|
@ -126,7 +143,7 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
OnClick = TBPrintClick
|
OnClick = TBPrintClick
|
||||||
end
|
end
|
||||||
object TBClose: TToolButton
|
object TBClose: TToolButton
|
||||||
Left = 761
|
Left = 911
|
||||||
Top = 0
|
Top = 0
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
Caption = #20851#38381
|
Caption = #20851#38381
|
||||||
|
@ -309,15 +326,12 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
end
|
end
|
||||||
item
|
item
|
||||||
Kind = skSum
|
Kind = skSum
|
||||||
Column = v1H_gs
|
|
||||||
end
|
end
|
||||||
item
|
item
|
||||||
Kind = skSum
|
Kind = skSum
|
||||||
Column = v1Column7
|
|
||||||
end
|
end
|
||||||
item
|
item
|
||||||
Kind = skSum
|
Kind = skSum
|
||||||
Column = v1Column8
|
|
||||||
end
|
end
|
||||||
item
|
item
|
||||||
Kind = skSum
|
Kind = skSum
|
||||||
|
@ -333,11 +347,9 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
end
|
end
|
||||||
item
|
item
|
||||||
Kind = skSum
|
Kind = skSum
|
||||||
Column = v1Column14
|
|
||||||
end
|
end
|
||||||
item
|
item
|
||||||
Kind = skSum
|
Kind = skSum
|
||||||
Column = v1Column15
|
|
||||||
end>
|
end>
|
||||||
DataController.Summary.SummaryGroups = <>
|
DataController.Summary.SummaryGroups = <>
|
||||||
OptionsCustomize.ColumnFiltering = False
|
OptionsCustomize.ColumnFiltering = False
|
||||||
|
@ -505,36 +517,6 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
Styles.Header = DataLink_TradeManage.Default
|
Styles.Header = DataLink_TradeManage.Default
|
||||||
Width = 63
|
Width = 63
|
||||||
end
|
end
|
||||||
object v1H_gs: TcxGridDBColumn
|
|
||||||
Caption = #22238#20179#32568#25968
|
|
||||||
DataBinding.FieldName = 'H_gs'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Options.Editing = False
|
|
||||||
Styles.Content = cxStyle_fontclPurple
|
|
||||||
Styles.Footer = cxStyle_fontclPurple
|
|
||||||
Styles.Header = cxStyle_fontclPurple
|
|
||||||
Width = 60
|
|
||||||
end
|
|
||||||
object v1Column7: TcxGridDBColumn
|
|
||||||
Caption = #22238#20179#21305#25968
|
|
||||||
DataBinding.FieldName = 'H_PS'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Options.Editing = False
|
|
||||||
Styles.Content = cxStyle_fontclPurple
|
|
||||||
Styles.Footer = cxStyle_fontclPurple
|
|
||||||
Styles.Header = cxStyle_fontclPurple
|
|
||||||
Width = 60
|
|
||||||
end
|
|
||||||
object v1Column8: TcxGridDBColumn
|
|
||||||
Caption = #22238#20179#25968#37327
|
|
||||||
DataBinding.FieldName = 'H_Qty'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Options.Editing = False
|
|
||||||
Styles.Content = cxStyle_fontclPurple
|
|
||||||
Styles.Footer = cxStyle_fontclPurple
|
|
||||||
Styles.Header = cxStyle_fontclPurple
|
|
||||||
Width = 60
|
|
||||||
end
|
|
||||||
object v1Column9: TcxGridDBColumn
|
object v1Column9: TcxGridDBColumn
|
||||||
Caption = #26410#23436#25104#25968#37327
|
Caption = #26410#23436#25104#25968#37327
|
||||||
DataBinding.FieldName = 'N_Qty'
|
DataBinding.FieldName = 'N_Qty'
|
||||||
|
@ -573,30 +555,16 @@ object frmClothContractList_Tp: TfrmClothContractList_Tp
|
||||||
Options.Editing = False
|
Options.Editing = False
|
||||||
Width = 80
|
Width = 80
|
||||||
end
|
end
|
||||||
object v1Column14: TcxGridDBColumn
|
|
||||||
Caption = #26816#39564#21305#25968
|
|
||||||
DataBinding.FieldName = 'J_ps'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Options.Editing = False
|
|
||||||
Styles.Content = cxStyle_fontclTeal
|
|
||||||
Styles.Footer = cxStyle_fontclTeal
|
|
||||||
Styles.Header = cxStyle_fontclTeal
|
|
||||||
Width = 60
|
|
||||||
end
|
|
||||||
object v1Column15: TcxGridDBColumn
|
|
||||||
Caption = #26816#39564#25968#37327
|
|
||||||
DataBinding.FieldName = 'J_Qty'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Options.Editing = False
|
|
||||||
Styles.Content = cxStyle_fontclTeal
|
|
||||||
Styles.Footer = cxStyle_fontclTeal
|
|
||||||
Styles.Header = cxStyle_fontclTeal
|
|
||||||
Width = 60
|
|
||||||
end
|
|
||||||
object v1Column1: TcxGridDBColumn
|
object v1Column1: TcxGridDBColumn
|
||||||
DataBinding.FieldName = 'IsZt'
|
DataBinding.FieldName = 'IsZt'
|
||||||
Visible = False
|
Visible = False
|
||||||
end
|
end
|
||||||
|
object Tv1Column1: TcxGridDBColumn
|
||||||
|
Caption = #21152#24613
|
||||||
|
DataBinding.FieldName = 'Jiaji'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
end
|
end
|
||||||
object cxGrid1Level1: TcxGridLevel
|
object cxGrid1Level1: TcxGridLevel
|
||||||
GridView = Tv1
|
GridView = Tv1
|
||||||
|
|
|
@ -83,14 +83,11 @@ type
|
||||||
FactoryNoName: TEdit;
|
FactoryNoName: TEdit;
|
||||||
cxTabControl1: TcxTabControl;
|
cxTabControl1: TcxTabControl;
|
||||||
v1C_Unit: TcxGridDBColumn;
|
v1C_Unit: TcxGridDBColumn;
|
||||||
v1Column7: TcxGridDBColumn;
|
|
||||||
v1Column8: TcxGridDBColumn;
|
|
||||||
Tchk: TToolButton;
|
Tchk: TToolButton;
|
||||||
TNochk: TToolButton;
|
TNochk: TToolButton;
|
||||||
ToolButton1: TToolButton;
|
ToolButton1: TToolButton;
|
||||||
v1Qty2: TcxGridDBColumn;
|
v1Qty2: TcxGridDBColumn;
|
||||||
v1C_Color: TcxGridDBColumn;
|
v1C_Color: TcxGridDBColumn;
|
||||||
v1H_gs: TcxGridDBColumn;
|
|
||||||
v1Column9: TcxGridDBColumn;
|
v1Column9: TcxGridDBColumn;
|
||||||
cxStyleRepository1: TcxStyleRepository;
|
cxStyleRepository1: TcxStyleRepository;
|
||||||
cxStyle1: TcxStyle;
|
cxStyle1: TcxStyle;
|
||||||
|
@ -113,10 +110,11 @@ type
|
||||||
v1Column11: TcxGridDBColumn;
|
v1Column11: TcxGridDBColumn;
|
||||||
v1Column12: TcxGridDBColumn;
|
v1Column12: TcxGridDBColumn;
|
||||||
v1Column13: TcxGridDBColumn;
|
v1Column13: TcxGridDBColumn;
|
||||||
v1Column14: TcxGridDBColumn;
|
|
||||||
v1Column15: TcxGridDBColumn;
|
|
||||||
v1Column1: TcxGridDBColumn;
|
v1Column1: TcxGridDBColumn;
|
||||||
ToolButton2: TToolButton;
|
ToolButton2: TToolButton;
|
||||||
|
TJj: TToolButton;
|
||||||
|
TnoJj: TToolButton;
|
||||||
|
Tv1Column1: TcxGridDBColumn;
|
||||||
procedure FormDestroy(Sender: TObject);
|
procedure FormDestroy(Sender: TObject);
|
||||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
procedure FormCreate(Sender: TObject);
|
procedure FormCreate(Sender: TObject);
|
||||||
|
@ -143,6 +141,8 @@ type
|
||||||
procedure Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
procedure Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||||
procedure Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
procedure Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||||
procedure ToolButton2Click(Sender: TObject);
|
procedure ToolButton2Click(Sender: TObject);
|
||||||
|
procedure TJjClick(Sender: TObject);
|
||||||
|
procedure TnoJjClick(Sender: TObject);
|
||||||
private
|
private
|
||||||
FInt, PFInt: Integer;
|
FInt, PFInt: Integer;
|
||||||
procedure InitGrid();
|
procedure InitGrid();
|
||||||
|
@ -186,29 +186,29 @@ begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfrmClothContractList_Tp.InitGrid();
|
procedure TfrmClothContractList_Tp.InitGrid();
|
||||||
var
|
var
|
||||||
strwhere: string;
|
strwhere: string;
|
||||||
begin
|
begin
|
||||||
strwhere := '';
|
strwhere := '';
|
||||||
if cxTabControl1.TabIndex < 2 then
|
if cxTabControl1.TabIndex < 2 then
|
||||||
// strwhere := strwhere + ' and isnull(A.status,''''0'''')=''''' + inttostr(cxTabControl1.TabIndex) + '''''';
|
// strwhere := strwhere + ' and isnull(A.status,''''0'''')=''''' + inttostr(cxTabControl1.TabIndex) + '''''';
|
||||||
strwhere := strwhere + ' and isnull(B.C_status,''''0'''')=''''' + inttostr(cxTabControl1.TabIndex) + '''''';
|
strwhere := strwhere + ' and isnull(B.C_status,''''0'''')=''''' + inttostr(cxTabControl1.TabIndex) + '''''';
|
||||||
if (trim(fDParameters1) = '²éѯ') then
|
if (trim(fDParameters1) = '²éѯ') then
|
||||||
strwhere := strwhere + ' and A.Filler=''''' + Trim(DName) + ''''' ';
|
strwhere := strwhere + ' and A.Filler=''''' + Trim(DName) + ''''' ';
|
||||||
try
|
try
|
||||||
ADOQueryMain.DisableControls;
|
ADOQueryMain.DisableControls;
|
||||||
with ADOQueryMain do
|
with ADOQueryMain do
|
||||||
begin
|
begin
|
||||||
Filtered := False;
|
Filtered := False;
|
||||||
Close;
|
Close;
|
||||||
sql.Clear;
|
sql.Clear;
|
||||||
sql.Add('exec P_Get_Contract_TG');
|
sql.Add('exec P_Get_Contract_TG');
|
||||||
sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
sql.Add('@begdate=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.DateTime)) + ''' ');
|
||||||
sql.Add(',@enddate=''' + Trim(FormatDateTime('yyyy-MM-dd', enddate.DateTime + 1)) + ''' ');
|
sql.Add(',@enddate=''' + Trim(FormatDateTime('yyyy-MM-dd', enddate.DateTime + 1)) + ''' ');
|
||||||
// sql.Add(',@conType= '''+TconType+''' ');
|
// sql.Add(',@conType= '''+TconType+''' ');
|
||||||
sql.Add(',@status=''' +strwhere + ''' ');
|
sql.Add(',@status=''' + strwhere + ''' ');
|
||||||
// ShowMessage(sql.text);
|
// ShowMessage(sql.text);
|
||||||
Open;
|
Open;
|
||||||
end;
|
end;
|
||||||
SCreateCDS20(ADOQueryMain, Order_Main);
|
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||||
SInitCDSData20(ADOQueryMain, Order_Main);
|
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||||
|
@ -373,7 +373,7 @@ procedure TfrmClothContractList_Tp.TBExportClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
if ADOQueryMain.IsEmpty then
|
if ADOQueryMain.IsEmpty then
|
||||||
Exit;
|
Exit;
|
||||||
TcxGridToExcel('Å÷²¼ºÏͬ¶©µ¥Áбí', cxGrid1);
|
TcxGridToExcel('坯布点色计划列表', cxGrid1);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfrmClothContractList_Tp.TBPrintClick(Sender: TObject);
|
procedure TfrmClothContractList_Tp.TBPrintClick(Sender: TObject);
|
||||||
|
@ -754,7 +754,7 @@ begin
|
||||||
end;
|
end;
|
||||||
finally
|
finally
|
||||||
frmClothContractInPut_Tp.Free;
|
frmClothContractInPut_Tp.Free;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfrmClothContractList_Tp.Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
procedure TfrmClothContractList_Tp.Tv1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||||
|
@ -763,7 +763,7 @@ begin
|
||||||
begin
|
begin
|
||||||
ACanvas.Brush.Color:=clSkyBlue;
|
ACanvas.Brush.Color:=clSkyBlue;
|
||||||
end; }
|
end; }
|
||||||
if AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('IsZt').Index] = 0 then
|
if AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('Jiaji').Index] = '加急' then
|
||||||
begin
|
begin
|
||||||
ACanvas.Brush.Color := Clred;
|
ACanvas.Brush.Color := Clred;
|
||||||
end;
|
end;
|
||||||
|
@ -809,5 +809,92 @@ begin
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Tp.TJjClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
exit;
|
||||||
|
|
||||||
|
if Order_Main.Locate('ssel', true, []) = false then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
try
|
||||||
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
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 Contract_main SET Jiaji=''加急'' ');
|
||||||
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
|
// sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
next;
|
||||||
|
end;
|
||||||
|
First;
|
||||||
|
EnableControls;
|
||||||
|
end;
|
||||||
|
|
||||||
|
InitGrid();
|
||||||
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
except
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
application.MessageBox('操作失败!', '提示信息', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmClothContractList_Tp.TnoJjClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if Order_Main.IsEmpty then
|
||||||
|
exit;
|
||||||
|
if Order_Main.Locate('ssel', true, []) = false then
|
||||||
|
begin
|
||||||
|
Application.MessageBox('没有选择数据!', '提示', 0);
|
||||||
|
Exit;
|
||||||
|
end;
|
||||||
|
try
|
||||||
|
ADOQueryCmd.Connection.BeginTrans;
|
||||||
|
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 Contract_main SET Jiaji='''' ');
|
||||||
|
sql.Add('where mainID =' + quotedstr(trim(Order_Main.fieldbyname('mainID').AsString)));
|
||||||
|
// sql.Add('and subID =' + quotedstr(trim(Order_Main.fieldbyname('subID').AsString)));
|
||||||
|
execsql;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
next;
|
||||||
|
end;
|
||||||
|
First;
|
||||||
|
EnableControls;
|
||||||
|
end;
|
||||||
|
|
||||||
|
InitGrid();
|
||||||
|
ADOQueryCmd.Connection.CommitTrans;
|
||||||
|
except
|
||||||
|
ADOQueryCmd.Connection.RollbackTrans;
|
||||||
|
application.MessageBox('操作失败!', '提示信息', 0);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
|
|
|
@ -33,7 +33,7 @@ uses
|
||||||
U_CP_COL_XL_ZD, U_CKPDlist, U_ClothContractList_HZ, U_ProductOrderNewList_ZD,
|
U_CP_COL_XL_ZD, U_CKPDlist, U_ClothContractList_HZ, U_ProductOrderNewList_ZD,
|
||||||
U_ClothContractList_SJDCK, U_KH_XS_YP_list, U_ProductOrderNewList_BH,
|
U_ClothContractList_SJDCK, U_KH_XS_YP_list, U_ProductOrderNewList_BH,
|
||||||
U_ClothContractList_HZ1, U_ClothContractList_CP, U_ClothContractList_SJD,
|
U_ClothContractList_HZ1, U_ClothContractList_CP, U_ClothContractList_SJD,
|
||||||
U_ClothContractList_SJDMX, U_ClothContractList_PBKC;
|
U_ClothContractList_Dp, U_ClothContractList_SJDMX, U_ClothContractList_PBKC;
|
||||||
|
|
||||||
/////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////
|
||||||
// ¹¦ÄÜ˵Ã÷:È¡DllÖеô°Ìå //
|
// ¹¦ÄÜ˵Ã÷:È¡DllÖеô°Ìå //
|
||||||
|
@ -80,8 +80,7 @@ begin
|
||||||
SetLength(user, 255);
|
SetLength(user, 255);
|
||||||
SetLength(pswd, 255);
|
SetLength(pswd, 255);
|
||||||
|
|
||||||
|
server := '101.132.143.144,7781';
|
||||||
server := '101.132.143.144,7781';
|
|
||||||
// server:='.';
|
// server:='.';
|
||||||
dtbase := 'hengmingdata';
|
dtbase := 'hengmingdata';
|
||||||
user := 'rtsa';
|
user := 'rtsa';
|
||||||
|
@ -619,10 +618,10 @@ begin
|
||||||
BorderStyle := mborderstyle;
|
BorderStyle := mborderstyle;
|
||||||
//show;
|
//show;
|
||||||
end;
|
end;
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
frmCpRkSaoMNew.BringToFront;
|
frmCpRkSaoMNew.BringToFront;
|
||||||
//句柄
|
//句柄
|
||||||
mnewHandle := frmCpRkSaoMNew.Handle;
|
mnewHandle := frmCpRkSaoMNew.Handle;
|
||||||
|
|
||||||
end;
|
end;
|
||||||
|
@ -659,16 +658,16 @@ begin
|
||||||
FormStyle := mstyle;
|
FormStyle := mstyle;
|
||||||
windowState := mstate;
|
windowState := mstate;
|
||||||
BorderStyle := mborderstyle;
|
BorderStyle := mborderstyle;
|
||||||
//show;
|
//show;
|
||||||
end;
|
end;
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
frmClothContractList_CG.BringToFront;
|
frmClothContractList_CG.BringToFront;
|
||||||
//句柄
|
//句柄
|
||||||
mnewHandle := frmClothContractList_CG.Handle;
|
mnewHandle := frmClothContractList_CG.Handle;
|
||||||
|
|
||||||
end;
|
end;
|
||||||
152: //坯布采购 到货 投匹
|
|
||||||
|
152: //坯布采购 回修 坯布点色计划
|
||||||
begin
|
begin
|
||||||
if frmClothContractList_Tp = nil then
|
if frmClothContractList_Tp = nil then
|
||||||
begin
|
begin
|
||||||
|
@ -709,7 +708,28 @@ begin
|
||||||
mnewHandle := frmClothContractList_JG.Handle;
|
mnewHandle := frmClothContractList_JG.Handle;
|
||||||
|
|
||||||
end;
|
end;
|
||||||
154: //坯布采购 到货 投匹
|
125: //坯布调拨管理
|
||||||
|
begin
|
||||||
|
if frmClothContractList_Dp = nil then
|
||||||
|
begin
|
||||||
|
frmClothContractList_Dp := TfrmClothContractList_Dp.Create(application.MainForm);
|
||||||
|
with frmClothContractList_Dp do
|
||||||
|
begin
|
||||||
|
caption := Trim(Title);
|
||||||
|
fDParameters1 := trim(DParameters1);
|
||||||
|
FormStyle := mstyle;
|
||||||
|
windowState := mstate;
|
||||||
|
BorderStyle := mborderstyle;
|
||||||
|
//show;
|
||||||
|
end;
|
||||||
|
end
|
||||||
|
else
|
||||||
|
frmClothContractList_Dp.BringToFront;
|
||||||
|
//句柄
|
||||||
|
mnewHandle := frmClothContractList_Dp.Handle;
|
||||||
|
|
||||||
|
end;
|
||||||
|
154: //坯布库存查询
|
||||||
begin
|
begin
|
||||||
if frmClothContractList_Help = nil then
|
if frmClothContractList_Help = nil then
|
||||||
begin
|
begin
|
||||||
|
|
|
@ -243,18 +243,11 @@ object frmZdyAttachCP: TfrmZdyAttachCP
|
||||||
end
|
end
|
||||||
object v2Column3: TcxGridDBColumn
|
object v2Column3: TcxGridDBColumn
|
||||||
Caption = #35268#26684
|
Caption = #35268#26684
|
||||||
DataBinding.FieldName = 'DEFstr1'
|
DataBinding.FieldName = 'DEFstr4'
|
||||||
PropertiesClassName = 'TcxTextEditProperties'
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
HeaderAlignmentHorz = taCenter
|
HeaderAlignmentHorz = taCenter
|
||||||
Width = 72
|
Width = 72
|
||||||
end
|
end
|
||||||
object v2Column4: TcxGridDBColumn
|
|
||||||
Caption = #25104#20221
|
|
||||||
DataBinding.FieldName = 'DEFstr2'
|
|
||||||
PropertiesClassName = 'TcxTextEditProperties'
|
|
||||||
HeaderAlignmentHorz = taCenter
|
|
||||||
Width = 74
|
|
||||||
end
|
|
||||||
object v2Column5: TcxGridDBColumn
|
object v2Column5: TcxGridDBColumn
|
||||||
Caption = #39068#33394
|
Caption = #39068#33394
|
||||||
DataBinding.FieldName = 'DEFstr3'
|
DataBinding.FieldName = 'DEFstr3'
|
||||||
|
@ -270,14 +263,14 @@ object frmZdyAttachCP: TfrmZdyAttachCP
|
||||||
end
|
end
|
||||||
object v2Column9: TcxGridDBColumn
|
object v2Column9: TcxGridDBColumn
|
||||||
Caption = #38376#24133
|
Caption = #38376#24133
|
||||||
DataBinding.FieldName = 'DEFstr7'
|
DataBinding.FieldName = 'DEFstr1'
|
||||||
PropertiesClassName = 'TcxTextEditProperties'
|
PropertiesClassName = 'TcxTextEditProperties'
|
||||||
HeaderAlignmentHorz = taCenter
|
HeaderAlignmentHorz = taCenter
|
||||||
Width = 73
|
Width = 73
|
||||||
end
|
end
|
||||||
object v2Column7: TcxGridDBColumn
|
object v2Column7: TcxGridDBColumn
|
||||||
Caption = #20811#37325
|
Caption = #20811#37325
|
||||||
DataBinding.FieldName = 'DEFstr8'
|
DataBinding.FieldName = 'DEFstr2'
|
||||||
HeaderAlignmentHorz = taCenter
|
HeaderAlignmentHorz = taCenter
|
||||||
Width = 61
|
Width = 61
|
||||||
end
|
end
|
||||||
|
@ -294,6 +287,12 @@ object frmZdyAttachCP: TfrmZdyAttachCP
|
||||||
HeaderAlignmentHorz = taCenter
|
HeaderAlignmentHorz = taCenter
|
||||||
Width = 60
|
Width = 60
|
||||||
end
|
end
|
||||||
|
object Tv2Column2: TcxGridDBColumn
|
||||||
|
Caption = #33394#21495
|
||||||
|
DataBinding.FieldName = 'DEFstr10'
|
||||||
|
HeaderAlignmentHorz = taCenter
|
||||||
|
Width = 60
|
||||||
|
end
|
||||||
end
|
end
|
||||||
object cxGridLevel1: TcxGridLevel
|
object cxGridLevel1: TcxGridLevel
|
||||||
GridView = Tv2
|
GridView = Tv2
|
||||||
|
|
|
@ -55,7 +55,6 @@ type
|
||||||
v2Column1: TcxGridDBColumn;
|
v2Column1: TcxGridDBColumn;
|
||||||
v2Column2: TcxGridDBColumn;
|
v2Column2: TcxGridDBColumn;
|
||||||
v2Column3: TcxGridDBColumn;
|
v2Column3: TcxGridDBColumn;
|
||||||
v2Column4: TcxGridDBColumn;
|
|
||||||
v2Column5: TcxGridDBColumn;
|
v2Column5: TcxGridDBColumn;
|
||||||
v2Column9: TcxGridDBColumn;
|
v2Column9: TcxGridDBColumn;
|
||||||
Label1: TLabel;
|
Label1: TLabel;
|
||||||
|
@ -70,6 +69,7 @@ type
|
||||||
defnote3: TEdit;
|
defnote3: TEdit;
|
||||||
Label4: TLabel;
|
Label4: TLabel;
|
||||||
Tv2Column1: TcxGridDBColumn;
|
Tv2Column1: TcxGridDBColumn;
|
||||||
|
Tv2Column2: TcxGridDBColumn;
|
||||||
procedure FormDestroy(Sender: TObject);
|
procedure FormDestroy(Sender: TObject);
|
||||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||||
procedure TBCloseClick(Sender: TObject);
|
procedure TBCloseClick(Sender: TObject);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user