111
This commit is contained in:
parent
eeaac35002
commit
5e37c18e31
|
|
@ -846,7 +846,7 @@ object frmBaoGuanInPut: TfrmBaoGuanInPut
|
|||
Height = 20
|
||||
Hint = 'OrdConPrcNote/'#20215#26684#26465#27454
|
||||
TabOrder = 6
|
||||
Text = 'C&F'
|
||||
Text = 'FOB'
|
||||
OnBtnClick = B6ChuYunGangBtnClick
|
||||
end
|
||||
object F2YunFee: TEdit
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
object frmConLCInPutDC: TfrmConLCInPutDC
|
||||
Left = 166
|
||||
Top = 50
|
||||
Left = 299
|
||||
Top = 79
|
||||
Width = 1073
|
||||
Height = 775
|
||||
Caption = #35746#33329#25351#31034#20070#24405#20837
|
||||
|
|
@ -621,7 +621,7 @@ object frmConLCInPutDC: TfrmConLCInPutDC
|
|||
Height = 20
|
||||
Hint = 'YFCF/'#36816#36153#25215#20184
|
||||
TabOrder = 13
|
||||
Text = 'FREIGHT PREPAID'
|
||||
Text = 'FREIGHT COLLECT'
|
||||
OnBtnUpClick = TOPlaceBtnUpClick
|
||||
OnBtnDnClick = SKBankBtnDnClick
|
||||
end
|
||||
|
|
|
|||
|
|
@ -211,7 +211,8 @@ begin
|
|||
FMainId := '';
|
||||
DCNO.Text := '系统自动编码';
|
||||
OrdConPrcNote.Text := 'FOB';
|
||||
YFCF.Text := 'FREIGHT PREPAID';
|
||||
YFCF.Text := 'FREIGHT COLLECT';
|
||||
|
||||
Order_Sub.DisableControls;
|
||||
with Order_Sub do
|
||||
begin
|
||||
|
|
|
|||
|
|
@ -1,317 +0,0 @@
|
|||
(**************************************************)
|
||||
|
||||
unit AES;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
SysUtils, Classes, Math, ElAES;
|
||||
|
||||
type
|
||||
TKeyBit = (kb128, kb192, kb256);
|
||||
|
||||
function StrToHex(Value: string): string;
|
||||
function HexToStr(Value: string): string;
|
||||
function EncryptString(Value: string; Key: string;
|
||||
KeyBit: TKeyBit = kb128): string;
|
||||
function DecryptString(Value: string; Key: string;
|
||||
KeyBit: TKeyBit = kb128): string;
|
||||
function EncryptStream(Stream: TStream; Key: string;
|
||||
KeyBit: TKeyBit = kb128): TStream;
|
||||
function DecryptStream(Stream: TStream; Key: string;
|
||||
KeyBit: TKeyBit = kb128): TStream;
|
||||
procedure EncryptFile(SourceFile, DestFile: string;
|
||||
Key: string; KeyBit: TKeyBit = kb128);
|
||||
procedure DecryptFile(SourceFile, DestFile: string;
|
||||
Key: string; KeyBit: TKeyBit = kb128);
|
||||
|
||||
implementation
|
||||
|
||||
function StrToHex(Value: string): string;
|
||||
var
|
||||
I: Integer;
|
||||
begin
|
||||
Result := '';
|
||||
for I := 1 to Length(Value) do
|
||||
Result := Result + IntToHex(Ord(Value[I]), 2);
|
||||
end;
|
||||
|
||||
function HexToStr(Value: string): string;
|
||||
var
|
||||
I: Integer;
|
||||
begin
|
||||
Result := '';
|
||||
for I := 1 to Length(Value) do
|
||||
begin
|
||||
if ((I mod 2) = 1) then
|
||||
Result := Result + Chr(StrToInt('0x'+ Copy(Value, I, 2)));
|
||||
end;
|
||||
end;
|
||||
|
||||
{ -- 字符串加密函数 默认按照 128 位密匙加密 -- }
|
||||
function EncryptString(Value: string; Key: string;
|
||||
KeyBit: TKeyBit = kb128): string;
|
||||
var
|
||||
SS, DS: TStringStream;
|
||||
Size: Int64;
|
||||
AESKey128: TAESKey128;
|
||||
AESKey192: TAESKey192;
|
||||
AESKey256: TAESKey256;
|
||||
begin
|
||||
Result := '';
|
||||
SS := TStringStream.Create(Value);
|
||||
DS := TStringStream.Create('');
|
||||
try
|
||||
Size := SS.Size;
|
||||
DS.WriteBuffer(Size, SizeOf(Size));
|
||||
{ -- 128 位密匙最大长度为 16 个字符 -- }
|
||||
if KeyBit = kb128 then
|
||||
begin
|
||||
FillChar(AESKey128, SizeOf(AESKey128), 0 );
|
||||
Move(PChar(Key)^, AESKey128, Min(SizeOf(AESKey128), Length(Key)));
|
||||
EncryptAESStreamECB(SS, 0, AESKey128, DS);
|
||||
end;
|
||||
{ -- 192 位密匙最大长度为 24 个字符 -- }
|
||||
if KeyBit = kb192 then
|
||||
begin
|
||||
FillChar(AESKey192, SizeOf(AESKey192), 0 );
|
||||
Move(PChar(Key)^, AESKey192, Min(SizeOf(AESKey192), Length(Key)));
|
||||
EncryptAESStreamECB(SS, 0, AESKey192, DS);
|
||||
end;
|
||||
{ -- 256 位密匙最大长度为 32 个字符 -- }
|
||||
if KeyBit = kb256 then
|
||||
begin
|
||||
FillChar(AESKey256, SizeOf(AESKey256), 0 );
|
||||
Move(PChar(Key)^, AESKey256, Min(SizeOf(AESKey256), Length(Key)));
|
||||
EncryptAESStreamECB(SS, 0, AESKey256, DS);
|
||||
end;
|
||||
Result := StrToHex(DS.DataString);
|
||||
finally
|
||||
SS.Free;
|
||||
DS.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
{ -- 字符串解密函数 默认按照 128 位密匙解密 -- }
|
||||
function DecryptString(Value: string; Key: string;
|
||||
KeyBit: TKeyBit = kb128): string;
|
||||
var
|
||||
SS, DS: TStringStream;
|
||||
Size: Int64;
|
||||
AESKey128: TAESKey128;
|
||||
AESKey192: TAESKey192;
|
||||
AESKey256: TAESKey256;
|
||||
begin
|
||||
Result := '';
|
||||
SS := TStringStream.Create(HexToStr(Value));
|
||||
DS := TStringStream.Create('');
|
||||
try
|
||||
Size := SS.Size;
|
||||
SS.ReadBuffer(Size, SizeOf(Size));
|
||||
{ -- 128 位密匙最大长度为 16 个字符 -- }
|
||||
if KeyBit = kb128 then
|
||||
begin
|
||||
FillChar(AESKey128, SizeOf(AESKey128), 0 );
|
||||
Move(PChar(Key)^, AESKey128, Min(SizeOf(AESKey128), Length(Key)));
|
||||
DecryptAESStreamECB(SS, SS.Size - SS.Position, AESKey128, DS);
|
||||
end;
|
||||
{ -- 192 位密匙最大长度为 24 个字符 -- }
|
||||
if KeyBit = kb192 then
|
||||
begin
|
||||
FillChar(AESKey192, SizeOf(AESKey192), 0 );
|
||||
Move(PChar(Key)^, AESKey192, Min(SizeOf(AESKey192), Length(Key)));
|
||||
DecryptAESStreamECB(SS, SS.Size - SS.Position, AESKey192, DS);
|
||||
end;
|
||||
{ -- 256 位密匙最大长度为 32 个字符 -- }
|
||||
if KeyBit = kb256 then
|
||||
begin
|
||||
FillChar(AESKey256, SizeOf(AESKey256), 0 );
|
||||
Move(PChar(Key)^, AESKey256, Min(SizeOf(AESKey256), Length(Key)));
|
||||
DecryptAESStreamECB(SS, SS.Size - SS.Position, AESKey256, DS);
|
||||
end;
|
||||
Result := DS.DataString;
|
||||
finally
|
||||
SS.Free;
|
||||
DS.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
{ -- 流加密函数 默认按照 128 位密匙解密 -- }
|
||||
function EncryptStream(Stream: TStream; Key: string;
|
||||
KeyBit: TKeyBit = kb128): TStream;
|
||||
var
|
||||
Count: Int64;
|
||||
OutStrm: TStream;
|
||||
AESKey128: TAESKey128;
|
||||
AESKey192: TAESKey192;
|
||||
AESKey256: TAESKey256;
|
||||
begin
|
||||
OutStrm := TStream.Create;
|
||||
Stream.Position := 0;
|
||||
Count := Stream.Size;
|
||||
OutStrm.Write(Count, SizeOf(Count));
|
||||
try
|
||||
{ -- 128 位密匙最大长度为 16 个字符 -- }
|
||||
if KeyBit = kb128 then
|
||||
begin
|
||||
FillChar(AESKey128, SizeOf(AESKey128), 0 );
|
||||
Move(PChar(Key)^, AESKey128, Min(SizeOf(AESKey128), Length(Key)));
|
||||
EncryptAESStreamECB(Stream, 0, AESKey128, OutStrm);
|
||||
end;
|
||||
{ -- 192 位密匙最大长度为 24 个字符 -- }
|
||||
if KeyBit = kb192 then
|
||||
begin
|
||||
FillChar(AESKey192, SizeOf(AESKey192), 0 );
|
||||
Move(PChar(Key)^, AESKey192, Min(SizeOf(AESKey192), Length(Key)));
|
||||
EncryptAESStreamECB(Stream, 0, AESKey192, OutStrm);
|
||||
end;
|
||||
{ -- 256 位密匙最大长度为 32 个字符 -- }
|
||||
if KeyBit = kb256 then
|
||||
begin
|
||||
FillChar(AESKey256, SizeOf(AESKey256), 0 );
|
||||
Move(PChar(Key)^, AESKey256, Min(SizeOf(AESKey256), Length(Key)));
|
||||
EncryptAESStreamECB(Stream, 0, AESKey256, OutStrm);
|
||||
end;
|
||||
Result := OutStrm;
|
||||
finally
|
||||
OutStrm.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
{ -- 流解密函数 默认按照 128 位密匙解密 -- }
|
||||
function DecryptStream(Stream: TStream; Key: string;
|
||||
KeyBit: TKeyBit = kb128): TStream;
|
||||
var
|
||||
Count, OutPos: Int64;
|
||||
OutStrm: TStream;
|
||||
AESKey128: TAESKey128;
|
||||
AESKey192: TAESKey192;
|
||||
AESKey256: TAESKey256;
|
||||
begin
|
||||
OutStrm := TStream.Create;
|
||||
Stream.Position := 0;
|
||||
OutPos :=OutStrm.Position;
|
||||
Stream.ReadBuffer(Count, SizeOf(Count));
|
||||
try
|
||||
{ -- 128 位密匙最大长度为 16 个字符 -- }
|
||||
if KeyBit = kb128 then
|
||||
begin
|
||||
FillChar(AESKey128, SizeOf(AESKey128), 0 );
|
||||
Move(PChar(Key)^, AESKey128, Min(SizeOf(AESKey128), Length(Key)));
|
||||
DecryptAESStreamECB(Stream, Stream.Size - Stream.Position,
|
||||
AESKey128, OutStrm);
|
||||
end;
|
||||
{ -- 192 位密匙最大长度为 24 个字符 -- }
|
||||
if KeyBit = kb192 then
|
||||
begin
|
||||
FillChar(AESKey192, SizeOf(AESKey192), 0 );
|
||||
Move(PChar(Key)^, AESKey192, Min(SizeOf(AESKey192), Length(Key)));
|
||||
DecryptAESStreamECB(Stream, Stream.Size - Stream.Position,
|
||||
AESKey192, OutStrm);
|
||||
end;
|
||||
{ -- 256 位密匙最大长度为 32 个字符 -- }
|
||||
if KeyBit = kb256 then
|
||||
begin
|
||||
FillChar(AESKey256, SizeOf(AESKey256), 0 );
|
||||
Move(PChar(Key)^, AESKey256, Min(SizeOf(AESKey256), Length(Key)));
|
||||
DecryptAESStreamECB(Stream, Stream.Size - Stream.Position,
|
||||
AESKey256, OutStrm);
|
||||
end;
|
||||
OutStrm.Size := OutPos + Count;
|
||||
OutStrm.Position := OutPos;
|
||||
Result := OutStrm;
|
||||
finally
|
||||
OutStrm.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
{ -- 文件加密函数 默认按照 128 位密匙解密 -- }
|
||||
procedure EncryptFile(SourceFile, DestFile: string;
|
||||
Key: string; KeyBit: TKeyBit = kb128);
|
||||
var
|
||||
SFS, DFS: TFileStream;
|
||||
Size: Int64;
|
||||
AESKey128: TAESKey128;
|
||||
AESKey192: TAESKey192;
|
||||
AESKey256: TAESKey256;
|
||||
begin
|
||||
SFS := TFileStream.Create(SourceFile, fmOpenRead);
|
||||
try
|
||||
DFS := TFileStream.Create(DestFile, fmCreate);
|
||||
try
|
||||
Size := SFS.Size;
|
||||
DFS.WriteBuffer(Size, SizeOf(Size));
|
||||
{ -- 128 位密匙最大长度为 16 个字符 -- }
|
||||
if KeyBit = kb128 then
|
||||
begin
|
||||
FillChar(AESKey128, SizeOf(AESKey128), 0 );
|
||||
Move(PChar(Key)^, AESKey128, Min(SizeOf(AESKey128), Length(Key)));
|
||||
EncryptAESStreamECB(SFS, 0, AESKey128, DFS);
|
||||
end;
|
||||
{ -- 192 位密匙最大长度为 24 个字符 -- }
|
||||
if KeyBit = kb192 then
|
||||
begin
|
||||
FillChar(AESKey192, SizeOf(AESKey192), 0 );
|
||||
Move(PChar(Key)^, AESKey192, Min(SizeOf(AESKey192), Length(Key)));
|
||||
EncryptAESStreamECB(SFS, 0, AESKey192, DFS);
|
||||
end;
|
||||
{ -- 256 位密匙最大长度为 32 个字符 -- }
|
||||
if KeyBit = kb256 then
|
||||
begin
|
||||
FillChar(AESKey256, SizeOf(AESKey256), 0 );
|
||||
Move(PChar(Key)^, AESKey256, Min(SizeOf(AESKey256), Length(Key)));
|
||||
EncryptAESStreamECB(SFS, 0, AESKey256, DFS);
|
||||
end;
|
||||
finally
|
||||
DFS.Free;
|
||||
end;
|
||||
finally
|
||||
SFS.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
{ -- 文件解密函数 默认按照 128 位密匙解密 -- }
|
||||
procedure DecryptFile(SourceFile, DestFile: string;
|
||||
Key: string; KeyBit: TKeyBit = kb128);
|
||||
var
|
||||
SFS, DFS: TFileStream;
|
||||
Size: Int64;
|
||||
AESKey128: TAESKey128;
|
||||
AESKey192: TAESKey192;
|
||||
AESKey256: TAESKey256;
|
||||
begin
|
||||
SFS := TFileStream.Create(SourceFile, fmOpenRead);
|
||||
try
|
||||
SFS.ReadBuffer(Size, SizeOf(Size));
|
||||
DFS := TFileStream.Create(DestFile, fmCreate);
|
||||
try
|
||||
{ -- 128 位密匙最大长度为 16 个字符 -- }
|
||||
if KeyBit = kb128 then
|
||||
begin
|
||||
FillChar(AESKey128, SizeOf(AESKey128), 0 );
|
||||
Move(PChar(Key)^, AESKey128, Min(SizeOf(AESKey128), Length(Key)));
|
||||
DecryptAESStreamECB(SFS, SFS.Size - SFS.Position, AESKey128, DFS);
|
||||
end;
|
||||
{ -- 192 位密匙最大长度为 24 个字符 -- }
|
||||
if KeyBit = kb192 then
|
||||
begin
|
||||
FillChar(AESKey192, SizeOf(AESKey192), 0 );
|
||||
Move(PChar(Key)^, AESKey192, Min(SizeOf(AESKey192), Length(Key)));
|
||||
DecryptAESStreamECB(SFS, SFS.Size - SFS.Position, AESKey192, DFS);
|
||||
end;
|
||||
{ -- 256 位密匙最大长度为 32 个字符 -- }
|
||||
if KeyBit = kb256 then
|
||||
begin
|
||||
FillChar(AESKey256, SizeOf(AESKey256), 0 );
|
||||
Move(PChar(Key)^, AESKey256, Min(SizeOf(AESKey256), Length(Key)));
|
||||
DecryptAESStreamECB(SFS, SFS.Size - SFS.Position, AESKey256, DFS);
|
||||
end;
|
||||
DFS.Size := Size;
|
||||
finally
|
||||
DFS.Free;
|
||||
end;
|
||||
finally
|
||||
SFS.Free;
|
||||
end;
|
||||
end;
|
||||
end.
|
||||
|
|
@ -1,42 +0,0 @@
|
|||
-$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
|
||||
|
|
@ -1,138 +0,0 @@
|
|||
[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\项目代码\振永\报关管理(BaoGuan.dll)\testDll.exe
|
||||
Launcher=
|
||||
UseLauncher=0
|
||||
DebugCWD=
|
||||
[Language]
|
||||
ActiveLang=
|
||||
ProjectLang=
|
||||
RootDir=
|
||||
[Version Info]
|
||||
IncludeVerInfo=0
|
||||
AutoIncBuild=0
|
||||
MajorVer=1
|
||||
MinorVer=0
|
||||
Release=0
|
||||
Build=0
|
||||
Debug=0
|
||||
PreRelease=0
|
||||
Special=0
|
||||
Private=0
|
||||
DLL=0
|
||||
Locale=2052
|
||||
CodePage=936
|
||||
[Version Info Keys]
|
||||
CompanyName=
|
||||
FileDescription=
|
||||
FileVersion=1.0.0.0
|
||||
InternalName=
|
||||
LegalCopyright=
|
||||
LegalTrademarks=
|
||||
OriginalFilename=
|
||||
ProductName=
|
||||
ProductVersion=1.0.0.0
|
||||
Comments=
|
||||
[Excluded Packages]
|
||||
c:\program files\borland\delphi7\Bin\DBWEBXPRT.BPL=Borland Web Wizard Package
|
||||
|
|
@ -1,126 +0,0 @@
|
|||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<ProjectGuid>{01F1D018-6773-4812-A6A3-E4BD48ED356E}</ProjectGuid>
|
||||
<MainSource>BaoGuan.dpr</MainSource>
|
||||
<Base>True</Base>
|
||||
<Config Condition="'$(Config)'==''">Debug</Config>
|
||||
<Platform Condition="'$(Platform)'==''">Win32</Platform>
|
||||
<TargetedPlatforms>38043</TargetedPlatforms>
|
||||
<AppType>Library</AppType>
|
||||
<FrameworkType>VCL</FrameworkType>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
|
||||
<Base>true</Base>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Config)'=='Release' or '$(Cfg_1)'!=''">
|
||||
<Cfg_1>true</Cfg_1>
|
||||
<CfgParent>Base</CfgParent>
|
||||
<Base>true</Base>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Config)'=='Debug' or '$(Cfg_2)'!=''">
|
||||
<Cfg_2>true</Cfg_2>
|
||||
<CfgParent>Base</CfgParent>
|
||||
<Base>true</Base>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Base)'!=''">
|
||||
<DCC_E>false</DCC_E>
|
||||
<DCC_F>false</DCC_F>
|
||||
<DCC_K>false</DCC_K>
|
||||
<DCC_N>true</DCC_N>
|
||||
<DCC_S>false</DCC_S>
|
||||
<DCC_ImageBase>00400000</DCC_ImageBase>
|
||||
<DCC_DebugInformation>1</DCC_DebugInformation>
|
||||
<DCC_SymbolReferenceInfo>1</DCC_SymbolReferenceInfo>
|
||||
<DCC_UnitAlias>WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;$(DCC_UnitAlias)</DCC_UnitAlias>
|
||||
<DCC_UnitSearchPath>D:\富通ERP;$(DCC_UnitSearchPath)</DCC_UnitSearchPath>
|
||||
<DCC_UsePackage>vcl;rtl;vclx;indy;inet;xmlrtl;vclie;inetdbbde;inetdbxpress;dbrtl;dsnap;dsnapcon;vcldb;soaprtl;VclSmp;dbexpress;dbxcds;bdertl;vcldbx;webdsnap;websnap;adortl;ibxpress;teeui;teedb;tee;dss;visualclx;visualdbclx;vclactnband;vclshlctrls;IntrawebDB_50_70;Intraweb_50_70;dclOffice2k;Rave50CLX;Rave50VCL;$(DCC_UsePackage)</DCC_UsePackage>
|
||||
<GenDll>true</GenDll>
|
||||
<SanitizedProjectName>BaoGuan</SanitizedProjectName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Cfg_1)'!=''">
|
||||
<DCC_Define>RELEASE;$(DCC_Define)</DCC_Define>
|
||||
<DCC_DebugInformation>0</DCC_DebugInformation>
|
||||
<DCC_LocalDebugSymbols>false</DCC_LocalDebugSymbols>
|
||||
<DCC_SymbolReferenceInfo>0</DCC_SymbolReferenceInfo>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Cfg_2)'!=''">
|
||||
<DCC_Define>DEBUG;$(DCC_Define)</DCC_Define>
|
||||
<DCC_Optimize>false</DCC_Optimize>
|
||||
<DCC_GenerateStackFrames>true</DCC_GenerateStackFrames>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<DelphiCompile Include="$(MainSource)">
|
||||
<MainSource>MainSource</MainSource>
|
||||
</DelphiCompile>
|
||||
<DCCReference Include="U_GetDllForm.pas"/>
|
||||
<DCCReference Include="U_DataLink.pas">
|
||||
<Form>DataLink_DDMD</Form>
|
||||
<DesignClass>TDataModule</DesignClass>
|
||||
</DCCReference>
|
||||
<DCCReference Include="U_FjList.pas">
|
||||
<Form>frmFjList</Form>
|
||||
</DCCReference>
|
||||
<DCCReference Include="U_ZDYHelp4.pas">
|
||||
<Form>frmZDYHelp4</Form>
|
||||
</DCCReference>
|
||||
<DCCReference Include="U_FjList_RZ.pas">
|
||||
<Form>frmFjList_RZ</Form>
|
||||
</DCCReference>
|
||||
<DCCReference Include="..\..\..\ThreeFun\Fun\U_CompressionFun.pas"/>
|
||||
<DCCReference Include="U_YFGLInPut.pas">
|
||||
<Form>frmYFGLInPut</Form>
|
||||
</DCCReference>
|
||||
<DCCReference Include="U_BaoGuanCRKCX.pas">
|
||||
<Form>frmBaoGuanCRKCX</Form>
|
||||
</DCCReference>
|
||||
<DCCReference Include="..\..\..\ThreeFun\Fun\U_RTFun.pas"/>
|
||||
<DCCReference Include="..\..\..\ThreeFun\Fun\U_Fun.pas"/>
|
||||
<DCCReference Include="..\..\..\ThreeFun\Fun\U_SelExportField.pas">
|
||||
<Form>frmSelExportField</Form>
|
||||
</DCCReference>
|
||||
<DCCReference Include="..\..\..\ThreeFun\Form\U_ColumnBandSet.pas">
|
||||
<Form>frmColumnBandSet</Form>
|
||||
</DCCReference>
|
||||
<DCCReference Include="..\..\..\ThreeFun\Form\U_ColumnSet.pas">
|
||||
<Form>frmColumnSet</Form>
|
||||
</DCCReference>
|
||||
<DCCReference Include="..\..\..\ThreeFun\Form\U_SelPrintFieldNew.pas">
|
||||
<Form>frmSelPrintFieldNew</Form>
|
||||
</DCCReference>
|
||||
<BuildConfiguration Include="Debug">
|
||||
<Key>Cfg_2</Key>
|
||||
<CfgParent>Base</CfgParent>
|
||||
</BuildConfiguration>
|
||||
<BuildConfiguration Include="Base">
|
||||
<Key>Base</Key>
|
||||
</BuildConfiguration>
|
||||
<BuildConfiguration Include="Release">
|
||||
<Key>Cfg_1</Key>
|
||||
<CfgParent>Base</CfgParent>
|
||||
</BuildConfiguration>
|
||||
</ItemGroup>
|
||||
<ProjectExtensions>
|
||||
<Borland.Personality>Delphi.Personality.12</Borland.Personality>
|
||||
<Borland.ProjectType/>
|
||||
<BorlandProject>
|
||||
<Delphi.Personality>
|
||||
<Source>
|
||||
<Source Name="MainSource">BaoGuan.dpr</Source>
|
||||
</Source>
|
||||
</Delphi.Personality>
|
||||
<Platforms>
|
||||
<Platform value="Android">True</Platform>
|
||||
<Platform value="Android64">True</Platform>
|
||||
<Platform value="iOSDevice64">True</Platform>
|
||||
<Platform value="iOSSimulator">True</Platform>
|
||||
<Platform value="Linux64">True</Platform>
|
||||
<Platform value="OSX64">True</Platform>
|
||||
<Platform value="Win32">True</Platform>
|
||||
<Platform value="Win64">True</Platform>
|
||||
</Platforms>
|
||||
</BorlandProject>
|
||||
<ProjectFileVersion>12</ProjectFileVersion>
|
||||
</ProjectExtensions>
|
||||
<Import Project="$(BDS)\Bin\CodeGear.Delphi.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Delphi.Targets')"/>
|
||||
<Import Project="$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj" Condition="Exists('$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj')"/>
|
||||
</Project>
|
||||
Binary file not shown.
Binary file not shown.
|
Before Width: | Height: | Size: 766 B |
|
|
@ -1,3 +0,0 @@
|
|||
[.ShellClassInfo]
|
||||
IconFile=C:\Program Files (x86)\360\360WangPan\new_desktop_win7.ico
|
||||
IconIndex=0
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,2 +0,0 @@
|
|||
[导出设置]
|
||||
导出字段=Begin/选择/外销发票号/公司/指示单号/报关品名/柜型/出货数量/单位/金额/出货日/船期/付款条件/部门/国家/业务员/货代/目的港
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
[FILEPATH]
|
||||
FileClass=YP,AA,BB,HT
|
||||
YP=D:\YP
|
||||
AA=D:\AA
|
||||
BB=D:\BB
|
||||
HT=D:\HT
|
||||
OTHER=D:\OTHER
|
||||
|
|
@ -1,164 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TfrxReport Version="5.6.1" DataSet="frxDBDataset1" DataSetName="frxDBDataset1" DotMatrixReport="False" IniFile="\Software\Fast Reports" OldStyleProgress="True" PreviewOptions.Buttons="4095" PreviewOptions.Zoom="1" PrintOptions.Printer="Default" PrintOptions.PrintOnSheet="0" ReportOptions.CreateDate="44867.5082009144" ReportOptions.Description.Text="" ReportOptions.LastChange="44874.6213397801" ScriptLanguage="PascalScript" ScriptText.Text="begin end.">
|
||||
<Datasets>
|
||||
<item DataSet="frxDBDataset1" DataSetName="frxDBDataset1"/>
|
||||
<item DataSet="frxDBDataset2" DataSetName="frxDBDataset2"/>
|
||||
</Datasets>
|
||||
<TfrxDataPage Name="Data" Height="1000" Left="0" Top="0" Width="1000"/>
|
||||
<TfrxReportPage Name="Page1" PaperWidth="210" PaperHeight="297" PaperSize="9" LeftMargin="10" RightMargin="10" TopMargin="10" BottomMargin="10" ColumnWidth="0" ColumnPositions.Text="" HGuides.Text="" VGuides.Text="">
|
||||
<TfrxMasterData Name="MasterData1" FillType="ftBrush" FillGap.Top="0" FillGap.Left="0" FillGap.Bottom="0" FillGap.Right="0" Height="120.94496" Left="0" Top="287.24428" Width="718.1107" AllowSplit="True" ColumnWidth="0" ColumnGap="0" DataSet="frxDBDataset2" DataSetName="frxDBDataset2" RowCount="0">
|
||||
<TfrxMemoView Name="Memo15" Left="3.77953" Top="11.33859" Width="169.50619394" Height="105.82684" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" SuppressRepeated="True" Text="[frxDBDataset2."zhumaitou"]"/>
|
||||
<TfrxMemoView Name="Memo16" Left="177.63791" Top="11.33859" Width="328.24645394" Height="34.01577" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="1" ParentFont="False" Text="ITEM: [frxDBDataset2."C3BGname"] [frxDBDataset2."C3BGnameEng"] [frxDBDataset2."ywnote"] [frxDBDataset2."conno"]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo17" Left="506.45702" Top="52.91342" Width="203.52196394" Height="64.25201" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaBottom" Text=" [frxDBDataset2."E1BZUnit"][frxDBDataset2."C7BGMoney"] [(IIF(<frxDBDataset2."CYFEE">>0,<frxDBDataset1."E1BZUnit">,''))][(IIF(<frxDBDataset2."CYFEE">>0,<frxDBDataset1."CYFEE">,''))]">
|
||||
<Formats>
|
||||
<item Kind="fkNumeric"/>
|
||||
<item FormatStr="%2.2f" Kind="fkNumeric"/>
|
||||
<item FormatStr="%2.2f" Kind="fkNumeric"/>
|
||||
<item FormatStr="%2.2f" Kind="fkNumeric"/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo19" Left="177.63791" Top="52.91342" Width="328.24645394" Height="64.25201" DataSet="frxDBDataset2" DataSetName="frxDBDataset2" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HideZeros="True" ParentFont="False" VAlign="vaBottom" Text="COMP:[frxDBDataset2."YSChenFen"] WEIGHT: [frxDBDataset2."YSKeZhong"] MORE OR LESS 10GRS/SQM WIDTH:[frxDBDataset2."YSFuKuan"] [frxDBDataset2."C4BGQty"][frxDBDataset2."C5BGUnit"] AT [frxDBDataset2."E1BZUnit"][frxDBDataset2."C6BGprice"]/[frxDBDataset2."C5BGUnit"] [(IIF(<frxDBDataset2."CYQty">>0,'SAMPLES',''))] [frxDBDataset2."CYQty"][(IIF(<frxDBDataset2."CYQty">>0,'AT',''))][(IIF(<frxDBDataset2."CYQty">>0,<frxDBDataset2."E1BZUnit">,''))][(IIF(<frxDBDataset2."CYQty">>0,<frxDBDataset2."C6BGprice">,''))][(IIF(<frxDBDataset2."CYQty">>0,'/'+<frxDBDataset2."C5BGUnit">,''))]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
</TfrxMasterData>
|
||||
<TfrxReportTitle Name="ReportTitle1" FillType="ftBrush" FillGap.Top="0" FillGap.Left="0" FillGap.Bottom="0" FillGap.Right="0" Height="207.87415" Left="0" Top="18.89765" Width="718.1107">
|
||||
<TfrxMemoView Name="Memo2" ShiftMode="smWhenOverlapped" Left="3.77953" Top="18.89765" Width="714.33117" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."gsdz"]"/>
|
||||
<TfrxMemoView Name="Memo3" Left="3.77953" Top="37.7953" Width="714.33117" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-16" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="*** COMMERCIAL INVOICE ***"/>
|
||||
<TfrxMemoView Name="Memo4" Left="3.77953" Top="56.69295" Width="37.7953" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-16" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="TO"/>
|
||||
<TfrxMemoView Name="Memo5" Left="45.35436" Top="56.69295" Width="264.5671" Height="64.25201" StretchMode="smActualHeight" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" Text=" [frxDBDataset1."fkr"]"/>
|
||||
<TfrxMemoView Name="Memo6" Left="408.76189606" Top="56.69295" Width="165.72666394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haRight" ParentFont="False" VAlign="vaCenter" Text="INVOICE NO.:"/>
|
||||
<TfrxMemoView Name="Memo7" Left="408.18924" Top="79.37013" Width="169.50619394" Height="30.23624" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" WordWrap="False" VAlign="vaCenter" Text="SALE CONFIRMATION NO.:"/>
|
||||
<TfrxMemoView Name="Memo8" Left="408.18924" Top="113.3859" Width="169.50619394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haRight" ParentFont="False" VAlign="vaCenter" Text="DATE.:"/>
|
||||
<TfrxMemoView Name="Memo9" Left="578.84074606" Top="56.69295" Width="139.26995394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text=" [frxDBDataset1."A4fpNo"]"/>
|
||||
<TfrxMemoView Name="Memo10" Left="578.26809" Top="79.37013" Width="139.26995394" Height="30.23624" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."A6PONO"]"/>
|
||||
<TfrxMemoView Name="Memo12" Left="7.55906" Top="139.84261" Width="169.50619394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="SHIPPING MARKS"/>
|
||||
<TfrxMemoView Name="Memo13" Left="177.63791" Top="139.84261" Width="328.24645394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="QUANTITY AND DESCRIPTION OF GOODS"/>
|
||||
<TfrxMemoView Name="Memo14" Left="506.45702" Top="139.84261" Width="211.08102394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="AMOUNT"/>
|
||||
<TfrxMemoView Name="Memo1" Left="3.77953" Top="3.46944695195361E-18" Width="714.33117" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-19" Font.Name="Times New Roman" Font.Style="1" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."sellname"]"/>
|
||||
<TfrxMemoView Name="Memo11" Left="177.63791" Top="173.85838" Width="328.24645394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="1" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."sellnote"]"/>
|
||||
<TfrxMemoView Name="Memo18" Left="502.67749" Top="173.85838" Width="211.08102394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."OrdConPrcNote"][(IIF(<frxDBDataset1."OrdConPrcNote">='FOB',<frxDBDataset1."B6ChuYunGang">,<frxDBDataset1."B7DaoHuoGang">))]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo20" Left="578.26809" Top="113.3859" Width="169.50619394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."dydate"]"/>
|
||||
</TfrxReportTitle>
|
||||
<TfrxReportSummary Name="ReportSummary1" FillType="ftBrush" FillGap.Top="0" FillGap.Left="0" FillGap.Bottom="0" FillGap.Right="0" Height="298.58287" Left="0" Top="468.66172" Width="718.1107">
|
||||
<TfrxMemoView Name="Memo22" Left="514.01608" Top="49.13389" Width="195.96290394" Height="64.25201" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HideZeros="True" ParentFont="False" Text="[(IIF(<frxDBDataset1."YSDJ">>0,<frxDBDataset1."E1BZUnit">,''))][frxDBDataset1."YSDJ"] [(IIF(<frxDBDataset1."JMMoney">>0,<frxDBDataset1."E1BZUnit">,''))][frxDBDataset1."JMMoney"] [(IIF(<frxDBDataset1."JSmoney">>0,<frxDBDataset1."E1BZUnit">,''))][frxDBDataset1."JSmoney"] [frxDBDataset1."E1BZUnit"][frxDBDataset1."ZMoney"] ">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo25" Left="173.85838" Top="49.13389" Width="328.24645394" Height="60.47248" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="[(IIF(<frxDBDataset1."YSDJ">>0,'DEPOSIT',''))] [frxDBDataset1."JMSM"] [frxDBDataset1."JSSM"]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo26" Left="7.55906" Top="147.40167" Width="706.19945394" Height="139.84261" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" Text="[frxDBDataset1."GSZH"]"/>
|
||||
<TfrxMemoView Name="Memo21" Left="173.85838" Top="7.55906" Width="328.24645394" Height="30.23624" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="1" ParentFont="False" Text="TOTAL QUANTITY:[SUM(<frxDBDataset1."C4BGQty">,MasterData1)][frxDBDataset1."C5BGUnit"]">
|
||||
<Formats>
|
||||
<item FormatStr="%2.2f" Kind="fkNumeric"/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo23" Left="510.23655" Top="7.55906" Width="199.74243394" Height="30.23624" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="1" ParentFont="False" Text="TOTAL AMOUNT:"/>
|
||||
<TfrxMemoView Name="Memo24" Left="173.85838" Top="120.94496" Width="328.24645394" Height="26.45671" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."note"]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
</TfrxReportSummary>
|
||||
</TfrxReportPage>
|
||||
<TfrxReportPage Name="Page2" PaperWidth="210" PaperHeight="297" PaperSize="9" LeftMargin="10" RightMargin="10" TopMargin="10" BottomMargin="10" ColumnWidth="0" ColumnPositions.Text="" HGuides.Text="" VGuides.Text="">
|
||||
<TfrxMasterData Name="MasterData2" FillType="ftBrush" FillGap.Top="0" FillGap.Left="0" FillGap.Bottom="0" FillGap.Right="0" Height="71.81107" Left="0" Top="287.24428" Width="718.1107" AllowSplit="True" ColumnWidth="0" ColumnGap="0" DataSet="frxDBDataset2" DataSetName="frxDBDataset2" RowCount="0">
|
||||
<TfrxMemoView Name="Memo27" Left="3.77953" Top="11.33859" Width="169.50619394" Height="56.69295" StretchMode="smActualHeight" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" SuppressRepeated="True" Text="[frxDBDataset2."zhumaitou"]"/>
|
||||
<TfrxMemoView Name="Memo28" Left="177.63791" Top="11.33859" Width="298.01021394" Height="34.01577" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="1" ParentFont="False" Text="ITEM: [frxDBDataset2."C3BGname"] [frxDBDataset2."C3BGnameEng"] [frxDBDataset2."ywnote"] [frxDBDataset2."conno"]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo53" Left="600.94527" Top="11.33859" Width="112.81324394" Height="34.01577" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" Text="[frxDBDataset2."rolls"] [frxDBDataset2."bzways"]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo54" Left="480.00031" Top="11.33859" Width="116.59277394" Height="34.01577" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" Text="[frxDBDataset2."C4BGQty"][frxDBDataset2."C5BGUnit"]">
|
||||
<Formats>
|
||||
<item FormatStr="%2.2f" Kind="fkNumeric"/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
</TfrxMasterData>
|
||||
<TfrxReportTitle Name="ReportTitle2" FillType="ftBrush" FillGap.Top="0" FillGap.Left="0" FillGap.Bottom="0" FillGap.Right="0" Height="207.87415" Left="0" Top="18.89765" Width="718.1107">
|
||||
<TfrxMemoView Name="Memo31" ShiftMode="smWhenOverlapped" Left="3.77953" Top="18.89765" Width="714.33117" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."gsdz"]"/>
|
||||
<TfrxMemoView Name="Memo32" Left="3.77953" Top="37.7953" Width="714.33117" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-16" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="*** WEIGHT NOTE ***"/>
|
||||
<TfrxMemoView Name="Memo33" Left="3.77953" Top="56.69295" Width="37.7953" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-16" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="TO"/>
|
||||
<TfrxMemoView Name="Memo34" Left="45.35436" Top="56.69295" Width="264.5671" Height="64.25201" StretchMode="smActualHeight" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" Text=" [frxDBDataset1."fkr"]"/>
|
||||
<TfrxMemoView Name="Memo35" Left="408.76189606" Top="56.69295" Width="165.72666394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haRight" ParentFont="False" VAlign="vaCenter" Text="INVOICE NO.:"/>
|
||||
<TfrxMemoView Name="Memo36" Left="404.40971" Top="79.37013" Width="169.50619394" Height="30.23624" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" WordWrap="False" VAlign="vaCenter" Text="SALE CONFIRMATION NO.:"/>
|
||||
<TfrxMemoView Name="Memo37" Left="408.18924" Top="113.3859" Width="169.50619394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haRight" ParentFont="False" VAlign="vaCenter" Text="DATE.:"/>
|
||||
<TfrxMemoView Name="Memo38" Left="578.84074606" Top="56.69295" Width="139.26995394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text=" [frxDBDataset1."A4fpNo"]"/>
|
||||
<TfrxMemoView Name="Memo39" Left="578.26809" Top="79.37013" Width="139.26995394" Height="30.23624" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."A6PONO"]"/>
|
||||
<TfrxMemoView Name="Memo40" Left="7.55906" Top="139.84261" Width="169.50619394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="SHIPPING MARKS"/>
|
||||
<TfrxMemoView Name="Memo41" Left="181.41744" Top="139.84261" Width="294.23068394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="DESCRIPTION OF GOODS"/>
|
||||
<TfrxMemoView Name="Memo42" Left="604.7248" Top="139.84261" Width="112.81324394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="NO. OF PKGS"/>
|
||||
<TfrxMemoView Name="Memo43" Left="3.77953" Top="3.46944695195361E-18" Width="714.33117" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-19" Font.Name="Times New Roman" Font.Style="1" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."sellname"]"/>
|
||||
<TfrxMemoView Name="Memo44" Left="177.63791" Top="173.85838" Width="298.01021394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="1" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."sellnote"]"/>
|
||||
<TfrxMemoView Name="Memo46" Left="578.26809" Top="113.3859" Width="169.50619394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="[frxDBDataset1."dydate"]"/>
|
||||
<TfrxMemoView Name="Memo45" Left="483.77984" Top="139.84261" Width="116.59277394" Height="18.89765" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="QUANTITY"/>
|
||||
</TfrxReportTitle>
|
||||
<TfrxReportSummary Name="ReportSummary2" FillType="ftBrush" FillGap.Top="0" FillGap.Left="0" FillGap.Bottom="0" FillGap.Right="0" Height="298.58287" Left="0" Top="419.52783" Width="718.1107">
|
||||
<TfrxMemoView Name="Memo50" Left="173.85838" Top="7.55906" Width="301.78974394" Height="30.23624" DisplayFormat.FormatStr="%2.2f" DisplayFormat.Kind="fkNumeric" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="1" HAlign="haRight" ParentFont="False" VAlign="vaBottom" Text="TOTAL :"/>
|
||||
<TfrxMemoView Name="Memo51" Left="480.00031" Top="7.55906" Width="116.59277394" Height="30.23624" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="[SUM(<frxDBDataset1."C4BGQty">,MasterData1)][frxDBDataset1."C5BGUnit"]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo52" Left="11.33859" Top="49.13389" Width="475.64812394" Height="26.45671" DisplayFormat.FormatStr="%2.2f" DisplayFormat.Kind="fkNumeric" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="TOTAL GROSS WEIGHT:[SUM(<frxDBDataset1."E3MaoZ">,MasterData1)]KGS"/>
|
||||
<TfrxMemoView Name="Memo29" Left="604.7248" Top="7.55906" Width="109.03371394" Height="30.23624" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" HAlign="haCenter" ParentFont="False" VAlign="vaCenter" Text="[SUM(<frxDBDataset1."rolls">,MasterData1)][frxDBDataset2."bzways"]">
|
||||
<Formats>
|
||||
<item/>
|
||||
<item/>
|
||||
</Formats>
|
||||
</TfrxMemoView>
|
||||
<TfrxMemoView Name="Memo30" Left="11.33859" Top="75.5906" Width="475.64812394" Height="26.45671" DisplayFormat.FormatStr="%2.2f" DisplayFormat.Kind="fkNumeric" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="TOTAL NET WEIGHT:[SUM(<frxDBDataset1."E4JingZ">,MasterData1)]KGS"/>
|
||||
<TfrxMemoView Name="Memo47" Left="11.33859" Top="105.82684" Width="479.42765394" Height="26.45671" DisplayFormat.FormatStr="%2.3f" DisplayFormat.Kind="fkNumeric" Font.Charset="1" Font.Color="-16777208" Font.Height="-13" Font.Name="Times New Roman" Font.Style="0" ParentFont="False" VAlign="vaCenter" Text="TOTAL MEASUREMENT:[SUM(<frxDBDataset1."BGTJ">,MasterData1)]CBM"/>
|
||||
</TfrxReportSummary>
|
||||
</TfrxReportPage>
|
||||
</TfrxReport>
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
#------------------------------------------------------------------------------
|
||||
VERSION = BWS.01
|
||||
#------------------------------------------------------------------------------
|
||||
!ifndef ROOT
|
||||
ROOT = $(MAKEDIR)\..
|
||||
!endif
|
||||
#------------------------------------------------------------------------------
|
||||
MAKE = $(ROOT)\bin\make.exe -$(MAKEFLAGS) -f$**
|
||||
DCC = $(ROOT)\bin\dcc32.exe $**
|
||||
BRCC = $(ROOT)\bin\brcc32.exe $**
|
||||
#------------------------------------------------------------------------------
|
||||
PROJECTS = testDll.exe ProductPrice.dll
|
||||
#------------------------------------------------------------------------------
|
||||
default: $(PROJECTS)
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
testDll.exe: testDll.dpr
|
||||
$(DCC)
|
||||
|
||||
ProductPrice.dll: ProductPrice.dpr
|
||||
$(DCC)
|
||||
|
||||
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
[SERVER]
|
||||
服务器地址=172.168.1.246
|
||||
软件名称=欣戈纺织
|
||||
|
|
@ -1,348 +0,0 @@
|
|||
object frmBanCpRkOutPut: TfrmBanCpRkOutPut
|
||||
Left = 201
|
||||
Top = 135
|
||||
Width = 1195
|
||||
Height = 503
|
||||
Align = alClient
|
||||
Caption = #25104#21697#20986#24211
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -13
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
Position = poScreenCenter
|
||||
OnClose = FormClose
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 107
|
||||
TextHeight = 13
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1179
|
||||
Height = 430
|
||||
Align = alClient
|
||||
TabOrder = 0
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource3
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skCount
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v2Column5
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v2Column6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Inactive = DataLink_TradeManage.SHuangSe
|
||||
Styles.IncSearch = DataLink_TradeManage.SHuangSe
|
||||
Styles.Selection = DataLink_TradeManage.SHuangSe
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #35746#21333#21495
|
||||
DataBinding.FieldName = 'orderNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #20986#26588#26085#26399
|
||||
DataBinding.FieldName = 'CRTime'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #20986#24211#31867#22411
|
||||
DataBinding.FieldName = 'CRType'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.DropDownListStyle = lsFixedList
|
||||
Properties.Items.Strings = (
|
||||
#27491#24120#20986#24211
|
||||
#22238#20462#20986#24211)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Caption = #35746#21333#21697#21517
|
||||
DataBinding.FieldName = 'MPRTCodeName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 64
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #20844#21496#21697#21517
|
||||
DataBinding.FieldName = 'ComPRTName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 59
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #25253#20851#21697#21517
|
||||
DataBinding.FieldName = 'BGName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Caption = #20986#26588#21253'/'#20214#25968#37327
|
||||
DataBinding.FieldName = 'BQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 93
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #20986#26588#21305#25968#37327
|
||||
DataBinding.FieldName = 'JQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 73
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Caption = #20986#26588#25968#37327
|
||||
DataBinding.FieldName = 'Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 65
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'QtyUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.DropDownListStyle = lsFixedList
|
||||
Properties.Items.Strings = (
|
||||
'M'
|
||||
'KG'
|
||||
'Y')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 35
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #20986#26588#36741#21161#25968#37327
|
||||
DataBinding.FieldName = 'FZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 95
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #20986#26588#36741#21161#21333#20301
|
||||
DataBinding.FieldName = 'FZUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'M'
|
||||
'Y')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 89
|
||||
end
|
||||
object v2Column5: TcxGridDBColumn
|
||||
Caption = #20986#26588#27611#37325
|
||||
DataBinding.FieldName = 'KGQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 58
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #20986#26588#20928#37325
|
||||
DataBinding.FieldName = 'KGQtyJ'
|
||||
FooterAlignmentHorz = taCenter
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Caption = #25253#20851#25968#37327
|
||||
DataBinding.FieldName = 'BGQty'
|
||||
Width = 61
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #25253#20851#25968#37327#21333#20301
|
||||
DataBinding.FieldName = 'BGQtyUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'M'
|
||||
'Y')
|
||||
Width = 85
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25253#20851#27611#37325
|
||||
DataBinding.FieldName = 'BGMZ'
|
||||
Width = 59
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Caption = #25253#20851#20928#37325
|
||||
DataBinding.FieldName = 'BGJZ'
|
||||
Width = 59
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #32440#31665#35268#26684
|
||||
DataBinding.FieldName = 'BoxSpec'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.OnButtonClick = v1Column15PropertiesButtonClick
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 64
|
||||
end
|
||||
object v2Column3: TcxGridDBColumn
|
||||
Caption = #39068#33394
|
||||
DataBinding.FieldName = 'PRTColor'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 42
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #33394#21495
|
||||
DataBinding.FieldName = 'SOrddefstr1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 55
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #33457#22411#33457#21495
|
||||
DataBinding.FieldName = 'PRTHX'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 57
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #38376#24133
|
||||
DataBinding.FieldName = 'MPRTMF'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 38
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #20811#37325
|
||||
DataBinding.FieldName = 'MPRTKZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 36
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #21152#24037#21333#20301
|
||||
DataBinding.FieldName = 'JGFactory'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.OnButtonClick = v1Column16PropertiesButtonClick
|
||||
Width = 60
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #22791#27880'('#26588')'
|
||||
DataBinding.FieldName = 'NoteG'
|
||||
Width = 66
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
Width = 68
|
||||
end
|
||||
end
|
||||
object cxGrid2Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1179
|
||||
Height = 33
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
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 = 1
|
||||
object TBAdd: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26032#22686
|
||||
ImageIndex = 103
|
||||
OnClick = TBAddClick
|
||||
end
|
||||
object TBDel: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#38500
|
||||
ImageIndex = 107
|
||||
OnClick = TBDelClick
|
||||
end
|
||||
object TBSave: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20445#23384
|
||||
ImageIndex = 14
|
||||
OnClick = TBSaveClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 55
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object DataSource3: TDataSource
|
||||
DataSet = CDS_Sub
|
||||
Left = 512
|
||||
Top = 136
|
||||
end
|
||||
object CDS_Sub: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 480
|
||||
Top = 136
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
Parameters = <>
|
||||
Left = 344
|
||||
Top = 136
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 368
|
||||
Top = 136
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 408
|
||||
Top = 136
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 440
|
||||
Top = 136
|
||||
end
|
||||
end
|
||||
|
|
@ -1,605 +0,0 @@
|
|||
unit U_BanCpRkOutPut;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxCalendar, cxDropDownEdit,
|
||||
ComCtrls, ToolWin, cxGridLevel, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridDBTableView, cxClasses, cxControls, cxGridCustomView, cxGrid,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, ADODB, DBClient, cxButtonEdit;
|
||||
|
||||
type
|
||||
TfrmBanCpRkOutPut = class(TForm)
|
||||
cxGrid2: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v2Column3: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v2Column5: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
cxGrid2Level1: TcxGridLevel;
|
||||
ToolBar1: TToolBar;
|
||||
TBAdd: TToolButton;
|
||||
TBDel: TToolButton;
|
||||
TBSave: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
DataSource3: TDataSource;
|
||||
CDS_Sub: TClientDataSet;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBAddClick(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBDelClick(Sender: TObject);
|
||||
procedure TBSaveClick(Sender: TObject);
|
||||
procedure v1Column15PropertiesButtonClick(Sender: TObject;
|
||||
AButtonIndex: Integer);
|
||||
procedure v1Column16PropertiesButtonClick(Sender: TObject;
|
||||
AButtonIndex: Integer);
|
||||
private
|
||||
{ Private declarations }
|
||||
function SaveCKData():Boolean;
|
||||
function YSData(Order_Main10:TClientDataSet):Boolean;
|
||||
public
|
||||
{ Public declarations }
|
||||
FBCId:String;
|
||||
end;
|
||||
|
||||
var
|
||||
frmBanCpRkOutPut: TfrmBanCpRkOutPut;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_OrderSel,U_DataLink,U_Fun,U_ZDYHelp;
|
||||
|
||||
{$R *.dfm}
|
||||
function TfrmBanCpRkOutPut.YSData(Order_Main10:TClientDataSet):Boolean;
|
||||
var
|
||||
CRID,YFID,Price,PriceUnit,OrderUnit,FComTaiTou,khName:String;
|
||||
flag:integer;
|
||||
// Price:double;
|
||||
begin
|
||||
Result:=False;
|
||||
with Order_Main10 do
|
||||
begin
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('select X1.customerNoName,X3.OrderUnit,X3.PRTPrice,X2.OrdconPrcUnit from JYOrder_main X1,JYOrdercon_main X2,JYOrdercon_Sub X3 Where X1.consubID=X3.subID and X2.mainID=X3.mainID and X1.Mainid='''+Trim(Order_Main10.fieldbyname('MainId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty then
|
||||
begin
|
||||
application.MessageBox('没有合同或指示单没有定位,不能出库','提示');
|
||||
exit;
|
||||
end;
|
||||
OrderUnit:=Trim(ADOQueryTemp.fieldbyname('OrderUnit').AsString);
|
||||
khName:=Trim(ADOQueryTemp.fieldbyname('customerNoName').AsString);
|
||||
Price:=Trim(ADOQueryTemp.fieldbyname('PRTPrice').AsString);
|
||||
PriceUnit:=Trim(ADOQueryTemp.fieldbyname('OrdconPrcUnit').AsString);
|
||||
flag:=0;
|
||||
IF OrderUnit= trim(Order_Main10.FieldByName('QtyUnit').AsString) then
|
||||
begin
|
||||
flag:=1;
|
||||
end
|
||||
else
|
||||
if OrderUnit= trim(Order_Main10.FieldByName('FZUnit').AsString) then
|
||||
begin
|
||||
flag:=2;
|
||||
end
|
||||
else IF trim(Order_Main10.FieldByName('FZUnit').AsString)='Kg' then
|
||||
begin
|
||||
flag:=3;
|
||||
end;
|
||||
IF Flag=0 then
|
||||
begin
|
||||
application.MessageBox('出库单位和合同单位不一致,不能出库!','提示信息',0);
|
||||
exit;
|
||||
end;
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete from YF_Money_CR where YfID='+quotedstr(trim(Order_Main10.fieldbyname('fYFID').AsString)));
|
||||
execsql;
|
||||
end;
|
||||
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('select * from YF_Money_KC where FactoryName='''+Trim(khName)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty=False then
|
||||
begin
|
||||
CRID:=ADOQueryTemp.fieldbyname('CRID').AsString;
|
||||
end else
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update YF_Money_CRID set CRID=CRID+1');
|
||||
sql.Add('select * from YF_Money_CRID ');
|
||||
Open;
|
||||
end;
|
||||
CRID:=ADOQueryCmd.fieldbyname('CRID').AsString;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('select * from YF_Money_KC where 1<>1');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Append;
|
||||
FieldByName('CRID').Value:=StrToInt(CRID);
|
||||
FieldByName('FactoryName').Value:=Trim(khName);
|
||||
FieldByName('ZdyStr1').Value:='应收收';
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from YF_Money_CR where FactoryName='''+Trim(khName)+''' ');
|
||||
sql.Add('and YFTypeId='''+Trim(Order_Main10.fieldbyname('Mainid').AsString)+''' ');
|
||||
sql.Add('and CRTime='''+formatdateTime('yyyy-MM-dd',Order_Main10.fieldbyname('CRTime').AsDateTime)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty then
|
||||
begin
|
||||
if GetLSNo(ADOQueryCmd,YFID,'CS','YF_Money_CR',3,1)=False then
|
||||
begin
|
||||
Application.MessageBox('取成品应收最大号失败!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from YF_Money_CR where 1<>1');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Append;
|
||||
FieldByName('YFID').Value:=Trim(YFID);
|
||||
FieldByName('YFTypeId').Value:=Trim(Order_Main10.fieldbyname('MainId').AsString);
|
||||
FieldByName('CRID').Value:=StrToInt(CRID);
|
||||
FieldByName('Filler').Value:=Trim(DName);
|
||||
FieldByName('CRType').Value:='应收款登记';
|
||||
FieldByName('CRFlag').Value:='应收收';
|
||||
FieldByName('QtyFlag').Value:=1;
|
||||
FieldByName('FactoryName').Value:=Trim(KHName);
|
||||
FieldByName('CRTime').Value:=Trim(FormatDateTime('yyyy-MM-dd',Order_Main10.fieldbyname('CRTime').AsDateTime));
|
||||
FieldByName('YFType').Value:='自动生成';
|
||||
FieldByName('Price').Value:=Price;
|
||||
FieldByName('HuiLv').Value:=1;
|
||||
|
||||
FieldByName('BZType').Value:=Trim(PriceUnit);
|
||||
FieldByName('QtyUnit').Value:=Trim(OrderUnit);
|
||||
FieldByName('ComTaiTou').Value:=Trim(KHName);
|
||||
FieldByName('YFName').Value:='销售金额';
|
||||
FieldByName('MainId').Value:=Trim(Order_Main10.fieldbyname('Mainid').AsString);
|
||||
Post;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
YFID:=Trim(ADOQueryTemp.fieldbyname('YFID').AsString);
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
if flag=1 then
|
||||
begin
|
||||
sql.Add('update YF_Money_CR Set Qty=(select isnull(Sum(A.Qty),0) from CK_BanCP_CR A ');
|
||||
end
|
||||
else IF flag=2 then
|
||||
begin
|
||||
sql.Add('update YF_Money_CR Set Qty=(select isnull(Sum(A.FZQty),0) from CK_BanCP_CR A ');
|
||||
end
|
||||
else if flag=3 then
|
||||
begin
|
||||
sql.Add('update YF_Money_CR Set Qty=(select isnull(Sum(A.KGQtyJ),0) from CK_BanCP_CR A ');
|
||||
end;
|
||||
SQL.Add(' where A.MainId=YF_Money_CR.YFTypeId and A.CRTime=YF_Money_CR.CRTime and A.MJID=A.BCID and A.CRType=''正常出库'' ');
|
||||
SQL.Add(' )');
|
||||
sql.Add(',PS=(select isnull(sum(JQty),0) from CK_BanCP_CR A ');
|
||||
SQL.Add(' where A.MainId=YF_Money_CR.YFTypeId and A.CRTime=YF_Money_CR.CRTime and A.MJID=A.BCID and A.CRType=''正常出库'' ');
|
||||
SQL.Add(' )');
|
||||
sql.Add(' where YFTypeId='''+Trim(Order_Main10.fieldbyname('Mainid').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update YF_Money_CR Set Money=Price*Qty,BBMoney=Price*Qty*HuiLv');
|
||||
sql.Add(' where YFID='''+Trim(YFID)+'''');
|
||||
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('Update CK_BanCp_CR Set FYFID='''+Trim(YFID)+''' ');
|
||||
sql.Add(' where BCID='''+Trim(Order_Main10.fieldbyname('BCID').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
Result:=True;
|
||||
end;
|
||||
|
||||
procedure TfrmBanCpRkOutPut.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBanCpRkOutPut.TBAddClick(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmOrderSel:=TfrmOrderSel.Create(Application);
|
||||
with frmOrderSel do
|
||||
begin
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
CDS_OrderSel.DisableControls;
|
||||
with CDS_OrderSel do
|
||||
begin
|
||||
First;
|
||||
while not Eof do
|
||||
begin
|
||||
if FieldByName('SSel').Value=True then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Append;
|
||||
FieldByName('MainId').Value:=Trim(CDS_OrderSel.fieldbyname('MainId').AsString);
|
||||
FieldByName('SubId').Value:=Trim(CDS_OrderSel.fieldbyname('SubId').AsString);
|
||||
FieldByName('OrderNo').Value:=Trim(CDS_OrderSel.fieldbyname('OrderNo').AsString);
|
||||
FieldByName('MPRTCodeName').Value:=Trim(CDS_OrderSel.fieldbyname('MPRTCodeName').AsString);
|
||||
FieldByName('PRTColor').Value:=Trim(CDS_OrderSel.fieldbyname('PRTColor').AsString);
|
||||
FieldByName('PRTHX').Value:=Trim(CDS_OrderSel.fieldbyname('PRTHX').AsString);
|
||||
FieldByName('MPRTMF').Value:=Trim(CDS_OrderSel.fieldbyname('MPRTMF').AsString);
|
||||
FieldByName('MPRTKZ').Value:=Trim(CDS_OrderSel.fieldbyname('MPRTKZ').AsString);
|
||||
FieldByName('Qty').Value:=CDS_OrderSel.fieldbyname('KCQty').Value;
|
||||
FieldByName('KgQty').Value:=CDS_OrderSel.fieldbyname('KCKgQty').Value;
|
||||
FieldByName('JQty').Value:=CDS_OrderSel.fieldbyname('KCJQty').Value;
|
||||
FieldByName('KgQtyJ').Value:=CDS_OrderSel.fieldbyname('KCKgQtyJ').Value;
|
||||
FieldByName('BQty').Value:=CDS_OrderSel.fieldbyname('KCBQty').Value;
|
||||
FieldByName('QtyUnit').Value:=CDS_OrderSel.fieldbyname('KCQtyUnit').Value;
|
||||
FieldByName('MJID').Value:=CDS_OrderSel.fieldbyname('CRID').Value;
|
||||
FieldByName('APID').Value:=CDS_OrderSel.fieldbyname('CRID').Value;
|
||||
FieldByName('CRID').Value:=CDS_OrderSel.fieldbyname('CRID').Value;
|
||||
FieldByName('QtyUnit').Value:=CDS_OrderSel.fieldbyname('KCQtyUnit').Value;
|
||||
FieldByName('ComPRTName').Value:=CDS_OrderSel.fieldbyname('ComPRTName').Value;
|
||||
FieldByName('CRType').Value:='正常出库';
|
||||
FieldByName('CRTime').Value:=FormatDateTime('yyyy-MM-dd',Now);
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
CDS_OrderSel.EnableControls;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmOrderSel.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
function TfrmBanCpRkOutPut.SaveCKData():Boolean;
|
||||
var
|
||||
FCRID,Maxno:string;
|
||||
begin
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Sub.DisableControls;
|
||||
with CDS_Sub do
|
||||
begin
|
||||
First;
|
||||
while not eof do
|
||||
begin
|
||||
FCRID:=CDS_Sub.fieldbyname('CRID').AsString;
|
||||
if Trim(CDS_Sub.fieldbyname('BCID').AsString)='' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryCmd,Maxno,'BC','CK_BanCP_CR',3,1)=False then
|
||||
begin
|
||||
Result:=False;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取入库编号失败!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
Maxno:=Trim(CDS_Sub.fieldbyname('BCID').AsString);
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from CK_BanCP_CR where BCID='''+Trim(Maxno)+'''');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
if Trim(CDS_Sub.fieldbyname('BCID').AsString)='' then
|
||||
begin
|
||||
Append;
|
||||
end else
|
||||
begin
|
||||
Edit;
|
||||
end;
|
||||
FieldByName('BCID').Value:=Trim(Maxno);
|
||||
FieldByName('MJID').Value:=Trim(Maxno);
|
||||
FieldByName('APID').Value:=Trim(Maxno);
|
||||
FieldByName('MainID').Value:=Trim(CDS_Sub.fieldbyname('MainID').AsString);
|
||||
FieldByName('SubID').Value:=Trim(CDS_Sub.fieldbyname('SubID').AsString);
|
||||
FieldByName('CRFlag').Value:='出库';
|
||||
FieldByName('CRType').Value:=Trim(CDS_Sub.fieldbyname('CRType').AsString);
|
||||
FieldByName('CRID').Value:=FCRID;
|
||||
FieldByName('CRTime').Value:=CDS_Sub.fieldbyname('CRTime').AsString;
|
||||
FieldByName('QtyUnit').Value:=CDS_Sub.fieldbyname('QtyUnit').AsString;
|
||||
FieldByName('ComPRTName').Value:=CDS_Sub.fieldbyname('ComPRTName').AsString;
|
||||
FieldByName('BGQtyUnit').Value:=CDS_Sub.fieldbyname('BGQtyUnit').AsString;
|
||||
FieldByName('FZQty').Value:=CDS_Sub.fieldbyname('FZQty').AsFloat;
|
||||
FieldByName('FZUnit').Value:=CDS_Sub.fieldbyname('FZUnit').AsString;
|
||||
FieldByName('BGName').Value:=CDS_Sub.fieldbyname('BGName').AsString;
|
||||
FieldByName('BoxSpec').Value:=CDS_Sub.fieldbyname('BoxSpec').AsString;
|
||||
FieldByName('JGFactory').Value:=CDS_Sub.fieldbyname('JGFactory').AsString;
|
||||
FieldByName('Note').Value:=CDS_Sub.fieldbyname('Note').AsString;
|
||||
FieldByName('NoteG').Value:=CDS_Sub.fieldbyname('NoteG').AsString;
|
||||
//FieldByName('GangNo').Value:=CDS_Sub.fieldbyname('GangNo').AsString;
|
||||
FieldByName('QtyFlag').Value:=-1;
|
||||
if Trim(CDS_Sub.fieldbyname('BGQty').AsString)<>'' then
|
||||
begin
|
||||
FieldByName('BGQty').Value:=CDS_Sub.fieldbyname('BGQty').Value;
|
||||
end else
|
||||
begin
|
||||
FieldByName('BGQty').Value:=0;
|
||||
end;
|
||||
if Trim(CDS_Sub.fieldbyname('BGJZ').AsString)<>'' then
|
||||
begin
|
||||
FieldByName('BGJZ').Value:=CDS_Sub.fieldbyname('BGJZ').Value;
|
||||
end else
|
||||
begin
|
||||
FieldByName('BGJZ').Value:=0;
|
||||
end;
|
||||
if Trim(CDS_Sub.fieldbyname('BGMZ').AsString)<>'' then
|
||||
begin
|
||||
FieldByName('BGMZ').Value:=CDS_Sub.fieldbyname('BGMZ').Value;
|
||||
end else
|
||||
begin
|
||||
FieldByName('BGMZ').Value:=0;
|
||||
end;
|
||||
if Trim(CDS_Sub.fieldbyname('JQty').AsString)<>'' then
|
||||
begin
|
||||
FieldByName('JQty').Value:=CDS_Sub.fieldbyname('JQty').Value;
|
||||
end else
|
||||
begin
|
||||
FieldByName('JQty').Value:=0;
|
||||
end;
|
||||
if Trim(CDS_Sub.fieldbyname('KGQty').AsString)<>'' then
|
||||
begin
|
||||
FieldByName('KGQty').Value:=CDS_Sub.fieldbyname('KGQty').Value;
|
||||
end else
|
||||
begin
|
||||
FieldByName('KGQty').Value:=0;
|
||||
end;
|
||||
if Trim(CDS_Sub.fieldbyname('BQty').AsString)<>'' then
|
||||
begin
|
||||
FieldByName('BQty').Value:=CDS_Sub.fieldbyname('BQty').Value;
|
||||
end else
|
||||
begin
|
||||
FieldByName('BQty').Value:=0;
|
||||
end;
|
||||
if Trim(CDS_Sub.fieldbyname('KGQtyJ').AsString)<>'' then
|
||||
begin
|
||||
FieldByName('KGQtyJ').Value:=CDS_Sub.fieldbyname('KGQtyJ').Value;
|
||||
end else
|
||||
begin
|
||||
FieldByName('KGQtyJ').Value:=0;
|
||||
end;
|
||||
if Trim(CDS_Sub.fieldbyname('Qty').AsString)<>'' then
|
||||
begin
|
||||
FieldByName('Qty').Value:=CDS_Sub.fieldbyname('Qty').Value;
|
||||
end else
|
||||
begin
|
||||
FieldByName('Qty').Value:=0;
|
||||
end;
|
||||
|
||||
if Trim(CDS_Sub.fieldbyname('BCID').AsString)='' then
|
||||
FieldByName('Filler').Value:=Trim(DName)
|
||||
else
|
||||
begin
|
||||
FieldByName('Editer').Value:=Trim(DName);
|
||||
FieldByName('EditTime').Value:=SGetServerDate(ADOQueryTemp);
|
||||
end;
|
||||
Post;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update CK_BanCP_KC Set KCQty=(select sum(Qty*QtyFlag) from CK_BanCP_CR A where A.CRID=CK_BanCP_KC.CRID)');
|
||||
sql.Add(',KCKgQty=(select sum(KgQty*QtyFlag) from CK_BanCP_CR A where A.CRID=CK_BanCP_KC.CRID)');
|
||||
sql.Add(',KCJQty=(select sum(JQty*QtyFlag) from CK_BanCP_CR A where A.CRID=CK_BanCP_KC.CRID)');
|
||||
sql.Add(',KCKgQtyJ=(select sum(KgQtyJ*QtyFlag) from CK_BanCP_CR A where A.CRID=CK_BanCP_KC.CRID)');
|
||||
sql.Add(',KCBQty=(select sum(BQty*QtyFlag) from CK_BanCP_CR A where A.CRID=CK_BanCP_KC.CRID)');
|
||||
sql.Add(' where CRID='+FCRID);
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Sub.Edit;
|
||||
CDS_Sub.FieldByName('BCID').Value:=trim(maxNO);
|
||||
CDS_Sub.post;
|
||||
IF not YSData(CDS_Sub) then
|
||||
begin
|
||||
application.MessageBox('应收款保存失败','提示信息',0);
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
CDS_Sub.EnableControls;
|
||||
exit;
|
||||
end;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
CDS_Sub.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
Result:=False;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('保存异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBanCpRkOutPut.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('成品出库S',Tv1,'成品仓库');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBanCpRkOutPut.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('成品出库S',Tv1,'成品仓库');
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.OrderNo,B.MPRTCodeName,B.MPRTMF,B.MPRTKZ,C.PRTColor,C.SOrddefstr1,C.PRTHX from CK_BanCp_CR A ');
|
||||
sql.Add(' inner join JYOrder_Main B on A.MainId=B.MainId');
|
||||
sql.Add(' inner join JYOrder_Sub C on A.SubId=C.SubId');
|
||||
sql.Add(' where A.BCID='''+Trim(FBCId)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryTemp,CDS_Sub);
|
||||
SInitCDSData20(ADOQueryTemp,CDS_Sub);
|
||||
end;
|
||||
|
||||
procedure TfrmBanCpRkOutPut.TBDelClick(Sender: TObject);
|
||||
begin
|
||||
if CDS_Sub.IsEmpty then Exit;
|
||||
CDS_Sub.Delete;
|
||||
end;
|
||||
|
||||
procedure TfrmBanCpRkOutPut.TBSaveClick(Sender: TObject);
|
||||
begin
|
||||
if CDS_Sub.IsEmpty then Exit;
|
||||
if CDS_Sub.Locate('CRTime',null,[])=True then
|
||||
begin
|
||||
Application.MessageBox('出库时间不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if CDS_Sub.Locate('CRType',null,[])=True then
|
||||
begin
|
||||
Application.MessageBox('出库类型不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
{if CDS_Sub.Locate('QtyUnit',null,[])=True then
|
||||
begin
|
||||
Application.MessageBox('单位不能为空!','提示',0);
|
||||
Exit;
|
||||
end; }
|
||||
if SaveCKData() then
|
||||
begin
|
||||
Application.MessageBox('保存成功!','提示',0);
|
||||
ModalResult:=1;
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBanCpRkOutPut.v1Column15PropertiesButtonClick(
|
||||
Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp:=TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag:='BoxSpec';
|
||||
flagname:='纸箱规格';
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('BoxSpec').Value:=Trim(ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBanCpRkOutPut.v1Column16PropertiesButtonClick(
|
||||
Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp:=TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag:='JGFactory';
|
||||
flagname:='加工单位';
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('JGFactory').Value:=Trim(ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,429 +0,0 @@
|
|||
object frmBaoGuanCRKCX: TfrmBaoGuanCRKCX
|
||||
Left = 189
|
||||
Top = 135
|
||||
Width = 1348
|
||||
Height = 635
|
||||
Caption = #25253#20851#20986#20837#24211#26597#35810
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -13
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
OnClose = FormClose
|
||||
OnCreate = FormCreate
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 107
|
||||
TextHeight = 13
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1332
|
||||
Height = 33
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object TPrint: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25171#21360
|
||||
ImageIndex = 4
|
||||
OnClick = TPrintClick
|
||||
end
|
||||
object ComboBox1: TComboBox
|
||||
Left = 189
|
||||
Top = 5
|
||||
Width = 145
|
||||
Height = 20
|
||||
Style = csDropDownList
|
||||
ItemHeight = 12
|
||||
TabOrder = 0
|
||||
Items.Strings = (
|
||||
#20837#24211#21333
|
||||
#20986#24211#21333)
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 334
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 397
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1332
|
||||
Height = 40
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 30
|
||||
Top = 13
|
||||
Width = 52
|
||||
Height = 13
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 182
|
||||
Top = 13
|
||||
Width = 13
|
||||
Height = 13
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 307
|
||||
Top = 13
|
||||
Width = 72
|
||||
Height = 13
|
||||
Caption = #20379#24212#21830'/'#23458#25143
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 533
|
||||
Top = 13
|
||||
Width = 39
|
||||
Height = 13
|
||||
Caption = #35746#21333#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 724
|
||||
Top = 13
|
||||
Width = 52
|
||||
Height = 13
|
||||
Caption = #21830#21697#21517#31216
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 921
|
||||
Top = 13
|
||||
Width = 26
|
||||
Height = 13
|
||||
Caption = #35268#26684
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 83
|
||||
Top = 9
|
||||
Width = 95
|
||||
Height = 21
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 196
|
||||
Top = 9
|
||||
Width = 96
|
||||
Height = 21
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object C3BGName: TEdit
|
||||
Tag = 2
|
||||
Left = 775
|
||||
Top = 9
|
||||
Width = 140
|
||||
Height = 21
|
||||
TabOrder = 2
|
||||
OnChange = A5ConNOChange
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 573
|
||||
Top = 9
|
||||
Width = 140
|
||||
Height = 21
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 3
|
||||
OnChange = A5ConNOChange
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 381
|
||||
Top = 9
|
||||
Width = 140
|
||||
Height = 21
|
||||
TabOrder = 4
|
||||
OnChange = A1ChuKouShangChange
|
||||
end
|
||||
object YSChenFen: TEdit
|
||||
Tag = 2
|
||||
Left = 948
|
||||
Top = 9
|
||||
Width = 140
|
||||
Height = 21
|
||||
TabOrder = 5
|
||||
OnChange = A5ConNOChange
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 73
|
||||
Width = 1332
|
||||
Height = 522
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1C4BGQty
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1C4BGQty
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skCount
|
||||
Column = v1A1ChuKouShang
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1C4BGQty
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsData.Deleting = False
|
||||
OptionsData.DeletingConfirmation = False
|
||||
OptionsData.Editing = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1A7FPDate: TcxGridDBColumn
|
||||
Caption = #26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1A1ChuKouShang: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830'/'#23458#25143
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1A5ConNO: TcxGridDBColumn
|
||||
Caption = #35746#21333#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 84
|
||||
end
|
||||
object v1C3BGName: TcxGridDBColumn
|
||||
Caption = #21830#21697#21517#31216
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 80
|
||||
end
|
||||
object v1YSChenFen: TcxGridDBColumn
|
||||
Caption = #35268#26684
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object v1C5BGUnit: TcxGridDBColumn
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object v1C4BGQty: TcxGridDBColumn
|
||||
Caption = #20837#24211#25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 71
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #20986#24211#25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1JC: TcxGridDBColumn
|
||||
Caption = #32467#23384
|
||||
DataBinding.FieldName = 'JC'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 114
|
||||
end
|
||||
end
|
||||
object cxGrid2Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object Panel2: TPanel
|
||||
Left = 571
|
||||
Top = 278
|
||||
Width = 235
|
||||
Height = 44
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Caption = #27491#22312#26597#35810#25968#25454#65292#35831#31245#21518#12290#12290#12290
|
||||
Color = clSkyBlue
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -13
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
TabOrder = 3
|
||||
Visible = False
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 1000
|
||||
Top = 202
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 960
|
||||
Top = 202
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 1035
|
||||
Top = 202
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = 360
|
||||
Top = 232
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBMain: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Main
|
||||
Left = 424
|
||||
Top = 232
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 392
|
||||
Top = 232
|
||||
end
|
||||
object CDS_HZ: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 488
|
||||
Top = 232
|
||||
end
|
||||
object CDS_PRT: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 456
|
||||
Top = 232
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 328
|
||||
Top = 232
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -1,245 +0,0 @@
|
|||
unit U_BaoGuanCRKCX;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxPC;
|
||||
|
||||
type
|
||||
TfrmBaoGuanCRKCX = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
cxGrid2Level1: TcxGridLevel;
|
||||
RM1: TRMGridReport;
|
||||
RMDBMain: TRMDBDataSet;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_HZ: TClientDataSet;
|
||||
CDS_PRT: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
Panel2: TPanel;
|
||||
Label6: TLabel;
|
||||
Label8: TLabel;
|
||||
Label3: TLabel;
|
||||
C3BGName: TEdit;
|
||||
A5ConNO: TEdit;
|
||||
A1ChuKouShang: TEdit;
|
||||
v1A7FPDate: TcxGridDBColumn;
|
||||
v1A1ChuKouShang: TcxGridDBColumn;
|
||||
v1A5ConNO: TcxGridDBColumn;
|
||||
v1C3BGName: TcxGridDBColumn;
|
||||
v1YSChenFen: TcxGridDBColumn;
|
||||
v1C5BGUnit: TcxGridDBColumn;
|
||||
v1C4BGQty: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
Label4: TLabel;
|
||||
YSChenFen: TEdit;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v1JC: TcxGridDBColumn;
|
||||
TPrint: TToolButton;
|
||||
ComboBox1: TComboBox;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure v2Column1CompareRowValuesForCellMerging(
|
||||
Sender: TcxGridColumn; ARow1: TcxGridDataRow;
|
||||
AProperties1: TcxCustomEditProperties; const AValue1: Variant;
|
||||
ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties;
|
||||
const AValue2: Variant; var AAreEqual: Boolean);
|
||||
procedure TPrintClick(Sender: TObject);
|
||||
procedure A1ChuKouShangChange(Sender: TObject);
|
||||
procedure A5ConNOChange(Sender: TObject);
|
||||
private
|
||||
procedure InitGrid();
|
||||
procedure GetColor(color:TColor);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanCRKCX: TfrmBaoGuanCRKCX;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanCRKCX:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.InitGrid();
|
||||
var
|
||||
fsj:string;
|
||||
begin
|
||||
Panel2.Visible:=True;
|
||||
Panel2.Refresh;
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,JC=cast(0 as decimal(18,2)) from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A7FPDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+'''');
|
||||
sql.Add(' and A7FPDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally;
|
||||
ADOQueryMain.EnableControls;
|
||||
Panel2.Visible:=False;
|
||||
end;
|
||||
Panel2.Visible:=False;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('财务报关销售报表',Tv1,'财务管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('财务报关销售报表',Tv1,'财务管理');
|
||||
//InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('财务报关销售报表',cxGrid2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.v2Column1CompareRowValuesForCellMerging(
|
||||
Sender: TcxGridColumn; ARow1: TcxGridDataRow;
|
||||
AProperties1: TcxCustomEditProperties; const AValue1: Variant;
|
||||
ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties;
|
||||
const AValue2: Variant; var AAreEqual: Boolean);
|
||||
|
||||
var
|
||||
colIdx0:integer;
|
||||
begin
|
||||
colIdx0:= tv1.GetColumnByFieldName('A4FPNO').Index;
|
||||
if ARow1.Values[colIdx0] = ARow2.Values[colIdx0] then
|
||||
AAreEqual := True
|
||||
else
|
||||
AAreEqual := False;
|
||||
end;
|
||||
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.GetColor(color:TColor);
|
||||
begin
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.TPrintClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile,fsj:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
if ComboBox1.Text='入库单' then
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\财务报关入库单.rmf';
|
||||
if ComboBox1.Text='出库单' then
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\财务报关出库单.rmf';
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['TaiTou']:=cxTabControl1.Tabs[cxTabControl1.TabIndex].Caption;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\财务报关入库单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.A1ChuKouShangChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanCRKCX.A5ConNOChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
end.
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -1,985 +0,0 @@
|
|||
object frmBaoGuanListBGD: TfrmBaoGuanListBGD
|
||||
Left = 110
|
||||
Top = 82
|
||||
Width = 1162
|
||||
Height = 615
|
||||
Caption = #25253#20851#21333#21015#34920
|
||||
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 = 1146
|
||||
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 = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton12: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = ToolButton12Click
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#36164#26009
|
||||
ImageIndex = 4
|
||||
Visible = False
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object ToolButton8: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21512#21516
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton8Click
|
||||
end
|
||||
object ToolButton9: TToolButton
|
||||
Left = 339
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21457#31080
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton9Click
|
||||
end
|
||||
object ToolButton10: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #35013#31665#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton10Click
|
||||
end
|
||||
object ToolButton11: TToolButton
|
||||
Left = 477
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#21333
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton11Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 552
|
||||
Top = 0
|
||||
Caption = #30003#25253#35201#32032
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 635
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
Visible = False
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 698
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1146
|
||||
Height = 37
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 168
|
||||
Top = 12
|
||||
Width = 12
|
||||
Height = 12
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 279
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 639
|
||||
Top = 12
|
||||
Width = 42
|
||||
Height = 12
|
||||
Caption = #23458#25143'PO#'
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 455
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21512#21516#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 831
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #20986#21475#21830
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 181
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 315
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object A6PONO: TEdit
|
||||
Tag = 2
|
||||
Left = 683
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 492
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A5ConNOKeyPress
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 868
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1146
|
||||
Height = 309
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellClick = Tv1CellClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v2Column6
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #20986#21475#21830
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #31246#21495
|
||||
DataBinding.FieldName = 'A2ShuiHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 97
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #28023#20851#32534#30721
|
||||
DataBinding.FieldName = 'A3HaiGuanBM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 93
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Alignment.Horz = taLeftJustify
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 125
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23458#25143'PO#'
|
||||
DataBinding.FieldName = 'A6PONO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24320#33322#26085#26399
|
||||
DataBinding.FieldName = 'B3KaiHangDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 62
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #36135#26588
|
||||
DataBinding.FieldName = 'B5HuoGui'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36816#28207
|
||||
DataBinding.FieldName = 'B6ChuYunGang'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 85
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21040#36135#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 51
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36152#26131#22269
|
||||
DataBinding.FieldName = 'B8MaoYiGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25269#36816#22269
|
||||
DataBinding.FieldName = 'B9DiYunGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'B10YunShuType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #36152#26131#26041#24335
|
||||
DataBinding.FieldName = 'D2MaoYiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 79
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #32467#27719#26041#24335
|
||||
DataBinding.FieldName = 'D3JiHuiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #25253#20851#26465#27454
|
||||
DataBinding.FieldName = 'F1BaoGuanTK'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #36816#36153
|
||||
DataBinding.FieldName = 'F2YunFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #20445#36153
|
||||
DataBinding.FieldName = 'F3BaoFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #36135#36816#20195#29702
|
||||
DataBinding.FieldName = 'F4HuoYunDaiLi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #33322#21517#33322#27425
|
||||
DataBinding.FieldName = 'B1HangBan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object v1Column24: TcxGridDBColumn
|
||||
Caption = #25552#21333#21495
|
||||
DataBinding.FieldName = 'B2TiDanHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column25: TcxGridDBColumn
|
||||
Caption = #31665#21495#23553#21495
|
||||
DataBinding.FieldName = 'B4XiangNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 72
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #33337#20844#21496
|
||||
DataBinding.FieldName = 'F5ChuanGongSi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #30331#35760#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column26: TcxGridDBColumn
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column27: TcxGridDBColumn
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column28: TcxGridDBColumn
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v1Column29: TcxGridDBColumn
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column30: TcxGridDBColumn
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoneyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 70
|
||||
Width = 1146
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Style = 8
|
||||
TabIndex = 0
|
||||
TabOrder = 3
|
||||
Tabs.Strings = (
|
||||
#24453#36865#23457
|
||||
#24050#36865#23457
|
||||
#24050#23457#25209
|
||||
#20840#37096)
|
||||
Visible = False
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1146
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object cxSplitter1: TcxSplitter
|
||||
Left = 0
|
||||
Top = 400
|
||||
Width = 1146
|
||||
Height = 8
|
||||
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||
AlignSplitter = salBottom
|
||||
Control = cxGrid2
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 408
|
||||
Width = 1146
|
||||
Height = 169
|
||||
Align = alBottom
|
||||
TabOrder = 5
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource2
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = cxGridDBColumn2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn10
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn11
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object cxGridDBColumn1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#21517
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 183
|
||||
end
|
||||
object cxGridDBColumn14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25104#20221#21547#37327
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn15: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24133#23485'(CM)'
|
||||
DataBinding.FieldName = 'YSFuKuan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn13: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #32455#36896#26041#27861
|
||||
DataBinding.FieldName = 'YSZhiZaoType'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#38024#32455
|
||||
#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object cxGridDBColumn16: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#29260
|
||||
DataBinding.FieldName = 'YSPinPai'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn17: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #29983#20135#21378#21830
|
||||
DataBinding.FieldName = 'YSShengChanShang'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = 'HS NO'
|
||||
DataBinding.FieldName = 'C2HSNO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 132
|
||||
end
|
||||
object cxGridDBColumn3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 51
|
||||
end
|
||||
object cxGridDBColumn4: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object cxGridDBColumn5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20215'(USD)'
|
||||
DataBinding.FieldName = 'C6BGPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 72
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object cxGridDBColumn8: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#21333#20301
|
||||
DataBinding.FieldName = 'E1BZUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'BALES'
|
||||
'ROLLS')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 67
|
||||
end
|
||||
object cxGridDBColumn10: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 62
|
||||
end
|
||||
object cxGridDBColumn11: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 64
|
||||
end
|
||||
object cxGridDBColumn12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21787#22836
|
||||
DataBinding.FieldName = 'E5MaiTou'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 768
|
||||
Top = 168
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 816
|
||||
Top = 224
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 472
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 912
|
||||
Top = 472
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 944
|
||||
Top = 472
|
||||
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 = 200
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 320
|
||||
Top = 208
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 208
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 288
|
||||
Top = 208
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,684 +0,0 @@
|
|||
unit U_BaoGuanListBGD;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxButtonEdit, cxTextEdit, cxPC, BtnEdit, cxSplitter;
|
||||
|
||||
type
|
||||
TfrmBaoGuanListBGD = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
cxTabControl1: TcxTabControl;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxSplitter1: TcxSplitter;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
Label5: TLabel;
|
||||
A6PONO: TEdit;
|
||||
Label8: TLabel;
|
||||
A5ConNO: TEdit;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label3: TLabel;
|
||||
A1ChuKouShang: TEdit;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
v1Column24: TcxGridDBColumn;
|
||||
v1Column25: TcxGridDBColumn;
|
||||
v1Column26: TcxGridDBColumn;
|
||||
v1Column27: TcxGridDBColumn;
|
||||
v1Column28: TcxGridDBColumn;
|
||||
v1Column29: TcxGridDBColumn;
|
||||
v1Column30: TcxGridDBColumn;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
cxGridDBColumn1: TcxGridDBColumn;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn3: TcxGridDBColumn;
|
||||
cxGridDBColumn4: TcxGridDBColumn;
|
||||
cxGridDBColumn5: TcxGridDBColumn;
|
||||
cxGridDBColumn6: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn8: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
cxGridDBColumn10: TcxGridDBColumn;
|
||||
cxGridDBColumn11: TcxGridDBColumn;
|
||||
cxGridDBColumn12: TcxGridDBColumn;
|
||||
cxGridDBColumn13: TcxGridDBColumn;
|
||||
cxGridDBColumn14: TcxGridDBColumn;
|
||||
cxGridDBColumn15: TcxGridDBColumn;
|
||||
cxGridDBColumn16: TcxGridDBColumn;
|
||||
cxGridDBColumn17: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
ToolButton7: TToolButton;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
ToolButton8: TToolButton;
|
||||
ToolButton9: TToolButton;
|
||||
ToolButton10: TToolButton;
|
||||
ToolButton11: TToolButton;
|
||||
ToolButton12: TToolButton;
|
||||
ToolButton3: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure A6PONOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure A5ConNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton7Click(Sender: TObject);
|
||||
procedure ToolButton8Click(Sender: TObject);
|
||||
procedure ToolButton9Click(Sender: TObject);
|
||||
procedure ToolButton10Click(Sender: TObject);
|
||||
procedure ToolButton11Click(Sender: TObject);
|
||||
procedure ToolButton12Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
private
|
||||
canshu1:string;
|
||||
canshu2:string;
|
||||
FDate:TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData():Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj:String);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanListBGD: TfrmBaoGuanListBGD;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp,U_BaoGuanInPut;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanListBGD.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanListBGD:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
canshu1:=Trim(DParameters1);
|
||||
canshu2:=Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where Valid=''Y'' ');
|
||||
{if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and Filler='''+Trim(DName)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
sql.Add(' and BGDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+'''');
|
||||
sql.Add(' and BGDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''');
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表BGD',Tv1,'报关管理');
|
||||
WriteCxGrid('报关明细BGD',Tv1,'报关管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表BGD',Tv1,'报关管理');
|
||||
ReadCxGrid('报关明细BGD',Tv1,'报关管理');
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('报关资料列表',cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,False);
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGD.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty=False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID='''+Trim(CDS_Main.fieldbyname('BGID').AsString)+'''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp,ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp,ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmBaoGuanListBGD.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer='''+Trim(DName)+''',EditTime=getdate()');
|
||||
sql.Add(' where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer='''+Trim(DName)+''',SEditTime=getdate() where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGD.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmBaoGuanListBGD.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A4FPNO,'''') like '''+'%'+Trim(A4FPNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGD.InitGridSql(var fsj:String);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
{ if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode='''+Trim(DCode)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.A6PONOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A6PONO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A6PONO,'''') like '''+'%'+Trim(A6PONO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.A5ConNOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A5ConNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A5ConNO,'''') like '''+'%'+Trim(A5ConNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.ToolButton7Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关资料.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.ToolButton8Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关合同.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.ToolButton9Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关发票.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.ToolButton10Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关装箱单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.ToolButton11Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.ToolButton12Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut:=TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId:=Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible:=False;
|
||||
ToolBar2.Visible:=False;
|
||||
Panel1.Enabled:=False;
|
||||
Tv1.OptionsData.Editing:=False;
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGD.ToolButton3Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\申报要素.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,979 +0,0 @@
|
|||
object frmBaoGuanListBGZL: TfrmBaoGuanListBGZL
|
||||
Left = 110
|
||||
Top = 82
|
||||
Width = 1162
|
||||
Height = 615
|
||||
Caption = #25253#20851#36164#26009#21015#34920
|
||||
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 = 1146
|
||||
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 = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton12: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = ToolButton12Click
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#36164#26009
|
||||
ImageIndex = 4
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object ToolButton8: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21512#21516
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton8Click
|
||||
end
|
||||
object ToolButton9: TToolButton
|
||||
Left = 339
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21457#31080
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton9Click
|
||||
end
|
||||
object ToolButton10: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #35013#31665#21333
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton10Click
|
||||
end
|
||||
object ToolButton11: TToolButton
|
||||
Left = 477
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#21333
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton11Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 552
|
||||
Top = 0
|
||||
Caption = #30003#25253#35201#32032
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 635
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 698
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1146
|
||||
Height = 37
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 168
|
||||
Top = 12
|
||||
Width = 12
|
||||
Height = 12
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 279
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 639
|
||||
Top = 12
|
||||
Width = 42
|
||||
Height = 12
|
||||
Caption = #23458#25143'PO#'
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 455
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21512#21516#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 831
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #20986#21475#21830
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 181
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 315
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object A6PONO: TEdit
|
||||
Tag = 2
|
||||
Left = 683
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 492
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A5ConNOKeyPress
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 868
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1146
|
||||
Height = 309
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellClick = Tv1CellClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v2Column6
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #20986#21475#21830
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #31246#21495
|
||||
DataBinding.FieldName = 'A2ShuiHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 97
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #28023#20851#32534#30721
|
||||
DataBinding.FieldName = 'A3HaiGuanBM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 93
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Alignment.Horz = taLeftJustify
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 125
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23458#25143'PO#'
|
||||
DataBinding.FieldName = 'A6PONO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24320#33322#26085#26399
|
||||
DataBinding.FieldName = 'B3KaiHangDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 62
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #36135#26588
|
||||
DataBinding.FieldName = 'B5HuoGui'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36816#28207
|
||||
DataBinding.FieldName = 'B6ChuYunGang'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 85
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21040#36135#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 51
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36152#26131#22269
|
||||
DataBinding.FieldName = 'B8MaoYiGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25269#36816#22269
|
||||
DataBinding.FieldName = 'B9DiYunGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'B10YunShuType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #36152#26131#26041#24335
|
||||
DataBinding.FieldName = 'D2MaoYiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 79
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #32467#27719#26041#24335
|
||||
DataBinding.FieldName = 'D3JiHuiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #25253#20851#26465#27454
|
||||
DataBinding.FieldName = 'F1BaoGuanTK'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #36816#36153
|
||||
DataBinding.FieldName = 'F2YunFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #20445#36153
|
||||
DataBinding.FieldName = 'F3BaoFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #36135#36816#20195#29702
|
||||
DataBinding.FieldName = 'F4HuoYunDaiLi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #33322#21517#33322#27425
|
||||
DataBinding.FieldName = 'B1HangBan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object v1Column24: TcxGridDBColumn
|
||||
Caption = #25552#21333#21495
|
||||
DataBinding.FieldName = 'B2TiDanHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column25: TcxGridDBColumn
|
||||
Caption = #31665#21495#23553#21495
|
||||
DataBinding.FieldName = 'B4XiangNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 72
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #33337#20844#21496
|
||||
DataBinding.FieldName = 'F5ChuanGongSi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #30331#35760#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column26: TcxGridDBColumn
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column27: TcxGridDBColumn
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column28: TcxGridDBColumn
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v1Column29: TcxGridDBColumn
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column30: TcxGridDBColumn
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoneyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 70
|
||||
Width = 1146
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Style = 8
|
||||
TabIndex = 0
|
||||
TabOrder = 3
|
||||
Tabs.Strings = (
|
||||
#24453#36865#23457
|
||||
#24050#36865#23457
|
||||
#24050#23457#25209
|
||||
#20840#37096)
|
||||
Visible = False
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1146
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object cxSplitter1: TcxSplitter
|
||||
Left = 0
|
||||
Top = 400
|
||||
Width = 1146
|
||||
Height = 8
|
||||
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||
AlignSplitter = salBottom
|
||||
Control = cxGrid2
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 408
|
||||
Width = 1146
|
||||
Height = 169
|
||||
Align = alBottom
|
||||
TabOrder = 5
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource2
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = cxGridDBColumn2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn10
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn11
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object cxGridDBColumn1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#21517
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 183
|
||||
end
|
||||
object cxGridDBColumn14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25104#20221#21547#37327
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn15: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24133#23485'(CM)'
|
||||
DataBinding.FieldName = 'YSFuKuan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn13: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #32455#36896#26041#27861
|
||||
DataBinding.FieldName = 'YSZhiZaoType'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#38024#32455
|
||||
#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object cxGridDBColumn16: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#29260
|
||||
DataBinding.FieldName = 'YSPinPai'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn17: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #29983#20135#21378#21830
|
||||
DataBinding.FieldName = 'YSShengChanShang'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = 'HS NO'
|
||||
DataBinding.FieldName = 'C2HSNO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 132
|
||||
end
|
||||
object cxGridDBColumn3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 51
|
||||
end
|
||||
object cxGridDBColumn4: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object cxGridDBColumn5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20215'(USD)'
|
||||
DataBinding.FieldName = 'C6BGPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 72
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object cxGridDBColumn8: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#21333#20301
|
||||
DataBinding.FieldName = 'E1BZUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'BALES'
|
||||
'ROLLS')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 67
|
||||
end
|
||||
object cxGridDBColumn10: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 62
|
||||
end
|
||||
object cxGridDBColumn11: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 64
|
||||
end
|
||||
object cxGridDBColumn12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21787#22836
|
||||
DataBinding.FieldName = 'E5MaiTou'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 768
|
||||
Top = 168
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 816
|
||||
Top = 224
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 472
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 912
|
||||
Top = 472
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 944
|
||||
Top = 472
|
||||
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 = 200
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 320
|
||||
Top = 208
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 208
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 288
|
||||
Top = 208
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,700 +0,0 @@
|
|||
unit U_BaoGuanListBGZL;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxButtonEdit, cxTextEdit, cxPC, BtnEdit, cxSplitter;
|
||||
|
||||
type
|
||||
TfrmBaoGuanListBGZL = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
cxTabControl1: TcxTabControl;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxSplitter1: TcxSplitter;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
Label5: TLabel;
|
||||
A6PONO: TEdit;
|
||||
Label8: TLabel;
|
||||
A5ConNO: TEdit;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label3: TLabel;
|
||||
A1ChuKouShang: TEdit;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
v1Column24: TcxGridDBColumn;
|
||||
v1Column25: TcxGridDBColumn;
|
||||
v1Column26: TcxGridDBColumn;
|
||||
v1Column27: TcxGridDBColumn;
|
||||
v1Column28: TcxGridDBColumn;
|
||||
v1Column29: TcxGridDBColumn;
|
||||
v1Column30: TcxGridDBColumn;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
cxGridDBColumn1: TcxGridDBColumn;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn3: TcxGridDBColumn;
|
||||
cxGridDBColumn4: TcxGridDBColumn;
|
||||
cxGridDBColumn5: TcxGridDBColumn;
|
||||
cxGridDBColumn6: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn8: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
cxGridDBColumn10: TcxGridDBColumn;
|
||||
cxGridDBColumn11: TcxGridDBColumn;
|
||||
cxGridDBColumn12: TcxGridDBColumn;
|
||||
cxGridDBColumn13: TcxGridDBColumn;
|
||||
cxGridDBColumn14: TcxGridDBColumn;
|
||||
cxGridDBColumn15: TcxGridDBColumn;
|
||||
cxGridDBColumn16: TcxGridDBColumn;
|
||||
cxGridDBColumn17: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
ToolButton7: TToolButton;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
ToolButton8: TToolButton;
|
||||
ToolButton9: TToolButton;
|
||||
ToolButton10: TToolButton;
|
||||
ToolButton11: TToolButton;
|
||||
ToolButton12: TToolButton;
|
||||
ToolButton3: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure A6PONOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure A5ConNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton7Click(Sender: TObject);
|
||||
procedure ToolButton8Click(Sender: TObject);
|
||||
procedure ToolButton9Click(Sender: TObject);
|
||||
procedure ToolButton10Click(Sender: TObject);
|
||||
procedure ToolButton11Click(Sender: TObject);
|
||||
procedure ToolButton12Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
private
|
||||
canshu1:string;
|
||||
canshu2:string;
|
||||
FDate:TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData():Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj:String);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanListBGZL: TfrmBaoGuanListBGZL;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp,U_BaoGuanInPut;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanListBGZL:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
canshu1:=Trim(DParameters1);
|
||||
canshu2:=Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where Valid=''Y'' ');
|
||||
{if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and Filler='''+Trim(DName)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
sql.Add(' and BGDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+'''');
|
||||
sql.Add(' and BGDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''');
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表',Tv1,'报关管理');
|
||||
WriteCxGrid('报关明细',Tv1,'报关管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表',Tv1,'报关管理');
|
||||
ReadCxGrid('报关明细',Tv1,'报关管理');
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('报关资料列表',cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,False);
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGZL.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty=False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID='''+Trim(CDS_Main.fieldbyname('BGID').AsString)+'''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp,ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp,ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmBaoGuanListBGZL.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer='''+Trim(DName)+''',EditTime=getdate()');
|
||||
sql.Add(' where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer='''+Trim(DName)+''',SEditTime=getdate() where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGZL.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A4FPNO,'''') like '''+'%'+Trim(A4FPNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGZL.InitGridSql(var fsj:String);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
{ if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode='''+Trim(DCode)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.A6PONOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A6PONO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A6PONO,'''') like '''+'%'+Trim(A6PONO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.A5ConNOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A5ConNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A5ConNO,'''') like '''+'%'+Trim(A5ConNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.ToolButton7Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关资料.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.ToolButton8Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关合同.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.ToolButton9Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
//fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
if Trim(CDS_Main.fieldbyname('A1ChuKouShang').AsString)='绍兴宇玎纺织有限公司' then
|
||||
begin
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票YD.rmf';
|
||||
end else
|
||||
if Trim(CDS_Main.fieldbyname('A1ChuKouShang').AsString)='绍兴锦凤进出口有限公司' then
|
||||
begin
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票JF.rmf';
|
||||
end;
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关发票.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.ToolButton10Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
//fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
if Trim(CDS_Main.fieldbyname('A1ChuKouShang').AsString)='绍兴宇玎纺织有限公司' then
|
||||
begin
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单YD.rmf';
|
||||
end else
|
||||
if Trim(CDS_Main.fieldbyname('A1ChuKouShang').AsString)='绍兴锦凤进出口有限公司' then
|
||||
begin
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单JF.rmf';
|
||||
end;
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else ZheSuanMiQty end as C4BGQtyJS ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关装箱单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.ToolButton11Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.ToolButton12Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut:=TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId:=Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible:=False;
|
||||
ToolBar2.Visible:=False;
|
||||
Panel1.Enabled:=False;
|
||||
Tv1.OptionsData.Editing:=False;
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZL.ToolButton3Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\申报要素.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,985 +0,0 @@
|
|||
object frmBaoGuanListBGZLCX: TfrmBaoGuanListBGZLCX
|
||||
Left = 110
|
||||
Top = 82
|
||||
Width = 1162
|
||||
Height = 615
|
||||
Caption = #25253#20851#36164#26009#21015#34920
|
||||
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 = 1146
|
||||
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 = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton12: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = ToolButton12Click
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#36164#26009
|
||||
ImageIndex = 4
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object ToolButton8: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21512#21516
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton8Click
|
||||
end
|
||||
object ToolButton9: TToolButton
|
||||
Left = 339
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21457#31080
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton9Click
|
||||
end
|
||||
object ToolButton10: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #35013#31665#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton10Click
|
||||
end
|
||||
object ToolButton11: TToolButton
|
||||
Left = 477
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton11Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 552
|
||||
Top = 0
|
||||
Caption = #30003#25253#35201#32032
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 635
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
Visible = False
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 698
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1146
|
||||
Height = 37
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 168
|
||||
Top = 12
|
||||
Width = 12
|
||||
Height = 12
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 279
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 639
|
||||
Top = 12
|
||||
Width = 42
|
||||
Height = 12
|
||||
Caption = #23458#25143'PO#'
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 455
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21512#21516#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 831
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #20986#21475#21830
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 181
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 315
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object A6PONO: TEdit
|
||||
Tag = 2
|
||||
Left = 683
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 492
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A5ConNOKeyPress
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 868
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1146
|
||||
Height = 309
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellClick = Tv1CellClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v2Column6
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #20986#21475#21830
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #31246#21495
|
||||
DataBinding.FieldName = 'A2ShuiHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 97
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #28023#20851#32534#30721
|
||||
DataBinding.FieldName = 'A3HaiGuanBM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 93
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Alignment.Horz = taLeftJustify
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 125
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23458#25143'PO#'
|
||||
DataBinding.FieldName = 'A6PONO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24320#33322#26085#26399
|
||||
DataBinding.FieldName = 'B3KaiHangDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 62
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #36135#26588
|
||||
DataBinding.FieldName = 'B5HuoGui'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36816#28207
|
||||
DataBinding.FieldName = 'B6ChuYunGang'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 85
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21040#36135#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 51
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36152#26131#22269
|
||||
DataBinding.FieldName = 'B8MaoYiGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25269#36816#22269
|
||||
DataBinding.FieldName = 'B9DiYunGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'B10YunShuType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #36152#26131#26041#24335
|
||||
DataBinding.FieldName = 'D2MaoYiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 79
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #32467#27719#26041#24335
|
||||
DataBinding.FieldName = 'D3JiHuiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #25253#20851#26465#27454
|
||||
DataBinding.FieldName = 'F1BaoGuanTK'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #36816#36153
|
||||
DataBinding.FieldName = 'F2YunFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #20445#36153
|
||||
DataBinding.FieldName = 'F3BaoFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #36135#36816#20195#29702
|
||||
DataBinding.FieldName = 'F4HuoYunDaiLi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #33322#21517#33322#27425
|
||||
DataBinding.FieldName = 'B1HangBan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object v1Column24: TcxGridDBColumn
|
||||
Caption = #25552#21333#21495
|
||||
DataBinding.FieldName = 'B2TiDanHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column25: TcxGridDBColumn
|
||||
Caption = #31665#21495#23553#21495
|
||||
DataBinding.FieldName = 'B4XiangNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 72
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #33337#20844#21496
|
||||
DataBinding.FieldName = 'F5ChuanGongSi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #30331#35760#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column26: TcxGridDBColumn
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column27: TcxGridDBColumn
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column28: TcxGridDBColumn
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v1Column29: TcxGridDBColumn
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column30: TcxGridDBColumn
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoneyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 70
|
||||
Width = 1146
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Style = 8
|
||||
TabIndex = 0
|
||||
TabOrder = 3
|
||||
Tabs.Strings = (
|
||||
#24453#36865#23457
|
||||
#24050#36865#23457
|
||||
#24050#23457#25209
|
||||
#20840#37096)
|
||||
Visible = False
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1146
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object cxSplitter1: TcxSplitter
|
||||
Left = 0
|
||||
Top = 400
|
||||
Width = 1146
|
||||
Height = 8
|
||||
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||
AlignSplitter = salBottom
|
||||
Control = cxGrid2
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 408
|
||||
Width = 1146
|
||||
Height = 169
|
||||
Align = alBottom
|
||||
TabOrder = 5
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource2
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = cxGridDBColumn2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn10
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn11
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object cxGridDBColumn1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#21517
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 183
|
||||
end
|
||||
object cxGridDBColumn14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25104#20221#21547#37327
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn15: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24133#23485'(CM)'
|
||||
DataBinding.FieldName = 'YSFuKuan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn13: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #32455#36896#26041#27861
|
||||
DataBinding.FieldName = 'YSZhiZaoType'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#38024#32455
|
||||
#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object cxGridDBColumn16: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#29260
|
||||
DataBinding.FieldName = 'YSPinPai'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn17: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #29983#20135#21378#21830
|
||||
DataBinding.FieldName = 'YSShengChanShang'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = 'HS NO'
|
||||
DataBinding.FieldName = 'C2HSNO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 132
|
||||
end
|
||||
object cxGridDBColumn3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 51
|
||||
end
|
||||
object cxGridDBColumn4: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object cxGridDBColumn5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20215'(USD)'
|
||||
DataBinding.FieldName = 'C6BGPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 72
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object cxGridDBColumn8: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#21333#20301
|
||||
DataBinding.FieldName = 'E1BZUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'BALES'
|
||||
'ROLLS')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 67
|
||||
end
|
||||
object cxGridDBColumn10: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 62
|
||||
end
|
||||
object cxGridDBColumn11: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 64
|
||||
end
|
||||
object cxGridDBColumn12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21787#22836
|
||||
DataBinding.FieldName = 'E5MaiTou'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 768
|
||||
Top = 168
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 816
|
||||
Top = 224
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 472
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 912
|
||||
Top = 472
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 944
|
||||
Top = 472
|
||||
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 = 200
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 320
|
||||
Top = 208
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 208
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 288
|
||||
Top = 208
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,684 +0,0 @@
|
|||
unit U_BaoGuanListBGZLCX;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxButtonEdit, cxTextEdit, cxPC, BtnEdit, cxSplitter;
|
||||
|
||||
type
|
||||
TfrmBaoGuanListBGZLCX = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
cxTabControl1: TcxTabControl;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxSplitter1: TcxSplitter;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
Label5: TLabel;
|
||||
A6PONO: TEdit;
|
||||
Label8: TLabel;
|
||||
A5ConNO: TEdit;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label3: TLabel;
|
||||
A1ChuKouShang: TEdit;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
v1Column24: TcxGridDBColumn;
|
||||
v1Column25: TcxGridDBColumn;
|
||||
v1Column26: TcxGridDBColumn;
|
||||
v1Column27: TcxGridDBColumn;
|
||||
v1Column28: TcxGridDBColumn;
|
||||
v1Column29: TcxGridDBColumn;
|
||||
v1Column30: TcxGridDBColumn;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
cxGridDBColumn1: TcxGridDBColumn;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn3: TcxGridDBColumn;
|
||||
cxGridDBColumn4: TcxGridDBColumn;
|
||||
cxGridDBColumn5: TcxGridDBColumn;
|
||||
cxGridDBColumn6: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn8: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
cxGridDBColumn10: TcxGridDBColumn;
|
||||
cxGridDBColumn11: TcxGridDBColumn;
|
||||
cxGridDBColumn12: TcxGridDBColumn;
|
||||
cxGridDBColumn13: TcxGridDBColumn;
|
||||
cxGridDBColumn14: TcxGridDBColumn;
|
||||
cxGridDBColumn15: TcxGridDBColumn;
|
||||
cxGridDBColumn16: TcxGridDBColumn;
|
||||
cxGridDBColumn17: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
ToolButton7: TToolButton;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
ToolButton8: TToolButton;
|
||||
ToolButton9: TToolButton;
|
||||
ToolButton10: TToolButton;
|
||||
ToolButton11: TToolButton;
|
||||
ToolButton12: TToolButton;
|
||||
ToolButton3: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure A6PONOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure A5ConNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton7Click(Sender: TObject);
|
||||
procedure ToolButton8Click(Sender: TObject);
|
||||
procedure ToolButton9Click(Sender: TObject);
|
||||
procedure ToolButton10Click(Sender: TObject);
|
||||
procedure ToolButton11Click(Sender: TObject);
|
||||
procedure ToolButton12Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
private
|
||||
canshu1:string;
|
||||
canshu2:string;
|
||||
FDate:TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData():Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj:String);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanListBGZLCX: TfrmBaoGuanListBGZLCX;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp,U_BaoGuanInPut;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanListBGZLCX:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
canshu1:=Trim(DParameters1);
|
||||
canshu2:=Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where Valid=''Y'' ');
|
||||
{if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and Filler='''+Trim(DName)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
sql.Add(' and BGDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+'''');
|
||||
sql.Add(' and BGDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''');
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表BGZL',Tv1,'报关管理');
|
||||
WriteCxGrid('报关明细BGZL',Tv1,'报关管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表BGZL',Tv1,'报关管理');
|
||||
ReadCxGrid('报关明细BGZL',Tv1,'报关管理');
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('报关资料列表',cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,False);
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGZLCX.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty=False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID='''+Trim(CDS_Main.fieldbyname('BGID').AsString)+'''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp,ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp,ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmBaoGuanListBGZLCX.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer='''+Trim(DName)+''',EditTime=getdate()');
|
||||
sql.Add(' where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer='''+Trim(DName)+''',SEditTime=getdate() where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGZLCX.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A4FPNO,'''') like '''+'%'+Trim(A4FPNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListBGZLCX.InitGridSql(var fsj:String);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
{ if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode='''+Trim(DCode)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.A6PONOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A6PONO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A6PONO,'''') like '''+'%'+Trim(A6PONO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.A5ConNOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A5ConNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A5ConNO,'''') like '''+'%'+Trim(A5ConNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.ToolButton7Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关资料.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.ToolButton8Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关合同.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.ToolButton9Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关发票.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.ToolButton10Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关装箱单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.ToolButton11Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.ToolButton12Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut:=TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId:=Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible:=False;
|
||||
ToolBar2.Visible:=False;
|
||||
Panel1.Enabled:=False;
|
||||
Tv1.OptionsData.Editing:=False;
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListBGZLCX.ToolButton3Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\申报要素.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,985 +0,0 @@
|
|||
object frmBaoGuanListFP: TfrmBaoGuanListFP
|
||||
Left = 110
|
||||
Top = 82
|
||||
Width = 1162
|
||||
Height = 615
|
||||
Caption = #25253#20851#21457#31080#21015#34920
|
||||
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 = 1146
|
||||
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 = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton12: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = ToolButton12Click
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#36164#26009
|
||||
ImageIndex = 4
|
||||
Visible = False
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object ToolButton8: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21512#21516
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton8Click
|
||||
end
|
||||
object ToolButton9: TToolButton
|
||||
Left = 339
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21457#31080
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton9Click
|
||||
end
|
||||
object ToolButton10: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #35013#31665#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton10Click
|
||||
end
|
||||
object ToolButton11: TToolButton
|
||||
Left = 477
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton11Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 552
|
||||
Top = 0
|
||||
Caption = #30003#25253#35201#32032
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 635
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
Visible = False
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 698
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1146
|
||||
Height = 37
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 168
|
||||
Top = 12
|
||||
Width = 12
|
||||
Height = 12
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 279
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 639
|
||||
Top = 12
|
||||
Width = 42
|
||||
Height = 12
|
||||
Caption = #23458#25143'PO#'
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 455
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21512#21516#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 831
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #20986#21475#21830
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 181
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 315
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object A6PONO: TEdit
|
||||
Tag = 2
|
||||
Left = 683
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 492
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A5ConNOKeyPress
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 868
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1146
|
||||
Height = 309
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellClick = Tv1CellClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v2Column6
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #20986#21475#21830
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #31246#21495
|
||||
DataBinding.FieldName = 'A2ShuiHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 97
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #28023#20851#32534#30721
|
||||
DataBinding.FieldName = 'A3HaiGuanBM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 93
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Alignment.Horz = taLeftJustify
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 125
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23458#25143'PO#'
|
||||
DataBinding.FieldName = 'A6PONO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24320#33322#26085#26399
|
||||
DataBinding.FieldName = 'B3KaiHangDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 62
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #36135#26588
|
||||
DataBinding.FieldName = 'B5HuoGui'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36816#28207
|
||||
DataBinding.FieldName = 'B6ChuYunGang'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 85
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21040#36135#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 51
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36152#26131#22269
|
||||
DataBinding.FieldName = 'B8MaoYiGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25269#36816#22269
|
||||
DataBinding.FieldName = 'B9DiYunGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'B10YunShuType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #36152#26131#26041#24335
|
||||
DataBinding.FieldName = 'D2MaoYiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 79
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #32467#27719#26041#24335
|
||||
DataBinding.FieldName = 'D3JiHuiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #25253#20851#26465#27454
|
||||
DataBinding.FieldName = 'F1BaoGuanTK'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #36816#36153
|
||||
DataBinding.FieldName = 'F2YunFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #20445#36153
|
||||
DataBinding.FieldName = 'F3BaoFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #36135#36816#20195#29702
|
||||
DataBinding.FieldName = 'F4HuoYunDaiLi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #33322#21517#33322#27425
|
||||
DataBinding.FieldName = 'B1HangBan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object v1Column24: TcxGridDBColumn
|
||||
Caption = #25552#21333#21495
|
||||
DataBinding.FieldName = 'B2TiDanHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column25: TcxGridDBColumn
|
||||
Caption = #31665#21495#23553#21495
|
||||
DataBinding.FieldName = 'B4XiangNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 72
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #33337#20844#21496
|
||||
DataBinding.FieldName = 'F5ChuanGongSi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #30331#35760#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column26: TcxGridDBColumn
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column27: TcxGridDBColumn
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column28: TcxGridDBColumn
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v1Column29: TcxGridDBColumn
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column30: TcxGridDBColumn
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoneyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 70
|
||||
Width = 1146
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Style = 8
|
||||
TabIndex = 0
|
||||
TabOrder = 3
|
||||
Tabs.Strings = (
|
||||
#24453#36865#23457
|
||||
#24050#36865#23457
|
||||
#24050#23457#25209
|
||||
#20840#37096)
|
||||
Visible = False
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1146
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object cxSplitter1: TcxSplitter
|
||||
Left = 0
|
||||
Top = 400
|
||||
Width = 1146
|
||||
Height = 8
|
||||
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||
AlignSplitter = salBottom
|
||||
Control = cxGrid2
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 408
|
||||
Width = 1146
|
||||
Height = 169
|
||||
Align = alBottom
|
||||
TabOrder = 5
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource2
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = cxGridDBColumn2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn10
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn11
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object cxGridDBColumn1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#21517
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 183
|
||||
end
|
||||
object cxGridDBColumn14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25104#20221#21547#37327
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn15: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24133#23485'(CM)'
|
||||
DataBinding.FieldName = 'YSFuKuan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn13: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #32455#36896#26041#27861
|
||||
DataBinding.FieldName = 'YSZhiZaoType'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#38024#32455
|
||||
#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object cxGridDBColumn16: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#29260
|
||||
DataBinding.FieldName = 'YSPinPai'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn17: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #29983#20135#21378#21830
|
||||
DataBinding.FieldName = 'YSShengChanShang'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = 'HS NO'
|
||||
DataBinding.FieldName = 'C2HSNO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 132
|
||||
end
|
||||
object cxGridDBColumn3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 51
|
||||
end
|
||||
object cxGridDBColumn4: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object cxGridDBColumn5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20215'(USD)'
|
||||
DataBinding.FieldName = 'C6BGPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 72
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object cxGridDBColumn8: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#21333#20301
|
||||
DataBinding.FieldName = 'E1BZUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'BALES'
|
||||
'ROLLS')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 67
|
||||
end
|
||||
object cxGridDBColumn10: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 62
|
||||
end
|
||||
object cxGridDBColumn11: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 64
|
||||
end
|
||||
object cxGridDBColumn12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21787#22836
|
||||
DataBinding.FieldName = 'E5MaiTou'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 768
|
||||
Top = 168
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 816
|
||||
Top = 224
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 472
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 912
|
||||
Top = 472
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 944
|
||||
Top = 472
|
||||
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 = 200
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 320
|
||||
Top = 208
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 208
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 288
|
||||
Top = 208
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,692 +0,0 @@
|
|||
unit U_BaoGuanListFP;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxButtonEdit, cxTextEdit, cxPC, BtnEdit, cxSplitter;
|
||||
|
||||
type
|
||||
TfrmBaoGuanListFP = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
cxTabControl1: TcxTabControl;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxSplitter1: TcxSplitter;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
Label5: TLabel;
|
||||
A6PONO: TEdit;
|
||||
Label8: TLabel;
|
||||
A5ConNO: TEdit;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label3: TLabel;
|
||||
A1ChuKouShang: TEdit;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
v1Column24: TcxGridDBColumn;
|
||||
v1Column25: TcxGridDBColumn;
|
||||
v1Column26: TcxGridDBColumn;
|
||||
v1Column27: TcxGridDBColumn;
|
||||
v1Column28: TcxGridDBColumn;
|
||||
v1Column29: TcxGridDBColumn;
|
||||
v1Column30: TcxGridDBColumn;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
cxGridDBColumn1: TcxGridDBColumn;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn3: TcxGridDBColumn;
|
||||
cxGridDBColumn4: TcxGridDBColumn;
|
||||
cxGridDBColumn5: TcxGridDBColumn;
|
||||
cxGridDBColumn6: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn8: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
cxGridDBColumn10: TcxGridDBColumn;
|
||||
cxGridDBColumn11: TcxGridDBColumn;
|
||||
cxGridDBColumn12: TcxGridDBColumn;
|
||||
cxGridDBColumn13: TcxGridDBColumn;
|
||||
cxGridDBColumn14: TcxGridDBColumn;
|
||||
cxGridDBColumn15: TcxGridDBColumn;
|
||||
cxGridDBColumn16: TcxGridDBColumn;
|
||||
cxGridDBColumn17: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
ToolButton7: TToolButton;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
ToolButton8: TToolButton;
|
||||
ToolButton9: TToolButton;
|
||||
ToolButton10: TToolButton;
|
||||
ToolButton11: TToolButton;
|
||||
ToolButton12: TToolButton;
|
||||
ToolButton3: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure A6PONOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure A5ConNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton7Click(Sender: TObject);
|
||||
procedure ToolButton8Click(Sender: TObject);
|
||||
procedure ToolButton9Click(Sender: TObject);
|
||||
procedure ToolButton10Click(Sender: TObject);
|
||||
procedure ToolButton11Click(Sender: TObject);
|
||||
procedure ToolButton12Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
private
|
||||
canshu1:string;
|
||||
canshu2:string;
|
||||
FDate:TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData():Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj:String);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanListFP: TfrmBaoGuanListFP;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp,U_BaoGuanInPut;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanListFP.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanListFP:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
canshu1:=Trim(DParameters1);
|
||||
canshu2:=Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where Valid=''Y'' ');
|
||||
{if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and Filler='''+Trim(DName)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
sql.Add(' and BGDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+'''');
|
||||
sql.Add(' and BGDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''');
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表FP',Tv1,'报关管理');
|
||||
WriteCxGrid('报关明细FP',Tv1,'报关管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表FP',Tv1,'报关管理');
|
||||
ReadCxGrid('报关明细FP',Tv1,'报关管理');
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('报关资料列表',cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,False);
|
||||
end;
|
||||
procedure TfrmBaoGuanListFP.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty=False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID='''+Trim(CDS_Main.fieldbyname('BGID').AsString)+'''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp,ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp,ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmBaoGuanListFP.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer='''+Trim(DName)+''',EditTime=getdate()');
|
||||
sql.Add(' where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer='''+Trim(DName)+''',SEditTime=getdate() where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListFP.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmBaoGuanListFP.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A4FPNO,'''') like '''+'%'+Trim(A4FPNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListFP.InitGridSql(var fsj:String);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
{ if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode='''+Trim(DCode)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.A6PONOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A6PONO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A6PONO,'''') like '''+'%'+Trim(A6PONO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.A5ConNOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A5ConNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A5ConNO,'''') like '''+'%'+Trim(A5ConNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.ToolButton7Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关资料.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.ToolButton8Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关合同.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.ToolButton9Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
//fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
if Trim(CDS_Main.fieldbyname('A1ChuKouShang').AsString)='绍兴宇玎纺织有限公司' then
|
||||
begin
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票YD.rmf';
|
||||
end else
|
||||
if Trim(CDS_Main.fieldbyname('A1ChuKouShang').AsString)='绍兴锦凤进出口有限公司' then
|
||||
begin
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票JF.rmf';
|
||||
end;
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关发票.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.ToolButton10Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关装箱单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.ToolButton11Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.ToolButton12Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut:=TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId:=Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible:=False;
|
||||
ToolBar2.Visible:=False;
|
||||
Panel1.Enabled:=False;
|
||||
Tv1.OptionsData.Editing:=False;
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListFP.ToolButton3Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\申报要素.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,985 +0,0 @@
|
|||
object frmBaoGuanListHT: TfrmBaoGuanListHT
|
||||
Left = 110
|
||||
Top = 82
|
||||
Width = 1162
|
||||
Height = 615
|
||||
Caption = #25253#20851#21512#21516#21015#34920
|
||||
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 = 1146
|
||||
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 = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton12: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = ToolButton12Click
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#36164#26009
|
||||
ImageIndex = 4
|
||||
Visible = False
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object ToolButton8: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21512#21516
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton8Click
|
||||
end
|
||||
object ToolButton9: TToolButton
|
||||
Left = 339
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21457#31080
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton9Click
|
||||
end
|
||||
object ToolButton10: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #35013#31665#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton10Click
|
||||
end
|
||||
object ToolButton11: TToolButton
|
||||
Left = 477
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton11Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 552
|
||||
Top = 0
|
||||
Caption = #30003#25253#35201#32032
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 635
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
Visible = False
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 698
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1146
|
||||
Height = 37
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 168
|
||||
Top = 12
|
||||
Width = 12
|
||||
Height = 12
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 279
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 639
|
||||
Top = 12
|
||||
Width = 42
|
||||
Height = 12
|
||||
Caption = #23458#25143'PO#'
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 455
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21512#21516#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 831
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #20986#21475#21830
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 181
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 315
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object A6PONO: TEdit
|
||||
Tag = 2
|
||||
Left = 683
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 492
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A5ConNOKeyPress
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 868
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1146
|
||||
Height = 309
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellClick = Tv1CellClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v2Column6
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #20986#21475#21830
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #31246#21495
|
||||
DataBinding.FieldName = 'A2ShuiHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 97
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #28023#20851#32534#30721
|
||||
DataBinding.FieldName = 'A3HaiGuanBM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 93
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Alignment.Horz = taLeftJustify
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 125
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23458#25143'PO#'
|
||||
DataBinding.FieldName = 'A6PONO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24320#33322#26085#26399
|
||||
DataBinding.FieldName = 'B3KaiHangDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 62
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #36135#26588
|
||||
DataBinding.FieldName = 'B5HuoGui'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36816#28207
|
||||
DataBinding.FieldName = 'B6ChuYunGang'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 85
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21040#36135#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 51
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36152#26131#22269
|
||||
DataBinding.FieldName = 'B8MaoYiGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25269#36816#22269
|
||||
DataBinding.FieldName = 'B9DiYunGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'B10YunShuType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #36152#26131#26041#24335
|
||||
DataBinding.FieldName = 'D2MaoYiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 79
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #32467#27719#26041#24335
|
||||
DataBinding.FieldName = 'D3JiHuiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #25253#20851#26465#27454
|
||||
DataBinding.FieldName = 'F1BaoGuanTK'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #36816#36153
|
||||
DataBinding.FieldName = 'F2YunFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #20445#36153
|
||||
DataBinding.FieldName = 'F3BaoFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #36135#36816#20195#29702
|
||||
DataBinding.FieldName = 'F4HuoYunDaiLi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #33322#21517#33322#27425
|
||||
DataBinding.FieldName = 'B1HangBan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object v1Column24: TcxGridDBColumn
|
||||
Caption = #25552#21333#21495
|
||||
DataBinding.FieldName = 'B2TiDanHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column25: TcxGridDBColumn
|
||||
Caption = #31665#21495#23553#21495
|
||||
DataBinding.FieldName = 'B4XiangNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 72
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #33337#20844#21496
|
||||
DataBinding.FieldName = 'F5ChuanGongSi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #30331#35760#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column26: TcxGridDBColumn
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column27: TcxGridDBColumn
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column28: TcxGridDBColumn
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v1Column29: TcxGridDBColumn
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column30: TcxGridDBColumn
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoneyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 70
|
||||
Width = 1146
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Style = 8
|
||||
TabIndex = 0
|
||||
TabOrder = 3
|
||||
Tabs.Strings = (
|
||||
#24453#36865#23457
|
||||
#24050#36865#23457
|
||||
#24050#23457#25209
|
||||
#20840#37096)
|
||||
Visible = False
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1146
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object cxSplitter1: TcxSplitter
|
||||
Left = 0
|
||||
Top = 400
|
||||
Width = 1146
|
||||
Height = 8
|
||||
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||
AlignSplitter = salBottom
|
||||
Control = cxGrid2
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 408
|
||||
Width = 1146
|
||||
Height = 169
|
||||
Align = alBottom
|
||||
TabOrder = 5
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource2
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = cxGridDBColumn2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn10
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn11
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object cxGridDBColumn1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#21517
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 183
|
||||
end
|
||||
object cxGridDBColumn14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25104#20221#21547#37327
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn15: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24133#23485'(CM)'
|
||||
DataBinding.FieldName = 'YSFuKuan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn13: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #32455#36896#26041#27861
|
||||
DataBinding.FieldName = 'YSZhiZaoType'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#38024#32455
|
||||
#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object cxGridDBColumn16: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#29260
|
||||
DataBinding.FieldName = 'YSPinPai'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn17: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #29983#20135#21378#21830
|
||||
DataBinding.FieldName = 'YSShengChanShang'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = 'HS NO'
|
||||
DataBinding.FieldName = 'C2HSNO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 132
|
||||
end
|
||||
object cxGridDBColumn3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 51
|
||||
end
|
||||
object cxGridDBColumn4: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object cxGridDBColumn5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20215'(USD)'
|
||||
DataBinding.FieldName = 'C6BGPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 72
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object cxGridDBColumn8: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#21333#20301
|
||||
DataBinding.FieldName = 'E1BZUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'BALES'
|
||||
'ROLLS')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 67
|
||||
end
|
||||
object cxGridDBColumn10: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 62
|
||||
end
|
||||
object cxGridDBColumn11: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 64
|
||||
end
|
||||
object cxGridDBColumn12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21787#22836
|
||||
DataBinding.FieldName = 'E5MaiTou'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 768
|
||||
Top = 168
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 816
|
||||
Top = 224
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 472
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 912
|
||||
Top = 472
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 944
|
||||
Top = 472
|
||||
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 = 200
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 320
|
||||
Top = 208
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 208
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 288
|
||||
Top = 208
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,684 +0,0 @@
|
|||
unit U_BaoGuanListHT;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxButtonEdit, cxTextEdit, cxPC, BtnEdit, cxSplitter;
|
||||
|
||||
type
|
||||
TfrmBaoGuanListHT = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
cxTabControl1: TcxTabControl;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxSplitter1: TcxSplitter;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
Label5: TLabel;
|
||||
A6PONO: TEdit;
|
||||
Label8: TLabel;
|
||||
A5ConNO: TEdit;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label3: TLabel;
|
||||
A1ChuKouShang: TEdit;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
v1Column24: TcxGridDBColumn;
|
||||
v1Column25: TcxGridDBColumn;
|
||||
v1Column26: TcxGridDBColumn;
|
||||
v1Column27: TcxGridDBColumn;
|
||||
v1Column28: TcxGridDBColumn;
|
||||
v1Column29: TcxGridDBColumn;
|
||||
v1Column30: TcxGridDBColumn;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
cxGridDBColumn1: TcxGridDBColumn;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn3: TcxGridDBColumn;
|
||||
cxGridDBColumn4: TcxGridDBColumn;
|
||||
cxGridDBColumn5: TcxGridDBColumn;
|
||||
cxGridDBColumn6: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn8: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
cxGridDBColumn10: TcxGridDBColumn;
|
||||
cxGridDBColumn11: TcxGridDBColumn;
|
||||
cxGridDBColumn12: TcxGridDBColumn;
|
||||
cxGridDBColumn13: TcxGridDBColumn;
|
||||
cxGridDBColumn14: TcxGridDBColumn;
|
||||
cxGridDBColumn15: TcxGridDBColumn;
|
||||
cxGridDBColumn16: TcxGridDBColumn;
|
||||
cxGridDBColumn17: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
ToolButton7: TToolButton;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
ToolButton8: TToolButton;
|
||||
ToolButton9: TToolButton;
|
||||
ToolButton10: TToolButton;
|
||||
ToolButton11: TToolButton;
|
||||
ToolButton12: TToolButton;
|
||||
ToolButton3: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure A6PONOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure A5ConNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton7Click(Sender: TObject);
|
||||
procedure ToolButton8Click(Sender: TObject);
|
||||
procedure ToolButton9Click(Sender: TObject);
|
||||
procedure ToolButton10Click(Sender: TObject);
|
||||
procedure ToolButton11Click(Sender: TObject);
|
||||
procedure ToolButton12Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
private
|
||||
canshu1:string;
|
||||
canshu2:string;
|
||||
FDate:TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData():Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj:String);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanListHT: TfrmBaoGuanListHT;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp,U_BaoGuanInPut;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanListHT.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanListHT:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
canshu1:=Trim(DParameters1);
|
||||
canshu2:=Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where Valid=''Y'' ');
|
||||
{if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and Filler='''+Trim(DName)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
sql.Add(' and BGDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+'''');
|
||||
sql.Add(' and BGDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''');
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表HT',Tv1,'报关管理');
|
||||
WriteCxGrid('报关明细HT',Tv1,'报关管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表HT',Tv1,'报关管理');
|
||||
ReadCxGrid('报关明细HT',Tv1,'报关管理');
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('报关资料列表',cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,False);
|
||||
end;
|
||||
procedure TfrmBaoGuanListHT.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty=False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID='''+Trim(CDS_Main.fieldbyname('BGID').AsString)+'''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp,ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp,ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmBaoGuanListHT.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer='''+Trim(DName)+''',EditTime=getdate()');
|
||||
sql.Add(' where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer='''+Trim(DName)+''',SEditTime=getdate() where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListHT.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmBaoGuanListHT.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A4FPNO,'''') like '''+'%'+Trim(A4FPNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListHT.InitGridSql(var fsj:String);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
{ if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode='''+Trim(DCode)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.A6PONOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A6PONO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A6PONO,'''') like '''+'%'+Trim(A6PONO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.A5ConNOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A5ConNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A5ConNO,'''') like '''+'%'+Trim(A5ConNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.ToolButton7Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关资料.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.ToolButton8Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关合同.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.ToolButton9Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关发票.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.ToolButton10Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关装箱单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.ToolButton11Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.ToolButton12Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut:=TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId:=Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible:=False;
|
||||
ToolBar2.Visible:=False;
|
||||
Panel1.Enabled:=False;
|
||||
Tv1.OptionsData.Editing:=False;
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListHT.ToolButton3Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\申报要素.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -1,985 +0,0 @@
|
|||
object frmBaoGuanListSBYS: TfrmBaoGuanListSBYS
|
||||
Left = 110
|
||||
Top = 82
|
||||
Width = 1162
|
||||
Height = 615
|
||||
Caption = #25253#20851#21333#21015#34920
|
||||
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 = 1146
|
||||
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 = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton12: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = ToolButton12Click
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#36164#26009
|
||||
ImageIndex = 4
|
||||
Visible = False
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object ToolButton8: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21512#21516
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton8Click
|
||||
end
|
||||
object ToolButton9: TToolButton
|
||||
Left = 339
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21457#31080
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton9Click
|
||||
end
|
||||
object ToolButton10: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #35013#31665#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton10Click
|
||||
end
|
||||
object ToolButton11: TToolButton
|
||||
Left = 477
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton11Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 552
|
||||
Top = 0
|
||||
Caption = #30003#25253#35201#32032
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 635
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
Visible = False
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 698
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1146
|
||||
Height = 37
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 168
|
||||
Top = 12
|
||||
Width = 12
|
||||
Height = 12
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 279
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 639
|
||||
Top = 12
|
||||
Width = 42
|
||||
Height = 12
|
||||
Caption = #23458#25143'PO#'
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 455
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21512#21516#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 831
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #20986#21475#21830
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 181
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 315
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object A6PONO: TEdit
|
||||
Tag = 2
|
||||
Left = 683
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 492
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A5ConNOKeyPress
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 868
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1146
|
||||
Height = 309
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellClick = Tv1CellClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v2Column6
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #20986#21475#21830
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #31246#21495
|
||||
DataBinding.FieldName = 'A2ShuiHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 97
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #28023#20851#32534#30721
|
||||
DataBinding.FieldName = 'A3HaiGuanBM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 93
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Alignment.Horz = taLeftJustify
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 125
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23458#25143'PO#'
|
||||
DataBinding.FieldName = 'A6PONO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24320#33322#26085#26399
|
||||
DataBinding.FieldName = 'B3KaiHangDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 62
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #36135#26588
|
||||
DataBinding.FieldName = 'B5HuoGui'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36816#28207
|
||||
DataBinding.FieldName = 'B6ChuYunGang'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 85
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21040#36135#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 51
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36152#26131#22269
|
||||
DataBinding.FieldName = 'B8MaoYiGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25269#36816#22269
|
||||
DataBinding.FieldName = 'B9DiYunGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'B10YunShuType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #36152#26131#26041#24335
|
||||
DataBinding.FieldName = 'D2MaoYiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 79
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #32467#27719#26041#24335
|
||||
DataBinding.FieldName = 'D3JiHuiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #25253#20851#26465#27454
|
||||
DataBinding.FieldName = 'F1BaoGuanTK'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #36816#36153
|
||||
DataBinding.FieldName = 'F2YunFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #20445#36153
|
||||
DataBinding.FieldName = 'F3BaoFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #36135#36816#20195#29702
|
||||
DataBinding.FieldName = 'F4HuoYunDaiLi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #33322#21517#33322#27425
|
||||
DataBinding.FieldName = 'B1HangBan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object v1Column24: TcxGridDBColumn
|
||||
Caption = #25552#21333#21495
|
||||
DataBinding.FieldName = 'B2TiDanHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column25: TcxGridDBColumn
|
||||
Caption = #31665#21495#23553#21495
|
||||
DataBinding.FieldName = 'B4XiangNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 72
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #33337#20844#21496
|
||||
DataBinding.FieldName = 'F5ChuanGongSi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #30331#35760#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column26: TcxGridDBColumn
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column27: TcxGridDBColumn
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column28: TcxGridDBColumn
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v1Column29: TcxGridDBColumn
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column30: TcxGridDBColumn
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoneyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 70
|
||||
Width = 1146
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Style = 8
|
||||
TabIndex = 0
|
||||
TabOrder = 3
|
||||
Tabs.Strings = (
|
||||
#24453#36865#23457
|
||||
#24050#36865#23457
|
||||
#24050#23457#25209
|
||||
#20840#37096)
|
||||
Visible = False
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1146
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object cxSplitter1: TcxSplitter
|
||||
Left = 0
|
||||
Top = 400
|
||||
Width = 1146
|
||||
Height = 8
|
||||
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||
AlignSplitter = salBottom
|
||||
Control = cxGrid2
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 408
|
||||
Width = 1146
|
||||
Height = 169
|
||||
Align = alBottom
|
||||
TabOrder = 5
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource2
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = cxGridDBColumn2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn10
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn11
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object cxGridDBColumn1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#21517
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 183
|
||||
end
|
||||
object cxGridDBColumn14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25104#20221#21547#37327
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn15: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24133#23485'(CM)'
|
||||
DataBinding.FieldName = 'YSFuKuan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn13: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #32455#36896#26041#27861
|
||||
DataBinding.FieldName = 'YSZhiZaoType'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#38024#32455
|
||||
#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object cxGridDBColumn16: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#29260
|
||||
DataBinding.FieldName = 'YSPinPai'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn17: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #29983#20135#21378#21830
|
||||
DataBinding.FieldName = 'YSShengChanShang'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = 'HS NO'
|
||||
DataBinding.FieldName = 'C2HSNO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 132
|
||||
end
|
||||
object cxGridDBColumn3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 51
|
||||
end
|
||||
object cxGridDBColumn4: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object cxGridDBColumn5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20215'(USD)'
|
||||
DataBinding.FieldName = 'C6BGPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 72
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object cxGridDBColumn8: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#21333#20301
|
||||
DataBinding.FieldName = 'E1BZUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'BALES'
|
||||
'ROLLS')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 67
|
||||
end
|
||||
object cxGridDBColumn10: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 62
|
||||
end
|
||||
object cxGridDBColumn11: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 64
|
||||
end
|
||||
object cxGridDBColumn12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21787#22836
|
||||
DataBinding.FieldName = 'E5MaiTou'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 768
|
||||
Top = 168
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 816
|
||||
Top = 224
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 472
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 912
|
||||
Top = 472
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 944
|
||||
Top = 472
|
||||
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 = 200
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 320
|
||||
Top = 208
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 208
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 288
|
||||
Top = 208
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,684 +0,0 @@
|
|||
unit U_BaoGuanListSBYS;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxButtonEdit, cxTextEdit, cxPC, BtnEdit, cxSplitter;
|
||||
|
||||
type
|
||||
TfrmBaoGuanListSBYS = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
cxTabControl1: TcxTabControl;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxSplitter1: TcxSplitter;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
Label5: TLabel;
|
||||
A6PONO: TEdit;
|
||||
Label8: TLabel;
|
||||
A5ConNO: TEdit;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label3: TLabel;
|
||||
A1ChuKouShang: TEdit;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
v1Column24: TcxGridDBColumn;
|
||||
v1Column25: TcxGridDBColumn;
|
||||
v1Column26: TcxGridDBColumn;
|
||||
v1Column27: TcxGridDBColumn;
|
||||
v1Column28: TcxGridDBColumn;
|
||||
v1Column29: TcxGridDBColumn;
|
||||
v1Column30: TcxGridDBColumn;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
cxGridDBColumn1: TcxGridDBColumn;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn3: TcxGridDBColumn;
|
||||
cxGridDBColumn4: TcxGridDBColumn;
|
||||
cxGridDBColumn5: TcxGridDBColumn;
|
||||
cxGridDBColumn6: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn8: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
cxGridDBColumn10: TcxGridDBColumn;
|
||||
cxGridDBColumn11: TcxGridDBColumn;
|
||||
cxGridDBColumn12: TcxGridDBColumn;
|
||||
cxGridDBColumn13: TcxGridDBColumn;
|
||||
cxGridDBColumn14: TcxGridDBColumn;
|
||||
cxGridDBColumn15: TcxGridDBColumn;
|
||||
cxGridDBColumn16: TcxGridDBColumn;
|
||||
cxGridDBColumn17: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
ToolButton7: TToolButton;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
ToolButton8: TToolButton;
|
||||
ToolButton9: TToolButton;
|
||||
ToolButton10: TToolButton;
|
||||
ToolButton11: TToolButton;
|
||||
ToolButton12: TToolButton;
|
||||
ToolButton3: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure A6PONOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure A5ConNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton7Click(Sender: TObject);
|
||||
procedure ToolButton8Click(Sender: TObject);
|
||||
procedure ToolButton9Click(Sender: TObject);
|
||||
procedure ToolButton10Click(Sender: TObject);
|
||||
procedure ToolButton11Click(Sender: TObject);
|
||||
procedure ToolButton12Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
private
|
||||
canshu1:string;
|
||||
canshu2:string;
|
||||
FDate:TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData():Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj:String);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanListSBYS: TfrmBaoGuanListSBYS;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp,U_BaoGuanInPut;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanListSBYS:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
canshu1:=Trim(DParameters1);
|
||||
canshu2:=Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where Valid=''Y'' ');
|
||||
{if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and Filler='''+Trim(DName)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
sql.Add(' and BGDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+'''');
|
||||
sql.Add(' and BGDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''');
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表SBYS',Tv1,'报关管理');
|
||||
WriteCxGrid('报关明细SBYS',Tv1,'报关管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表SBYS',Tv1,'报关管理');
|
||||
ReadCxGrid('报关明细SBYS',Tv1,'报关管理');
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('报关资料列表',cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,False);
|
||||
end;
|
||||
procedure TfrmBaoGuanListSBYS.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty=False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID='''+Trim(CDS_Main.fieldbyname('BGID').AsString)+'''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp,ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp,ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmBaoGuanListSBYS.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer='''+Trim(DName)+''',EditTime=getdate()');
|
||||
sql.Add(' where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer='''+Trim(DName)+''',SEditTime=getdate() where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListSBYS.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A4FPNO,'''') like '''+'%'+Trim(A4FPNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListSBYS.InitGridSql(var fsj:String);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
{ if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode='''+Trim(DCode)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.A6PONOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A6PONO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A6PONO,'''') like '''+'%'+Trim(A6PONO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.A5ConNOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A5ConNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A5ConNO,'''') like '''+'%'+Trim(A5ConNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.ToolButton7Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关资料.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.ToolButton8Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关合同.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.ToolButton9Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关发票.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.ToolButton10Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关装箱单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.ToolButton11Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.ToolButton12Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut:=TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId:=Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible:=False;
|
||||
ToolBar2.Visible:=False;
|
||||
Panel1.Enabled:=False;
|
||||
Tv1.OptionsData.Editing:=False;
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListSBYS.ToolButton3Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\申报要素.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,985 +0,0 @@
|
|||
object frmBaoGuanListZXD: TfrmBaoGuanListZXD
|
||||
Left = 110
|
||||
Top = 82
|
||||
Width = 1162
|
||||
Height = 615
|
||||
Caption = #25253#20851#35013#31665#21333#21015#34920
|
||||
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 = 1146
|
||||
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 = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton12: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = ToolButton12Click
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#36164#26009
|
||||
ImageIndex = 4
|
||||
Visible = False
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object ToolButton8: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21512#21516
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton8Click
|
||||
end
|
||||
object ToolButton9: TToolButton
|
||||
Left = 339
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21457#31080
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton9Click
|
||||
end
|
||||
object ToolButton10: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #35013#31665#21333
|
||||
ImageIndex = 14
|
||||
OnClick = ToolButton10Click
|
||||
end
|
||||
object ToolButton11: TToolButton
|
||||
Left = 477
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25253#20851#21333
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton11Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 552
|
||||
Top = 0
|
||||
Caption = #30003#25253#35201#32032
|
||||
ImageIndex = 14
|
||||
Visible = False
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 635
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
Visible = False
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 698
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1146
|
||||
Height = 37
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 168
|
||||
Top = 12
|
||||
Width = 12
|
||||
Height = 12
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 279
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 639
|
||||
Top = 12
|
||||
Width = 42
|
||||
Height = 12
|
||||
Caption = #23458#25143'PO#'
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 455
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21512#21516#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 831
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #20986#21475#21830
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 181
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 315
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object A6PONO: TEdit
|
||||
Tag = 2
|
||||
Left = 683
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 492
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A5ConNOKeyPress
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 868
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A6PONOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1146
|
||||
Height = 309
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellClick = Tv1CellClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v2Column6
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column26
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column27
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column28
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column29
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column30
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column19
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #20986#21475#21830
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #31246#21495
|
||||
DataBinding.FieldName = 'A2ShuiHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 97
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #28023#20851#32534#30721
|
||||
DataBinding.FieldName = 'A3HaiGuanBM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 93
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Alignment.Horz = taLeftJustify
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 125
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23458#25143'PO#'
|
||||
DataBinding.FieldName = 'A6PONO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21457#31080#26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24320#33322#26085#26399
|
||||
DataBinding.FieldName = 'B3KaiHangDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 62
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #36135#26588
|
||||
DataBinding.FieldName = 'B5HuoGui'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36816#28207
|
||||
DataBinding.FieldName = 'B6ChuYunGang'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 85
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21040#36135#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 51
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36152#26131#22269
|
||||
DataBinding.FieldName = 'B8MaoYiGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25269#36816#22269
|
||||
DataBinding.FieldName = 'B9DiYunGuo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'B10YunShuType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 60
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #36152#26131#26041#24335
|
||||
DataBinding.FieldName = 'D2MaoYiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 79
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #32467#27719#26041#24335
|
||||
DataBinding.FieldName = 'D3JiHuiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #25253#20851#26465#27454
|
||||
DataBinding.FieldName = 'F1BaoGuanTK'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #36816#36153
|
||||
DataBinding.FieldName = 'F2YunFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #20445#36153
|
||||
DataBinding.FieldName = 'F3BaoFee'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #36135#36816#20195#29702
|
||||
DataBinding.FieldName = 'F4HuoYunDaiLi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column22: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
object v1Column23: TcxGridDBColumn
|
||||
Caption = #33322#21517#33322#27425
|
||||
DataBinding.FieldName = 'B1HangBan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object v1Column24: TcxGridDBColumn
|
||||
Caption = #25552#21333#21495
|
||||
DataBinding.FieldName = 'B2TiDanHao'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column25: TcxGridDBColumn
|
||||
Caption = #31665#21495#23553#21495
|
||||
DataBinding.FieldName = 'B4XiangNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 72
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #33337#20844#21496
|
||||
DataBinding.FieldName = 'F5ChuanGongSi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #30331#35760#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column26: TcxGridDBColumn
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column27: TcxGridDBColumn
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQtyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column28: TcxGridDBColumn
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
object v1Column29: TcxGridDBColumn
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column30: TcxGridDBColumn
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoneyHZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 68
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 70
|
||||
Width = 1146
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Style = 8
|
||||
TabIndex = 0
|
||||
TabOrder = 3
|
||||
Tabs.Strings = (
|
||||
#24453#36865#23457
|
||||
#24050#36865#23457
|
||||
#24050#23457#25209
|
||||
#20840#37096)
|
||||
Visible = False
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1146
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object cxSplitter1: TcxSplitter
|
||||
Left = 0
|
||||
Top = 400
|
||||
Width = 1146
|
||||
Height = 8
|
||||
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||
AlignSplitter = salBottom
|
||||
Control = cxGrid2
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 408
|
||||
Width = 1146
|
||||
Height = 169
|
||||
Align = alBottom
|
||||
TabOrder = 5
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource2
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
Column = cxGridDBColumn2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn9
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn10
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn11
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object cxGridDBColumn1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#21517
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 183
|
||||
end
|
||||
object cxGridDBColumn14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25104#20221#21547#37327
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn15: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24133#23485'(CM)'
|
||||
DataBinding.FieldName = 'YSFuKuan'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn13: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #32455#36896#26041#27861
|
||||
DataBinding.FieldName = 'YSZhiZaoType'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#38024#32455
|
||||
#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object cxGridDBColumn16: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21697#29260
|
||||
DataBinding.FieldName = 'YSPinPai'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn17: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #29983#20135#21378#21830
|
||||
DataBinding.FieldName = 'YSShengChanShang'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = 'HS NO'
|
||||
DataBinding.FieldName = 'C2HSNO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 132
|
||||
end
|
||||
object cxGridDBColumn3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 51
|
||||
end
|
||||
object cxGridDBColumn4: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 43
|
||||
end
|
||||
object cxGridDBColumn5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20215'(USD)'
|
||||
DataBinding.FieldName = 'C6BGPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn6: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #37329#39069'(USD)'
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 72
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#25968#37327
|
||||
DataBinding.FieldName = 'E1BZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 60
|
||||
end
|
||||
object cxGridDBColumn8: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21253#35013#21333#20301
|
||||
DataBinding.FieldName = 'E1BZUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
'BALES'
|
||||
'ROLLS')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #23610#30721'(CBM)'
|
||||
DataBinding.FieldName = 'E2ChiMaQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 67
|
||||
end
|
||||
object cxGridDBColumn10: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #27611#37325'(KG)'
|
||||
DataBinding.FieldName = 'E3MaoZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 62
|
||||
end
|
||||
object cxGridDBColumn11: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20928#37325'(KG)'
|
||||
DataBinding.FieldName = 'E4JingZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 64
|
||||
end
|
||||
object cxGridDBColumn12: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21787#22836
|
||||
DataBinding.FieldName = 'E5MaiTou'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 768
|
||||
Top = 168
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 816
|
||||
Top = 224
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 472
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 912
|
||||
Top = 472
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 944
|
||||
Top = 472
|
||||
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 = 200
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 320
|
||||
Top = 208
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 208
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 288
|
||||
Top = 208
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,692 +0,0 @@
|
|||
unit U_BaoGuanListZXD;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxButtonEdit, cxTextEdit, cxPC, BtnEdit, cxSplitter;
|
||||
|
||||
type
|
||||
TfrmBaoGuanListZXD = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
cxTabControl1: TcxTabControl;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxSplitter1: TcxSplitter;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
Label5: TLabel;
|
||||
A6PONO: TEdit;
|
||||
Label8: TLabel;
|
||||
A5ConNO: TEdit;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
Label3: TLabel;
|
||||
A1ChuKouShang: TEdit;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1Column22: TcxGridDBColumn;
|
||||
v1Column23: TcxGridDBColumn;
|
||||
v1Column24: TcxGridDBColumn;
|
||||
v1Column25: TcxGridDBColumn;
|
||||
v1Column26: TcxGridDBColumn;
|
||||
v1Column27: TcxGridDBColumn;
|
||||
v1Column28: TcxGridDBColumn;
|
||||
v1Column29: TcxGridDBColumn;
|
||||
v1Column30: TcxGridDBColumn;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
cxGridDBColumn1: TcxGridDBColumn;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn3: TcxGridDBColumn;
|
||||
cxGridDBColumn4: TcxGridDBColumn;
|
||||
cxGridDBColumn5: TcxGridDBColumn;
|
||||
cxGridDBColumn6: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn8: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
cxGridDBColumn10: TcxGridDBColumn;
|
||||
cxGridDBColumn11: TcxGridDBColumn;
|
||||
cxGridDBColumn12: TcxGridDBColumn;
|
||||
cxGridDBColumn13: TcxGridDBColumn;
|
||||
cxGridDBColumn14: TcxGridDBColumn;
|
||||
cxGridDBColumn15: TcxGridDBColumn;
|
||||
cxGridDBColumn16: TcxGridDBColumn;
|
||||
cxGridDBColumn17: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
ToolButton7: TToolButton;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
ToolButton8: TToolButton;
|
||||
ToolButton9: TToolButton;
|
||||
ToolButton10: TToolButton;
|
||||
ToolButton11: TToolButton;
|
||||
ToolButton12: TToolButton;
|
||||
ToolButton3: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure A6PONOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure A5ConNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton7Click(Sender: TObject);
|
||||
procedure ToolButton8Click(Sender: TObject);
|
||||
procedure ToolButton9Click(Sender: TObject);
|
||||
procedure ToolButton10Click(Sender: TObject);
|
||||
procedure ToolButton11Click(Sender: TObject);
|
||||
procedure ToolButton12Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
private
|
||||
canshu1:string;
|
||||
canshu2:string;
|
||||
FDate:TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData():Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj:String);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanListZXD: TfrmBaoGuanListZXD;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp,U_BaoGuanInPut;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanListZXD.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanListZXD:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
canshu1:=Trim(DParameters1);
|
||||
canshu2:=Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where Valid=''Y'' ');
|
||||
{if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and Filler='''+Trim(DName)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
sql.Add(' and BGDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+'''');
|
||||
sql.Add(' and BGDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''');
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表ZXD',Tv1,'报关管理');
|
||||
WriteCxGrid('报关明细ZXD',Tv1,'报关管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表ZXD',Tv1,'报关管理');
|
||||
ReadCxGrid('报关明细ZXD',Tv1,'报关管理');
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('报关资料列表',cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main,False);
|
||||
end;
|
||||
procedure TfrmBaoGuanListZXD.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty=False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID='''+Trim(CDS_Main.fieldbyname('BGID').AsString)+'''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp,ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp,ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmBaoGuanListZXD.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer='''+Trim(DName)+''',EditTime=getdate()');
|
||||
sql.Add(' where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer='''+Trim(DName)+''',SEditTime=getdate() where BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListZXD.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmBaoGuanListZXD.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A4FPNO,'''') like '''+'%'+Trim(A4FPNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
procedure TfrmBaoGuanListZXD.InitGridSql(var fsj:String);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
{ if Trim(canshu1)<>'高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode='''+Trim(DCode)+'''');
|
||||
end;}
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')='''' ');
|
||||
end else
|
||||
begin
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(SChker,'''')<>'''' and isnull(Chker,'''')='''' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(Chker,'''')<>'''' ');
|
||||
end;
|
||||
end;
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.Tv1CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.A6PONOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A6PONO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A6PONO,'''') like '''+'%'+Trim(A6PONO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.A5ConNOKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
if Trim(A5ConNO.Text)='' then Exit;
|
||||
fsj:=' and isnull(A.A5ConNO,'''') like '''+'%'+Trim(A5ConNO.Text)+'%'+'''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.ToolButton7Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关资料.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.ToolButton8Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关合同.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.ToolButton9Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关发票.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.ToolButton10Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
//fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
if Trim(CDS_Main.fieldbyname('A1ChuKouShang').AsString)='绍兴宇玎纺织有限公司' then
|
||||
begin
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单YD.rmf';
|
||||
end else
|
||||
if Trim(CDS_Main.fieldbyname('A1ChuKouShang').AsString)='绍兴锦凤进出口有限公司' then
|
||||
begin
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关装箱单JF.rmf';
|
||||
end;
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else ZheSuanMiQty end as C4BGQtyJS ');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关装箱单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.ToolButton11Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关单.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.ToolButton12Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut:=TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId:=Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible:=False;
|
||||
ToolBar2.Visible:=False;
|
||||
Panel1.Enabled:=False;
|
||||
Tv1.OptionsData.Editing:=False;
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanListZXD.ToolButton3Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile:string;
|
||||
EngMoney,BZZH:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.*,Case when C5BGUnit=''MTR'' then C4BGQty else Null end as C4BGQtyJS ');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then E4JingZ else Null End As E4JingZJS');
|
||||
sql.Add(',Case when C5BGUnit<>''KG'' then ''KGS'' else Null End As JZUnit');
|
||||
sql.Add(',Case when C5BGUnit=''KG'' then ''KGS'' else C5BGUnit End As C5BGUnitJS');
|
||||
sql.add(' ,A1ChuKouShangEng=(select Note from KH_Zdy where Type=''A1ChuKouShang'' and ZdyName=A.A1ChuKouShang )');
|
||||
sql.add(' ,B6ChuYunGangEng=(select Note from KH_Zdy where Type=''B6ChuYunGang'' and ZdyName=A.B6ChuYunGang )');
|
||||
sql.Add(',HTDate=(select ORDDate from JYOrderCon_Main F where F.ConNo=A.A5ConNO)');
|
||||
sql.Add(',KHNameEng=(select KHNameEng from ZH_KH_Info KH where KH.KHNameJC=');
|
||||
sql.Add(' (select CustomerNoName from JYOrderCon_Main F where F.ConNo=A.A5ConNO ))');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A inner join JYOrder_BaoGuan_Sub B on A.BGId=B.BGId ');
|
||||
sql.Add(' where A.BGId='''+Trim(CDS_Main.fieldbyname('BGId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint,CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint,CDS_Print);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\申报要素.rmf'),'提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,519 +0,0 @@
|
|||
object frmBaoGuanXSList: TfrmBaoGuanXSList
|
||||
Left = 117
|
||||
Top = 78
|
||||
Width = 1238
|
||||
Height = 618
|
||||
Caption = #38144#21806#26376#25253#34920
|
||||
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 = 1222
|
||||
Height = 33
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 101
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object TBRKCX: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25171#21360
|
||||
ImageIndex = 4
|
||||
OnClick = TBRKCXClick
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
Caption = 'ToolButton1'
|
||||
ImageIndex = 22
|
||||
Visible = False
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 353
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1222
|
||||
Height = 40
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 168
|
||||
Top = 12
|
||||
Width = 12
|
||||
Height = 12
|
||||
Caption = #33267
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 279
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 455
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #35746#21333#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 647
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #20986#21475#21830
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 9
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 181
|
||||
Top = 9
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 315
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
end
|
||||
object A5ConNO: TEdit
|
||||
Tag = 2
|
||||
Left = 492
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 3
|
||||
end
|
||||
object A1ChuKouShang: TEdit
|
||||
Tag = 2
|
||||
Left = 684
|
||||
Top = 8
|
||||
Width = 129
|
||||
Height = 20
|
||||
TabOrder = 4
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 115
|
||||
Width = 1222
|
||||
Height = 465
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1Column9
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.CellMerging = True
|
||||
Options.Sorting = False
|
||||
Width = 100
|
||||
OnCompareRowValuesForCellMerging = v2Column1CompareRowValuesForCellMerging
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Caption = #20986#21475#21830
|
||||
DataBinding.FieldName = 'A1ChuKouShang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 134
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #35746#21333#21495
|
||||
DataBinding.FieldName = 'A5ConNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.CellMerging = True
|
||||
Options.Sorting = False
|
||||
Width = 126
|
||||
OnCompareRowValuesForCellMerging = v2Column1CompareRowValuesForCellMerging
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #21697#21517
|
||||
DataBinding.FieldName = 'C3BGName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 166
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #25104#20221#21547#37327
|
||||
DataBinding.FieldName = 'YSChenFen'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 149
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #20986#36135#26085#26399
|
||||
DataBinding.FieldName = 'A7FPDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.CellMerging = True
|
||||
Options.Sorting = False
|
||||
Width = 74
|
||||
OnCompareRowValuesForCellMerging = v2Column1CompareRowValuesForCellMerging
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #20986#21475#26085#26399
|
||||
DataBinding.FieldName = 'B3KaiHangDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.CellMerging = True
|
||||
Options.Sorting = False
|
||||
Width = 67
|
||||
OnCompareRowValuesForCellMerging = v2Column1CompareRowValuesForCellMerging
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #25104#20132#26041#24335
|
||||
DataBinding.FieldName = 'F1BaoGuanTK'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.CellMerging = True
|
||||
Options.Sorting = False
|
||||
Width = 65
|
||||
OnCompareRowValuesForCellMerging = v2Column1CompareRowValuesForCellMerging
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #20184#27454#26041#24335
|
||||
DataBinding.FieldName = 'D3JiHuiType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.CellMerging = True
|
||||
Options.Sorting = False
|
||||
Width = 62
|
||||
OnCompareRowValuesForCellMerging = v2Column1CompareRowValuesForCellMerging
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Caption = #25253#20851#25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 50
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #25253#20851#21333#20215
|
||||
DataBinding.FieldName = 'C6BGPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #25253#20851#37329#39069
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 68
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36741#21161#25968#37327
|
||||
DataBinding.FieldName = 'FZQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 64
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Caption = #36741#21161#21333#20301
|
||||
DataBinding.FieldName = 'FZQtyUnit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 66
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #21046#21333#20154
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #29366#24577
|
||||
DataBinding.FieldName = 'Status'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 62
|
||||
end
|
||||
end
|
||||
object cxGrid2Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object Panel2: TPanel
|
||||
Left = 416
|
||||
Top = 192
|
||||
Width = 217
|
||||
Height = 41
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Caption = #27491#22312#26597#35810#25968#25454#65292#35831#31245#21518#12290#12290#12290
|
||||
Color = clSkyBlue
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
TabOrder = 3
|
||||
Visible = False
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 94
|
||||
Width = 1222
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Style = 8
|
||||
TabOrder = 4
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 21
|
||||
ClientRectRight = 1222
|
||||
ClientRectTop = 0
|
||||
end
|
||||
object cxTabControl3: TcxTabControl
|
||||
Left = 0
|
||||
Top = 73
|
||||
Width = 1222
|
||||
Height = 21
|
||||
Align = alTop
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
Style = 8
|
||||
TabIndex = 3
|
||||
TabOrder = 5
|
||||
Tabs.Strings = (
|
||||
#24453#36865#23457
|
||||
#24453#26680#23545
|
||||
#24453#23457#26680
|
||||
#24050#23457#26680
|
||||
#20840#37096)
|
||||
Visible = False
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1222
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 1000
|
||||
Top = 32
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 960
|
||||
Top = 32
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 1040
|
||||
Top = 32
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 920
|
||||
Top = 152
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 888
|
||||
Top = 152
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 952
|
||||
Top = 152
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = 360
|
||||
Top = 232
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBMain: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_PRT
|
||||
Left = 424
|
||||
Top = 232
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 392
|
||||
Top = 232
|
||||
end
|
||||
object RMDBHZ: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_HZ
|
||||
Left = 520
|
||||
Top = 232
|
||||
end
|
||||
object CDS_HZ: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 488
|
||||
Top = 232
|
||||
end
|
||||
object CDS_PRT: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 456
|
||||
Top = 232
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 328
|
||||
Top = 232
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -1,328 +0,0 @@
|
|||
unit U_BaoGuanXSList;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, cxCheckBox, RM_Common,
|
||||
RM_Class, RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, Menus,
|
||||
cxCalendar, cxPC;
|
||||
|
||||
type
|
||||
TfrmBaoGuanXSList = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBExport: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxGrid2Level1: TcxGridLevel;
|
||||
RM1: TRMGridReport;
|
||||
RMDBMain: TRMDBDataSet;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
RMDBHZ: TRMDBDataSet;
|
||||
CDS_HZ: TClientDataSet;
|
||||
CDS_PRT: TClientDataSet;
|
||||
TBRKCX: TToolButton;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
Panel2: TPanel;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
cxTabControl1: TcxTabControl;
|
||||
Label6: TLabel;
|
||||
Label8: TLabel;
|
||||
Label3: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
A5ConNO: TEdit;
|
||||
A1ChuKouShang: TEdit;
|
||||
cxTabControl3: TcxTabControl;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
ToolButton1: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure v2Column1CompareRowValuesForCellMerging(
|
||||
Sender: TcxGridColumn; ARow1: TcxGridDataRow;
|
||||
AProperties1: TcxCustomEditProperties; const AValue1: Variant;
|
||||
ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties;
|
||||
const AValue2: Variant; var AAreEqual: Boolean);
|
||||
procedure TBRKCXClick(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
private
|
||||
procedure InitGrid();
|
||||
procedure GetColor(color:TColor);
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmBaoGuanXSList: TfrmBaoGuanXSList;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmBaoGuanXSList.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmBaoGuanXSList:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime:=SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime:=SGetServerDateMBeg(ADOQueryTemp);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.InitGrid();
|
||||
var
|
||||
fsj:string;
|
||||
begin
|
||||
Panel2.Visible:=True;
|
||||
Panel2.Refresh;
|
||||
fsj:=' and A7FPDate>='''+Trim(FormatDateTime('yyyy-MM-dd',BegDate.Date))+''''
|
||||
+' and A7FPDate<'''+Trim(FormatDateTime('yyyy-MM-dd',EndDate.Date+1))+'''';
|
||||
if cxTabControl1.Tabs[cxTabControl1.TabIndex].Caption<>'全部' then
|
||||
begin
|
||||
fsj:=fsj+' and A1ChuKouShang like '''+'%'+Trim(cxTabControl1.Tabs[cxTabControl1.TabIndex].Caption)+'%'+''''
|
||||
end;
|
||||
if cxTabControl3.TabIndex=0 then
|
||||
begin
|
||||
fsj:=fsj+'and isnull(SChker,'''')=''''';
|
||||
end else
|
||||
if cxTabControl3.TabIndex=1 then
|
||||
begin
|
||||
fsj:=fsj+' and isnull(OKPerson,'''')='''' and isnull(SChker,'''')<>'''' ';
|
||||
end else
|
||||
if cxTabControl3.TabIndex=2 then
|
||||
begin
|
||||
fsj:=fsj+' and isnull(Chker,'''')='''' and isnull(OKPerson,'''')<>'''' ';
|
||||
end else
|
||||
if cxTabControl3.TabIndex=3 then
|
||||
begin
|
||||
fsj:=fsj+' and isnull(Chker,'''')<>'''' ';
|
||||
end;
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' exec P_View_BaoGuanData_XS :WSql');
|
||||
Parameters.ParamByName('WSql').Value:=fsj;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
Panel2.Visible:=False;
|
||||
end;
|
||||
Panel2.Visible:=False;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('财务报关销售报表',Tv1,'财务管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('财务报关销售报表',Tv1,'财务管理');
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from KH_Zdy where Type=''A1ChuKouShang'' ');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
First;
|
||||
while not Eof do
|
||||
begin
|
||||
cxTabControl1.Tabs.Add(ADOQueryTemp.fieldbyname('ZdyName').asstring);
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
cxTabControl1.Tabs.Add('全部');
|
||||
//InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then exit;
|
||||
TcxGridToExcel('财务报关销售报表',cxGrid2);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.v2Column1CompareRowValuesForCellMerging(
|
||||
Sender: TcxGridColumn; ARow1: TcxGridDataRow;
|
||||
AProperties1: TcxCustomEditProperties; const AValue1: Variant;
|
||||
ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties;
|
||||
const AValue2: Variant; var AAreEqual: Boolean);
|
||||
|
||||
var
|
||||
colIdx0:integer;
|
||||
begin
|
||||
colIdx0:= tv1.GetColumnByFieldName('A4FPNO').Index;
|
||||
if ARow1.Values[colIdx0] = ARow2.Values[colIdx0] then
|
||||
AAreEqual := True
|
||||
else
|
||||
AAreEqual := False;
|
||||
end;
|
||||
|
||||
|
||||
procedure TfrmBaoGuanXSList.TBRKCXClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile,fsj:string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then Exit;
|
||||
//if cxTabControl3.TabIndex<>3 then Exit;
|
||||
fPrintFile:= ExtractFilePath(Application.ExeName) + 'Report\报关销售资料.rmf';
|
||||
fsj:=' and SubString(convert(varchar(10),A7FPDate,120),1,7)='''+Copy(Trim(CDS_Main.fieldbyname('A7FPDate').AsString),1,7)+'''';
|
||||
if cxTabControl1.Tabs[cxTabControl1.TabIndex].Caption<>'全部' then
|
||||
begin
|
||||
fsj:=fsj+' and A1ChuKouShang like '''+'%'+Trim(cxTabControl1.Tabs[cxTabControl1.TabIndex].Caption)+'%'+'''';
|
||||
//+' and isnull(Chker,'''')<>'''' ';
|
||||
end else
|
||||
begin
|
||||
Exit;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('exec P_View_BaoGuanData_XS :WSql');
|
||||
Parameters.ParamByName('WSql').Value:=fsj;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryTemp,CDS_PRT);
|
||||
SInitCDSData20(ADOQueryTemp,CDS_PRT);
|
||||
RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
RMVariables['TaiTou']:=cxTabControl1.Tabs[cxTabControl1.TabIndex].Caption;
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找'+ExtractFilePath(Application.ExeName)+'Report\报关销售资料.rmf'),'提示',0);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmBaoGuanXSList.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
GetColor(clRed);
|
||||
end;
|
||||
|
||||
procedure TfrmBaoGuanXSList.GetColor(color:TColor);
|
||||
var
|
||||
R,G,B:Integer;
|
||||
color10:TColor;
|
||||
begin
|
||||
R:=0;
|
||||
G:=0;
|
||||
B:=0;
|
||||
for R:=0 to 255 do
|
||||
begin
|
||||
for G:=0 to 255 do
|
||||
begin
|
||||
for B:=0 to 255 do
|
||||
begin
|
||||
//HZ:=i+j+k;
|
||||
color10:=(R shr 3)shl 11+(G shr 2)shl 5+B shr 3;
|
||||
if color10=color then
|
||||
begin
|
||||
Application.MessageBox(PChar('R='+IntToStr(R)+',G='+IntToStr(G)+',B='+IntToStr(B)),'提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,602 +0,0 @@
|
|||
object frmCHHZList: TfrmCHHZList
|
||||
Left = 150
|
||||
Top = 116
|
||||
Width = 1060
|
||||
Height = 614
|
||||
Caption = #20986#36135#21512#35745#28165#21333
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1044
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
Visible = False
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25512#36865
|
||||
ImageIndex = 22
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 26
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1044
|
||||
Height = 49
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 12
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #25253#20851#26085#26399
|
||||
end
|
||||
object Label16: TLabel
|
||||
Left = 371
|
||||
Top = 11
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #37096#38376
|
||||
end
|
||||
object Label17: TLabel
|
||||
Left = 523
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21161' '#29702
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 674
|
||||
Top = 10
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #32452#38271
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 155
|
||||
Top = 11
|
||||
Width = 30
|
||||
Height = 12
|
||||
Caption = '-----'
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 184
|
||||
Top = 9
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object bm: TEdit
|
||||
Tag = 2
|
||||
Left = 403
|
||||
Top = 7
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 1
|
||||
OnChange = bmChange
|
||||
end
|
||||
object YWY: TEdit
|
||||
Tag = 2
|
||||
Left = 564
|
||||
Top = 7
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 2
|
||||
OnChange = YWYChange
|
||||
end
|
||||
object zz: TEdit
|
||||
Tag = 2
|
||||
Left = 706
|
||||
Top = 6
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 3
|
||||
OnChange = YWYChange
|
||||
end
|
||||
object BEGDATE: TDateTimePicker
|
||||
Left = 64
|
||||
Top = 9
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 4
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 141
|
||||
Width = 1044
|
||||
Height = 317
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object TV1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'YEARusd'
|
||||
Column = TV1Column4
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'monthusd'
|
||||
Column = TV1Column2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'WEEKUSD'
|
||||
Column = TV1Column15
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = TV1Column12
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = TV1Column13
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = TV1Column16
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Content = cxStyle1
|
||||
Styles.Inactive = cxStyle1
|
||||
Styles.IncSearch = cxStyle1
|
||||
Styles.Selection = cxStyle1
|
||||
Styles.Header = cxStyle1
|
||||
object TV1Column8: TcxGridDBColumn
|
||||
Caption = #37096#38376
|
||||
DataBinding.FieldName = 'bm'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.CellMerging = True
|
||||
Width = 75
|
||||
end
|
||||
object TV1Column11: TcxGridDBColumn
|
||||
Caption = #32452#38271
|
||||
DataBinding.FieldName = 'zz'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.CellMerging = True
|
||||
Width = 78
|
||||
end
|
||||
object TV1Column14: TcxGridDBColumn
|
||||
Caption = #21161#29702
|
||||
DataBinding.FieldName = 'YWY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 69
|
||||
end
|
||||
object TV1Column9: TcxGridDBColumn
|
||||
Caption = #24066#22330
|
||||
DataBinding.FieldName = 'TOCOUNTRY1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object TV1Column15: TcxGridDBColumn
|
||||
Caption = #21608#32047#35745'(USD)'
|
||||
DataBinding.FieldName = 'usdweekmoney'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = '$,0.00;$-,0.00'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 100
|
||||
end
|
||||
object TV1Column2: TcxGridDBColumn
|
||||
Caption = #26376#32047#35745'(USD)'
|
||||
DataBinding.FieldName = 'usdmonthmoney'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = '$,0.00;$-,0.00'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 100
|
||||
end
|
||||
object TV1Column4: TcxGridDBColumn
|
||||
Caption = #24180#32047#35745'(USD)'
|
||||
DataBinding.FieldName = 'usdYEARmoney'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = '$,0.00;$-,0.00'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 108
|
||||
end
|
||||
object TV1Column6: TcxGridDBColumn
|
||||
Caption = #32452#21608#32047#35745'(USD)'
|
||||
DataBinding.FieldName = 'zWEEKUSD'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = '$,0.00;$-,0.00'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.CellMerging = True
|
||||
Width = 143
|
||||
OnCompareRowValuesForCellMerging = TV1Column10CompareRowValuesForCellMerging
|
||||
end
|
||||
object TV1Column7: TcxGridDBColumn
|
||||
Caption = #32452#26376#32047#35745'(USD)'
|
||||
DataBinding.FieldName = 'ZMONTHUSD'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = '$,0.00;$-,0.00'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.CellMerging = True
|
||||
Width = 149
|
||||
OnCompareRowValuesForCellMerging = TV1Column10CompareRowValuesForCellMerging
|
||||
end
|
||||
object TV1Column10: TcxGridDBColumn
|
||||
Caption = #32452#24180#32047#35745'(USD)'
|
||||
DataBinding.FieldName = 'ZYEARUSD'
|
||||
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||
Properties.DisplayFormat = '$,0.00;$-,0.00'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Options.CellMerging = True
|
||||
Width = 135
|
||||
OnCompareRowValuesForCellMerging = TV1Column10CompareRowValuesForCellMerging
|
||||
end
|
||||
object TV1Column5: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'WEEKUSD'
|
||||
Visible = False
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column1: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'YEARUSD'
|
||||
Visible = False
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column3: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'MONTHUSD'
|
||||
Visible = False
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column12: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'nfrmbw'
|
||||
Visible = False
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column13: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'nfrmbm'
|
||||
Visible = False
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column16: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'nfrmby'
|
||||
Visible = False
|
||||
Width = 66
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object Panel2: TPanel
|
||||
Left = 0
|
||||
Top = 458
|
||||
Width = 1044
|
||||
Height = 117
|
||||
Align = alBottom
|
||||
TabOrder = 3
|
||||
object Label4: TLabel
|
||||
Left = 27
|
||||
Top = 7
|
||||
Width = 144
|
||||
Height = 24
|
||||
Caption = #26412#21608#21512#35745'USD:'
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -24
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 28
|
||||
Top = 34
|
||||
Width = 120
|
||||
Height = 24
|
||||
Caption = #26376#21512#35745'USD:'
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -24
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 27
|
||||
Top = 67
|
||||
Width = 144
|
||||
Height = 24
|
||||
Caption = #24180#24230#24635#35745'USD:'
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -24
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
end
|
||||
object Panel3: TPanel
|
||||
Left = 0
|
||||
Top = 81
|
||||
Width = 1044
|
||||
Height = 60
|
||||
Align = alTop
|
||||
Caption = #20986' '#36135' '#28165' '#21333' '#27719' '#24635' '#34920
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -27
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
TabOrder = 4
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 925
|
||||
Top = 217
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 893
|
||||
Top = 217
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 957
|
||||
Top = 217
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 858
|
||||
Top = 188
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 777
|
||||
Top = 299
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 883
|
||||
Top = 487
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 917
|
||||
Top = 487
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 949
|
||||
Top = 487
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowDialog = False
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 1013
|
||||
Top = 212
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 252
|
||||
Top = 364
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 300
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = ADOQueryMain
|
||||
Left = 256
|
||||
Top = 336
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 984
|
||||
Top = 212
|
||||
end
|
||||
object cxStyleRepository1: TcxStyleRepository
|
||||
PixelsPerInch = 96
|
||||
object cxStyle1: TcxStyle
|
||||
AssignedValues = [svFont]
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Name = #24494#36719#38597#40657
|
||||
Font.Style = [fsBold]
|
||||
end
|
||||
end
|
||||
object cxStyleRepository2: TcxStyleRepository
|
||||
PixelsPerInch = 96
|
||||
object cxStyle2: TcxStyle
|
||||
end
|
||||
end
|
||||
object IdHTTP1: TIdHTTP
|
||||
MaxLineAction = maException
|
||||
ReadTimeout = 0
|
||||
AllowCookies = True
|
||||
ProxyParams.BasicAuthentication = False
|
||||
ProxyParams.ProxyPort = 0
|
||||
Request.ContentLength = -1
|
||||
Request.ContentRangeEnd = 0
|
||||
Request.ContentRangeStart = 0
|
||||
Request.ContentType = 'text/html'
|
||||
Request.Accept = 'text/html, */*'
|
||||
Request.BasicAuthentication = False
|
||||
Request.UserAgent = 'Mozilla/3.0 (compatible; Indy Library)'
|
||||
HTTPOptions = [hoForceEncodeParams]
|
||||
Left = 348
|
||||
Top = 172
|
||||
end
|
||||
end
|
||||
|
|
@ -1,937 +0,0 @@
|
|||
unit U_CHHZList;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||||
cxEdit, DB, cxDBData, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridBandedTableView, cxGridDBBandedTableView, cxGridLevel, cxClasses,
|
||||
cxControls, cxGridCustomView, cxGridDBTableView, cxGrid, StdCtrls, ComCtrls,
|
||||
ExtCtrls, ToolWin, cxGridCustomPopupMenu, cxGridPopupMenu, ADODB, DBClient,
|
||||
cxDropDownEdit, cxCheckBox, RM_Common, RM_Class, RM_e_Xls, RM_Dataset,
|
||||
RM_System, RM_GridReport, Menus, cxCalendar, cxButtonEdit, cxTextEdit, cxPC,
|
||||
BtnEdit, cxSplitter, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator,
|
||||
dxBarBuiltInMenu, MovePanel, cxCalc, Registry, cxCurrencyEdit, IdBaseComponent,
|
||||
IdComponent, IdTCPConnection, IdTCPClient, IdHTTP;
|
||||
|
||||
type
|
||||
TfrmCHHZList = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
cxGrid2: TcxGrid;
|
||||
TV1: TcxGridDBTableView;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
TV1Column8: TcxGridDBColumn;
|
||||
TV1Column9: TcxGridDBColumn;
|
||||
TV1Column14: TcxGridDBColumn;
|
||||
TV1Column15: TcxGridDBColumn;
|
||||
ToolButton1: TToolButton;
|
||||
Label1: TLabel;
|
||||
TV1Column2: TcxGridDBColumn;
|
||||
TV1Column4: TcxGridDBColumn;
|
||||
TV1Column6: TcxGridDBColumn;
|
||||
TV1Column7: TcxGridDBColumn;
|
||||
TV1Column10: TcxGridDBColumn;
|
||||
Label16: TLabel;
|
||||
Label17: TLabel;
|
||||
bm: TEdit;
|
||||
YWY: TEdit;
|
||||
TV1Column11: TcxGridDBColumn;
|
||||
Label2: TLabel;
|
||||
zz: TEdit;
|
||||
TV1Column1: TcxGridDBColumn;
|
||||
TV1Column3: TcxGridDBColumn;
|
||||
TV1Column5: TcxGridDBColumn;
|
||||
BEGDATE: TDateTimePicker;
|
||||
Label3: TLabel;
|
||||
TV1Column12: TcxGridDBColumn;
|
||||
TV1Column13: TcxGridDBColumn;
|
||||
TV1Column16: TcxGridDBColumn;
|
||||
Panel2: TPanel;
|
||||
Label4: TLabel;
|
||||
Label5: TLabel;
|
||||
Label6: TLabel;
|
||||
Panel3: TPanel;
|
||||
cxStyleRepository1: TcxStyleRepository;
|
||||
cxStyle1: TcxStyle;
|
||||
cxStyleRepository2: TcxStyleRepository;
|
||||
cxStyle2: TcxStyle;
|
||||
ToolButton2: TToolButton;
|
||||
IdHTTP1: TIdHTTP;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure GCNAMEKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure KHNameKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure TBCopyClick(Sender: TObject);
|
||||
procedure TBBGZLClick(Sender: TObject);
|
||||
procedure TBHTClick(Sender: TObject);
|
||||
procedure TBFPClick(Sender: TObject);
|
||||
procedure TBZXDClick(Sender: TObject);
|
||||
procedure TBBGDClick(Sender: TObject);
|
||||
procedure TBViewClick(Sender: TObject);
|
||||
procedure TBSBYSClick(Sender: TObject);
|
||||
procedure TBAllClick(Sender: TObject);
|
||||
procedure YWYChange(Sender: TObject);
|
||||
procedure Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
|
||||
procedure huodaiBtnClick(Sender: TObject);
|
||||
procedure B7DaoHuoGangBtnClick(Sender: TObject);
|
||||
procedure BtnEditA1BtnClick(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure ComboBox1Change(Sender: TObject);
|
||||
procedure bmKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure bmChange(Sender: TObject);
|
||||
procedure TV1Column10CompareRowValuesForCellMerging(Sender: TcxGridColumn; ARow1: TcxGridDataRow; AProperties1: TcxCustomEditProperties; const AValue1: Variant; ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties; const AValue2: Variant; var AAreEqual: Boolean);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
private
|
||||
canshu2: string;
|
||||
FDate: TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData(): Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj: string);
|
||||
function GetShellFolders(strDir: string): string;
|
||||
procedure InitPrtData();
|
||||
{ Private declarations }
|
||||
public
|
||||
canshu1: string;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
//var
|
||||
//frmBaoGuanList: TfrmBaoGuanList;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_RTFun, U_ZDYHelp, U_BaoGuanInPut, U_Fun, U_UserSel;
|
||||
|
||||
{$R *.dfm}
|
||||
function TfrmCHHZList.GetShellFolders(strDir: string): string;
|
||||
const
|
||||
regPath = '\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders';
|
||||
var
|
||||
Reg: TRegistry;
|
||||
strFolders: string;
|
||||
begin
|
||||
Reg := TRegistry.Create;
|
||||
try
|
||||
Reg.RootKey := HKEY_CURRENT_USER;
|
||||
if Reg.OpenKey(regPath, false) then
|
||||
begin
|
||||
strFolders := Reg.ReadString(strDir);
|
||||
end;
|
||||
finally
|
||||
Reg.Free;
|
||||
end;
|
||||
result := strFolders;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
//frmBaoGuanList:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Application := MainApplication;
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||
BEGDATE.DateTime := EndDate.DateTime - 7;
|
||||
canshu1 := Trim(DParameters1);
|
||||
canshu2 := Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.InitGrid();
|
||||
var
|
||||
fwhere, Pwhere: string;
|
||||
f1, f2, f3, f4, f5, f6: string;
|
||||
begin
|
||||
Pwhere := SGetFilters(Panel1, 1, 2);
|
||||
|
||||
begin
|
||||
if trim(Pwhere) <> '' then
|
||||
fwhere := fwhere + ' and ' + trim(Pwhere);
|
||||
end;
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
// SQL.Add('select * from (');
|
||||
|
||||
sql.Add('EXEC P_CHQD_List @enddate=' + QuotedStr(FormatDateTime('yyyy-MM-dd', ENDDate.DateTime)));
|
||||
SQL.Add(',@BEGDATE=' + QuotedStr(FormatDateTime('yyyy-MM-dd', BEGDate.DateTime)));
|
||||
|
||||
|
||||
// sql.Add('select A.*,B.* ');
|
||||
// ShowMessage(sql.Text);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
|
||||
// FloatToCurr()
|
||||
// ShowMessage(CurrToStr(FloatToCurr(tV1.DataController.Summary.FooterSummaryValues[10])));
|
||||
// ShowMessage(VarToStr(FloatToCurr(1234)));
|
||||
|
||||
|
||||
if CDS_Main.IsEmpty = False then
|
||||
begin
|
||||
f1 := VarToStr(FormatFloat('0,0.00', (tV1.DataController.Summary.FooterSummaryValues[10])));
|
||||
if f1 = '00.00' then
|
||||
begin
|
||||
f1 := '0.00';
|
||||
end;
|
||||
f2 := VarToStr(FormatFloat('0,0.00', (tV1.DataController.Summary.FooterSummaryValues[11])));
|
||||
if f2 = '00.00' then
|
||||
begin
|
||||
f2 := '0.00';
|
||||
end;
|
||||
f3 := VarToStr(FormatFloat('0,0.00', (tV1.DataController.Summary.FooterSummaryValues[9])));
|
||||
if f3 = '00.00' then
|
||||
begin
|
||||
f3 := '0.00';
|
||||
end;
|
||||
f4 := VarToStr(FormatFloat('0,0.00', (tV1.DataController.Summary.FooterSummaryValues[12])));
|
||||
if f4 = '00.00' then
|
||||
begin
|
||||
f4 := '0.00';
|
||||
end;
|
||||
f5 := VarToStr(FormatFloat('0,0.00', (tV1.DataController.Summary.FooterSummaryValues[8])));
|
||||
if f5 = '00.00' then
|
||||
begin
|
||||
f5 := '0.00';
|
||||
end;
|
||||
f6 := VarToStr(FormatFloat('0,0.00', (tV1.DataController.Summary.FooterSummaryValues[13])));
|
||||
if f6 = '00.00' then
|
||||
begin
|
||||
f6 := '0.00';
|
||||
end;
|
||||
Label4.Caption := '本周合计USD:$' + f1 + '(含人民币:¥' + f2 + ')';
|
||||
Label5.Caption := '月合计USD:$' + f3 + '(含人民币:¥' + f4 + ')';
|
||||
Label6.Caption := '年度总计USD:$' + f5 + '(含人民币:¥' + f6 + ')';
|
||||
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
ENDDate.SetFocus;
|
||||
InitGrid();
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表' + self.Caption, Tv1, '出货清单33');
|
||||
// WriteCxGrid('报关明细' + self.Caption, Tv2, '报关管理8');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表' + self.Caption, Tv1, '出货清单33');
|
||||
// ReadCxGrid('报关明细' + self.Caption, Tv2, '报关管理8');
|
||||
canshu1 := Trim(DParameters1);
|
||||
// ShowMessage(canshu1);
|
||||
|
||||
InitGrid();
|
||||
RM1.CanExport := true;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
// TcxGridToExcel(Trim(CDS_Main.fieldbyname('A4FPNO').AsString) + Trim(CDS_Main.fieldbyname('A5ConNO').AsString), cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main, True);
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main, False);
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty = False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID=''' + Trim(CDS_Main.fieldbyname('BGID').AsString) + '''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp, ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp, ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmCHHZList.DelData(): Boolean;
|
||||
begin
|
||||
try
|
||||
Result := false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel', True, []) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer=''' + Trim(DName) + ''',EditTime=getdate()');
|
||||
sql.Add(' where BGId=''' + Trim(CDS_Main.fieldbyname('BGId').AsString) + '''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer=''' + Trim(DName) + ''',SEditTime=getdate() where BGId=''' + Trim(CDS_Main.fieldbyname('BGId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result := True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result := False;
|
||||
Application.MessageBox('数据删除异常!', '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.InitGridSql(var fsj: string);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
if Trim(canshu1) <> '高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode=''' + Trim(DCode) + '''');
|
||||
end;
|
||||
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.GCNAMEKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
// if Key = #13 then
|
||||
// begin
|
||||
// if Trim(A6PONO.Text) = '' then
|
||||
// Exit;
|
||||
// fsj := ' and isnull(A.A6PONO,'''') like ''' + '%' + Trim(A6PONO.Text) + '%' + '''';
|
||||
// InitGridSql(fsj);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.KHNameKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
// if Key = #13 then
|
||||
// begin
|
||||
// if Trim(A5ConNO.Text) = '' then
|
||||
// Exit;
|
||||
// fsj := ' and isnull(A.A5ConNO,'''') like ''' + '%' + Trim(A5ConNO.Text) + '%' + '''';
|
||||
// InitGridSql(fsj);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBCopyClick(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
// if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut := TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId := Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
CopyStr := '99';
|
||||
//TBDel.Visible:=False;
|
||||
//TBAdd.Visible:=False;
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.InitPrtData();
|
||||
begin
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' exec P_View_BaoGuanData :BGID ');
|
||||
Parameters.ParamByName('BGID').Value := Trim(CDS_Main.fieldbyname('BGId').AsString);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint, CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint, CDS_Print);
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBBGZLClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBHTClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBFPClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBZXDClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBBGDClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBViewClick(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
//if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut := TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId := Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible := False;
|
||||
ToolBar2.Visible := False;
|
||||
Panel1.Enabled := False;
|
||||
Tv1.OptionsData.Editing := False;
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBSBYSClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TBAllClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile, FZMFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\全部报关资料.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
//RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
if RM1.CanExport = true then
|
||||
begin
|
||||
FZMFile := 'C:\Users\Administrator\Desktop';
|
||||
if not DirectoryExists(FZMFile) then
|
||||
begin
|
||||
FZMFile := 'C:\Documents and Settings\Administrator\桌面\' + trim(CDS_Main.fieldbyname('A4FPNO').AsString) + ' ' + trim(CDS_Main.fieldbyname('A5ConNO').AsString) + '.xls';
|
||||
end
|
||||
else
|
||||
begin
|
||||
FZMFile := 'C:\Users\Administrator\Desktop\' + trim(CDS_Main.fieldbyname('A4FPNO').AsString) + ' ' + trim(CDS_Main.fieldbyname('A5ConNO').AsString) + '.XLS';
|
||||
end;
|
||||
RM1.ExportTo(RMXLSExport1, FZMFile);
|
||||
end;
|
||||
RM1.CanExport := true;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
RM1.CanExport := False;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\全部报关资料.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.YWYChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.huodaiBtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.B7DaoHuoGangBtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.BtnEditA1BtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
// SelExportData(Tv1, ADOQueryMain, '出货清单');
|
||||
// with ADOQueryMain do
|
||||
// begin
|
||||
// Filtered := False;
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// sql.Add('select A.*,B.* ');
|
||||
//// SQL.Add(',HDNAME=(SELECT HDNAME FROM JYOrderCon_TT C WHERE C.DCNO=A.DCNO)');
|
||||
// SQL.Add(',TOCOUNTRY1=(SELECT TOP 1 ISNULL(note,zdyname) FROM KH_ZDY D WHERE D.ZDYNAME=A.TOCOUNTRY)');
|
||||
// SQL.Add(',BM=(SELECT ISNULL(UDEPT,'''')+USERNAME FROM SY_User C WHERE C.USERNAME=A.FILLER )');
|
||||
//
|
||||
// sql.Add(' from JYOrder_BaoGuan_Main A INNER JOIN JYOrder_BaoGuan_SUB B ON A.BGID=B.BGID ');
|
||||
// sql.Add(' where A.Valid=''Y'' and B.SValid=''Y'' ');
|
||||
// SQL.Add('AND bgStatus=''√''');
|
||||
// sql.Add(' and filltime>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
// sql.Add(' and filltime<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
// sql.Add('order by YWY');
|
||||
//// ShowMessage(sql.Text);
|
||||
// Open;
|
||||
// end;
|
||||
// SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
// SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
// TBFind.Click();
|
||||
TcxGridToExcel('出货合计清单', cxGrid2);
|
||||
|
||||
InitGrid();
|
||||
TBFind.Click();
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.ComboBox1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.bmKeyPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.bmChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.TV1Column10CompareRowValuesForCellMerging(Sender: TcxGridColumn; ARow1: TcxGridDataRow; AProperties1: TcxCustomEditProperties; const AValue1: Variant; ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties; const AValue2: Variant; var AAreEqual: Boolean);
|
||||
begin
|
||||
if ARow1.Values[TV1Column8.Index] = ARow2.Values[TV1Column8.Index] then
|
||||
AAreEqual := True
|
||||
else
|
||||
AAreEqual := False;
|
||||
end;
|
||||
|
||||
procedure TfrmCHHZList.ToolButton2Click(Sender: TObject);
|
||||
var
|
||||
FBJNO: string;
|
||||
fgdy: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
exit;
|
||||
// if CDS_Main.Locate('ssel', true, []) = false then
|
||||
// begin
|
||||
// Application.MessageBox('没有选择数据!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
|
||||
|
||||
fgdy := '';
|
||||
try
|
||||
frmUserSel := TfrmUserSel.Create(Application);
|
||||
with frmUserSel do
|
||||
begin
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
while frmUserSel.CDS_User.Locate('SSel', True, []) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
|
||||
sql.Add('exec P_INSERT_WXTS ');
|
||||
// sql.Add('@BJNO=' + quotedstr(trim(CDS_Main.fieldbyname('BJNO').AsString)));
|
||||
sql.Add('@CODE=' + quotedstr(Trim(CDS_User.fieldbyname('wxid').AsString)));
|
||||
SQL.Add(',@enddate=' + QuotedStr(FormatDateTime('yyyy-MM-dd', Self.ENDDate.DateTime)));
|
||||
SQL.Add(',@BEGDATE=' + QuotedStr(FormatDateTime('yyyy-MM-dd', Self.BEGDate.DateTime)));
|
||||
sql.Add(',@note=' + quotedstr(Trim(Self.Label4.Caption)));
|
||||
sql.Add(',@note2=' + quotedstr(Trim(Self.Label5.Caption)));
|
||||
sql.Add(',@note3=' + quotedstr(Trim(Self.Label6.Caption)));
|
||||
execsql;
|
||||
end;
|
||||
GetHTTP(IdHTTP1, 'http://zhengyong.rightsoft.top/api/message/send/BgchSummary');
|
||||
frmUserSel.CDS_User.Delete;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmUserSel.Free;
|
||||
application.MessageBox('推送成功!', '提示信息');
|
||||
end;
|
||||
|
||||
// try
|
||||
// with CDS_Main do
|
||||
// begin
|
||||
//
|
||||
// with ADOQueryCmd do
|
||||
// begin
|
||||
// close;
|
||||
// sql.Clear;
|
||||
//
|
||||
// sql.Add('exec P_INSERT_WXTS ');
|
||||
// sql.Add('@CODE=' + quotedstr(Trim(DName)));
|
||||
// SQL.Add(',@enddate=' + QuotedStr(FormatDateTime('yyyy-MM-dd', ENDDate.DateTime)));
|
||||
// SQL.Add(',@BEGDATE=' + QuotedStr(FormatDateTime('yyyy-MM-dd', BEGDate.DateTime)));
|
||||
// sql.Add(',@note=' + quotedstr(Trim(Label4.Caption)));
|
||||
// sql.Add(',@note2=' + quotedstr(Trim(Label5.Caption)));
|
||||
// sql.Add(',@note3=' + quotedstr(Trim(Label6.Caption)));
|
||||
// execsql;
|
||||
// end;
|
||||
//
|
||||
// end;
|
||||
// GetHTTP(IdHTTP1, 'http://zhengyong.rightsoft.top/api/message/send/BgchSummary');
|
||||
// application.MessageBox('推送成功!', '提示信息');
|
||||
// initgrid();
|
||||
// except
|
||||
// CDS_Main.EnableControls;
|
||||
// application.MessageBox('推送失败!', '提示信息', 0);
|
||||
// end;
|
||||
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -1,664 +0,0 @@
|
|||
object frmCHList: TfrmCHList
|
||||
Left = 146
|
||||
Top = 122
|
||||
Width = 1384
|
||||
Height = 670
|
||||
Caption = #20986#36135#28165#21333
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1368
|
||||
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_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
Visible = False
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 26
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #30452#25509#23548#20986
|
||||
ImageIndex = 4
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 276
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #30830#35748#24320#31080
|
||||
ImageIndex = 31
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object ToolButton4: TToolButton
|
||||
Left = 363
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #25764#38144#24320#31080
|
||||
ImageIndex = 52
|
||||
OnClick = ToolButton4Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 450
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1368
|
||||
Height = 59
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label6: TLabel
|
||||
Left = 379
|
||||
Top = 12
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #22806#38144#21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 236
|
||||
Top = 35
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #24037#21378
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 553
|
||||
Top = 11
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #23458#25143#21517#31216
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 553
|
||||
Top = 34
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #25253#20851#21697#21517
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 403
|
||||
Top = 36
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #19994#21153#21592
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 212
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #35745#21010#21333#21495
|
||||
end
|
||||
object Label1: TLabel
|
||||
Left = 713
|
||||
Top = 10
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #37096' '#38376
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 88
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 88
|
||||
Top = 31
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 445
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object GCNAME: TEdit
|
||||
Tag = 2
|
||||
Left = 264
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object KHName: TEdit
|
||||
Tag = 2
|
||||
Left = 605
|
||||
Top = 7
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object BGCODENAME: TEdit
|
||||
Tag = 2
|
||||
Left = 605
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object YWY: TEdit
|
||||
Tag = 2
|
||||
Left = 445
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 6
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object orderno: TEdit
|
||||
Tag = 2
|
||||
Left = 264
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 7
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object ComboBox1: TComboBox
|
||||
Left = 8
|
||||
Top = 8
|
||||
Width = 73
|
||||
Height = 20
|
||||
ItemHeight = 12
|
||||
ItemIndex = 0
|
||||
TabOrder = 8
|
||||
Text = #25253#20851#26085#26399
|
||||
OnChange = ComboBox1Change
|
||||
Items.Strings = (
|
||||
#25253#20851#26085#26399
|
||||
#33337#26399
|
||||
#20986#36135#26085#26399)
|
||||
end
|
||||
object ywzb: TEdit
|
||||
Tag = 2
|
||||
Left = 765
|
||||
Top = 6
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 9
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1368
|
||||
Height = 540
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object TV1: TcxGridDBTableView
|
||||
PopupMenu = PopupMenu1
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OnCustomDrawCell = TV1CustomDrawCell
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
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 = TV1Column15
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object tv2Column1: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 49
|
||||
end
|
||||
object TV1Column4: TcxGridDBColumn
|
||||
Caption = #24050#24320#31080
|
||||
DataBinding.FieldName = 'KPFLAG'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object TV1Column12: TcxGridDBColumn
|
||||
Caption = #22806#38144#21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 83
|
||||
end
|
||||
object TV1Column11: TcxGridDBColumn
|
||||
Caption = #20844#21496
|
||||
DataBinding.FieldName = 'BGTAITOU'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 82
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #35745#21010#21333#21495
|
||||
DataBinding.FieldName = 'orderno'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.Items.Strings = (
|
||||
#26797#32455
|
||||
#38024#32455
|
||||
#32463#32534
|
||||
#21050#32483
|
||||
#38024#32455#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Width = 71
|
||||
end
|
||||
object Tv1Column1: TcxGridDBColumn
|
||||
Caption = #25253#20851#21697#21517
|
||||
DataBinding.FieldName = 'BGCODENAME'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 69
|
||||
end
|
||||
object tv2Column2: TcxGridDBColumn
|
||||
Caption = #26588#22411
|
||||
DataBinding.FieldName = 'guixing'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36135#25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxCalcEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Sorting = False
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Width = 46
|
||||
end
|
||||
object TV1Column15: TcxGridDBColumn
|
||||
Caption = #37329#39069
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 74
|
||||
end
|
||||
object TV1Column3: TcxGridDBColumn
|
||||
Caption = #32467#31639#24065#31181
|
||||
DataBinding.FieldName = 'JSBZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 74
|
||||
end
|
||||
object tv2Column5: TcxGridDBColumn
|
||||
Caption = #20986#36135#26085
|
||||
DataBinding.FieldName = 'htdate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
end
|
||||
object TV1Column7: TcxGridDBColumn
|
||||
Caption = #33337#26399
|
||||
DataBinding.FieldName = 'chuandate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
end
|
||||
object tv2Column6: TcxGridDBColumn
|
||||
Caption = #20184#27454#26465#20214
|
||||
DataBinding.FieldName = 'OrdConPrcNote'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column8: TcxGridDBColumn
|
||||
Caption = #37096#38376
|
||||
DataBinding.FieldName = 'ywzb'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#23458#26381#19968#32452
|
||||
#23458#26381#20108#32452
|
||||
#23458#26381#19977#32452
|
||||
#23458#26381#22235#32452
|
||||
#23458#26381#20116#32452
|
||||
#23458#26381#20845#32452
|
||||
#23458#26381#19971#32452
|
||||
#23458#26381#20843#32452
|
||||
#23458#26381#20061#32452
|
||||
#23458#26381#21313#32452)
|
||||
Properties.OnChange = TV1Column8PropertiesChange
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 75
|
||||
end
|
||||
object TV1Column9: TcxGridDBColumn
|
||||
Caption = #22269#23478
|
||||
DataBinding.FieldName = 'TOCOUNTRY1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object TV1Column14: TcxGridDBColumn
|
||||
Caption = #19994#21153#21592
|
||||
DataBinding.FieldName = 'YWY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 69
|
||||
end
|
||||
object TV1Column10: TcxGridDBColumn
|
||||
Caption = #36135#20195
|
||||
DataBinding.FieldName = 'huodai'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column13: TcxGridDBColumn
|
||||
Caption = #30446#30340#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column2: TcxGridDBColumn
|
||||
Caption = #23457#26680#26085#26399
|
||||
DataBinding.FieldName = 'ChkTime'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
GroupSummaryAlignment = taCenter
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 74
|
||||
end
|
||||
object TV1Column5: TcxGridDBColumn
|
||||
Caption = #24320#31080#26085#26399
|
||||
DataBinding.FieldName = 'KPDATE'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 59
|
||||
end
|
||||
object TV1Column6: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'YKP'
|
||||
Visible = False
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object MovePanel1: TMovePanel
|
||||
Left = 435
|
||||
Top = 149
|
||||
Width = 249
|
||||
Height = 118
|
||||
TabOrder = 3
|
||||
Visible = False
|
||||
object Label12: TLabel
|
||||
Left = 25
|
||||
Top = 34
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #24320#31080#26085#26399
|
||||
end
|
||||
object kpdate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object Button1: TButton
|
||||
Left = 25
|
||||
Top = 75
|
||||
Width = 75
|
||||
Height = 21
|
||||
Caption = #30830' '#35748
|
||||
TabOrder = 1
|
||||
OnClick = Button1Click
|
||||
end
|
||||
object Button2: TButton
|
||||
Left = 129
|
||||
Top = 74
|
||||
Width = 75
|
||||
Height = 21
|
||||
Caption = #21462' '#28040
|
||||
TabOrder = 2
|
||||
OnClick = Button2Click
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 925
|
||||
Top = 217
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 886
|
||||
Top = 216
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 957
|
||||
Top = 217
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 858
|
||||
Top = 188
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 858
|
||||
Top = 216
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 883
|
||||
Top = 487
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 917
|
||||
Top = 487
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 949
|
||||
Top = 487
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowDialog = False
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 225
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 252
|
||||
Top = 364
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 300
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = ADOQueryMain
|
||||
Left = 256
|
||||
Top = 336
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,556 +0,0 @@
|
|||
object frmCHListsel2: TfrmCHListsel2
|
||||
Left = 132
|
||||
Top = 116
|
||||
Width = 1384
|
||||
Height = 670
|
||||
Caption = #20986#36135#28165#21333#36873#25321
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1368
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object ToolButton1: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36873#25321
|
||||
ImageIndex = 31
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBRafresh: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
Visible = False
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1368
|
||||
Height = 59
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label6: TLabel
|
||||
Left = 379
|
||||
Top = 12
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #22806#38144#21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 236
|
||||
Top = 35
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #24037#21378
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 553
|
||||
Top = 11
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #23458#25143#21517#31216
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 403
|
||||
Top = 36
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #19994#21153#21592
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 212
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #35745#21010#21333#21495
|
||||
end
|
||||
object Label1: TLabel
|
||||
Left = 752
|
||||
Top = 8
|
||||
Width = 220
|
||||
Height = 21
|
||||
Caption = #27880#65306#23383#20307#32418#33394#20026#26080#21512#21516
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -21
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 88
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 88
|
||||
Top = 31
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 445
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object GCNAME: TEdit
|
||||
Tag = 2
|
||||
Left = 264
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnKeyPress = ZordernoKeyPress
|
||||
end
|
||||
object KHName: TEdit
|
||||
Tag = 2
|
||||
Left = 605
|
||||
Top = 7
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnKeyPress = ZordernoKeyPress
|
||||
end
|
||||
object YWY: TEdit
|
||||
Tag = 2
|
||||
Left = 445
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnKeyPress = ZordernoKeyPress
|
||||
end
|
||||
object Zorderno: TEdit
|
||||
Tag = 2
|
||||
Left = 264
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 6
|
||||
OnKeyPress = ZordernoKeyPress
|
||||
end
|
||||
object ComboBox1: TComboBox
|
||||
Left = 8
|
||||
Top = 8
|
||||
Width = 73
|
||||
Height = 20
|
||||
ItemHeight = 12
|
||||
ItemIndex = 0
|
||||
TabOrder = 7
|
||||
Text = #25253#20851#26085#26399
|
||||
OnChange = ComboBox1Change
|
||||
Items.Strings = (
|
||||
#25253#20851#26085#26399
|
||||
#33337#26399
|
||||
#20986#36135#26085#26399)
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1368
|
||||
Height = 540
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object TV1: TcxGridDBTableView
|
||||
OnDblClick = TV1DblClick
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OnCustomDrawCell = TV1CustomDrawCell
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
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 = TV1Column15
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object tv2Column1: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 68
|
||||
end
|
||||
object TV1Column12: TcxGridDBColumn
|
||||
Caption = #22806#38144#21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 83
|
||||
end
|
||||
object TV1Column11: TcxGridDBColumn
|
||||
Caption = #20844#21496
|
||||
DataBinding.FieldName = 'BGTAITOU'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 82
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #35745#21010#21333#21495
|
||||
DataBinding.FieldName = 'ZORDERNO'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.Items.Strings = (
|
||||
#26797#32455
|
||||
#38024#32455
|
||||
#32463#32534
|
||||
#21050#32483
|
||||
#38024#32455#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Sorting = False
|
||||
Width = 71
|
||||
end
|
||||
object tv2Column2: TcxGridDBColumn
|
||||
Caption = #26588#22411
|
||||
DataBinding.FieldName = 'guixing'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36135#25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxCalcEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Sorting = False
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Sorting = False
|
||||
Width = 46
|
||||
end
|
||||
object TV1Column15: TcxGridDBColumn
|
||||
Caption = #37329#39069
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object TV1Column3: TcxGridDBColumn
|
||||
Caption = #32467#31639#24065#31181
|
||||
DataBinding.FieldName = 'JSBZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 73
|
||||
end
|
||||
object tv2Column5: TcxGridDBColumn
|
||||
Caption = #20986#36135#26085
|
||||
DataBinding.FieldName = 'htdate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
end
|
||||
object TV1Column7: TcxGridDBColumn
|
||||
Caption = #33337#26399
|
||||
DataBinding.FieldName = 'chuandate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
end
|
||||
object tv2Column6: TcxGridDBColumn
|
||||
Caption = #20184#27454#26465#20214
|
||||
DataBinding.FieldName = 'OrdConPrcNote'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column8: TcxGridDBColumn
|
||||
Caption = #37096#38376
|
||||
DataBinding.FieldName = 'bm'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 75
|
||||
end
|
||||
object TV1Column9: TcxGridDBColumn
|
||||
Caption = #22269#23478
|
||||
DataBinding.FieldName = 'TOCOUNTRY1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 76
|
||||
end
|
||||
object TV1Column14: TcxGridDBColumn
|
||||
Caption = #19994#21153#21592
|
||||
DataBinding.FieldName = 'YWY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 69
|
||||
end
|
||||
object TV1Column10: TcxGridDBColumn
|
||||
Caption = #36135#20195
|
||||
DataBinding.FieldName = 'huodai'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column13: TcxGridDBColumn
|
||||
Caption = #30446#30340#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column2: TcxGridDBColumn
|
||||
Caption = #23457#26680#26085#26399
|
||||
DataBinding.FieldName = 'ChkTime'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
GroupSummaryAlignment = taCenter
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 74
|
||||
end
|
||||
object TV1Column1: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'ISCONNO'
|
||||
Visible = False
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 925
|
||||
Top = 217
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 893
|
||||
Top = 217
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 957
|
||||
Top = 217
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 858
|
||||
Top = 188
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 777
|
||||
Top = 299
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 883
|
||||
Top = 487
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 917
|
||||
Top = 487
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 949
|
||||
Top = 487
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowDialog = False
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 225
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 252
|
||||
Top = 364
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 300
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = ADOQueryMain
|
||||
Left = 256
|
||||
Top = 336
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,862 +0,0 @@
|
|||
unit U_CHListsel2;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||||
cxEdit, DB, cxDBData, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridBandedTableView, cxGridDBBandedTableView, cxGridLevel, cxClasses,
|
||||
cxControls, cxGridCustomView, cxGridDBTableView, cxGrid, StdCtrls, ComCtrls,
|
||||
ExtCtrls, ToolWin, cxGridCustomPopupMenu, cxGridPopupMenu, ADODB, DBClient,
|
||||
cxDropDownEdit, cxCheckBox, RM_Common, RM_Class, RM_e_Xls, RM_Dataset,
|
||||
RM_System, RM_GridReport, Menus, cxCalendar, cxButtonEdit, cxTextEdit, cxPC,
|
||||
BtnEdit, cxSplitter, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator,
|
||||
dxBarBuiltInMenu, MovePanel, cxCalc, Registry;
|
||||
|
||||
type
|
||||
TfrmCHListsel2 = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
Label5: TLabel;
|
||||
GCNAME: TEdit;
|
||||
Label8: TLabel;
|
||||
KHName: TEdit;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
Label2: TLabel;
|
||||
YWY: TEdit;
|
||||
cxGrid2: TcxGrid;
|
||||
TV1: TcxGridDBTableView;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
tv2Column1: TcxGridDBColumn;
|
||||
tv2Column2: TcxGridDBColumn;
|
||||
tv2Column5: TcxGridDBColumn;
|
||||
tv2Column6: TcxGridDBColumn;
|
||||
TV1Column7: TcxGridDBColumn;
|
||||
TV1Column8: TcxGridDBColumn;
|
||||
TV1Column9: TcxGridDBColumn;
|
||||
TV1Column10: TcxGridDBColumn;
|
||||
TV1Column11: TcxGridDBColumn;
|
||||
TV1Column12: TcxGridDBColumn;
|
||||
TV1Column13: TcxGridDBColumn;
|
||||
TV1Column14: TcxGridDBColumn;
|
||||
Label4: TLabel;
|
||||
Zorderno: TEdit;
|
||||
TV1Column15: TcxGridDBColumn;
|
||||
TV1Column2: TcxGridDBColumn;
|
||||
ComboBox1: TComboBox;
|
||||
ToolButton1: TToolButton;
|
||||
TV1Column1: TcxGridDBColumn;
|
||||
Label1: TLabel;
|
||||
TV1Column3: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure GCNAMEKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure KHNameKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure TBBGZLClick(Sender: TObject);
|
||||
procedure TBHTClick(Sender: TObject);
|
||||
procedure TBFPClick(Sender: TObject);
|
||||
procedure TBZXDClick(Sender: TObject);
|
||||
procedure TBBGDClick(Sender: TObject);
|
||||
procedure TBSBYSClick(Sender: TObject);
|
||||
procedure TBAllClick(Sender: TObject);
|
||||
procedure YWYChange(Sender: TObject);
|
||||
procedure Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
|
||||
procedure huodaiBtnClick(Sender: TObject);
|
||||
procedure B7DaoHuoGangBtnClick(Sender: TObject);
|
||||
procedure BtnEditA1BtnClick(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
procedure ComboBox1Change(Sender: TObject);
|
||||
procedure ZordernoKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure TV1DblClick(Sender: TObject);
|
||||
procedure TV1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||
private
|
||||
canshu2: string;
|
||||
FDate: TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData(): Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj: string);
|
||||
function GetShellFolders(strDir: string): string;
|
||||
procedure InitPrtData();
|
||||
{ Private declarations }
|
||||
public
|
||||
canshu1: string;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmCHListsel2: tfrmCHListsel2;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_RTFun, U_ZDYHelp, U_Fun;
|
||||
|
||||
{$R *.dfm}
|
||||
function TfrmCHListsel2.GetShellFolders(strDir: string): string;
|
||||
const
|
||||
regPath = '\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders';
|
||||
var
|
||||
Reg: TRegistry;
|
||||
strFolders: string;
|
||||
begin
|
||||
Reg := TRegistry.Create;
|
||||
try
|
||||
Reg.RootKey := HKEY_CURRENT_USER;
|
||||
if Reg.OpenKey(regPath, false) then
|
||||
begin
|
||||
strFolders := Reg.ReadString(strDir);
|
||||
end;
|
||||
finally
|
||||
Reg.Free;
|
||||
end;
|
||||
result := strFolders;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
//frmBaoGuanList:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Application := MainApplication;
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime := EndDate.DateTime - 90;
|
||||
canshu1 := Trim(DParameters1);
|
||||
canshu2 := Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.InitGrid();
|
||||
var
|
||||
fwhere, Pwhere: string;
|
||||
begin
|
||||
Pwhere := SGetFilters(Panel1, 1, 2);
|
||||
|
||||
begin
|
||||
if trim(Pwhere) <> '' then
|
||||
fwhere := fwhere + ' and ' + trim(Pwhere);
|
||||
end;
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
// SQL.Add('select * from (');
|
||||
sql.Add('select * from (');
|
||||
sql.Add('select A.*, ');
|
||||
SQL.Add('ISCONNO=(CASE WHEN (SELECT COUNT(CONNO) FROM JYOrder_Main C Inner join JYOrder_BaoGuan_Sub B ON C.ORDERNO=B.ORDERNO WHERE ISNULL(C.CONNO,'''')<>'''' ');
|
||||
sql.Add('AND A.BGID=B.BGID )>0 THEN 1 ELSE 0 END ) ');
|
||||
sql.Add(',TDShouHuoPerson=(select TDShouHuoPerson from JYOrderCon_TT t where t.dcno=a.dcno )');
|
||||
sql.Add(',maitou=(select zhumaitou from JYOrderCon_TT t where t.dcno=a.dcno )');
|
||||
SQL.Add(',ShDAYS=(SELECT top 1 note FROM KH_ZDY k WHERE TYPE =''shfs'' and a.shfs=k.zdyname )');
|
||||
SQL.Add(',ZORDERNO=cast((select B.ORDERNO+'';'' from JYOrder_BaoGuan_SUB B where B.BGID=A.BGID AND SVALID=''Y'' for xml path('''')) as varchar(200))');
|
||||
sql.Add(',C4BGQty=(select sum(C4BGQty) from JYOrder_BaoGuan_SUB B where B.BGID=A.BGID AND SVALID=''Y'' )');
|
||||
sql.Add(',C5BGUnit=(select top 1 C5BGUnit from JYOrder_BaoGuan_SUB B where B.BGID=A.BGID AND SVALID=''Y'' )');
|
||||
sql.Add(',C7BGMoney=(select sum(C7BGMoney) from JYOrder_BaoGuan_SUB B where B.BGID=A.BGID AND SVALID=''Y'' )');
|
||||
SQL.Add(',TOCOUNTRY1=(SELECT TOP 1 ISNULL(note,zdyname) FROM KH_ZDY D WHERE D.ZDYNAME=A.TOCOUNTRY)');
|
||||
SQL.Add(',BM=(SELECT ISNULL(UDEPT,'''')+USERNAME FROM SY_User C WHERE C.USERNAME=A.FILLER )');
|
||||
// SQL.Add(',COADDRESS=(select TOP 1 COADDRESS from Company B where cotype=''客户'' and valid=''Y'' AND A.KHNAME=B.CONAME)');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where A.Valid=''Y'' ');
|
||||
SQL.Add('AND bgStatus=''√''');
|
||||
sql.Add(') aa where 1=1');
|
||||
sql.Add(fwhere);
|
||||
if ComboBox1.Text = '报关日期' then
|
||||
begin
|
||||
sql.Add(' and bgdate>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
sql.Add(' and bgdate<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
SQL.Add('order by bgdate desc');
|
||||
end
|
||||
else if ComboBox1.Text = '船期' then
|
||||
begin
|
||||
sql.Add(' and chuandate>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
sql.Add(' and chuandate<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
SQL.Add('order by chuandate desc ');
|
||||
end
|
||||
else if combobox1.Text = '出货日期' then
|
||||
begin
|
||||
sql.Add(' and htdate>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
sql.Add(' and htdate<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
SQL.Add('order by htdate desc');
|
||||
end;
|
||||
// sql.Add(' ) AA');
|
||||
// ShowMessage(sql.Text);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表' + self.Caption, Tv1, '出货清单');
|
||||
// WriteCxGrid('报关明细' + self.Caption, Tv2, '报关管理8');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表' + self.Caption, Tv1, '出货清单');
|
||||
// ReadCxGrid('报关明细' + self.Caption, Tv2, '报关管理8');
|
||||
canshu1 := Trim(DParameters1);
|
||||
// ShowMessage(canshu1);
|
||||
|
||||
InitGrid();
|
||||
RM1.CanExport := true;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
// TcxGridToExcel(Trim(CDS_Main.fieldbyname('A4FPNO').AsString) + Trim(CDS_Main.fieldbyname('A5ConNO').AsString), cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main, True);
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main, False);
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty = False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID=''' + Trim(CDS_Main.fieldbyname('BGID').AsString) + '''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp, ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp, ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmCHListsel2.DelData(): Boolean;
|
||||
begin
|
||||
try
|
||||
Result := false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel', True, []) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer=''' + Trim(DName) + ''',EditTime=getdate()');
|
||||
sql.Add(' where BGId=''' + Trim(CDS_Main.fieldbyname('BGId').AsString) + '''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer=''' + Trim(DName) + ''',SEditTime=getdate() where BGId=''' + Trim(CDS_Main.fieldbyname('BGId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result := True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result := False;
|
||||
Application.MessageBox('数据删除异常!', '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text) = '' then
|
||||
Exit;
|
||||
fsj := ' and isnull(A.A4FPNO,'''') like ''' + '%' + Trim(A4FPNO.Text) + '%' + '''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.InitGridSql(var fsj: string);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
if Trim(canshu1) <> '高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode=''' + Trim(DCode) + '''');
|
||||
end;
|
||||
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.GCNAMEKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
// if Key = #13 then
|
||||
// begin
|
||||
// if Trim(A6PONO.Text) = '' then
|
||||
// Exit;
|
||||
// fsj := ' and isnull(A.A6PONO,'''') like ''' + '%' + Trim(A6PONO.Text) + '%' + '''';
|
||||
// InitGridSql(fsj);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.KHNameKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
// if Key = #13 then
|
||||
// begin
|
||||
// if Trim(A5ConNO.Text) = '' then
|
||||
// Exit;
|
||||
// fsj := ' and isnull(A.A5ConNO,'''') like ''' + '%' + Trim(A5ConNO.Text) + '%' + '''';
|
||||
// InitGridSql(fsj);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.InitPrtData();
|
||||
begin
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' exec P_View_BaoGuanData :BGID ');
|
||||
Parameters.ParamByName('BGID').Value := Trim(CDS_Main.fieldbyname('BGId').AsString);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint, CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint, CDS_Print);
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBBGZLClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBHTClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBFPClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBZXDClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBBGDClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBSBYSClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TBAllClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile, FZMFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\全部报关资料.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
//RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
if RM1.CanExport = true then
|
||||
begin
|
||||
FZMFile := 'C:\Users\Administrator\Desktop';
|
||||
if not DirectoryExists(FZMFile) then
|
||||
begin
|
||||
FZMFile := 'C:\Documents and Settings\Administrator\桌面\' + trim(CDS_Main.fieldbyname('A4FPNO').AsString) + ' ' + trim(CDS_Main.fieldbyname('A5ConNO').AsString) + '.xls';
|
||||
end
|
||||
else
|
||||
begin
|
||||
FZMFile := 'C:\Users\Administrator\Desktop\' + trim(CDS_Main.fieldbyname('A4FPNO').AsString) + ' ' + trim(CDS_Main.fieldbyname('A5ConNO').AsString) + '.XLS';
|
||||
end;
|
||||
RM1.ExportTo(RMXLSExport1, FZMFile);
|
||||
end;
|
||||
RM1.CanExport := true;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
RM1.CanExport := False;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\全部报关资料.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.YWYChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.huodaiBtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.B7DaoHuoGangBtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.BtnEditA1BtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
ModalResult := 1;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.ToolButton2Click(Sender: TObject);
|
||||
var
|
||||
fPrintFile, FTaiTou: string;
|
||||
EngMoney, LBName, fImagePath2: string;
|
||||
begin
|
||||
// LBName := RadioGroup2.Items.Strings[RadioGroup2.ItemIndex];
|
||||
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\出货清单.rmf';
|
||||
ExportFtErpFile('出货清单.rmf', ADOQueryPrint);
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
// SQL.Add(',HDNAME=(SELECT HDNAME FROM JYOrderCon_TT C WHERE C.DCNO=A.DCNO)');
|
||||
SQL.Add(',TOCOUNTRY1=(SELECT TOP 1 ISNULL(note,zdyname) FROM KH_ZDY D WHERE D.ZDYNAME=A.TOCOUNTRY)');
|
||||
SQL.Add(',BM=(SELECT ISNULL(UDEPT,'''')+USERNAME FROM SY_User C WHERE C.USERNAME=A.FILLER )');
|
||||
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A INNER JOIN JYOrder_BaoGuan_SUB B ON A.BGID=B.BGID ');
|
||||
sql.Add(' where A.Valid=''Y'' and B.SValid=''Y'' ');
|
||||
SQL.Add('AND bgStatus=''√''');
|
||||
// sql.Add(' and filltime>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
// sql.Add(' and filltime<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
if ComboBox1.Text = '报关日期' then
|
||||
begin
|
||||
sql.Add(' and bgdate>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
sql.Add(' and bgdate<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
// SQL.Add('order by bgdate desc');
|
||||
end
|
||||
else if ComboBox1.Text = '船期' then
|
||||
begin
|
||||
sql.Add(' and chuandate>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
sql.Add(' and chuandate<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
// SQL.Add('order by chuandate desc ');
|
||||
end
|
||||
else if combobox1.Text = '出货日期' then
|
||||
begin
|
||||
sql.Add(' and htdate>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
sql.Add(' and htdate<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
// SQL.Add('order by htdate desc');
|
||||
end;
|
||||
sql.Add('order by YWY');
|
||||
// ShowMessage(sql.Text);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
TBFind.Click();
|
||||
// with ADOQueryPrint do
|
||||
// begin
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// sql.Add('exec P_Print_BGD ');
|
||||
//
|
||||
// SQL.ADD('@bgid=''' + Trim(CDS_Main.fieldbyname('BGID').AsString) + '''');
|
||||
// ShowMessage(SQL.Text);
|
||||
// Open;
|
||||
// end;
|
||||
// SCreateCDS20(ADOQueryPrint, CDS_Print);
|
||||
// SInitCDSData20(ADOQueryPrint, CDS_Print);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
fImagePath2 := GetShellFolders('Desktop') + '\出货清单.xls';
|
||||
if FileExists(fImagePath2) then
|
||||
DeleteFile(fImagePath2); //label.xls
|
||||
fImagePath2 := GetShellFolders('Desktop') + '\出货清单.xls';
|
||||
|
||||
RM1.PrepareReport;
|
||||
Sleep(1000);
|
||||
RM1.ExportTo(RMXLSExport1, fImagePath2);
|
||||
|
||||
end
|
||||
else
|
||||
begin
|
||||
// Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf'), '提示', 0);
|
||||
Application.MessageBox(PChar('没有找' + trim(fPrintFile)), '提示信息', 0);
|
||||
Exit;
|
||||
end;
|
||||
initgrid();
|
||||
TBFind.Click();
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.ComboBox1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.ZordernoKeyPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TV1DblClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
ModalResult := 1;
|
||||
end;
|
||||
|
||||
procedure TfrmCHListsel2.TV1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||
begin
|
||||
if (AViewInfo.GridRecord.Values[TV1Column1.Index] = 0) then
|
||||
begin
|
||||
ACanvas.FONT.Color := CLRED;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -1,760 +0,0 @@
|
|||
object frmCPBaoJiaChk: TfrmCPBaoJiaChk
|
||||
Left = 192
|
||||
Top = 63
|
||||
Width = 1148
|
||||
Height = 614
|
||||
Caption = #25253#20215#36873#25321
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
OnClose = FormClose
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1132
|
||||
Height = 31
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 83
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
DisabledImages = DataLink_TradeManage.ThreeImgList
|
||||
Flat = True
|
||||
Images = DataLink_TradeManage.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 9
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 59
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 53
|
||||
Visible = False
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #30830#23450
|
||||
ImageIndex = 106
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object ToolButton6: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #22270#29255#19979#36733
|
||||
ImageIndex = 104
|
||||
OnClick = ToolButton6Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 339
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 55
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 31
|
||||
Width = 1132
|
||||
Height = 58
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 315
|
||||
Top = 15
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #20135#21697#20013#25991
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 315
|
||||
Top = 39
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #20135#21697#33521#25991
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 433
|
||||
Top = 15
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #20135#21697#35268#26684
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 179
|
||||
Top = 15
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #26032#32534#21495
|
||||
end
|
||||
object Label7: TLabel
|
||||
Left = 557
|
||||
Top = 39
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #20811#37325
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 179
|
||||
Top = 39
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #32769#32534#21495
|
||||
end
|
||||
object Label9: TLabel
|
||||
Left = 433
|
||||
Top = 39
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #20135#21697#25104#20221
|
||||
end
|
||||
object Label10: TLabel
|
||||
Left = 557
|
||||
Top = 15
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #38376#24133
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 24
|
||||
Top = 16
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 669
|
||||
Top = 15
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #19994#21153#21592
|
||||
end
|
||||
object Label11: TLabel
|
||||
Left = 669
|
||||
Top = 39
|
||||
Width = 42
|
||||
Height = 12
|
||||
Caption = #23458' '#25143
|
||||
end
|
||||
object CYName: TEdit
|
||||
Tag = 2
|
||||
Left = 365
|
||||
Top = 11
|
||||
Width = 56
|
||||
Height = 20
|
||||
TabOrder = 0
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
object CYEName: TEdit
|
||||
Tag = 2
|
||||
Left = 365
|
||||
Top = 35
|
||||
Width = 57
|
||||
Height = 20
|
||||
TabOrder = 1
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
object CYSpec: TEdit
|
||||
Tag = 2
|
||||
Left = 480
|
||||
Top = 11
|
||||
Width = 61
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
object CYNO: TEdit
|
||||
Tag = 2
|
||||
Left = 216
|
||||
Top = 11
|
||||
Width = 89
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = CYNoChange
|
||||
end
|
||||
object CYKZ: TEdit
|
||||
Tag = 2
|
||||
Left = 583
|
||||
Top = 35
|
||||
Width = 76
|
||||
Height = 20
|
||||
TabOrder = 4
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
object CYNOOld: TEdit
|
||||
Tag = 2
|
||||
Left = 216
|
||||
Top = 35
|
||||
Width = 89
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
object CYECF: TEdit
|
||||
Tag = 2
|
||||
Left = 482
|
||||
Top = 35
|
||||
Width = 59
|
||||
Height = 20
|
||||
TabOrder = 6
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
object CYMF: TEdit
|
||||
Tag = 2
|
||||
Left = 583
|
||||
Top = 11
|
||||
Width = 76
|
||||
Height = 20
|
||||
TabOrder = 7
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
object begdate: TDateTimePicker
|
||||
Left = 74
|
||||
Top = 13
|
||||
Width = 89
|
||||
Height = 20
|
||||
Date = 41423.454483136570000000
|
||||
Time = 41423.454483136570000000
|
||||
TabOrder = 8
|
||||
end
|
||||
object enddate: TDateTimePicker
|
||||
Left = 74
|
||||
Top = 35
|
||||
Width = 89
|
||||
Height = 20
|
||||
Date = 41423.454483136570000000
|
||||
Time = 41423.454483136570000000
|
||||
TabOrder = 9
|
||||
end
|
||||
object BJPerson: TEdit
|
||||
Tag = 2
|
||||
Left = 711
|
||||
Top = 11
|
||||
Width = 76
|
||||
Height = 20
|
||||
TabOrder = 10
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
object KHName: TEdit
|
||||
Tag = 2
|
||||
Left = 711
|
||||
Top = 35
|
||||
Width = 76
|
||||
Height = 20
|
||||
TabOrder = 11
|
||||
OnChange = CYNOOldChange
|
||||
end
|
||||
end
|
||||
object Panel2: TPanel
|
||||
Left = 512
|
||||
Top = 232
|
||||
Width = 185
|
||||
Height = 41
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Caption = #27491#22312#26597#35810#25968#25454#65292#35831#31245#21518#12290#12290#12290
|
||||
Color = clSkyBlue
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
TabOrder = 2
|
||||
Visible = False
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 89
|
||||
Width = 1132
|
||||
Height = 310
|
||||
Align = alClient
|
||||
TabOrder = 3
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
NavigatorButtons.Delete.Enabled = False
|
||||
NavigatorButtons.Delete.Visible = False
|
||||
OnCellClick = Tv2CellClick
|
||||
OnCellDblClick = Tv2CellDblClick
|
||||
DataController.DataSource = DSBJ
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsData.Deleting = False
|
||||
OptionsData.DeletingConfirmation = False
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Inactive = DataLink_TradeManage.SHuangSe
|
||||
Styles.IncSearch = DataLink_TradeManage.SHuangSe
|
||||
Styles.Selection = DataLink_TradeManage.SHuangSe
|
||||
object v2Column17: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSEl'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 44
|
||||
end
|
||||
object v2Column8: TcxGridDBColumn
|
||||
Caption = #25253#20215#21333#21495
|
||||
DataBinding.FieldName = 'BJNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 69
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #26032#32534#21495
|
||||
DataBinding.FieldName = 'CYNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 58
|
||||
end
|
||||
object v1Column41: TcxGridDBColumn
|
||||
Caption = #32769#32534#21495
|
||||
DataBinding.FieldName = 'CYNOOld'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 61
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Caption = #19994#21153#21592
|
||||
DataBinding.FieldName = 'BJPerson'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 68
|
||||
end
|
||||
object v2Column10: TcxGridDBColumn
|
||||
Caption = #25253#20215#26102#38388
|
||||
DataBinding.FieldName = 'BJTime'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 63
|
||||
end
|
||||
object v2Column9: TcxGridDBColumn
|
||||
Caption = #25253#20215#27425#25968
|
||||
DataBinding.FieldName = 'BJCount'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 62
|
||||
end
|
||||
object v2Column11: TcxGridDBColumn
|
||||
Caption = #20215#26684#26415#35821
|
||||
DataBinding.FieldName = 'PriceSY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 59
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #25253#20215
|
||||
DataBinding.FieldName = 'BJPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 55
|
||||
end
|
||||
object v2Column12: TcxGridDBColumn
|
||||
Caption = #20323#37329'(%)'
|
||||
DataBinding.FieldName = 'YongJin'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 55
|
||||
end
|
||||
object v2Column13: TcxGridDBColumn
|
||||
Caption = 'M/Y/'#22871
|
||||
DataBinding.FieldName = 'QtyUnit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 48
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #24065#31181
|
||||
DataBinding.FieldName = 'BZType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 71
|
||||
end
|
||||
object v2Column14: TcxGridDBColumn
|
||||
Caption = #25104#21697#20215
|
||||
DataBinding.FieldName = 'CPPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 55
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Caption = #23458#25143
|
||||
DataBinding.FieldName = 'KHName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 59
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Caption = #30446#26631#24066#22330
|
||||
DataBinding.FieldName = 'MBShiChang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 74
|
||||
end
|
||||
object v2Column2: TcxGridDBColumn
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 68
|
||||
end
|
||||
object v2Column3: TcxGridDBColumn
|
||||
Caption = #21697#36136#35201#27714
|
||||
DataBinding.FieldName = 'PinZhiYQ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 110
|
||||
end
|
||||
object v2Column15: TcxGridDBColumn
|
||||
Caption = #25253#20215#22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 85
|
||||
end
|
||||
object v2Column7: TcxGridDBColumn
|
||||
Caption = #23457#26680#20154
|
||||
DataBinding.FieldName = 'Chker'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 63
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Caption = #23457#26680#29366#24577
|
||||
DataBinding.FieldName = 'ChkStatus'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 71
|
||||
end
|
||||
object v2Column4: TcxGridDBColumn
|
||||
Caption = #23457#26680#20215#26684
|
||||
DataBinding.FieldName = 'ChkPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 63
|
||||
end
|
||||
object v2Column5: TcxGridDBColumn
|
||||
Caption = #23457#26680#22791#27880
|
||||
DataBinding.FieldName = 'ChkNote'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 79
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #20135#21697#20013#25991
|
||||
DataBinding.FieldName = 'CYName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 68
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #20135#21697#33521#25991
|
||||
DataBinding.FieldName = 'CYEName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 66
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #20135#21697#25104#20221
|
||||
DataBinding.FieldName = 'CYECF'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 69
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #20135#21697#35268#26684
|
||||
DataBinding.FieldName = 'CYSpec'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 67
|
||||
end
|
||||
object v2Column16: TcxGridDBColumn
|
||||
Caption = #22383#24067#36136#22320
|
||||
DataBinding.FieldName = 'PBName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 72
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #22383#24067#38376#24133
|
||||
DataBinding.FieldName = 'PBMF'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 64
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #25104#21697#21360#26579#24037#33402
|
||||
DataBinding.FieldName = 'CYGY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 94
|
||||
end
|
||||
object v1Column25: TcxGridDBColumn
|
||||
Caption = #25104#21697#38468#21152#24037#33402
|
||||
DataBinding.FieldName = 'CYGYAdd'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 90
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #25104#21697#38376#24133
|
||||
DataBinding.FieldName = 'CYMF'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 73
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #25104#21697#20811#37325
|
||||
DataBinding.FieldName = 'CYKZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 67
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object cxSplitter2: TcxSplitter
|
||||
Left = 0
|
||||
Top = 399
|
||||
Width = 1132
|
||||
Height = 8
|
||||
HotZoneClassName = 'TcxMediaPlayer9Style'
|
||||
AlignSplitter = salBottom
|
||||
Control = cxGrid4
|
||||
end
|
||||
object cxGrid4: TcxGrid
|
||||
Left = 0
|
||||
Top = 407
|
||||
Width = 1132
|
||||
Height = 169
|
||||
Align = alBottom
|
||||
TabOrder = 5
|
||||
object Tv21: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
NavigatorButtons.Delete.Enabled = False
|
||||
NavigatorButtons.Delete.Visible = False
|
||||
DataController.DataSource = DS_Chk
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsData.Deleting = False
|
||||
OptionsData.DeletingConfirmation = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.GroupByBox = False
|
||||
object cxGridDBColumn15: TcxGridDBColumn
|
||||
Caption = #36865#23457#20154
|
||||
DataBinding.FieldName = 'Chkperson'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 84
|
||||
end
|
||||
object cxGridDBColumn17: TcxGridDBColumn
|
||||
Caption = #36865#23457#26102#38388
|
||||
DataBinding.FieldName = 'FillTime'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 152
|
||||
end
|
||||
object cxGridDBColumn16: TcxGridDBColumn
|
||||
Caption = #23457#26680#20154
|
||||
DataBinding.FieldName = 'NextChkperson'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 76
|
||||
end
|
||||
object cxGridDBColumn18: TcxGridDBColumn
|
||||
Caption = #23457#26680#39034#24207
|
||||
DataBinding.FieldName = 'ChkOrder'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 65
|
||||
end
|
||||
object v21Column1: TcxGridDBColumn
|
||||
Caption = #23457#26680#26102#38388
|
||||
DataBinding.FieldName = 'ChkTime'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 159
|
||||
end
|
||||
object cxGridDBColumn19: TcxGridDBColumn
|
||||
Caption = #29366#24577
|
||||
DataBinding.FieldName = 'ChkStatus'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 93
|
||||
end
|
||||
object v21Column2: TcxGridDBColumn
|
||||
Caption = #23457#26680#20215#26684
|
||||
DataBinding.FieldName = 'ChkPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 75
|
||||
end
|
||||
object v21Column3: TcxGridDBColumn
|
||||
Caption = #23457#26680#22791#27880
|
||||
DataBinding.FieldName = 'ChkNote'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
Width = 177
|
||||
end
|
||||
end
|
||||
object cxGridLevel3: TcxGridLevel
|
||||
GridView = Tv21
|
||||
end
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 181
|
||||
Top = 185
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
Parameters = <>
|
||||
Left = 221
|
||||
Top = 185
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 253
|
||||
Top = 185
|
||||
end
|
||||
object ODPat: TOpenDialog
|
||||
Options = [ofReadOnly, ofAllowMultiSelect, ofPathMustExist, ofFileMustExist, ofEnableSizing]
|
||||
Left = 884
|
||||
Top = 5
|
||||
end
|
||||
object IdFTP1: TIdFTP
|
||||
MaxLineAction = maException
|
||||
ReadTimeout = 0
|
||||
ProxySettings.ProxyType = fpcmNone
|
||||
ProxySettings.Port = 0
|
||||
Left = 845
|
||||
Top = 4
|
||||
end
|
||||
object SaveDialog1: TSaveDialog
|
||||
Left = 769
|
||||
Top = 5
|
||||
end
|
||||
object CDS_BJ: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 376
|
||||
Top = 248
|
||||
end
|
||||
object DSBJ: TDataSource
|
||||
DataSet = CDS_BJ
|
||||
Left = 483
|
||||
Top = 248
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 408
|
||||
Top = 248
|
||||
end
|
||||
object ADOQuerySub: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 437
|
||||
Top = 249
|
||||
end
|
||||
object DS_Chk: TDataSource
|
||||
DataSet = CDS_Chk
|
||||
Left = 419
|
||||
Top = 464
|
||||
end
|
||||
object CDS_Chk: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 448
|
||||
Top = 464
|
||||
end
|
||||
object cxGridPopupMenu3: TcxGridPopupMenu
|
||||
Grid = cxGrid4
|
||||
PopupMenus = <>
|
||||
Left = 480
|
||||
Top = 464
|
||||
end
|
||||
end
|
||||
|
|
@ -1,375 +0,0 @@
|
|||
unit U_CPBaoJiaChk;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
|
||||
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin,
|
||||
StdCtrls, cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
|
||||
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
|
||||
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
|
||||
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
||||
IdTCPClient, IdFTP,ShellAPI,IniFiles, cxCheckBox, Menus, cxPC;
|
||||
|
||||
type
|
||||
TfrmCPBaoJiaChk = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
Panel1: TPanel;
|
||||
ToolButton2: TToolButton;
|
||||
Label1: TLabel;
|
||||
CYName: TEdit;
|
||||
Label4: TLabel;
|
||||
CYEName: TEdit;
|
||||
Label5: TLabel;
|
||||
CYSpec: TEdit;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ToolButton1: TToolButton;
|
||||
ODPat: TOpenDialog;
|
||||
IdFTP1: TIdFTP;
|
||||
SaveDialog1: TSaveDialog;
|
||||
ToolButton6: TToolButton;
|
||||
Label3: TLabel;
|
||||
CYNO: TEdit;
|
||||
Panel2: TPanel;
|
||||
Label7: TLabel;
|
||||
CYKZ: TEdit;
|
||||
Label8: TLabel;
|
||||
Label9: TLabel;
|
||||
CYNOOld: TEdit;
|
||||
CYECF: TEdit;
|
||||
Label10: TLabel;
|
||||
CYMF: TEdit;
|
||||
CDS_BJ: TClientDataSet;
|
||||
DSBJ: TDataSource;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
Label2: TLabel;
|
||||
begdate: TDateTimePicker;
|
||||
enddate: TDateTimePicker;
|
||||
ADOQuerySub: TADOQuery;
|
||||
DS_Chk: TDataSource;
|
||||
CDS_Chk: TClientDataSet;
|
||||
cxGridPopupMenu3: TcxGridPopupMenu;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v1Column41: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column25: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
cxSplitter2: TcxSplitter;
|
||||
cxGrid4: TcxGrid;
|
||||
Tv21: TcxGridDBTableView;
|
||||
cxGridDBColumn15: TcxGridDBColumn;
|
||||
cxGridDBColumn16: TcxGridDBColumn;
|
||||
cxGridDBColumn17: TcxGridDBColumn;
|
||||
cxGridDBColumn18: TcxGridDBColumn;
|
||||
cxGridDBColumn19: TcxGridDBColumn;
|
||||
cxGridLevel3: TcxGridLevel;
|
||||
v21Column1: TcxGridDBColumn;
|
||||
Label6: TLabel;
|
||||
BJPerson: TEdit;
|
||||
Label11: TLabel;
|
||||
KHName: TEdit;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v2Column2: TcxGridDBColumn;
|
||||
v2Column3: TcxGridDBColumn;
|
||||
v21Column2: TcxGridDBColumn;
|
||||
v21Column3: TcxGridDBColumn;
|
||||
v2Column4: TcxGridDBColumn;
|
||||
v2Column5: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v2Column7: TcxGridDBColumn;
|
||||
v2Column8: TcxGridDBColumn;
|
||||
v2Column9: TcxGridDBColumn;
|
||||
v2Column10: TcxGridDBColumn;
|
||||
v2Column11: TcxGridDBColumn;
|
||||
v2Column12: TcxGridDBColumn;
|
||||
v2Column13: TcxGridDBColumn;
|
||||
v2Column14: TcxGridDBColumn;
|
||||
v2Column15: TcxGridDBColumn;
|
||||
v2Column16: TcxGridDBColumn;
|
||||
v2Column17: TcxGridDBColumn;
|
||||
ToolButton3: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure cxDBTreeList1DblClick(Sender: TObject);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
procedure CYNoChange(Sender: TObject);
|
||||
procedure ToolButton6Click(Sender: TObject);
|
||||
procedure Tv2CellDblClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure CYNOOldChange(Sender: TObject);
|
||||
procedure Tv2CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
CPID:string;
|
||||
PState:Integer;
|
||||
FCPID,FTopID:String;
|
||||
procedure InitGrid();
|
||||
procedure ReadINIFile();
|
||||
|
||||
public
|
||||
{ Public declarations }
|
||||
FFint:Integer;
|
||||
end;
|
||||
|
||||
var
|
||||
frmCPBaoJiaChk: TfrmCPBaoJiaChk;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_Fun,U_ZDYHelp;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
|
||||
|
||||
procedure TfrmCPBaoJiaChk.InitGrid();
|
||||
begin
|
||||
|
||||
try
|
||||
ADOQuerySub.DisableControls;
|
||||
with ADOQuerySub do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select A.BJPerSon,A.BJPrice,A.BZType,A.KHName,A.BJID,A.MBShiChang,A.Qty,A.PinZhiYQ, A.BJTime,');
|
||||
sql.Add('A.Chker,A.ChkStatus,A.ChkPrice,A.ChkNote,A.BJNO,A.BJCount,A.YongJIn,A.CPPrice,A.PriceSY,A.QtyUnit,A.Note,B.* ');
|
||||
sql.Add('from CP_BaoJia A');
|
||||
SQL.Add('left join CP_YDang B on A.CYID=B.CYID ');
|
||||
{if Trim(DParameters1)='高权限' then
|
||||
begin
|
||||
|
||||
end else
|
||||
begin
|
||||
sql.Add('where exists(select * from CP_BaoJia_Chk C where C.ChkTime>=:begdate and ChkTime<:enddate ');
|
||||
sql.Add(' and isnull(C.ChkStatus,'''')<>'''' and C.BJID=A.BJID and NextChkPerson='''+Trim(DName)+''')');
|
||||
sql.Add(' and A.ChkStatus=''审核通过''');
|
||||
end;}
|
||||
sql.Add(' where isnull(A.Chker,'''')<>'''' and A.ChkStatus=''审核通过'' ');
|
||||
sql.Add(' and A.FillTime>=:begdate and A.FillTime<:enddate ');
|
||||
|
||||
Parameters.ParamByName('begdate').Value:=Trim(FormatDateTime('yyyy-MM-dd',begdate.DateTime));
|
||||
Parameters.ParamByName('enddate').Value:=Trim(FormatDateTime('yyyy-MM-dd',enddate.DateTime+1));
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQuerySub,CDS_BJ);
|
||||
SInitCDSData20(ADOQuerySub,CDS_BJ);
|
||||
finally
|
||||
ADOQuerySub.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmCPBaoJiaChk:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('bjshWTSel',Tv2,'报价管理');
|
||||
WriteCxGrid('bjshWTSSel',Tv21,'报价管理');
|
||||
if DirectoryExists(ExtractFileDir('D:\Right1209')) then
|
||||
winexec('cmd /c rd /s /q D:\Right1209',sw_hide);
|
||||
Close;
|
||||
end;
|
||||
procedure TfrmCPBaoJiaChk.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('bjshWTSel',Tv2,'报价管理');
|
||||
ReadCxGrid('bjshWTSSel',Tv21,'报价管理');
|
||||
enddate.Date:=SGetServerDate(ADOQueryCmd);
|
||||
begdate.Date:=enddate.Date-7;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.cxDBTreeList1DblClick(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.ToolButton2Click(Sender: TObject);
|
||||
begin
|
||||
if ADOQuerySub.Active then
|
||||
begin
|
||||
SDofilter(ADOQuerySub,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQuerySub,CDS_BJ);
|
||||
SInitCDSData20(ADOQuerySub,CDS_BJ);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.CYNoChange(Sender: TObject);
|
||||
begin
|
||||
if Length(Trim(TEdit(Sender).Text))<3 then Exit;
|
||||
if ADOQuerySub.Active then
|
||||
begin
|
||||
SDofilter(ADOQuerySub,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQuerySub,CDS_BJ);
|
||||
SInitCDSData20(ADOQuerySub,CDS_BJ);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.ToolButton6Click(Sender: TObject);
|
||||
var
|
||||
fHandle:THandle;
|
||||
FInt:Integer;
|
||||
FFName,FPath:String;
|
||||
begin
|
||||
{FPath:='C:\HTTP1209\';
|
||||
if DirectoryExists(ExtractFileDir(FPath)) then
|
||||
winexec('cmd /c rd /s /q C:\HTTP1209',sw_hide);}
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from XD_File where CYNO='''+Trim(CDS_BJ.fieldbyname('CYNO').AsString)+'''');
|
||||
Open;
|
||||
if IsEmpty then
|
||||
begin
|
||||
Application.MessageBox('样品图片未上传!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
try
|
||||
ReadINIFile();
|
||||
server:=ReadINIFileStr('SYSTEMSET.INI','SERVER','服务器地址','127.0.0.1');
|
||||
if Length(server)<6 then
|
||||
begin
|
||||
server:='127.0.0.1';
|
||||
end;
|
||||
IdFTP1.Host :=server;//PicSvr;
|
||||
IdFTP1.Username := 'three';
|
||||
IdFTP1.Password := '641010';
|
||||
IdFTP1.Connect();
|
||||
except
|
||||
IdFTP1.Quit;
|
||||
Application.MessageBox('无法连接到文件服务器,请检查!', '提示', MB_ICONWARNING);
|
||||
Exit;
|
||||
end;
|
||||
FPath:='D:\Right1209\';
|
||||
if not DirectoryExists(ExtractFileDir(FPath)) then
|
||||
CreateDir(ExtractFileDir(FPath));
|
||||
FFName:=Trim(ADOQueryTemp.fieldbyname('FileName').AsString);
|
||||
FFName:=FPath+FFName;
|
||||
if FileExists(FFName) then
|
||||
begin
|
||||
FInt:=1;
|
||||
end;
|
||||
if FInt<>1 then
|
||||
IdFTP1.Get('YP\'+Trim(ADOQueryTemp.fieldbyname('FileName').AsString),
|
||||
FPath+Trim(ADOQueryTemp.fieldbyname('FileName').AsString)
|
||||
);
|
||||
if IdFTP1.Connected then IdFTP1.Quit;
|
||||
ShellExecute(Handle, 'open',PChar(FPath+Trim(ADOQueryTemp.fieldbyname('FileName').AsString)),'', '', SW_SHOWNORMAL);
|
||||
|
||||
end;
|
||||
procedure TfrmCPBaoJiaChk.ReadINIFile();
|
||||
var
|
||||
programIni:Tinifile; //配置文件名
|
||||
FileName:string;
|
||||
begin
|
||||
FileName:=ExtractFilePath(Paramstr(0))+'SYSTEMSET.INI';
|
||||
programIni:=Tinifile.create(FileName);
|
||||
server:=programIni.ReadString('SERVER','服务器地址','127.0.0.1');
|
||||
programIni.Free;
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.Tv2CellDblClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
ToolButton6.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.CYNOOldChange(Sender: TObject);
|
||||
begin
|
||||
|
||||
if ADOQuerySub.Active then
|
||||
begin
|
||||
SDofilter(ADOQuerySub,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQuerySub,CDS_BJ);
|
||||
SInitCDSData20(ADOQuerySub,CDS_BJ);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.Tv2CellClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
if CDS_BJ.IsEmpty then Exit;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from CP_BaoJia_Chk where BJID='''+Trim(CDS_BJ.fieldbyname('BJID').AsString)+'''');
|
||||
sql.Add(' order by ChkOrder ');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryTemp,CDS_Chk);
|
||||
SInitCDSData20(ADOQueryTemp,CDS_Chk);
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
if CDS_BJ.IsEmpty then
|
||||
begin
|
||||
with Self.ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from CP_BaoJia_Chk where 1<>1');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryTemp,CDS_Chk);
|
||||
SInitCDSData20(ADOQueryTemp,CDS_Chk);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCPBaoJiaChk.ToolButton3Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_BJ.Locate('SSel',True,[])=False then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
ModalResult:=1;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,312 +0,0 @@
|
|||
object frmCPOutListCX: TfrmCPOutListCX
|
||||
Left = 187
|
||||
Top = 129
|
||||
Width = 1396
|
||||
Height = 654
|
||||
Caption = #25104#21697#20986#24211#26597#35810
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -13
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
Position = poScreenCenter
|
||||
OnClose = FormClose
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 107
|
||||
TextHeight = 13
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1380
|
||||
Height = 33
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
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 = 9
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
Caption = #30830#23450
|
||||
ImageIndex = 41
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 122
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 55
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 1380
|
||||
Height = 43
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label5: TLabel
|
||||
Left = 24
|
||||
Top = 13
|
||||
Width = 39
|
||||
Height = 13
|
||||
Caption = #21512#21516#21495
|
||||
end
|
||||
object orderNo: TEdit
|
||||
Tag = 2
|
||||
Left = 65
|
||||
Top = 10
|
||||
Width = 213
|
||||
Height = 21
|
||||
TabOrder = 0
|
||||
OnKeyPress = orderNoKeyPress
|
||||
end
|
||||
end
|
||||
object MovePanel2: TMovePanel
|
||||
Left = 373
|
||||
Top = 208
|
||||
Width = 313
|
||||
Height = 53
|
||||
BevelInner = bvLowered
|
||||
Caption = #27491#22312#25191#34892#25968#25454#25805#20316#65292#35831#31245#21518#12290#12290#12290
|
||||
Color = clSkyBlue
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -15
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
TabOrder = 2
|
||||
Visible = False
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 76
|
||||
Width = 1380
|
||||
Height = 538
|
||||
Align = alClient
|
||||
TabOrder = 3
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skCount
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v2Column6
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Inactive = DataLink_TradeManage.SHuangSe
|
||||
Styles.IncSearch = DataLink_TradeManage.SHuangSe
|
||||
Styles.Selection = DataLink_TradeManage.SHuangSe
|
||||
Styles.Header = DataLink_TradeManage.Default
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 53
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'ConNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1OrderNo: TcxGridDBColumn
|
||||
Caption = #25351#31034#21333#21495
|
||||
DataBinding.FieldName = 'OrderNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1FHMoney: TcxGridDBColumn
|
||||
Caption = #24212#25910#37329#39069
|
||||
DataBinding.FieldName = 'FHMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1YRLMoney: TcxGridDBColumn
|
||||
Caption = #24050#35748#39046#37329#39069
|
||||
DataBinding.FieldName = 'YRLMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 71
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #20986#26588#26085#26399
|
||||
DataBinding.FieldName = 'CRTime'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 78
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Caption = #36135#29289#21517#31216'('#20013#25991')'
|
||||
DataBinding.FieldName = 'MPRTCodeName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 111
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #36135#29289#21517#31216'('#33521#25991')'
|
||||
DataBinding.FieldName = 'PRTEngCodeName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 95
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #38376#24133
|
||||
DataBinding.FieldName = 'MPRTMF'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #20811#37325
|
||||
DataBinding.FieldName = 'MPRTKZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 45
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Caption = #20986#26588#25968#37327
|
||||
DataBinding.FieldName = 'Qty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 88
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #25968#37327#21333#20301
|
||||
DataBinding.FieldName = 'QtyUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.DropDownListStyle = lsFixedList
|
||||
Properties.Items.Strings = (
|
||||
'M'
|
||||
'Kg'
|
||||
'Y')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 71
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #21333#20215
|
||||
DataBinding.FieldName = 'PRTPrice'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 63
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #24065#31181
|
||||
DataBinding.FieldName = 'OrdConPrcUnit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 47
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Caption = #20215#26684#26415#35821
|
||||
DataBinding.FieldName = 'OrdConPrcNote'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #20215#26684#35828#26126
|
||||
DataBinding.FieldName = 'OrdConPrcShuoM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1ZSYJMoney: TcxGridDBColumn
|
||||
Caption = #25972#25968#20323#37329
|
||||
DataBinding.FieldName = 'ZSYJMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1GDYJMoney: TcxGridDBColumn
|
||||
Caption = #22266#23450#20323#37329
|
||||
DataBinding.FieldName = 'GDYJMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1FZYJMoney: TcxGridDBColumn
|
||||
Caption = #20998#20540#20323#37329
|
||||
DataBinding.FieldName = 'FZYJMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
end
|
||||
object cxGrid2Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 776
|
||||
Top = 160
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 808
|
||||
Top = 160
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 784
|
||||
Top = 248
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 744
|
||||
Top = 168
|
||||
end
|
||||
end
|
||||
|
|
@ -1,159 +0,0 @@
|
|||
unit U_CPOutListCX;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridBandedTableView, cxGridDBBandedTableView,
|
||||
cxGridLevel, cxClasses, cxControls, cxGridCustomView, cxGridDBTableView,
|
||||
cxGrid, StdCtrls, ComCtrls, ExtCtrls, ToolWin, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxDropDownEdit, RM_Common, RM_Class,
|
||||
RM_e_Xls, RM_Dataset, RM_System, RM_GridReport, cxCheckBox, Menus,
|
||||
MovePanel, cxCalendar, cxButtonEdit;
|
||||
|
||||
type
|
||||
TfrmCPOutListCX = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryMain: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
CDS_Main: TClientDataSet;
|
||||
Label5: TLabel;
|
||||
orderNo: TEdit;
|
||||
MovePanel2: TMovePanel;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
cxGrid2Level1: TcxGridLevel;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
ToolButton1: TToolButton;
|
||||
v1ZSYJMoney: TcxGridDBColumn;
|
||||
v1GDYJMoney: TcxGridDBColumn;
|
||||
v1FZYJMoney: TcxGridDBColumn;
|
||||
v1OrderNo: TcxGridDBColumn;
|
||||
v1FHMoney: TcxGridDBColumn;
|
||||
v1YRLMoney: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure orderNoKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
private
|
||||
procedure InitGrid();
|
||||
{ Private declarations }
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmCPOutListCX: TfrmCPOutListCX;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_Fun,U_BanCpRkOutPut;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmCPOutListCX.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmCPOutListCX:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmCPOutListCX.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmCPOutListCX.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
SQL.Add('select A.*,D.ConNo,B.MPRTCodeName,B.MPRTMF,B.MPRTKZ,B.OrderNo,D.OrdConPrcUnit ');
|
||||
sql.Add(',D.OrdConPrcNote,D.OrdConPrcShuoM,C.*,FHMoney=round(C.PRTPrice*A.Qty,2,1) ');
|
||||
sql.add(',YRLMoney=(select Sum(FP.FPMoney)+isnull(sum(FP.SXMoney),0) from SK_Money_FP FP where FP.BCID=A.BCID and FP.WBID=A.Mainid)');
|
||||
sql.add('from CK_BanCP_CR A ');
|
||||
Sql.add(' inner join JYOrder_Main B on A.MainId=B.MainId');
|
||||
sql.Add(' left join JYOrderCon_Sub C on B.ConSubId=C.Subid');
|
||||
sql.Add(' left join JYOrderCon_Main D on C.Mainid=D.Mainid');
|
||||
sql.Add(' where D.ConNo like '''+'%'+Trim(orderNo.Text)+'%'+'''');
|
||||
SQL.Add(' and CRType=''正常出库'' and A.BCID=A.MJID');
|
||||
sql.add(' order by B.OrderNo');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain,CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCPOutListCX.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCPOutListCX.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('业务成品出库查询',Tv1,'成品仓库');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmCPOutListCX.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('业务成品出库查询',Tv1,'成品仓库');
|
||||
end;
|
||||
|
||||
procedure TfrmCPOutListCX.N1Click(Sender: TObject);
|
||||
begin
|
||||
//SelOKNo(CDS_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmCPOutListCX.N2Click(Sender: TObject);
|
||||
begin
|
||||
//SelOKNo(CDS_Main,False);
|
||||
end;
|
||||
|
||||
|
||||
|
||||
procedure TfrmCPOutListCX.orderNoKeyPress(Sender: TObject;
|
||||
var Key: Char);
|
||||
begin
|
||||
if Key=#13 then
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCPOutListCX.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('业务成品出库查询',Tv1,'成品仓库');
|
||||
ModalResult:=1;
|
||||
end;
|
||||
|
||||
end.
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,907 +0,0 @@
|
|||
unit U_ConLCInPutDC;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||||
cxEdit, DB, cxDBData, cxGridLevel, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridDBTableView, cxClasses, cxControls, cxGridCustomView, cxGrid, cxMemo,
|
||||
cxRichEdit, ComCtrls, cxContainer, cxTextEdit, cxMaskEdit, cxButtonEdit,
|
||||
StdCtrls, ToolWin, DBClient, ADODB, ExtCtrls, BtnEdit, cxCalendar, StrUtils,
|
||||
cxDropDownEdit, cxCurrencyEdit, cxLookAndFeels, cxLookAndFeelPainters,
|
||||
cxNavigator, dxSkinsCore, dxSkinsDefaultPainters, dxSkinscxPCPainter;
|
||||
|
||||
type
|
||||
TfrmConLCInPutDC = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBSave: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
ScrollBox1: TScrollBox;
|
||||
ADOTemp: TADOQuery;
|
||||
ADOCmd: TADOQuery;
|
||||
ADOQuery1: TADOQuery;
|
||||
Label10: TLabel;
|
||||
Label24: TLabel;
|
||||
DCNO: TEdit;
|
||||
Label18: TLabel;
|
||||
FromPlace: TBtnEditC;
|
||||
Label19: TLabel;
|
||||
TOPlace: TBtnEditC;
|
||||
Label25: TLabel;
|
||||
ChuanInfo: TBtnEditC;
|
||||
Label26: TLabel;
|
||||
HangBanName: TBtnEditC;
|
||||
ToolBar2: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
Order_Sub: TClientDataSet;
|
||||
DataSource1: TDataSource;
|
||||
Label8: TLabel;
|
||||
CYDATE: TDateTimePicker;
|
||||
Label11: TLabel;
|
||||
XYZNO: TBtnEditC;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
Label13: TLabel;
|
||||
ESCXGS: TEdit;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
Label20: TLabel;
|
||||
OrdConPrcNote: TBtnEditC;
|
||||
Label23: TLabel;
|
||||
ToolButton1: TToolButton;
|
||||
Label32: TLabel;
|
||||
BGTAITOU: TBtnEditC;
|
||||
Label38: TLabel;
|
||||
fileTT: TBtnEditC;
|
||||
Label1: TLabel;
|
||||
TOCOUNTRY: TBtnEditC;
|
||||
Label5: TLabel;
|
||||
Label7: TLabel;
|
||||
KHName: TBtnEditC;
|
||||
Label9: TLabel;
|
||||
YFCF: TBtnEditC;
|
||||
Label14: TLabel;
|
||||
YSFS: TBtnEditC;
|
||||
Label15: TLabel;
|
||||
ping: TBtnEditC;
|
||||
Label16: TLabel;
|
||||
Label17: TLabel;
|
||||
SSCDGS: TEdit;
|
||||
Label27: TLabel;
|
||||
SSCGGS: TEdit;
|
||||
Label6: TLabel;
|
||||
Label12: TLabel;
|
||||
Label21: TLabel;
|
||||
HDName: TBtnEditC;
|
||||
SellNOTE: TMemo;
|
||||
Label2: TLabel;
|
||||
TDShouHuoPerson: TMemo;
|
||||
Label3: TLabel;
|
||||
TDTongZhiPerson: TMemo;
|
||||
Label4: TLabel;
|
||||
ZhuMaiTou: TMemo;
|
||||
Label22: TLabel;
|
||||
DJYQ: TMemo;
|
||||
Label28: TLabel;
|
||||
ZXPLACE: TMemo;
|
||||
Label29: TLabel;
|
||||
Note: TMemo;
|
||||
Label30: TLabel;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
ToolButton2: TToolButton;
|
||||
BTDate: TDateTimePicker;
|
||||
DZY: TComboBox;
|
||||
YWY: TComboBox;
|
||||
BGY: TComboBox;
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBSaveClick(Sender: TObject);
|
||||
procedure SKBankBtnDnClick(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure v1Column1PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Label36DblClick(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure Label29DblClick(Sender: TObject);
|
||||
procedure Label3DblClick(Sender: TObject);
|
||||
procedure XYZNOBtnUpClick(Sender: TObject);
|
||||
procedure OrdConPrcNoteBtnUpClick(Sender: TObject);
|
||||
procedure TOPlaceBtnUpClick(Sender: TObject);
|
||||
procedure KHNameBtnUpClick(Sender: TObject);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
procedure v1Column15PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column8PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure DZYDropDown(Sender: TObject);
|
||||
procedure YWYDropDown(Sender: TObject);
|
||||
procedure BGYDropDown(Sender: TObject);
|
||||
procedure v1Column1PropertiesEditValueChanged(Sender: TObject);
|
||||
private
|
||||
procedure InitData();
|
||||
procedure ZDYHelp(FButn: TcxButtonEdit; LType: string);
|
||||
function SaveData(): Boolean;
|
||||
{ Private declarations }
|
||||
public
|
||||
PState, CopyInt: Integer;
|
||||
FMainId, FFMainId: string;
|
||||
FXS: Integer;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmConLCInPutDC: TfrmConLCInPutDC;
|
||||
newh: hwnd;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_ZDYHelp, U_Fun, U_ZDYHelpSel, U_CPBaoJiaChk, U_CPOutListCX,
|
||||
U_ProductOrderList_Sel, U_ZdyAttachment;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmConLCInPutDC.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.InitData();
|
||||
begin
|
||||
CYDATE.DateTime := SGetServerDateTime(ADOTemp);
|
||||
BTDate.DateTime := CYDATE.DateTime;
|
||||
if PState = 0 then
|
||||
begin
|
||||
BTDate.Checked := False;
|
||||
BGY.Text := Trim(DName);
|
||||
DZY.Text := Trim(DName);
|
||||
end;
|
||||
// BTDate.Checked := False;
|
||||
with ADOQuery1 do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add(' select * from JYOrderCon_TT_Sub ');
|
||||
if PState = 1 then
|
||||
begin
|
||||
sql.Add('where TTId=''' + Trim(FMainId) + '''');
|
||||
end;
|
||||
if PState = 0 then
|
||||
begin
|
||||
sql.Add(' where 1=2');
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQuery1, Order_Sub);
|
||||
SInitCDSData20(ADOQuery1, Order_Sub);
|
||||
with ADOQuery1 do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * ');
|
||||
sql.add('from JYOrderCon_TT where TTId=''' + Trim(FMainId) + '''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQuery1.IsEmpty = false then
|
||||
SCSHDataNew(ADOQuery1, ScrollBox1, 2);
|
||||
if PState <> 0 then
|
||||
begin
|
||||
DZY.Text := ADOQuery1.fieldbyname('DZY').AsString;
|
||||
YWY.Text := ADOQuery1.fieldbyname('YWY').AsString;
|
||||
BGY.Text := ADOQuery1.fieldbyname('BGY').AsString;
|
||||
end;
|
||||
|
||||
if CopyInt = 99 then
|
||||
begin
|
||||
PState := 0;
|
||||
FMainId := '';
|
||||
DCNO.Text := '系统自动编码';
|
||||
OrdConPrcNote.Text := 'FOB';
|
||||
YFCF.Text := 'FREIGHT COLLECT';
|
||||
|
||||
Order_Sub.DisableControls;
|
||||
with Order_Sub do
|
||||
begin
|
||||
First;
|
||||
while not Eof do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('TSID').Value := '';
|
||||
Post;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
Order_Sub.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.ZDYHelp(FButn: TcxButtonEdit; LType: string);
|
||||
var
|
||||
FType, ZDYName, FText: string;
|
||||
begin
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.FormShow(Sender: TObject);
|
||||
begin
|
||||
InitData();
|
||||
end;
|
||||
|
||||
function TfrmConLCInPutDC.SaveData(): Boolean;
|
||||
var
|
||||
maxno, submaxno, MAXDCNO: string;
|
||||
begin
|
||||
try
|
||||
ADOCmd.Connection.BeginTrans;
|
||||
///保存主表
|
||||
if Trim(FMainId) = '' then
|
||||
begin
|
||||
if GetLSNo(ADOCmd, maxno, 'DC', 'JYOrderCon_TT', 3, 1) = False then
|
||||
begin
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取最大号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
maxno := Trim(FMainId);
|
||||
end;
|
||||
if (Trim(DCNO.Text) = '系统自动编码') and (FMainId = '') then
|
||||
begin
|
||||
if GetLSNo(ADOCmd, MAXDCNO, 'ZY', 'JYOrderCon_TT', 3, 1) = False then
|
||||
begin
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取最大号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
DCNO.Text := Trim(MAXDCNO);
|
||||
end;
|
||||
|
||||
with ADOCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
SQL.Add('select * from JYOrderCon_TT where TTId=''' + Trim(FMainId) + '''');
|
||||
Open;
|
||||
end;
|
||||
with ADOCmd do
|
||||
begin
|
||||
if Trim(FMainId) = '' then
|
||||
begin
|
||||
Append;
|
||||
fieldbyname('XGCount').Value := 0;
|
||||
fieldbyname('EditFlag').Value := '';
|
||||
fieldbyname('EditNote').Value := '';
|
||||
fieldbyname('EditSQTime').Value := NULL;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Edit;
|
||||
//fieldbyname('XGCount').Value:=fieldbyname('XGCount').AsFloat+1;
|
||||
end;
|
||||
FieldByName('TTId').Value := Trim(maxno);
|
||||
fieldbyname('fillCode').Value := trim(DCode);
|
||||
SSetsaveSqlNew(ADOCmd, 'JYOrderCon_TT', ScrollBox1, 2);
|
||||
if BTDate.Checked = True then
|
||||
begin
|
||||
fieldbyname('BTDate').Value := BTDate.DateTime;
|
||||
end
|
||||
else
|
||||
begin
|
||||
fieldbyname('BTDate').Value := null;
|
||||
end;
|
||||
FieldByName('TTType').Value := 'DC';
|
||||
FieldByName('ChkStatus').Value := '';
|
||||
FieldByName('SChkFlag').Value := 0;
|
||||
if Trim(FMainId) = '' then
|
||||
begin
|
||||
//FieldByName('SKDate').Value:=SGetServerDate(ADOTemp);
|
||||
FieldByName('Filler').Value := Trim(DName);
|
||||
end
|
||||
else
|
||||
begin
|
||||
FieldByName('Editer').Value := Trim(DName);
|
||||
FieldByName('EditTime').Value := SGetServerDateTime(ADOTemp);
|
||||
end;
|
||||
// FieldByName('Note').Value:=Trim(Note.Text);
|
||||
Post;
|
||||
end;
|
||||
|
||||
with Order_Sub do
|
||||
begin
|
||||
First;
|
||||
while not Eof do
|
||||
begin
|
||||
if Trim(Order_Sub.fieldbyname('TSId').AsString) = '' then
|
||||
begin
|
||||
if GetLSNo(ADOCmd, submaxno, 'DTS', 'JYOrderCon_TT_Sub', 4, 1) = False then
|
||||
begin
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取子流水号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
submaxno := Trim(Order_Sub.fieldbyname('TSId').AsString);
|
||||
end;
|
||||
with ADOCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('select * from JYOrderCon_TT_Sub where TSId=''' + Trim(submaxno) + '''');
|
||||
Open;
|
||||
end;
|
||||
with ADOCmd do
|
||||
begin
|
||||
if IsEmpty then
|
||||
Append
|
||||
else
|
||||
Edit;
|
||||
FieldByName('TTId').Value := Trim(maxno);
|
||||
FieldByName('TSId').Value := Trim(submaxno);
|
||||
fieldbyname('BCID').Value := Order_Sub.fieldbyname('BCID').asstring;
|
||||
FieldByName('PRTCodeName').Value := Order_Sub.fieldbyname('PRTCodeName').Value;
|
||||
FieldByName('PRTEngCodeName').Value := Order_Sub.fieldbyname('PRTEngCodeName').Value;
|
||||
FieldByName('OrderUnit').Value := Order_Sub.fieldbyname('OrderUnit').Value;
|
||||
FieldByName('PRTMF').Value := Order_Sub.fieldbyname('PRTMF').Value;
|
||||
FieldByName('PRTKZ').Value := Order_Sub.fieldbyname('PRTKZ').Value;
|
||||
RTSetSaveDataCDS(ADOCmd, Tv1, Order_Sub, 'JYOrderCon_TT_Sub', 0);
|
||||
if Trim(Order_Sub.fieldbyname('PRTOrderQty').AsString) = '' then
|
||||
begin
|
||||
fieldbyname('PRTOrderQty').Value := 0
|
||||
end
|
||||
else
|
||||
begin
|
||||
FieldByName('PRTOrderQty').Value := Order_Sub.fieldbyname('PRTOrderQty').Value;
|
||||
end;
|
||||
if Trim(Order_Sub.fieldbyname('PRTPrice').AsString) = '' then
|
||||
begin
|
||||
fieldbyname('PRTPrice').Value := 0
|
||||
end
|
||||
else
|
||||
begin
|
||||
FieldByName('PRTPrice').Value := Order_Sub.fieldbyname('PRTPrice').Value;
|
||||
end;
|
||||
Post;
|
||||
end;
|
||||
Order_Sub.Edit;
|
||||
Order_Sub.FieldByName('TSId').Value := Trim(submaxno);
|
||||
//Order_Sub.Post;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
with ADOCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrderCon_TT where DCNO=''' + Trim(DCNO.Text) + '''');
|
||||
Sql.Add(' and TTType=''DC''');
|
||||
Open;
|
||||
end;
|
||||
if ADOCmd.RecordCount > 1 then
|
||||
begin
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('订舱编号重复!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
{with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrderCon_TT Set SChkFlag=0,SChkStatus='''' where TTID='''+Trim(maxno)+'''');
|
||||
//sql.add(' delete OrdConDanZH_Chk where MainId='''+Trim(maxno)+'''');
|
||||
ExecSQL;
|
||||
end; }
|
||||
// with ADOCmd do
|
||||
// begin
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// sql.Add('delete from OrdConDanZH_Chk where MainId=''' + Trim(FMainId) + '''');
|
||||
// execsql;
|
||||
// end;
|
||||
ADOCmd.Connection.CommitTrans;
|
||||
FMainId := Trim(maxno);
|
||||
Result := True;
|
||||
except
|
||||
Result := False;
|
||||
ADOCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('保存失败!', '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.TBSaveClick(Sender: TObject);
|
||||
var
|
||||
FReal: Double;
|
||||
begin
|
||||
ToolBar1.SetFocus;
|
||||
|
||||
// if Note.Text = '' then
|
||||
// begin
|
||||
// application.MessageBox('备注不能为空', '提示');
|
||||
// exit;
|
||||
// end;
|
||||
// if FPTaiTou.Text = '' then
|
||||
// begin
|
||||
// application.MessageBox('发货人不能为空', '提示');
|
||||
// exit;
|
||||
// end;
|
||||
if FMainId <> '' then
|
||||
begin
|
||||
with ADOTemp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('select * from JYOrderCon_TT where TTId=''' + Trim(FMainId) + '''');
|
||||
Open;
|
||||
end;
|
||||
if (Trim(ADOTemp.FieldByName('ChkStatus').AsString) = '审核通过') or (Trim(ADOTemp.FieldByName('ChkStatus').AsString) = '单据修改') then
|
||||
begin
|
||||
Application.MessageBox('已审核不能修改!', '提示', 0);
|
||||
Exit;
|
||||
end
|
||||
else if Trim(ADOTemp.FieldByName('ChkStatus').AsString) = '' then
|
||||
begin
|
||||
if ADOTemp.FieldByName('SChkFlag').AsBoolean = True then
|
||||
begin
|
||||
Application.MessageBox('审核中不能修改!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
if SaveData() then
|
||||
begin
|
||||
Application.MessageBox('保存成功!', '提示', 0);
|
||||
Modalresult := 1;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.SKBankBtnDnClick(Sender: TObject);
|
||||
begin
|
||||
TBtnEditC(Sender).Text := '';
|
||||
TBtnEditC(Sender).TxtCode := '';
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
with Order_Sub do
|
||||
begin
|
||||
Append;
|
||||
FieldByName('BZUNIT').value := 'BALES';
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if Trim(Order_Sub.fieldbyname('TSId').AsString) <> '' then
|
||||
begin
|
||||
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
with ADOCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('Delete from JYOrderCon_TT_Sub where TSId=''' + Trim(Order_Sub.fieldbyname('TSId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
Order_Sub.Delete;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.v1Column1PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'SYiDuanZ';
|
||||
flagname := '溢短装';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
Self.Order_Sub.Edit;
|
||||
Self.Order_Sub.FieldByName('SYiDuanZ').Value := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.Label36DblClick(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmZDYHelpSel := TfrmZDYHelpSel.Create(Application);
|
||||
with frmZDYHelpSel do
|
||||
begin
|
||||
flag := 'LbNameNote';
|
||||
flagname := '标签内容';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
ClientDataSet1.DisableControls;
|
||||
with ClientDataSet1 do
|
||||
begin
|
||||
First;
|
||||
while not Eof do
|
||||
begin
|
||||
if ClientDataSet1.FieldByName('SSel').AsBoolean = True then
|
||||
begin
|
||||
if Trim(Self.ZhuMaiTou.Text) = '' then
|
||||
begin
|
||||
Self.ZhuMaiTou.Text := Trim(ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end
|
||||
else
|
||||
begin
|
||||
Self.ZhuMaiTou.Text := Self.ZhuMaiTou.Text + #13 + Trim(ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
ClientDataSet1.EnableControls;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if Order_Sub.IsEmpty then
|
||||
Exit;
|
||||
CopyAddRowCDS(Order_Sub);
|
||||
with Order_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('TSID').Value := null;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.Label29DblClick(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'TDShouHuoPerson';
|
||||
flagname := '提单收货人';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TDShouHuoPerson.Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.Label3DblClick(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'TDTongZhiPerson';
|
||||
flagname := '提单通知人';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TDTongZhiPerson.Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.XYZNOBtnUpClick(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(DParameters1) <> '高权限' then
|
||||
begin
|
||||
TBAdd.Visible := false;
|
||||
TBDel.Visible := false;
|
||||
TBEdit.Visible := false;
|
||||
TBSave.Visible := false;
|
||||
end;
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.OrdConPrcNoteBtnUpClick(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 flag = 'TOCOUNTRY' then
|
||||
begin
|
||||
fnote := True;
|
||||
V1Note.Caption := '中文名称';
|
||||
V1Name.Caption := '英文名称';
|
||||
end
|
||||
else
|
||||
begin
|
||||
fnote := false;
|
||||
end;
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
if (OrdConPrcNote.Text = 'FOB') or (OrdConPrcNote.Text = 'FCA') then
|
||||
begin
|
||||
YFCF.Text := 'FREIGHT COLLECT';
|
||||
|
||||
end
|
||||
else if (OrdConPrcNote.Text = 'CIF') or (OrdConPrcNote.Text = 'CFR') then
|
||||
begin
|
||||
YFCF.Text := 'FREIGHT PREPAID';
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.TOPlaceBtnUpClick(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 flag = 'TOCOUNTRY' then
|
||||
begin
|
||||
fnote := True;
|
||||
V1Note.Caption := '中文名称';
|
||||
V1Name.Caption := '英文名称';
|
||||
end
|
||||
else
|
||||
begin
|
||||
fnote := false;
|
||||
end;
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.KHNameBtnUpClick(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmZdyAttachment := TfrmZdyAttachment.Create(Application);
|
||||
with frmZdyAttachment do
|
||||
begin
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
self.KHName.TxtCode := Trim(CDS_HZ.fieldbyname('CoCode').AsString);
|
||||
self.KHName.Text := Trim(CDS_HZ.fieldbyname('CoName').AsString);
|
||||
|
||||
TDShouHuoPerson.Text := Trim(CDS_HZ.fieldbyname('CoName').AsString) + #$d#$a + (StringReplace(CDS_HZ.fieldbyname('CoAddress').AsString, ' ', #$d#$a, [rfReplaceAll]));
|
||||
TDTongZhiPerson.Text := Trim(CDS_HZ.fieldbyname('CoName').AsString) + #$d#$a + (StringReplace(CDS_HZ.fieldbyname('CoAddress').AsString, ' ', #$d#$a, [rfReplaceAll]));
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZdyAttachment.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.ToolButton2Click(Sender: TObject);
|
||||
begin
|
||||
frmProductOrderList_Sel := TfrmProductOrderList_Sel.Create(self);
|
||||
with frmProductOrderList_Sel do
|
||||
begin
|
||||
if showmodal = 1 then
|
||||
begin
|
||||
while frmProductOrderList_Sel.Order_Main.Locate('SSel', True, []) do
|
||||
begin
|
||||
Self.Order_Sub.Append;
|
||||
|
||||
Self.Order_Sub.FieldbyName('PRTPrice').Value := 0;
|
||||
Self.Order_Sub.FieldbyName('Money').Value := 0;
|
||||
Self.Order_Sub.fieldbyname('FromOrderno').Value := Order_Main.fieldbyname('Orderno').asstring;
|
||||
Self.Order_Sub.fieldbyname('FromMainId').Value := Order_Main.fieldbyname('MainId').asstring;
|
||||
Self.Order_Sub.fieldbyname('PRTCODE').Value := Order_Main.fieldbyname('MPRTCODE').asstring;
|
||||
Self.Order_Sub.fieldbyname('PRTCODENAME').Value := Order_Main.fieldbyname('MPRTCODENAME').asstring;
|
||||
Self.Order_Sub.fieldbyname('PRTMF').Value := Order_Main.fieldbyname('MPRTMF').asstring;
|
||||
Self.Order_Sub.fieldbyname('PRTKZ').Value := Order_Main.fieldbyname('MPRTKZ').asstring;
|
||||
Self.Order_Sub.fieldbyname('PRTCF').Value := Order_Main.fieldbyname('MPRTCF').asstring;
|
||||
Self.Order_Sub.fieldbyname('PRTORDERQTY').Value := Order_Main.fieldbyname('PRTORDERQTY').ASFLOAT;
|
||||
Self.Order_Sub.FieldByName('BZUNIT').value := 'BALES';
|
||||
Self.Order_Sub.Post;
|
||||
frmProductOrderList_Sel.Order_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.v1Column15PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
// fsj := Trim(TEdit(Sender).Hint);
|
||||
// FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'BZUNIT';
|
||||
flagname := '包装单位';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Order_Sub do
|
||||
begin
|
||||
Edit;
|
||||
Order_Sub.fieldbyname('BZUNIT').Value := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.v1Column8PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'PRICEBZ';
|
||||
flagname := '币种';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Order_Sub do
|
||||
begin
|
||||
Edit;
|
||||
Order_Sub.fieldbyname('PRICEBZ').Value := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.DZYDropDown(Sender: TObject);
|
||||
begin
|
||||
with ADOTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('SELECT * FROM SY_User WHERE Udept LIKE ''%单证%'' ');
|
||||
|
||||
Open;
|
||||
end;
|
||||
DZY.Items.Clear;
|
||||
while not ADOTemp.eof do
|
||||
begin
|
||||
DZY.Items.Add(Trim(ADOTemp.fieldbyname('username').AsString));
|
||||
ADOTemp.next;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.YWYDropDown(Sender: TObject);
|
||||
begin
|
||||
with ADOTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from KH_ZDY where type=''jhdywy'' ');
|
||||
|
||||
Open;
|
||||
end;
|
||||
YWY.Items.Clear;
|
||||
while not ADOTemp.eof do
|
||||
begin
|
||||
YWY.Items.Add(Trim(ADOTemp.fieldbyname('zdyname').AsString));
|
||||
ADOTemp.next;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.BGYDropDown(Sender: TObject);
|
||||
begin
|
||||
with ADOTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('SELECT * FROM SY_User WHERE Udept LIKE ''%单证%'' ');
|
||||
|
||||
Open;
|
||||
end;
|
||||
BGY.Items.Clear;
|
||||
while not ADOTemp.eof do
|
||||
begin
|
||||
BGY.Items.Add(Trim(ADOTemp.fieldbyname('username').AsString));
|
||||
ADOTemp.next;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmConLCInPutDC.v1Column1PropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
mvalue, FFieldName: string;
|
||||
FQuantity, FUnitPrice, FCourierCharge: double;
|
||||
begin
|
||||
if TcxTextEdit(Sender).EditingText = '' then
|
||||
begin
|
||||
mvalue := '0';
|
||||
end
|
||||
else
|
||||
mvalue := TcxTextEdit(Sender).EditingText;
|
||||
FFieldName := Trim(Tv1.Controller.FocusedColumn.DataBinding.FilterFieldName);
|
||||
with Order_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName(FFieldName).Value := Trim(mvalue);
|
||||
Post;
|
||||
|
||||
FQuantity := FieldByName('PRTOrderQty').asfloat;
|
||||
FUnitPrice := FieldByName('PRTPrice').asfloat;
|
||||
end;
|
||||
|
||||
with Order_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('MONEY').Value := (FQuantity * FUnitPrice);
|
||||
Post;
|
||||
end;
|
||||
|
||||
tv1.Controller.EditingController.ShowEdit();
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -1,536 +0,0 @@
|
|||
object frmDCDList_Sel: TfrmDCDList_Sel
|
||||
Left = 195
|
||||
Top = 125
|
||||
Width = 1121
|
||||
Height = 593
|
||||
Caption = #35746#33329#21333#36873#25321
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1105
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object ToolButton3: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36873#25321
|
||||
ImageIndex = 31
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1105
|
||||
Height = 77
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 23
|
||||
Top = 18
|
||||
Width = 52
|
||||
Height = 12
|
||||
Caption = #26597#35810#26085#26399
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 176
|
||||
Top = 45
|
||||
Width = 52
|
||||
Height = 12
|
||||
Caption = #25351#31034#21333#21495
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 176
|
||||
Top = 18
|
||||
Width = 52
|
||||
Height = 12
|
||||
Caption = #35746#33329#21333#21495
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 328
|
||||
Top = 45
|
||||
Width = 39
|
||||
Height = 12
|
||||
Caption = #30446#30340#28207
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 341
|
||||
Top = 18
|
||||
Width = 26
|
||||
Height = 12
|
||||
Caption = #23458#25143
|
||||
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 = 14
|
||||
Width = 85
|
||||
Height = 20
|
||||
Date = 40675.464742650460000000
|
||||
Format = 'yyyy-MM-dd'
|
||||
Time = 40675.464742650460000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 76
|
||||
Top = 40
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40675.464761099540000000
|
||||
Format = 'yyyy-MM-dd'
|
||||
Time = 40675.464761099540000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object zorderno: TEdit
|
||||
Tag = 2
|
||||
Left = 230
|
||||
Top = 40
|
||||
Width = 83
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = DCNOChange
|
||||
OnKeyPress = DCNOKeyPress
|
||||
end
|
||||
object DCNO: TEdit
|
||||
Tag = 2
|
||||
Left = 231
|
||||
Top = 14
|
||||
Width = 81
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = DCNOChange
|
||||
OnKeyPress = DCNOKeyPress
|
||||
end
|
||||
object TOPlace: TEdit
|
||||
Tag = 2
|
||||
Left = 371
|
||||
Top = 40
|
||||
Width = 83
|
||||
Height = 20
|
||||
TabOrder = 4
|
||||
OnChange = DCNOChange
|
||||
OnKeyPress = DCNOKeyPress
|
||||
end
|
||||
object KHName: TEdit
|
||||
Tag = 2
|
||||
Left = 372
|
||||
Top = 14
|
||||
Width = 81
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = DCNOChange
|
||||
OnKeyPress = DCNOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 109
|
||||
Width = 1105
|
||||
Height = 445
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
PopupMenu = PopupMenu1
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 44
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #35746#33329
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1ConNo: TcxGridDBColumn
|
||||
Caption = #25253#20851
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 73
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #35746#33329#21333#32534#21495
|
||||
DataBinding.FieldName = 'DCNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Focusing = False
|
||||
Width = 91
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #20844#21496
|
||||
DataBinding.FieldName = 'GSNAME'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Focusing = False
|
||||
Width = 71
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Caption = #20986#36816#26085#26399
|
||||
DataBinding.FieldName = 'CYDATE'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Focusing = False
|
||||
Width = 67
|
||||
end
|
||||
object v1Column21: TcxGridDBColumn
|
||||
Caption = #21457#31080#21495#30721
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Focusing = False
|
||||
Width = 90
|
||||
end
|
||||
object v1OrdPerson1: TcxGridDBColumn
|
||||
Caption = #25351#31034#21333#21495
|
||||
DataBinding.FieldName = 'ZORDERNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 78
|
||||
end
|
||||
object v1CustomerNoName: TcxGridDBColumn
|
||||
Caption = #23458#25143
|
||||
DataBinding.FieldName = 'KHName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 76
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #35013#36816#28207
|
||||
DataBinding.FieldName = 'FromPlace'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 74
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #30446#30340#28207
|
||||
DataBinding.FieldName = 'TOPlace'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 72
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #36135#20195
|
||||
DataBinding.FieldName = 'HDName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 91
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #33337#20844#21496
|
||||
DataBinding.FieldName = 'ChuanInfo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #35013#31665#20449#24687
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 92
|
||||
end
|
||||
object v1Column17: TcxGridDBColumn
|
||||
Caption = #24635#25968#37327
|
||||
DataBinding.FieldName = 'ZQTY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 73
|
||||
end
|
||||
object v1Column18: TcxGridDBColumn
|
||||
Caption = #24635#37329#39069
|
||||
DataBinding.FieldName = 'ZMONEY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 63
|
||||
end
|
||||
object v1Column19: TcxGridDBColumn
|
||||
Caption = #24635#25910#36141#37329#39069
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 106
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Caption = #24635#27611#37325
|
||||
DataBinding.FieldName = 'ZMAOZHONG'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 75
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #24635#20928#37325
|
||||
DataBinding.FieldName = 'ZJINGZHONG'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Focusing = False
|
||||
Width = 61
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #24635#20307#31215
|
||||
DataBinding.FieldName = 'ZTIJI'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 103
|
||||
end
|
||||
object v1FKPayment: TcxGridDBColumn
|
||||
Caption = #24635#20214#25968
|
||||
DataBinding.FieldName = 'ZBZJS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1YJDCDate: TcxGridDBColumn
|
||||
Caption = #22791#22949#26085#26399
|
||||
DataBinding.FieldName = 'BTDATE'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 87
|
||||
end
|
||||
object v1YJSHDate: TcxGridDBColumn
|
||||
Caption = #36816#36153#25215#20184
|
||||
DataBinding.FieldName = 'YFCF'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Focusing = False
|
||||
Width = 84
|
||||
end
|
||||
object v1EditNote: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'YSFS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1EditSQTime: TcxGridDBColumn
|
||||
Caption = #21046#21333#26085#26399
|
||||
DataBinding.FieldName = 'FILLTIME'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.SaveTime = False
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1LCChuanQ: TcxGridDBColumn
|
||||
Caption = #21046#21333#20154
|
||||
DataBinding.FieldName = 'FILLER'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object v1YiDuanZ: TcxGridDBColumn
|
||||
Caption = #19979#19968#27493#25805#20316#21592
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 83
|
||||
end
|
||||
object v1LCQty: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'NOTE'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 500
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 544
|
||||
Top = 176
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 576
|
||||
Top = 280
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 552
|
||||
Top = 216
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 312
|
||||
Top = 248
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = Order_Main
|
||||
Left = 440
|
||||
Top = 184
|
||||
end
|
||||
object Order_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 464
|
||||
Top = 208
|
||||
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
|
||||
object RMDBMain: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 392
|
||||
Top = 200
|
||||
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 = 528
|
||||
Top = 280
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 288
|
||||
Top = 184
|
||||
object N2: TMenuItem
|
||||
Caption = #26377#20379#24212#21830
|
||||
end
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 360
|
||||
Top = 240
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 344
|
||||
Top = 288
|
||||
end
|
||||
end
|
||||
|
|
@ -1,240 +0,0 @@
|
|||
unit U_DCDList_Sel;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, StdCtrls, ExtCtrls, ComCtrls, ToolWin, cxStyles, cxCustomData,
|
||||
cxGraphics, cxFilter, cxData, cxDataStorage, cxEdit, DB, cxDBData, ADODB,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxClasses, cxControls,
|
||||
cxGridCustomView, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||
cxGrid, DBClient, cxCheckBox, cxCalendar, cxSplitter, RM_Dataset, RM_System,
|
||||
RM_Common, RM_Class, RM_GridReport, RM_e_Xls, Menus, cxLookAndFeels,
|
||||
cxLookAndFeelPainters, cxNavigator;
|
||||
|
||||
type
|
||||
TfrmDCDList_Sel = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
Order_Main: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBMain: TRMDBDataSet;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N2: TMenuItem;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
CDS_Print: TClientDataSet;
|
||||
ToolButton3: TToolButton;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v1ConNo: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
v1Column21: TcxGridDBColumn;
|
||||
v1OrdPerson1: TcxGridDBColumn;
|
||||
v1CustomerNoName: TcxGridDBColumn;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
v1Column17: TcxGridDBColumn;
|
||||
v1Column18: TcxGridDBColumn;
|
||||
v1Column19: TcxGridDBColumn;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
v1FKPayment: TcxGridDBColumn;
|
||||
v1YJDCDate: TcxGridDBColumn;
|
||||
v1YJSHDate: TcxGridDBColumn;
|
||||
v1EditNote: TcxGridDBColumn;
|
||||
v1EditSQTime: TcxGridDBColumn;
|
||||
v1LCChuanQ: TcxGridDBColumn;
|
||||
v1YiDuanZ: TcxGridDBColumn;
|
||||
v1LCQty: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
Label1: TLabel;
|
||||
Label4: TLabel;
|
||||
Label2: TLabel;
|
||||
Label3: TLabel;
|
||||
Label5: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
zorderno: TEdit;
|
||||
DCNO: TEdit;
|
||||
TOPlace: TEdit;
|
||||
KHName: TEdit;
|
||||
ToolButton1: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
procedure OrderNoKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure DCNOChange(Sender: TObject);
|
||||
procedure DCNOKeyPress(Sender: TObject; var Key: Char);
|
||||
private
|
||||
DQdate: TDateTime;
|
||||
procedure InitGrid();
|
||||
procedure InitForm();
|
||||
{ Private declarations }
|
||||
public
|
||||
FFInt, FCloth: Integer;
|
||||
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmDCDList_Sel: TfrmDCDList_Sel;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_Fun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmDCDList_Sel.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmDCDList_Sel := nil;
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.FormCreate(Sender: TObject);
|
||||
begin
|
||||
cxgrid1.Align := alClient;
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
WriteCxGrid('指示单列表选择', Tv1, '生产指示单管理');
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.InitGrid();
|
||||
begin
|
||||
// if Length(Trim(self.ConNO.Text)) < 3 then
|
||||
// Exit;
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select ');
|
||||
sql.Add('A.*');
|
||||
SQL.Add(',GSNAME=''振永纺织''');
|
||||
SQL.Add(',ZORDERNO=CAST((SELECT STUFF(( SELECT '','' +convert(VARCHAR, FROMORDERNO) FROM JYOrderCon_TT_Sub B WHERE A.TTID=B.TTId FOR XML PATH('''')), 1, 1, '''') )AS VARCHAR)');
|
||||
SQL.Add(',ZQTY=(SELECT SUM(PRTORDERQTY) FROM JYOrderCon_TT_Sub C WHERE A.TTID=C.TTId)');
|
||||
SQL.Add(',ZMONEY=(SELECT SUM(MONEY) FROM JYOrderCon_TT_Sub C WHERE A.TTID=C.TTId)');
|
||||
SQL.Add(',ZMAOZHONG=(SELECT SUM(MAOZHONG) FROM JYOrderCon_TT_Sub C WHERE A.TTID=C.TTId)');
|
||||
SQL.Add(',ZJINGZHONG=(SELECT SUM(JINGZHONG) FROM JYOrderCon_TT_Sub C WHERE A.TTID=C.TTId)');
|
||||
SQL.Add(',ZTIJI=(SELECT SUM(tiji) FROM JYOrderCon_TT_Sub C WHERE A.TTID=C.TTId)');
|
||||
SQL.Add(',ZBZJS=(SELECT SUM(BZJS) FROM JYOrderCon_TT_Sub C WHERE A.TTID=C.TTId)');
|
||||
sql.Add(' from JYOrderCon_TT A ');
|
||||
SQL.Add('where ((FILLTIME>=''' + FormatDateTime('yyyy-MM-dd', BegDate.DateTime) + '''');
|
||||
SQL.Add('and FILLTIME<''' + FormatDateTime('yyyy-MM-dd', enddate.DateTime + 1) + ''') or ChkStatus=''审核不通过'') ');
|
||||
|
||||
if DCNO.Text <> '' then
|
||||
begin
|
||||
SQL.Add('AND dcno like' + quotedstr('%' + trim(DCNO.text) + '%'));
|
||||
end;
|
||||
if KHName.Text <> '' then
|
||||
begin
|
||||
SQL.Add('AND KHName like' + quotedstr('%' + trim(KHName.text) + '%'));
|
||||
end;
|
||||
if zorderno.Text <> '' then
|
||||
begin
|
||||
SQL.Add('AND CAST((SELECT STUFF(( SELECT '','' +convert(VARCHAR, FROMORDERNO) FROM JYOrderCon_TT_Sub B WHERE A.TTID=B.TTId FOR XML PATH('''')), 1, 1, '''') )AS VARCHAR) like' + quotedstr('%' + trim(zorderno.text) + '%'));
|
||||
end;
|
||||
if TOPlace.Text <> '' then
|
||||
begin
|
||||
SQL.Add('AND TOPlace like' + quotedstr('%' + trim(TOPlace.text) + '%'));
|
||||
end;
|
||||
// else if cxTabControl1.TabIndex = 1 then
|
||||
// begin
|
||||
// SQL.Add('AND ISNULL(SChkFlag,0)=1 AND ISNULL(ChkStatus,0)=0 ');
|
||||
// end
|
||||
// else if cxTabControl1.TabIndex = 2 then
|
||||
// begin
|
||||
// SQL.Add(' AND ChkStatus=1 ');
|
||||
// end;
|
||||
//ShowMessage(SQL.Text);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.InitForm();
|
||||
begin
|
||||
BegDate.DateTime := SGetServerDate10(ADOQueryTemp) - 90;
|
||||
EndDate.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||
ReadCxGrid('指示单列表选择', Tv1, '生产指示单管理');
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.FormShow(Sender: TObject);
|
||||
begin
|
||||
InitForm();
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.ToolButton3Click(Sender: TObject);
|
||||
begin
|
||||
ModalResult := 1;
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.OrderNoKeyPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.DCNOChange(Sender: TObject);
|
||||
begin
|
||||
|
||||
// InitGrid();
|
||||
// if ADOQueryMain.Active then
|
||||
// begin
|
||||
// SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
// SCreateCDS20(ADOQueryMain, Order_Main);
|
||||
// SInitCDSData20(ADOQueryMain, Order_Main);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmDCDList_Sel.DCNOKeyPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,72 +0,0 @@
|
|||
unit U_DataLink;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
SysUtils, Classes, DB, ADODB, ImgList, Controls, cxStyles, cxLookAndFeels,
|
||||
Windows,Messages,forms,OleCtnrs,DateUtils, cxClasses, dxSkinsCore,
|
||||
dxSkinsDefaultPainters;
|
||||
var
|
||||
DConString:String; {全局连接字符串}
|
||||
server, dtbase, user, pswd: String; {数据库连接参数}
|
||||
DCurHandle:hwnd; //当前窗体句柄
|
||||
DName:string ; //#用户名#//
|
||||
DCode:string ; //#用户编号#//
|
||||
PicSvr:string;
|
||||
Ddatabase:string; //#数据库名称#//
|
||||
DTitCaption: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
|
||||
TDataLink_DDMD = class(TDataModule)
|
||||
AdoDataLink: TADOQuery;
|
||||
ADOLink: TADOConnection;
|
||||
ThreeImgList: TImageList;
|
||||
ThreeLookAndFeelCol: TcxLookAndFeelController;
|
||||
ThreeColorBase: TcxStyleRepository;
|
||||
SHuangSe: TcxStyle;
|
||||
SkyBlue: TcxStyle;
|
||||
Default: TcxStyle;
|
||||
QHuangSe: TcxStyle;
|
||||
Red: TcxStyle;
|
||||
FontBlue: TcxStyle;
|
||||
TextSHuangSe: TcxStyle;
|
||||
FonePurple: TcxStyle;
|
||||
FoneClMaroon: TcxStyle;
|
||||
FoneRed: TcxStyle;
|
||||
RowColor: TcxStyle;
|
||||
handBlack: TcxStyle;
|
||||
cxBlue: TcxStyle;
|
||||
SHuangSeCu: TcxStyle;
|
||||
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
|
||||
DataLink_DDMD: TDataLink_DDMD;
|
||||
|
||||
implementation
|
||||
{$R *.dfm}
|
||||
|
||||
|
||||
procedure TDataLink_DDMD.DataModuleDestroy(Sender: TObject);
|
||||
begin
|
||||
DataLink_DDMD:=nil;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -1,188 +0,0 @@
|
|||
object frmFileUp: TfrmFileUp
|
||||
Left = 247
|
||||
Top = 162
|
||||
Width = 634
|
||||
Height = 447
|
||||
Caption = #19978#20256#25991#20214
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
OnCreate = FormCreate
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object cxGrid7: TcxGrid
|
||||
Left = 0
|
||||
Top = 41
|
||||
Width = 555
|
||||
Height = 367
|
||||
Align = alClient
|
||||
TabOrder = 0
|
||||
object TV7: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsBehavior.FocusCellOnCycle = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsData.Editing = False
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.Indicator = True
|
||||
object FileName: TcxGridDBColumn
|
||||
Tag = 1
|
||||
Caption = #25991#20214#21517#31216
|
||||
DataBinding.FieldName = 'FileName'
|
||||
FooterAlignmentHorz = taCenter
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 121
|
||||
end
|
||||
object FileDate: TcxGridDBColumn
|
||||
Tag = 1
|
||||
Caption = #19978#20256#26085#26399
|
||||
DataBinding.FieldName = 'FileDate'
|
||||
FooterAlignmentHorz = taCenter
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 104
|
||||
end
|
||||
end
|
||||
object cxGridLevel6: TcxGridLevel
|
||||
GridView = TV7
|
||||
end
|
||||
end
|
||||
object Panel16: TPanel
|
||||
Left = 190
|
||||
Top = 126
|
||||
Width = 138
|
||||
Height = 30
|
||||
BevelInner = bvRaised
|
||||
Caption = #27491#22312#19978#20256#12290#12290#12290
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
Visible = False
|
||||
end
|
||||
object ToolBar6: TToolBar
|
||||
Left = 555
|
||||
Top = 41
|
||||
Width = 63
|
||||
Height = 367
|
||||
Align = alRight
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Flat = True
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ShowCaptions = True
|
||||
TabOrder = 2
|
||||
object FileUp: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #19978#20256
|
||||
ImageIndex = 109
|
||||
Wrap = True
|
||||
OnClick = FileUpClick
|
||||
end
|
||||
object FileDel: TToolButton
|
||||
Left = 0
|
||||
Top = 30
|
||||
AutoSize = True
|
||||
Caption = #21024#38500
|
||||
ImageIndex = 17
|
||||
Wrap = True
|
||||
OnClick = FileDelClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 618
|
||||
Height = 41
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
TabOrder = 3
|
||||
object Label1: TLabel
|
||||
Left = 8
|
||||
Top = 14
|
||||
Width = 68
|
||||
Height = 16
|
||||
Caption = #20135#21697#32534#21495
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -16
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Image2: TImage
|
||||
Left = 537
|
||||
Top = 17
|
||||
Width = 23
|
||||
Height = 16
|
||||
end
|
||||
object Code: TEdit
|
||||
Left = 78
|
||||
Top = 9
|
||||
Width = 211
|
||||
Height = 24
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -16
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
ReadOnly = True
|
||||
TabOrder = 0
|
||||
end
|
||||
end
|
||||
object ODPat: TOpenDialog
|
||||
Options = [ofReadOnly, ofAllowMultiSelect, ofPathMustExist, ofFileMustExist, ofEnableSizing]
|
||||
Left = 404
|
||||
Top = 197
|
||||
end
|
||||
object IdFTP1: TIdFTP
|
||||
MaxLineAction = maException
|
||||
ReadTimeout = 0
|
||||
ProxySettings.ProxyType = fpcmNone
|
||||
ProxySettings.Port = 0
|
||||
Left = 405
|
||||
Top = 236
|
||||
end
|
||||
object SaveDialog1: TSaveDialog
|
||||
Left = 409
|
||||
Top = 285
|
||||
end
|
||||
object ADOQueryFile: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 488
|
||||
Top = 144
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = ADOQueryFile
|
||||
Left = 392
|
||||
Top = 168
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 496
|
||||
Top = 216
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 504
|
||||
Top = 264
|
||||
end
|
||||
end
|
||||
|
|
@ -1,357 +0,0 @@
|
|||
unit U_FileUp;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, ComCtrls, ToolWin, ExtCtrls,
|
||||
cxGridLevel, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||
cxClasses, cxControls, cxGridCustomView, cxGrid, IdBaseComponent,
|
||||
IdComponent, IdTCPConnection, IdTCPClient, IdFTP, StdCtrls, ADODB,jpeg,
|
||||
BtnEdit,IniFiles;
|
||||
|
||||
type
|
||||
TfrmFileUp = class(TForm)
|
||||
cxGrid7: TcxGrid;
|
||||
TV7: TcxGridDBTableView;
|
||||
FileName: TcxGridDBColumn;
|
||||
FileDate: TcxGridDBColumn;
|
||||
cxGridLevel6: TcxGridLevel;
|
||||
Panel16: TPanel;
|
||||
ToolBar6: TToolBar;
|
||||
FileUp: TToolButton;
|
||||
FileDel: TToolButton;
|
||||
Panel1: TPanel;
|
||||
Label1: TLabel;
|
||||
Code: TEdit;
|
||||
ODPat: TOpenDialog;
|
||||
IdFTP1: TIdFTP;
|
||||
SaveDialog1: TSaveDialog;
|
||||
ADOQueryFile: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
Image2: TImage;
|
||||
procedure FileUpClick(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure FileDelClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
private
|
||||
lstPat: TStringList;
|
||||
AJpeg: TJPEGImage;
|
||||
procedure CreThumb(AJPeg:TJPEGImage;Image1:TImage;Width, Height: Integer);
|
||||
procedure SaveImageOther();
|
||||
procedure ReadINIFile10();
|
||||
{ Private declarations }
|
||||
public
|
||||
CYID:String;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmFileUp: TfrmFileUp;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmFileUp.ReadINIFile10();
|
||||
var
|
||||
programIni:Tinifile; //配置文件名
|
||||
FileName:string;
|
||||
begin
|
||||
FileName:=ExtractFilePath(Paramstr(0))+'SYSTEMSET.INI';
|
||||
programIni:=Tinifile.create(FileName);
|
||||
server:=programIni.ReadString('SERVER','服务器地址','127.0.0.1');
|
||||
programIni.Free;
|
||||
end;
|
||||
procedure TfrmFileUp.FileUpClick(Sender: TObject);
|
||||
var
|
||||
i,j: Integer;
|
||||
PatFile: String;
|
||||
FTPPath,FConNo,MaxNo:string;
|
||||
AJpeg: TJPEGImage;
|
||||
begin
|
||||
if Trim(Code.Text)='' then
|
||||
begin
|
||||
Application.MessageBox('编号不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
lstPat.Clear;
|
||||
if ODPat.Execute then
|
||||
begin
|
||||
lstPat.AddStrings(ODPat.Files);
|
||||
end;
|
||||
|
||||
if lstPat.Count > 0 then
|
||||
begin
|
||||
try
|
||||
ReadINIFile10();
|
||||
server:=ReadINIFileStr('SYSTEMSET.INI','SERVER','服务器地址','127.0.0.1');
|
||||
IdFTP1.Host :=server;//PicSvr;
|
||||
IdFTP1.Username := 'three';
|
||||
IdFTP1.Password := '641010';
|
||||
IdFTP1.Connect();
|
||||
except
|
||||
IdFTP1.Quit;
|
||||
Application.MessageBox('无法连接到文件服务器,请检查!', '提示', MB_ICONWARNING);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
Panel16.Visible:=True;
|
||||
Panel16.Refresh;
|
||||
AJpeg:=TJpegImage.Create();
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select Count(*) MM from XD_File where CYID='''+Trim(CYID)+'''');
|
||||
SQL.Add('and filetype=''YP''');
|
||||
Open;
|
||||
j:=fieldbyname('MM').AsInteger;
|
||||
end;
|
||||
Image2.Picture.LoadFromFile(ODPat.FileName);
|
||||
AJpeg.Assign(Image2.Picture.Graphic);
|
||||
CreThumb(AJpeg,Image2,216, 187);
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
for i := 0 to lstPat.Count - 1 do
|
||||
begin
|
||||
PatFile := ExtractFileName(lstPat[i]);
|
||||
PatFile:=Copy(PatFile,(Pos('.',PatFile)+1),(Length(PatFile)-Pos('.',PatFile)) ) ;
|
||||
FConNo:=Trim(Code.Text);
|
||||
while Pos('/',FConNo)>0 do
|
||||
begin
|
||||
Delete(FConNo,Pos('/',FConNo),1);
|
||||
end;
|
||||
PatFile:=Trim(FConNo)+'-'+Inttostr(j+i+1)+'.'+PatFile;
|
||||
if IdFTP1.Connected then
|
||||
begin
|
||||
try
|
||||
{if not DirectoryExists('D:\图片\'+Trim(gDef1)) then
|
||||
ForceDirectories('D:\图片\'+Trim(gDef1)); }
|
||||
IdFTP1.Put(lstPat[i], Trim('\YP')+'\'+Trim(PatFile));
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select * from XD_File where CYID='''+Trim(CYID)+'''');
|
||||
SQL.Add(' and filename='''+Trim(PatFile)+'''');
|
||||
SQL.Add(' and filetype=''YP''');
|
||||
Open;
|
||||
if not IsEmpty then
|
||||
begin
|
||||
Panel16.Visible:=False;
|
||||
Application.MessageBox(PChar('文件<'+Trim(PatFile)+'>重复,'+inttostr(i)+'个文件上传成功!'),'提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
if GetLSNo(ADOQueryCmd,MaxNo,'YP','XD_File',4,1)=False then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取图片最大号失败!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select * from XD_File where 1<>1');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Append;
|
||||
FieldByName('XFID').Value:=Trim(MaxNo);
|
||||
FieldByName('CYID').Value:=Trim(CYID);
|
||||
FieldByName('CYNO').Value:=Trim(Code.Text);
|
||||
FieldByName('filename').Value:=Trim(PatFile);
|
||||
FieldByName('FileDate').Value:=SGetServerDate(ADOQueryTemp);
|
||||
fieldbyname('FileType').value:=Trim('YP');
|
||||
Post;
|
||||
end;
|
||||
except
|
||||
//ADOQueryCmd.Connection.RollbackTrans;
|
||||
//Application.MessageBox('图片上传失败!','提示',0);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update CP_YDang Set TPFlag=1 where CYID='''+Trim(CYID)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
SaveImageOther();
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('图片上传失败!','提示',0);
|
||||
end;
|
||||
if IdFTP1.Connected then IdFTP1.Quit;
|
||||
with ADOQueryFile do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select * from XD_File where CYID='''+Trim(CYID)+'''');
|
||||
open;
|
||||
end;
|
||||
Panel16.Visible:=False;
|
||||
if i>0 then
|
||||
Application.MessageBox(PChar(inttostr(i)+'个文件上传成功!'),'提示',0);
|
||||
ModalResult:=1;
|
||||
end;
|
||||
procedure TfrmFileUp.CreThumb(AJPeg:TJPEGImage;Image1:TImage;Width, Height: Integer);
|
||||
var
|
||||
Bitmap: TBitmap;
|
||||
Ratio: Double;
|
||||
ARect: TRect;
|
||||
AHeight, AHeightOffset: Integer;
|
||||
AWidth, AWidthOffset: Integer;
|
||||
begin
|
||||
Bitmap := TBitmap.Create;
|
||||
try
|
||||
Ratio := AJPeg.Width /AJPeg.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));
|
||||
ARect := Rect(AWidthOffset, AHeightOffset, AWidth + AWidthOffset, AHeight + AHeightOffset);
|
||||
Bitmap.Canvas.StretchDraw(ARect, AJPeg);
|
||||
Image1.Picture.Assign(BitMap);
|
||||
finally
|
||||
Bitmap.Free;
|
||||
end;
|
||||
end;
|
||||
procedure TfrmFileUp.SaveImageOther();
|
||||
var
|
||||
AJpeg: TJPEGImage;
|
||||
myStream: TADOBlobStream;
|
||||
ImgMaxNo:String;
|
||||
i,j: Integer;
|
||||
PatFile: String;
|
||||
FTPPath,FConNo,MaxNo,FTFID:string;
|
||||
begin
|
||||
if Image2.Picture=nil then Exit;
|
||||
AJpeg:=TJpegImage.Create();
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from TP_File where WBID='''+Trim(CYID)+'''');
|
||||
Open;
|
||||
end;
|
||||
FTFID:=Trim(ADOQueryTemp.fieldbyname('TFID').AsString);
|
||||
if Trim(FTFID)='' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryCmd,ImgMaxNo,'TF','TP_File',3,1)=False then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取图片表最大号失败!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
ImgMaxNo:=Trim(FTFID);
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add( ' select * from TP_File where TFID='''+Trim(FTFID)+'''');
|
||||
open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
if Trim(FTFID)='' then
|
||||
begin
|
||||
Append;
|
||||
FieldByName('Filler').Value:=Trim(DName);
|
||||
end
|
||||
else
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('Editer').Value:=Trim(DName);
|
||||
FieldByName('EditTime').Value:=SGetServerDateTime(ADOQueryTemp);
|
||||
end;
|
||||
FieldByName('TFID').Value:=Trim(ImgMaxNo);
|
||||
FieldByName('WBID').Value:=Trim(CYID);
|
||||
//FieldByName('TFIdx').Value:=cxTabControl2.TabIndex;
|
||||
FieldByName('TFType').Value:='样品';
|
||||
AJpeg.Assign(Image2.Picture.Graphic);
|
||||
//CreThumb(AJpeg,Image1,160, 120);
|
||||
myStream := TADOBlobStream.Create(TBlobField(ADOQueryCmd.FieldByName('FilesOther')), bmWrite);
|
||||
AJpeg.Assign(Image2.Picture.Graphic);
|
||||
AJpeg.SaveToStream(myStream);
|
||||
myStream.Free;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmFileUp.FormCreate(Sender: TObject);
|
||||
begin
|
||||
lstPat := TStringList.Create;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmFileUp.FileDelClick(Sender: TObject);
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
SQL.Add(' Delete XD_File where XFID='''+Trim(ADOQueryFile.fieldbyname('XFID').AsString)+'''');
|
||||
SQL.Add(' Delete TP_File where WBID='''+Trim(CYID)+''' and TFType=''样品'' ');
|
||||
ExecSQL;
|
||||
end;
|
||||
with ADOQueryFile do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select * from XD_File where CYID='''+Trim(CYID)+'''');
|
||||
SQL.Add(' and FileType=''YP''');
|
||||
open;
|
||||
end;
|
||||
if ADOQueryFile.IsEmpty then
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update CP_YDang Set TPFlag=0 where CYID='''+Trim(CYID)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmFileUp.FormShow(Sender: TObject);
|
||||
begin
|
||||
with ADOQueryFile do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select * from XD_File where CYID='''+Trim(CYID)+'''');
|
||||
SQL.Add(' and FileType=''YP''');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,172 +0,0 @@
|
|||
object frmFjList: TfrmFjList
|
||||
Left = 154
|
||||
Top = 62
|
||||
Width = 1049
|
||||
Height = 540
|
||||
BorderIcons = [biSystemMenu, biMinimize]
|
||||
Caption = #38468#20214#20449#24687
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ListView1: TListView
|
||||
Left = 36
|
||||
Top = 88
|
||||
Width = 141
|
||||
Height = 137
|
||||
Columns = <>
|
||||
TabOrder = 0
|
||||
OnDblClick = ListView1DblClick
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 882
|
||||
Top = 0
|
||||
Width = 151
|
||||
Height = 501
|
||||
Align = alRight
|
||||
TabOrder = 1
|
||||
object FileName: TcxButton
|
||||
Left = 30
|
||||
Top = 60
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #28155#21152
|
||||
TabOrder = 0
|
||||
OnClick = FileNameClick
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
object cxButton1: TcxButton
|
||||
Left = 30
|
||||
Top = 96
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #21024#38500
|
||||
TabOrder = 1
|
||||
OnClick = cxButton1Click
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
object cxButton2: TcxButton
|
||||
Left = 30
|
||||
Top = 132
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #20445#23384
|
||||
TabOrder = 2
|
||||
OnClick = cxButton2Click
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
object cxButton3: TcxButton
|
||||
Left = 30
|
||||
Top = 172
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #20851#38381
|
||||
TabOrder = 3
|
||||
Visible = False
|
||||
OnClick = cxButton3Click
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
object cxButton4: TcxButton
|
||||
Left = 30
|
||||
Top = 220
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #28155#21152#25991#20214#22841
|
||||
TabOrder = 4
|
||||
OnClick = cxButton4Click
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
end
|
||||
object Panel2: TPanel
|
||||
Left = 24
|
||||
Top = 124
|
||||
Width = 193
|
||||
Height = 41
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Caption = 'Panel2'
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
TabOrder = 2
|
||||
Visible = False
|
||||
OnDblClick = Panel2DblClick
|
||||
end
|
||||
object ShellListView1: TShellListView
|
||||
Left = 177
|
||||
Top = 0
|
||||
Width = 705
|
||||
Height = 501
|
||||
ObjectTypes = [otFolders, otNonFolders]
|
||||
Root = 'rfDesktop'
|
||||
ShellTreeView = ShellTreeView1
|
||||
Sorted = True
|
||||
Align = alClient
|
||||
ReadOnly = False
|
||||
TabOrder = 3
|
||||
end
|
||||
object ShellTreeView1: TShellTreeView
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 177
|
||||
Height = 501
|
||||
ObjectTypes = [otFolders]
|
||||
Root = 'rfDesktop'
|
||||
ShellListView = ShellListView1
|
||||
UseShellImages = True
|
||||
Align = alLeft
|
||||
AutoRefresh = False
|
||||
Indent = 19
|
||||
ParentColor = False
|
||||
RightClickSelect = True
|
||||
ShowRoot = False
|
||||
TabOrder = 4
|
||||
end
|
||||
object ADOQueryTmp: TADOQuery
|
||||
Connection = ADOConnection1
|
||||
Parameters = <>
|
||||
Left = 512
|
||||
Top = 28
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = ADOConnection1
|
||||
Parameters = <>
|
||||
Left = 560
|
||||
Top = 24
|
||||
end
|
||||
object ImageList1: TImageList
|
||||
Left = 520
|
||||
Top = 212
|
||||
end
|
||||
object IdFTP1: TIdFTP
|
||||
MaxLineAction = maException
|
||||
ReadTimeout = 0
|
||||
ProxySettings.ProxyType = fpcmNone
|
||||
ProxySettings.Port = 0
|
||||
Left = 340
|
||||
Top = 190
|
||||
end
|
||||
object ADOConnection1: TADOConnection
|
||||
LoginPrompt = False
|
||||
Left = 484
|
||||
Top = 240
|
||||
end
|
||||
end
|
||||
|
|
@ -1,436 +0,0 @@
|
|||
unit U_FjList;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, ExtCtrls, ComCtrls, Menus, cxLookAndFeelPainters, StdCtrls,
|
||||
cxButtons, DB, ADODB, ImgList,shellapi, IdBaseComponent, IdComponent,
|
||||
IdTCPConnection, IdTCPClient, IdFTP, ShlObj, cxShellCommon, cxControls,
|
||||
cxContainer, cxShellTreeView, cxShellListView, ShellCtrls;
|
||||
|
||||
type
|
||||
TfrmFjList = class(TForm)
|
||||
ListView1: TListView;
|
||||
Panel1: TPanel;
|
||||
FileName: TcxButton;
|
||||
cxButton1: TcxButton;
|
||||
cxButton2: TcxButton;
|
||||
cxButton3: TcxButton;
|
||||
ADOQueryTmp: TADOQuery;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ImageList1: TImageList;
|
||||
Panel2: TPanel;
|
||||
IdFTP1: TIdFTP;
|
||||
ADOConnection1: TADOConnection;
|
||||
cxButton4: TcxButton;
|
||||
ShellListView1: TShellListView;
|
||||
ShellTreeView1: TShellTreeView;
|
||||
procedure cxButton3Click(Sender: TObject);
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FileNameClick(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure ListView1DblClick(Sender: TObject);
|
||||
procedure cxButton1Click(Sender: TObject);
|
||||
procedure cxButton2Click(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure Panel2DblClick(Sender: TObject);
|
||||
procedure cxButton4Click(Sender: TObject);
|
||||
private
|
||||
procedure InitData();
|
||||
{ Private declarations }
|
||||
public
|
||||
fkeyNO:string;
|
||||
fType:string;
|
||||
fId:integer;
|
||||
|
||||
fstatus:integer;
|
||||
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmFjList: TfrmFjList;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun;
|
||||
{$R *.dfm}
|
||||
procedure TfrmFjList.InitData();
|
||||
var
|
||||
ListItem: TListItem;
|
||||
Flag: Cardinal;
|
||||
info: SHFILEINFOA;
|
||||
Icon: TIcon;
|
||||
begin
|
||||
ListView1.Items.Clear;
|
||||
try
|
||||
|
||||
with adoqueryTmp do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select fileName from TP_File ');
|
||||
sql.Add('where WBID='+quotedstr(trim(fkeyNO)));
|
||||
sql.Add('and TFType='+quotedstr(trim(fType)));
|
||||
open;
|
||||
if not IsEmpty then
|
||||
begin
|
||||
while not eof do
|
||||
begin
|
||||
with ListView1 do
|
||||
begin
|
||||
LargeImages := ImageList1;
|
||||
Icon := TIcon.Create;
|
||||
ListItem := Items.Add;
|
||||
Listitem.Caption := trim(fieldbyname('fileName').AsString);
|
||||
// Listitem.SubItems.Add(OpenDiaLog.FileName);
|
||||
Flag := (SHGFI_SMALLICON or SHGFI_ICON or SHGFI_USEFILEATTRIBUTES);
|
||||
SHGetFileInfo(Pchar(trim(fieldbyname('fileName').AsString)), 0, info, Sizeof(info), Flag);
|
||||
Icon.Handle := info.hIcon;
|
||||
ImageList1.AddIcon(Icon);
|
||||
ListItem.ImageIndex := ImageList1.Count - 1;
|
||||
end;
|
||||
next;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
except
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.cxButton3Click(Sender: TObject);
|
||||
begin
|
||||
ADOQueryTmp.Close;
|
||||
ADOQuerycmd.Close;
|
||||
ListView1.Items.Free;
|
||||
ModalResult:=-1;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmFjList:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.FileNameClick(Sender: TObject);
|
||||
var
|
||||
OpenDiaLog: TOpenDialog;
|
||||
fFileName:string;
|
||||
fFilePath:string;
|
||||
maxNo:string;
|
||||
// myStream: TADOBlobStream;
|
||||
// FJStream : TMemoryStream;
|
||||
begin
|
||||
|
||||
try
|
||||
OpenDiaLog := TOpenDialog.Create(Self);
|
||||
if OpenDiaLog.Execute then
|
||||
begin
|
||||
fFilePath:=OpenDiaLog.FileName;
|
||||
fFileName:=ExtractFileName(OpenDiaLog.FileName);
|
||||
|
||||
|
||||
with adoqueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select TFId from TP_File ');
|
||||
sql.Add('where WBID<>'+quotedstr(trim(fkeyNO)));
|
||||
sql.Add('and TFType='+quotedstr(trim(fType)));
|
||||
sql.Add('and FileName='+quotedstr(trim(fFileName)));
|
||||
open;
|
||||
IF not adoqueryCmd.IsEmpty then
|
||||
begin
|
||||
application.MessageBox('此附件名称已存在,请修改文件名,继续上传!','提示信息',MB_ICONERROR);
|
||||
exit;
|
||||
end;
|
||||
end;
|
||||
|
||||
Panel2.Caption:='正在上传数据,请稍等...';
|
||||
Panel2.Visible:=true;
|
||||
application.ProcessMessages;
|
||||
|
||||
if GetLSNo(ADOQueryCmd,maxNo,'FJ','TP_File',4,1)=False then
|
||||
begin
|
||||
Application.MessageBox('取最大号失败!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
|
||||
adoqueryCmd.Connection.BeginTrans;
|
||||
|
||||
|
||||
with adoqueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('delete from TP_File ');
|
||||
sql.Add('where WBID='+quotedstr(trim(fkeyNO)));
|
||||
sql.Add('and TFType='+quotedstr(trim(fType)));
|
||||
sql.Add('and FileName='+quotedstr(trim(fFileName)));
|
||||
execsql;
|
||||
end;
|
||||
|
||||
try
|
||||
with adoqueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from TP_File ');
|
||||
sql.Add('where WBID='+quotedstr(trim(fkeyNO)));
|
||||
sql.Add('and TFType='+quotedstr(trim(fType)));
|
||||
sql.Add('and FileName='+quotedstr(trim(fFileName)));
|
||||
open;
|
||||
append;
|
||||
fieldbyname('TFID').Value:=trim(maxNO);
|
||||
fieldbyname('WBID').Value:=trim(fkeyNO);
|
||||
fieldbyname('TFType').Value:=trim(fType);
|
||||
fieldbyname('FileName').Value:=trim(fFileName);
|
||||
// tblobfield(FieldByName('Filesother')).LoadFromFile(fFilePath);
|
||||
post;
|
||||
end;
|
||||
|
||||
if fFilePath <> '' then
|
||||
begin
|
||||
try
|
||||
IdFTP1.Host :='127.0.0.1';
|
||||
IdFTP1.Username := 'three';
|
||||
IdFTP1.Password := '641010';
|
||||
IdFTP1.Connect();
|
||||
IdFTP1.Put(fFilePath, 'FJ\' + Trim(fFileName));
|
||||
IdFTP1.Quit;
|
||||
except
|
||||
IdFTP1.Quit;
|
||||
Application.MessageBox('上传客户图样文件失败,请检查文件服务器!', '提示', MB_ICONWARNING);
|
||||
end;
|
||||
end;
|
||||
IdFTP1.Quit;
|
||||
|
||||
Panel2.Visible:=false;
|
||||
initdata();
|
||||
finally
|
||||
// FJStream.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
adoqueryCmd.Connection.CommitTrans;
|
||||
except
|
||||
adoqueryCmd.Connection.RollbackTrans;
|
||||
application.MessageBox('附件保存失败!','提示信息',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.FormCreate(Sender: TObject);
|
||||
begin
|
||||
with ADOConnection1 do
|
||||
begin
|
||||
Connected:=false;
|
||||
ConnectionString:=DConString;
|
||||
//ConnectionString:='';
|
||||
Connected:=true;
|
||||
end;
|
||||
ListView1.Align:=alclient;
|
||||
fstatus:=0;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.FormShow(Sender: TObject);
|
||||
begin
|
||||
IF fstatus=0 then Panel1.Visible:=true
|
||||
else Panel1.Visible:=false;
|
||||
//initdata();
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.ListView1DblClick(Sender: TObject);
|
||||
var
|
||||
sFieldName:string;
|
||||
fileName:string;
|
||||
begin
|
||||
if ListView1.Items.Count<1 THEN EXIT;
|
||||
|
||||
if listView1.SelCount<1 then exit;
|
||||
sFieldName:='D:\图片查看';
|
||||
|
||||
if not DirectoryExists(pchar(sFieldName)) then
|
||||
CreateDirectory(pchar(sFieldName),nil);
|
||||
|
||||
fileName:=ListView1.Selected.Caption;
|
||||
|
||||
sFieldName:=sFieldName+'\'+trim(fileName);
|
||||
|
||||
try
|
||||
IdFTP1.Host :='127.0.0.1';
|
||||
IdFTP1.Username := 'three';
|
||||
IdFTP1.Password := '641010';
|
||||
IdFTP1.Connect();
|
||||
except
|
||||
;
|
||||
end;
|
||||
|
||||
if IdFTP1.Connected then
|
||||
begin
|
||||
|
||||
Panel2.Caption:='正在下载数据,请稍等...';
|
||||
Panel2.Visible:=true;
|
||||
application.ProcessMessages;
|
||||
try
|
||||
IdFTP1.Get('FJ\'+ Trim(fileName), sFieldName,false, true);
|
||||
except
|
||||
Panel2.Visible:=false;
|
||||
Application.MessageBox('客户图样文件不存在', '提示', MB_ICONWARNING);
|
||||
IdFTP1.Quit;
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Panel2.Visible:=false;
|
||||
Application.MessageBox('无法连接文件服务器', '提示', MB_ICONWARNING);
|
||||
IdFTP1.Quit;
|
||||
Exit;
|
||||
end;
|
||||
Panel2.Visible:=false;
|
||||
if IdFTP1.Connected then IdFTP1.Quit;
|
||||
ShellExecute(Handle, 'open',PChar(sFieldName),'', '', SW_SHOWNORMAL);
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.cxButton1Click(Sender: TObject);
|
||||
var
|
||||
fFileName:string;
|
||||
fFilePath:string;
|
||||
begin
|
||||
if listView1.SelCount<1 then exit;
|
||||
|
||||
try
|
||||
fFileName:=ListView1.Selected.Caption;
|
||||
// ADOQueryTmp.Locate('fileName',fFileName,[]);
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('delete from TP_File ');
|
||||
sql.Add('where WBID='+quotedstr(trim(fkeyNO)));
|
||||
sql.Add('and TFType='+quotedstr(trim(fType)));
|
||||
sql.Add('and FileName='+quotedstr(trim(fFileName)));
|
||||
execsql;
|
||||
end;
|
||||
|
||||
initData();
|
||||
|
||||
except
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.cxButton2Click(Sender: TObject);
|
||||
var
|
||||
SaveDialog: TSaveDialog;
|
||||
fFileName:string;
|
||||
fFilePath:string;
|
||||
begin
|
||||
if listView1.SelCount<1 then exit;
|
||||
|
||||
try
|
||||
|
||||
fFileName:=ListView1.Selected.Caption;
|
||||
|
||||
SaveDialog := TSaveDialog.Create(Self);
|
||||
|
||||
SaveDialog.FileName:=fFileName;
|
||||
if SaveDialog.Execute then
|
||||
begin
|
||||
Panel2.Caption:='正在保存数据,请稍等...';
|
||||
Panel2.Visible:=true;
|
||||
application.ProcessMessages;
|
||||
fFilePath:=SaveDialog.FileName;
|
||||
try
|
||||
IdFTP1.Host := '127.0.0.1';
|
||||
IdFTP1.Username := 'three';
|
||||
IdFTP1.Password := '641010';
|
||||
IdFTP1.Connect();
|
||||
except
|
||||
;
|
||||
end;
|
||||
|
||||
if IdFTP1.Connected then
|
||||
begin
|
||||
|
||||
Panel2.Caption:='正在下载数据,请稍等...';
|
||||
Panel2.Visible:=true;
|
||||
application.ProcessMessages;
|
||||
try
|
||||
IdFTP1.Get('FJ\'+ Trim(fFileName), fFilePath,false, true);
|
||||
except
|
||||
Panel2.Visible:=false;
|
||||
Application.MessageBox('客户图样文件不存在', '提示', MB_ICONWARNING);
|
||||
IdFTP1.Quit;
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Panel2.Visible:=false;
|
||||
Application.MessageBox('无法连接文件服务器', '提示', MB_ICONWARNING);
|
||||
IdFTP1.Quit;
|
||||
Exit;
|
||||
end;
|
||||
Panel2.Visible:=false;
|
||||
if IdFTP1.Connected then IdFTP1.Quit;
|
||||
end;
|
||||
except
|
||||
Panel2.Visible:=false;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
if fId=10 then Action:=cafree
|
||||
else
|
||||
Action:=cahide;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.Panel2DblClick(Sender: TObject);
|
||||
begin
|
||||
Panel2.Visible:=false;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList.cxButton4Click(Sender: TObject);
|
||||
var
|
||||
fFilePath,FName:string;
|
||||
begin
|
||||
if Assigned(ShellListView1.Selected) then
|
||||
begin
|
||||
if ShellListView1.Selected.Selected then
|
||||
begin
|
||||
if ShellListView1.SelectedFolder.IsFolder then
|
||||
begin
|
||||
ShowMessage(ShellListView1.SelectedFolder.PathName);
|
||||
end
|
||||
else
|
||||
begin
|
||||
ShowMessage(ShellListView1.SelectedFolder.PathName);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
//if fFilePath <> '' then
|
||||
//fFilePath:=ShellListView1.SelectedFolder.PathName;
|
||||
// FName:=ShellListView1.SelectedFolder.DisplayName;
|
||||
begin
|
||||
try
|
||||
IdFTP1.Host :='127.0.0.1';
|
||||
IdFTP1.Username := 'three';
|
||||
IdFTP1.Password := '641010';
|
||||
IdFTP1.Connect();
|
||||
IdFTP1.Put(ShellListView1.SelectedFolder.PathName, 'FJ\' +ShellListView1.SelectedFolder.PathName);
|
||||
IdFTP1.Quit;
|
||||
except
|
||||
IdFTP1.Quit;
|
||||
Application.MessageBox('上传客户图样文件失败,请检查文件服务器!', '提示', MB_ICONWARNING);
|
||||
end;
|
||||
end;
|
||||
IdFTP1.Quit;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,183 +0,0 @@
|
|||
object frmFjList_RZ: TfrmFjList_RZ
|
||||
Left = 177
|
||||
Top = 159
|
||||
Width = 1062
|
||||
Height = 514
|
||||
BorderIcons = [biSystemMenu, biMinimize]
|
||||
Caption = #38468#20214#20449#24687
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ListView1: TListView
|
||||
Left = 40
|
||||
Top = 20
|
||||
Width = 429
|
||||
Height = 77
|
||||
Columns = <>
|
||||
TabOrder = 0
|
||||
OnDblClick = ListView1DblClick
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 878
|
||||
Top = 0
|
||||
Width = 151
|
||||
Height = 517
|
||||
Align = alRight
|
||||
TabOrder = 1
|
||||
object FileName: TcxButton
|
||||
Left = 30
|
||||
Top = 60
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #28155#21152
|
||||
TabOrder = 0
|
||||
OnClick = FileNameClick
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
object cxButton1: TcxButton
|
||||
Left = 30
|
||||
Top = 96
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #21024#38500
|
||||
TabOrder = 1
|
||||
OnClick = cxButton1Click
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
object cxButton2: TcxButton
|
||||
Left = 30
|
||||
Top = 132
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #19979#36733
|
||||
TabOrder = 2
|
||||
OnClick = cxButton2Click
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
object cxButton3: TcxButton
|
||||
Left = 30
|
||||
Top = 172
|
||||
Width = 75
|
||||
Height = 25
|
||||
Hint = 'Filesother'
|
||||
Caption = #20851#38381
|
||||
TabOrder = 3
|
||||
Visible = False
|
||||
OnClick = cxButton3Click
|
||||
LookAndFeel.Kind = lfOffice11
|
||||
end
|
||||
end
|
||||
object Panel2: TPanel
|
||||
Left = 176
|
||||
Top = 140
|
||||
Width = 193
|
||||
Height = 41
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Caption = 'Panel2'
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
TabOrder = 2
|
||||
Visible = False
|
||||
OnDblClick = Panel2DblClick
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 80
|
||||
Top = 200
|
||||
Width = 593
|
||||
Height = 317
|
||||
TabOrder = 3
|
||||
object Tv1: TcxGridDBTableView
|
||||
OnDblClick = Tv1DblClick
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsData.Deleting = False
|
||||
OptionsData.Editing = False
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.Indicator = True
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #25991#20214#21517#31216
|
||||
DataBinding.FieldName = 'FileName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 146
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #25991#20214#20462#25913#26102#38388
|
||||
DataBinding.FieldName = 'TFdate'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 140
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #25805#20316#21592
|
||||
DataBinding.FieldName = 'Filler'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 83
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #19978#20256#26102#38388
|
||||
DataBinding.FieldName = 'FillTime'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 140
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object ADOQueryTmp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 520
|
||||
Top = 28
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 568
|
||||
Top = 32
|
||||
end
|
||||
object ImageList1: TImageList
|
||||
Left = 536
|
||||
Top = 228
|
||||
end
|
||||
object IdFTP1: TIdFTP
|
||||
MaxLineAction = maException
|
||||
ReadTimeout = 0
|
||||
ProxySettings.ProxyType = fpcmNone
|
||||
ProxySettings.Port = 0
|
||||
Left = 492
|
||||
Top = 166
|
||||
end
|
||||
object ADOConnection1: TADOConnection
|
||||
LoginPrompt = False
|
||||
Left = 460
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = ADOQueryTmp
|
||||
Left = 548
|
||||
Top = 124
|
||||
end
|
||||
end
|
||||
|
|
@ -1,400 +0,0 @@
|
|||
unit U_FjList_RZ;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, ExtCtrls, ComCtrls, Menus, cxLookAndFeelPainters, StdCtrls,
|
||||
cxButtons, DB, ADODB, ImgList,shellapi, IdBaseComponent, IdComponent,
|
||||
IdTCPConnection, IdTCPClient, IdFTP, cxStyles, cxCustomData, cxGraphics,
|
||||
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, cxGridCustomTableView,
|
||||
cxGridTableView, cxGridDBTableView, cxGridLevel, cxClasses, cxControls,
|
||||
cxGridCustomView, cxGrid;
|
||||
|
||||
type
|
||||
TfrmFjList_RZ = class(TForm)
|
||||
ListView1: TListView;
|
||||
Panel1: TPanel;
|
||||
FileName: TcxButton;
|
||||
cxButton1: TcxButton;
|
||||
cxButton2: TcxButton;
|
||||
cxButton3: TcxButton;
|
||||
ADOQueryTmp: TADOQuery;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ImageList1: TImageList;
|
||||
Panel2: TPanel;
|
||||
IdFTP1: TIdFTP;
|
||||
ADOConnection1: TADOConnection;
|
||||
Tv1: TcxGridDBTableView;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
cxGrid1: TcxGrid;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
DataSource1: TDataSource;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
procedure cxButton3Click(Sender: TObject);
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FileNameClick(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure ListView1DblClick(Sender: TObject);
|
||||
procedure cxButton1Click(Sender: TObject);
|
||||
procedure cxButton2Click(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure Panel2DblClick(Sender: TObject);
|
||||
procedure Tv1DblClick(Sender: TObject);
|
||||
private
|
||||
procedure InitData();
|
||||
{ Private declarations }
|
||||
public
|
||||
fkeyNO:string;
|
||||
fType:string;
|
||||
fId:integer;
|
||||
fstatus:integer;
|
||||
// fmanage:string;
|
||||
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmFjList_RZ: TfrmFjList_RZ;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_CompressionFun;
|
||||
{$R *.dfm}
|
||||
procedure TfrmFjList_RZ.InitData();
|
||||
var
|
||||
ListItem: TListItem;
|
||||
Flag: Cardinal;
|
||||
info: SHFILEINFOA;
|
||||
Icon: TIcon;
|
||||
begin
|
||||
ListView1.Items.Clear;
|
||||
try
|
||||
|
||||
with adoqueryTmp do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from TP_File ');
|
||||
sql.Add('where WBID='+quotedstr(trim(fkeyNO)));
|
||||
sql.Add('and TFType='+quotedstr(trim(fType)));
|
||||
open;
|
||||
{ if not IsEmpty then
|
||||
begin
|
||||
while not eof do
|
||||
begin
|
||||
with ListView1 do
|
||||
begin
|
||||
LargeImages := ImageList1;
|
||||
Icon := TIcon.Create;
|
||||
ListItem := Items.Add;
|
||||
Listitem.Caption := trim(fieldbyname('fileName').AsString);
|
||||
// Listitem.SubItems.Add(OpenDiaLog.FileName);
|
||||
Flag := (SHGFI_SMALLICON or SHGFI_ICON or SHGFI_USEFILEATTRIBUTES);
|
||||
SHGetFileInfo(Pchar(trim(fieldbyname('fileName').AsString)), 0, info, Sizeof(info), Flag);
|
||||
Icon.Handle := info.hIcon;
|
||||
ImageList1.AddIcon(Icon);
|
||||
ListItem.ImageIndex := ImageList1.Count - 1;
|
||||
end;
|
||||
next;
|
||||
end;
|
||||
end; }
|
||||
end;
|
||||
except
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.cxButton3Click(Sender: TObject);
|
||||
begin
|
||||
ADOQueryTmp.Close;
|
||||
ADOQuerycmd.Close;
|
||||
ListView1.Items.Free;
|
||||
ModalResult:=-1;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmFjList_RZ:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.FileNameClick(Sender: TObject);
|
||||
var
|
||||
OpenDiaLog: TOpenDialog;
|
||||
fFileName:string;
|
||||
fFilePath:string;
|
||||
maxNo:string;
|
||||
// myStream: TADOBlobStream;
|
||||
FJStream : TMemoryStream;
|
||||
mfileSize:integer;
|
||||
mCreationTime:TdateTime;
|
||||
mWriteTime:TdateTime;
|
||||
begin
|
||||
|
||||
try
|
||||
adoqueryCmd.Connection.BeginTrans;
|
||||
OpenDiaLog := TOpenDialog.Create(Self);
|
||||
if OpenDiaLog.Execute then
|
||||
begin
|
||||
fFilePath:=OpenDiaLog.FileName;
|
||||
fFileName:=ExtractFileName(OpenDiaLog.FileName);
|
||||
Panel2.Caption:='正在上传数据,请稍等...';
|
||||
Panel2.Visible:=true;
|
||||
application.ProcessMessages;
|
||||
|
||||
if GetLSNo(ADOQueryCmd,maxNo,'FJ','TP_File',4,1)=False then
|
||||
begin
|
||||
adoqueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取最大号失败!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
//获取文件信息
|
||||
GetFileInfo(fFilePath,mfileSize,mCreationTime,mWriteTime);
|
||||
with adoqueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('delete from TP_File ');
|
||||
sql.Add('where TFID='+quotedstr(trim(maxNO)));
|
||||
execsql;
|
||||
end;
|
||||
try
|
||||
FJStream:=TMemoryStream.Create;
|
||||
with adoqueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from TP_File ');
|
||||
sql.Add('where TFID='+quotedstr(trim(maxNO)));
|
||||
// sql.Add('where WBID='+quotedstr(trim(fkeyNO)));
|
||||
// sql.Add('and TFType='+quotedstr(trim(fType)));
|
||||
// sql.Add('and FileName='+quotedstr(trim(fFileName)));
|
||||
open;
|
||||
append;
|
||||
fieldbyname('TFID').Value:=trim(maxNO);
|
||||
fieldbyname('WBID').Value:=trim(fkeyNO);
|
||||
fieldbyname('TFType').Value:=trim(fType);
|
||||
fieldbyname('Filler').Value:=trim(DName);
|
||||
fieldbyname('FileName').Value:=trim(fFileName);
|
||||
fieldbyname('TFDate').Value:=mWriteTime;
|
||||
FJStream.LoadFromFile(fFilePath);
|
||||
CompressionStream(FJStream);
|
||||
tblobfield(FieldByName('Filesother')).LoadFromStream(FJStream);
|
||||
post;
|
||||
end;
|
||||
Panel2.Visible:=false;
|
||||
initdata();
|
||||
finally
|
||||
FJStream.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
adoqueryCmd.Connection.CommitTrans;
|
||||
except
|
||||
adoqueryCmd.Connection.RollbackTrans;
|
||||
application.MessageBox('附件保存失败!','提示信息',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.FormCreate(Sender: TObject);
|
||||
begin
|
||||
with ADOConnection1 do
|
||||
begin
|
||||
Connected:=false;
|
||||
ConnectionString:=DConString;
|
||||
//ConnectionString:='';
|
||||
Connected:=true;
|
||||
end;
|
||||
cxGrid1.Align:=alclient;
|
||||
fstatus:=0;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.FormShow(Sender: TObject);
|
||||
begin
|
||||
IF fstatus=0 then Panel1.Visible:=true
|
||||
else Panel1.Visible:=false;
|
||||
initdata();
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.ListView1DblClick(Sender: TObject);
|
||||
var
|
||||
sFieldName:string;
|
||||
fileName:string;
|
||||
begin
|
||||
if ListView1.Items.Count<1 THEN EXIT;
|
||||
|
||||
if listView1.SelCount<1 then exit;
|
||||
sFieldName:='D:\图片查看';
|
||||
|
||||
if not DirectoryExists(pchar(sFieldName)) then
|
||||
CreateDirectory(pchar(sFieldName),nil);
|
||||
|
||||
fileName:=ListView1.Selected.Caption;
|
||||
|
||||
sFieldName:=sFieldName+'\'+trim(fileName);
|
||||
|
||||
try
|
||||
IdFTP1.Host := PicSvr;
|
||||
IdFTP1.Username := 'three';
|
||||
IdFTP1.Password := '641010';
|
||||
IdFTP1.Connect();
|
||||
except
|
||||
;
|
||||
end;
|
||||
|
||||
if IdFTP1.Connected then
|
||||
begin
|
||||
|
||||
Panel2.Caption:='正在下载数据,请稍等...';
|
||||
Panel2.Visible:=true;
|
||||
application.ProcessMessages;
|
||||
try
|
||||
IdFTP1.Get('FJ\'+ Trim(fileName), sFieldName,false, true);
|
||||
except
|
||||
Panel2.Visible:=false;
|
||||
Application.MessageBox('客户图样文件不存在', '提示', MB_ICONWARNING);
|
||||
IdFTP1.Quit;
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Panel2.Visible:=false;
|
||||
Application.MessageBox('无法连接文件服务器', '提示', MB_ICONWARNING);
|
||||
IdFTP1.Quit;
|
||||
Exit;
|
||||
end;
|
||||
Panel2.Visible:=false;
|
||||
if IdFTP1.Connected then IdFTP1.Quit;
|
||||
ShellExecute(Handle, 'open',PChar(sFieldName),'', '', SW_SHOWNORMAL);
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.cxButton1Click(Sender: TObject);
|
||||
var
|
||||
fFileName:string;
|
||||
fFilePath:string;
|
||||
begin
|
||||
// if listView1.SelCount<1 then exit;
|
||||
|
||||
IF ADOQueryTmp.IsEmpty then exit;
|
||||
|
||||
try
|
||||
// fFileName:=ListView1.Selected.Caption;
|
||||
// ADOQueryTmp.Locate('fileName',fFileName,[]);
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('delete from TP_File ');
|
||||
sql.Add('where TFID='+quotedstr(trim(ADOQueryTmp.fieldbyname('TFID').AsString)));
|
||||
// sql.Add('and TFType='+quotedstr(trim(fType)));
|
||||
// sql.Add('and FileName='+quotedstr(trim(fFileName)));
|
||||
execsql;
|
||||
end;
|
||||
|
||||
initData();
|
||||
|
||||
except
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.cxButton2Click(Sender: TObject);
|
||||
var
|
||||
SaveDialog: TSaveDialog;
|
||||
fFileName:string;
|
||||
fFilePath:string;
|
||||
ff: TADOBlobStream;
|
||||
FJStream : TMemoryStream;
|
||||
begin
|
||||
if adoqueryTmp.IsEmpty then exit;
|
||||
|
||||
try
|
||||
|
||||
fFileName:=adoqueryTmp.fieldbyname('FileName').AsString;
|
||||
|
||||
SaveDialog := TSaveDialog.Create(Self);
|
||||
|
||||
SaveDialog.FileName:=fFileName;
|
||||
if SaveDialog.Execute then
|
||||
begin
|
||||
Panel2.Caption:='正在保存数据,请稍等...';
|
||||
Panel2.Visible:=true;
|
||||
application.ProcessMessages;
|
||||
fFilePath:=SaveDialog.FileName;
|
||||
|
||||
try
|
||||
ff := TADOBlobstream.Create(adoqueryTmp.fieldByName('FilesOther') as TblobField, bmRead);
|
||||
|
||||
fjStream:= TMemoryStream.Create ;
|
||||
ff.SaveToStream(fjStream);
|
||||
UnCompressionStream(fjStream);
|
||||
fjStream.SaveToFile(fFilePath);
|
||||
// ShellExecute(Handle, 'open',PChar(sFieldName),'', '', SW_SHOWNORMAL);
|
||||
finally
|
||||
fjStream.free;
|
||||
ff.Free;
|
||||
end;
|
||||
|
||||
|
||||
Panel2.Visible:=false;
|
||||
// if IdFTP1.Connected then IdFTP1.Quit;
|
||||
end;
|
||||
except
|
||||
Panel2.Visible:=false;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
if fId=10 then Action:=cafree
|
||||
else
|
||||
Action:=cahide;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.Panel2DblClick(Sender: TObject);
|
||||
begin
|
||||
Panel2.Visible:=false;
|
||||
end;
|
||||
|
||||
procedure TfrmFjList_RZ.Tv1DblClick(Sender: TObject);
|
||||
var
|
||||
sFieldName:string;
|
||||
fileName:string;
|
||||
ff: TADOBlobStream;
|
||||
FJStream : TMemoryStream;
|
||||
begin
|
||||
|
||||
IF adoqueryTmp.IsEmpty then exit;
|
||||
|
||||
sFieldName:='D:\图片查看';
|
||||
|
||||
if not DirectoryExists(pchar(sFieldName)) then
|
||||
CreateDirectory(pchar(sFieldName),nil);
|
||||
|
||||
fileName:=adoqueryTmp.fieldbyname('FileName').AsString;
|
||||
|
||||
sFieldName:=sFieldName+'\'+trim(fileName);
|
||||
|
||||
try
|
||||
ff := TADOBlobstream.Create(adoqueryTmp.fieldByName('FilesOther') as TblobField, bmRead);
|
||||
|
||||
fjStream:= TMemoryStream.Create ;
|
||||
ff.SaveToStream(fjStream);
|
||||
UnCompressionStream(fjStream);
|
||||
fjStream.SaveToFile(sFieldName);
|
||||
ShellExecute(Handle, 'open',PChar(sFieldName),'', '', SW_SHOWNORMAL);
|
||||
finally
|
||||
fjStream.free;
|
||||
ff.Free;
|
||||
end;
|
||||
|
||||
|
||||
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,510 +0,0 @@
|
|||
object frmGJKDList: TfrmGJKDList
|
||||
Left = 122
|
||||
Top = 123
|
||||
Width = 1384
|
||||
Height = 670
|
||||
Caption = #22269#38469#24555#36882
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1368
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
Visible = False
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20837
|
||||
ImageIndex = 22
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26032#22686
|
||||
ImageIndex = 2
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 315
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#38500
|
||||
ImageIndex = 3
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 378
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1368
|
||||
Height = 59
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label5: TLabel
|
||||
Left = 187
|
||||
Top = 35
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #21333#21495
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 175
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #30446#30340#22320
|
||||
end
|
||||
object Label1: TLabel
|
||||
Left = 25
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 322
|
||||
Top = 13
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #23492#20214#20154
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 578
|
||||
Top = 13
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #24555#36882#20844#21496
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 7
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 30
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object DANNO: TEdit
|
||||
Tag = 2
|
||||
Left = 215
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnKeyPress = TOCOUNTRYKeyPress
|
||||
end
|
||||
object TOCOUNTRY: TEdit
|
||||
Tag = 2
|
||||
Left = 215
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnKeyPress = TOCOUNTRYKeyPress
|
||||
end
|
||||
object JJREN: TEdit
|
||||
Tag = 2
|
||||
Left = 362
|
||||
Top = 9
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 4
|
||||
OnKeyPress = TOCOUNTRYKeyPress
|
||||
end
|
||||
object cxButtonEdit1: TcxButtonEdit
|
||||
Left = 631
|
||||
Top = 8
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.ReadOnly = True
|
||||
TabOrder = 5
|
||||
OnClick = cxButtonEdit1Click
|
||||
Width = 121
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1368
|
||||
Height = 540
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object TV1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OnCustomDrawCell = TV1CustomDrawCell
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object tv2Column1: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 68
|
||||
end
|
||||
object TV1Column7: TcxGridDBColumn
|
||||
Caption = #23492#20214#26085#26399
|
||||
DataBinding.FieldName = 'CRTIME2'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
Properties.OnEditValueChanged = TV1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 81
|
||||
end
|
||||
object TV1Column1: TcxGridDBColumn
|
||||
Caption = #30446#30340#22320
|
||||
DataBinding.FieldName = 'TOCOUNTRY'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = TV1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column2: TcxGridDBColumn
|
||||
Caption = #37325#37327#65288'KG'#65289
|
||||
DataBinding.FieldName = 'qty'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = TV1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object TV1Column3: TcxGridDBColumn
|
||||
Caption = #21333#21495
|
||||
DataBinding.FieldName = 'DANNO'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = TV1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column4: TcxGridDBColumn
|
||||
Caption = #23492#20214#20154
|
||||
DataBinding.FieldName = 'JJREN'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = TV1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 85
|
||||
end
|
||||
object TV1Column5: TcxGridDBColumn
|
||||
Caption = #37329#39069
|
||||
DataBinding.FieldName = 'MONEY'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = TV1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column15: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'note'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = TV1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column16: TcxGridDBColumn
|
||||
Caption = #30331#35760#26085#26399
|
||||
DataBinding.FieldName = 'filltime'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column6: TcxGridDBColumn
|
||||
Caption = #24555#36882#20844#21496
|
||||
DataBinding.FieldName = 'FACTORYNAME'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = TV1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 77
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object Panel6: TPanel
|
||||
Left = 506
|
||||
Top = 248
|
||||
Width = 185
|
||||
Height = 41
|
||||
Caption = #27491#22312#23548#20837#65292#35831#31245#21518#12290#12290#12290
|
||||
TabOrder = 3
|
||||
Visible = False
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 338
|
||||
Top = 330
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 312
|
||||
Top = 305
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 342
|
||||
Top = 278
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 283
|
||||
Top = 354
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 284
|
||||
Top = 328
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 313
|
||||
Top = 330
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 315
|
||||
Top = 276
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 777
|
||||
Top = 299
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 916
|
||||
Top = 514
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 917
|
||||
Top = 488
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 942
|
||||
Top = 515
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 341
|
||||
Top = 305
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 256
|
||||
Top = 357
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 300
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 256
|
||||
Top = 328
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 256
|
||||
Top = 276
|
||||
end
|
||||
object RM2: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDB_2
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 284
|
||||
Top = 303
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDB_2: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Main
|
||||
Left = 285
|
||||
Top = 277
|
||||
end
|
||||
object OpenDialog1: TOpenDialog
|
||||
Left = 474
|
||||
Top = 258
|
||||
end
|
||||
end
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,539 +0,0 @@
|
|||
object frmGYSList: TfrmGYSList
|
||||
Left = 43
|
||||
Top = 66
|
||||
Width = 1182
|
||||
Height = 606
|
||||
Caption = #20379#24212#21830#30331#35760
|
||||
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 = 1166
|
||||
Height = 62
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 107
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object TBAdd: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26032#22686
|
||||
ImageIndex = 1
|
||||
OnClick = TBAddClick
|
||||
end
|
||||
object TBEdit: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20462#25913
|
||||
ImageIndex = 11
|
||||
OnClick = TBEditClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBDel: TToolButton
|
||||
Left = 315
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#38500
|
||||
ImageIndex = 3
|
||||
OnClick = TBDelClick
|
||||
end
|
||||
object ToolButton4: TToolButton
|
||||
Left = 378
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26356#26032#36134#26399#22825#25968
|
||||
ImageIndex = 22
|
||||
Wrap = True
|
||||
OnClick = ToolButton4Click
|
||||
end
|
||||
object Panel2: TPanel
|
||||
Left = 0
|
||||
Top = 30
|
||||
Width = 119
|
||||
Height = 30
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 0
|
||||
object Label3: TLabel
|
||||
Left = 8
|
||||
Top = 8
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #36134#26399#22825#25968
|
||||
end
|
||||
object LockDays: TEdit
|
||||
Left = 58
|
||||
Top = 5
|
||||
Width = 52
|
||||
Height = 20
|
||||
TabOrder = 0
|
||||
end
|
||||
end
|
||||
object ToolButton5: TToolButton
|
||||
Left = 119
|
||||
Top = 30
|
||||
AutoSize = True
|
||||
Caption = #26356#26032#22823#31867
|
||||
ImageIndex = 22
|
||||
OnClick = ToolButton5Click
|
||||
end
|
||||
object Panel3: TPanel
|
||||
Left = 206
|
||||
Top = 30
|
||||
Width = 107
|
||||
Height = 30
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label4: TLabel
|
||||
Left = 8
|
||||
Top = 8
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #22823#31867
|
||||
end
|
||||
object BigType: TComboBox
|
||||
Left = 34
|
||||
Top = 5
|
||||
Width = 70
|
||||
Height = 20
|
||||
Style = csDropDownList
|
||||
ItemHeight = 12
|
||||
TabOrder = 0
|
||||
Items.Strings = (
|
||||
#24212#20184#27454
|
||||
#21333#35777
|
||||
#20179#24211
|
||||
#26426#29289#26009
|
||||
#20854#20182)
|
||||
end
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 313
|
||||
Top = 30
|
||||
AutoSize = True
|
||||
Caption = #20379#24212#21830#38145#23450
|
||||
ImageIndex = 35
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 412
|
||||
Top = 30
|
||||
AutoSize = True
|
||||
Caption = #35299#38145
|
||||
ImageIndex = 41
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 475
|
||||
Top = 30
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 97
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 538
|
||||
Top = 30
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 152
|
||||
Width = 1166
|
||||
Height = 415
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 1
|
||||
object Tv1: TcxGridDBTableView
|
||||
OnMouseDown = Tv1MouseDown
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 46
|
||||
end
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830#32534#21495
|
||||
DataBinding.FieldName = 'KHCode'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830#20840#31216
|
||||
DataBinding.FieldName = 'KHName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 88
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830#31616#31216
|
||||
DataBinding.FieldName = 'KHNameJC'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 139
|
||||
end
|
||||
object v1Column15: TcxGridDBColumn
|
||||
Caption = #22823#31867
|
||||
DataBinding.FieldName = 'BigType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 87
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830#31867#22411
|
||||
DataBinding.FieldName = 'KHType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #32479#35745#21333#20301#21517#31216
|
||||
DataBinding.FieldName = 'TJKHName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 102
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #30005#35805
|
||||
DataBinding.FieldName = 'ZKTelNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 96
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #20256#30495
|
||||
DataBinding.FieldName = 'ZKFax'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 89
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #22320#22336
|
||||
DataBinding.FieldName = 'ZKAddress'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 112
|
||||
end
|
||||
object v1Column16: TcxGridDBColumn
|
||||
Caption = #36127#36131#20154
|
||||
DataBinding.FieldName = 'FZPerson'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.DropDownRows = 40
|
||||
Properties.ImmediatePost = True
|
||||
Properties.OnChange = v1Column16PropertiesChange
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 73
|
||||
end
|
||||
object v1Column12: TcxGridDBColumn
|
||||
Caption = #32852#31995#20154
|
||||
DataBinding.FieldName = 'LXR'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 82
|
||||
end
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Caption = #32852#31995#20154#30005#35805
|
||||
DataBinding.FieldName = 'LXRTel'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v1Column3: TcxGridDBColumn
|
||||
Caption = #26159#21542#26377#25928
|
||||
DataBinding.FieldName = 'Valid'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 76
|
||||
end
|
||||
object v1Column8: TcxGridDBColumn
|
||||
Caption = #24050#38145#23450
|
||||
DataBinding.FieldName = 'LockFlag'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 64
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Caption = #36134#26399#22825#25968
|
||||
DataBinding.FieldName = 'lockDays'
|
||||
Options.Editing = False
|
||||
Width = 59
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 62
|
||||
Width = 1166
|
||||
Height = 67
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 2
|
||||
object Label9: TLabel
|
||||
Left = 27
|
||||
Top = 15
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #20379#24212#21830#31616#31216
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 27
|
||||
Top = 39
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #20379#24212#21830#32534#21495
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label34: TLabel
|
||||
Left = 249
|
||||
Top = 15
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #20379#24212#21830#31867#22411
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label1: TLabel
|
||||
Left = 241
|
||||
Top = 39
|
||||
Width = 78
|
||||
Height = 12
|
||||
Caption = #32479#35745#21333#20301#21517#31216
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 465
|
||||
Top = 15
|
||||
Width = 39
|
||||
Height = 12
|
||||
Caption = #36127#36131#20154
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object KHNameJC: TEdit
|
||||
Tag = 2
|
||||
Left = 94
|
||||
Top = 11
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 0
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
object KHCode: TEdit
|
||||
Tag = 2
|
||||
Left = 94
|
||||
Top = 35
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 1
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
object KHType: TEdit
|
||||
Tag = 2
|
||||
Left = 320
|
||||
Top = 11
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
object TJKHName: TEdit
|
||||
Tag = 2
|
||||
Left = 320
|
||||
Top = 35
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
object CheckBox1: TCheckBox
|
||||
Left = 508
|
||||
Top = 37
|
||||
Width = 97
|
||||
Height = 17
|
||||
Caption = #26174#31034#26080#25928#25968#25454
|
||||
TabOrder = 4
|
||||
end
|
||||
object FZPerson: TEdit
|
||||
Tag = 2
|
||||
Left = 506
|
||||
Top = 11
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
end
|
||||
object cxTabControl1: TcxTabControl
|
||||
Left = 0
|
||||
Top = 129
|
||||
Width = 1166
|
||||
Height = 23
|
||||
Align = alTop
|
||||
TabOrder = 3
|
||||
Properties.CustomButtons.Buttons = <>
|
||||
Properties.Style = 8
|
||||
Properties.TabIndex = 0
|
||||
Properties.Tabs.Strings = (
|
||||
#24212#20184#27454
|
||||
#21333#35777
|
||||
#20179#24211
|
||||
#26426#29289#26009
|
||||
#20854#20182
|
||||
#20840#37096)
|
||||
OnChange = cxTabControl1Change
|
||||
ClientRectBottom = 23
|
||||
ClientRectRight = 1166
|
||||
ClientRectTop = 23
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 464
|
||||
Top = 160
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 432
|
||||
Top = 200
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 392
|
||||
Top = 200
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 304
|
||||
Top = 152
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = Order_Main
|
||||
Left = 352
|
||||
Top = 160
|
||||
end
|
||||
object Order_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 416
|
||||
Top = 160
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 304
|
||||
Top = 192
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N2Click
|
||||
end
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N1Click
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -1,620 +0,0 @@
|
|||
unit U_GYSList;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, StdCtrls, ExtCtrls, ComCtrls, ToolWin, cxStyles, cxCustomData,
|
||||
cxGraphics, cxFilter, cxData, cxDataStorage, cxEdit, DB, cxDBData, ADODB,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxClasses,
|
||||
cxControls, cxGridCustomView, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridDBTableView, cxGrid, DBClient, cxCheckBox, cxCalendar, cxSplitter,
|
||||
RM_Dataset, RM_System, RM_Common, RM_Class, RM_GridReport, RM_e_Xls,
|
||||
Menus, cxButtonEdit, cxDropDownEdit, cxPC, cxLookAndFeels,
|
||||
cxLookAndFeelPainters, cxNavigator, dxBarBuiltInMenu;
|
||||
|
||||
type
|
||||
TfrmGYSList = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBAdd: TToolButton;
|
||||
TBEdit: TToolButton;
|
||||
TBDel: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Tv1: TcxGridDBTableView;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
cxGrid1: TcxGrid;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
TBExport: TToolButton;
|
||||
Order_Main: TClientDataSet;
|
||||
ToolButton1: TToolButton;
|
||||
Panel1: TPanel;
|
||||
Label9: TLabel;
|
||||
KHNameJC: TEdit;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
Label2: TLabel;
|
||||
KHCode: TEdit;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
Label34: TLabel;
|
||||
v1Column3: TcxGridDBColumn;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
KHType: TEdit;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
Label1: TLabel;
|
||||
TJKHName: TEdit;
|
||||
CheckBox1: TCheckBox;
|
||||
ToolButton2: TToolButton;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N2: TMenuItem;
|
||||
N1: TMenuItem;
|
||||
v1Column8: TcxGridDBColumn;
|
||||
ToolButton3: TToolButton;
|
||||
v1Column12: TcxGridDBColumn;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
Panel2: TPanel;
|
||||
Label3: TLabel;
|
||||
LockDays: TEdit;
|
||||
ToolButton4: TToolButton;
|
||||
cxTabControl1: TcxTabControl;
|
||||
v1Column15: TcxGridDBColumn;
|
||||
ToolButton5: TToolButton;
|
||||
Panel3: TPanel;
|
||||
BigType: TComboBox;
|
||||
Label4: TLabel;
|
||||
v1Column16: TcxGridDBColumn;
|
||||
Label5: TLabel;
|
||||
FZPerson: TEdit;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure TBEditClick(Sender: TObject);
|
||||
procedure TBDelClick(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure TBAddClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure CheckBox1Click(Sender: TObject);
|
||||
procedure CheckBox2Click(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure CustomerNoNameChange(Sender: TObject);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
procedure ToolButton4Click(Sender: TObject);
|
||||
procedure ToolButton5Click(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure v1Column16PropertiesChange(Sender: TObject);
|
||||
procedure Tv1MouseDown(Sender: TObject; Button: TMouseButton;
|
||||
Shift: TShiftState; X, Y: Integer);
|
||||
private
|
||||
canshu1:string;
|
||||
DQdate:TDateTime;
|
||||
procedure InitGrid();
|
||||
procedure InitForm();
|
||||
function DelData():Boolean;
|
||||
{ Private declarations }
|
||||
public
|
||||
FFInt,FCloth:Integer;
|
||||
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmGYSList: TfrmGYSList;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp, U_GYSInPutTab, U_ZDYHelpSel;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmGYSList.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmGYSList:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.FormCreate(Sender: TObject);
|
||||
begin
|
||||
cxgrid1.Align:=alClient;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
WriteCxGrid('供应商登记',Tv1,'供应商管理');
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from ZH_KH_Info A ');
|
||||
sql.Add(' where Type=''GYS'' ');
|
||||
if CheckBox1.Checked=false then
|
||||
begin
|
||||
sql.Add(' and Valid=''Y'' ');
|
||||
end;
|
||||
if cxTabControl1.TabIndex=0 then
|
||||
begin
|
||||
sql.Add(' and isnull(BigType,'''')=''应付款'' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=1 then
|
||||
begin
|
||||
sql.Add(' and isnull(BigType,'''')=''单证'' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=2 then
|
||||
begin
|
||||
sql.Add(' and isnull(BigType,'''')=''仓库'' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=3 then
|
||||
begin
|
||||
sql.Add(' and isnull(BigType,'''')=''机物料'' ');
|
||||
end else
|
||||
if cxTabControl1.TabIndex=4 then
|
||||
begin
|
||||
sql.Add(' and isnull(BigType,'''')=''其他'' ');
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,Order_Main);
|
||||
SInitCDSData20(ADOQueryMain,Order_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
procedure TfrmGYSList.InitForm();
|
||||
begin
|
||||
ReadCxGrid('供应商登记',Tv1,'供应商管理');
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.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 TfrmGYSList.TBEditClick(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
try
|
||||
frmGYSInPutTab:=TfrmGYSInPutTab.Create(Application);
|
||||
with frmGYSInPutTab do
|
||||
begin
|
||||
PState:=1;
|
||||
FMainId:=Trim(Self.Order_Main.fieldbyname('ZKId').AsString);
|
||||
frmGYSInPutTab.canshu1:=Trim(Self.canshu1);
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmGYSInPutTab.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.TBDelClick(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select Top 1* from JYOrder_Main_MD_DuiZhang ');
|
||||
sql.Add(' where FactoryNo='''+Trim(Order_Main.fieldbyname('ZKId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty=False then
|
||||
begin
|
||||
Application.MessageBox('已有对账数据不能删除!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select Top 1* from YF_Money_PaiKuan ');
|
||||
sql.Add(' where FactoryNo='''+Trim(Order_Main.fieldbyname('ZKId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty=False then
|
||||
begin
|
||||
Application.MessageBox('已有资金申请数据不能删除!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select Top 1* from JYOrder_Main_MD ');
|
||||
sql.Add(' where FactoryNo='''+Trim(Order_Main.fieldbyname('ZKId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty=False then
|
||||
begin
|
||||
Application.MessageBox('已有码单数据不能删除!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select Top 1* from YF_Money_CR ');
|
||||
sql.Add(' where FactoryNo='''+Trim(Order_Main.fieldbyname('ZKId').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty=False then
|
||||
begin
|
||||
Application.MessageBox('已有入账数据不能删除!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Application.MessageBox('确定要删除数据吗?','提示',32+4)<>IDYES then Exit;
|
||||
if DelData() then
|
||||
begin
|
||||
Order_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
|
||||
function TfrmGYSList.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update ZH_KH_Info Set Valid=''N'' where ZKId='''+Trim(Order_Main.fieldbyname('ZKId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then Exit;
|
||||
TcxGridToExcel('供应商列表',cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.TBAddClick(Sender: TObject);
|
||||
var
|
||||
maxno:string;
|
||||
begin
|
||||
try
|
||||
frmGYSInPutTab:=TfrmGYSInPutTab.Create(Application);
|
||||
with frmGYSInPutTab do
|
||||
begin
|
||||
PState:=0;
|
||||
FMainId:='';
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmGYSInPutTab.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.FormShow(Sender: TObject);
|
||||
begin
|
||||
InitForm();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.CheckBox1Click(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.CheckBox2Click(Sender: TObject);
|
||||
begin
|
||||
TBRafresh.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
try
|
||||
frmGYSInPutTab:=TfrmGYSInPutTab.Create(Application);
|
||||
with frmGYSInPutTab do
|
||||
begin
|
||||
PState:=1;
|
||||
FMainId:=Trim(Self.Order_Main.fieldbyname('ZKId').AsString);
|
||||
TBSave.Visible:=False;
|
||||
if ShowModal=1 then
|
||||
begin
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmGYSInPutTab.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.CustomerNoNameChange(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 TfrmGYSList.ToolButton2Click(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
if Order_Main.Locate('SSel',True,[])=False then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Application.MessageBox('确定要锁定数据吗?','提示',32+4)<>IDYES then Exit;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
Order_Main.DisableControls;
|
||||
with Order_Main do
|
||||
begin
|
||||
First;
|
||||
while Order_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update ZH_KH_Info Set ');
|
||||
sql.Add(' LockFlag=1');
|
||||
sql.Add(' where ZKID='''+Order_Main.fieldbyname('ZKID').AsString+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
Edit;
|
||||
FieldByName('SSel').Value:=False;
|
||||
FieldByName('LockFlag').Value:=True;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
Order_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
//Application.MessageBox('锁定成功!','提示',0);
|
||||
Exit;
|
||||
except
|
||||
Order_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('锁定异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(Order_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(Order_Main,False);
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.ToolButton3Click(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
if Order_Main.Locate('SSel',True,[])=False then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Application.MessageBox('确定要解锁数据吗?','提示',32+4)<>IDYES then Exit;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
Order_Main.DisableControls;
|
||||
with Order_Main do
|
||||
begin
|
||||
First;
|
||||
while Order_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update ZH_KH_Info Set ');
|
||||
sql.Add(' LockFlag=0');
|
||||
sql.Add(' where ZKID='''+Order_Main.fieldbyname('ZKID').AsString+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
Edit;
|
||||
FieldByName('SSel').Value:=False;
|
||||
FieldByName('LockFlag').Value:=False;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
Order_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
//Application.MessageBox('解锁成功!','提示',0);
|
||||
Exit;
|
||||
except
|
||||
Order_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('解锁异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.ToolButton4Click(Sender: TObject);
|
||||
var
|
||||
FInteger:Integer;
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
if Order_Main.Locate('SSel',True,[])=False then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Trim(LockDays.Text)='' then
|
||||
begin
|
||||
Application.MessageBox('账期天数不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if TryStrToInt(Trim(LockDays.Text),FInteger)=False then
|
||||
begin
|
||||
Application.MessageBox('账期天数非法数字!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Application.MessageBox('确定要更新账期天数吗?','提示',32+4)<>IDYES then Exit;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
Order_Main.DisableControls;
|
||||
with Order_Main do
|
||||
begin
|
||||
First;
|
||||
while Order_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update ZH_KH_Info Set ');
|
||||
sql.Add(' lockDays='+LockDays.Text);
|
||||
sql.Add(' where ZKID='''+Order_Main.fieldbyname('ZKID').AsString+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
Edit;
|
||||
FieldByName('SSel').Value:=False;
|
||||
FieldByName('lockDays').Value:=LockDays.Text;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
Order_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Application.MessageBox('更新成功!','提示',0);
|
||||
Exit;
|
||||
except
|
||||
Order_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('更新异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.ToolButton5Click(Sender: TObject);
|
||||
begin
|
||||
if Order_Main.IsEmpty then Exit;
|
||||
if Order_Main.Locate('SSel',True,[])=False then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Trim(BigType.Text)='' then
|
||||
begin
|
||||
Application.MessageBox('大类不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Application.MessageBox('确定要更新大类吗?','提示',32+4)<>IDYES then Exit;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
Order_Main.DisableControls;
|
||||
with Order_Main do
|
||||
begin
|
||||
First;
|
||||
while Order_Main.Locate('SSel',True,[]) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update ZH_KH_Info Set ');
|
||||
sql.Add(' BigType='''+Trim(BigType.Text)+'''');
|
||||
sql.Add(' where ZKID='''+Order_Main.fieldbyname('ZKID').AsString+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
Edit;
|
||||
FieldByName('SSel').Value:=False;
|
||||
FieldByName('BigType').Value:=BigType.Text;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
Order_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Application.MessageBox('更新成功!','提示',0);
|
||||
Exit;
|
||||
except
|
||||
Order_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('更新异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.v1Column16PropertiesChange(Sender: TObject);
|
||||
var
|
||||
mvalue:String;
|
||||
begin
|
||||
mvalue:=TcxComboBox(Sender).EditText;
|
||||
with Order_Main do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('FZPerson').Value:=Trim(mvalue);
|
||||
Post;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update ZH_KH_Info Set FZPerson='''+Trim(mvalue)+'''');
|
||||
SQL.Add(' where ZKID='''+Trim(Order_Main.fieldbyname('ZKID').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSList.Tv1MouseDown(Sender: TObject; Button: TMouseButton;
|
||||
Shift: TShiftState; X, Y: Integer);
|
||||
var
|
||||
fsj:string;
|
||||
begin
|
||||
fsj:='select distinct(FZPerson) Name ,Code='''' from ZH_KH_Info where Type=''GYS''';
|
||||
SInitCxGridComboBoxBySql(ADOQueryCmd,v1Column16,fsj,0,True,'');
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,304 +0,0 @@
|
|||
object frmGYSSelList: TfrmGYSSelList
|
||||
Left = 206
|
||||
Top = 98
|
||||
Width = 906
|
||||
Height = 606
|
||||
Caption = #20379#24212#21830#36873#25321
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 890
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36873#25321
|
||||
ImageIndex = 10
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 99
|
||||
Width = 890
|
||||
Height = 468
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 1
|
||||
object Tv1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellDblClick = Tv1CellDblClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column2: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830#32534#21495
|
||||
DataBinding.FieldName = 'KHCode'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 117
|
||||
end
|
||||
object v1Column7: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830#20840#31216
|
||||
DataBinding.FieldName = 'KHName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 88
|
||||
end
|
||||
object v1Column6: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830#31616#31216
|
||||
DataBinding.FieldName = 'KHNameJC'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 139
|
||||
end
|
||||
object v1Column1: TcxGridDBColumn
|
||||
Caption = #20379#24212#21830#31867#22411
|
||||
DataBinding.FieldName = 'KHType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 81
|
||||
end
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #32479#35745#21333#20301#21517#31216
|
||||
DataBinding.FieldName = 'TJKHName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 102
|
||||
end
|
||||
object v1Column9: TcxGridDBColumn
|
||||
Caption = #30005#35805
|
||||
DataBinding.FieldName = 'ZKTelNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 96
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #20256#30495
|
||||
DataBinding.FieldName = 'ZKFax'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 89
|
||||
end
|
||||
object v1Column11: TcxGridDBColumn
|
||||
Caption = #22320#22336
|
||||
DataBinding.FieldName = 'ZKAddress'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 112
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 890
|
||||
Height = 67
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 2
|
||||
object Label9: TLabel
|
||||
Left = 27
|
||||
Top = 15
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #20379#24212#21830#31616#31216
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 27
|
||||
Top = 39
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #20379#24212#21830#32534#21495
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label34: TLabel
|
||||
Left = 261
|
||||
Top = 15
|
||||
Width = 65
|
||||
Height = 12
|
||||
Caption = #20379#24212#21830#31867#22411
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label1: TLabel
|
||||
Left = 253
|
||||
Top = 39
|
||||
Width = 78
|
||||
Height = 12
|
||||
Caption = #32479#35745#21333#20301#21517#31216
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object KHNameJC: TEdit
|
||||
Tag = 2
|
||||
Left = 94
|
||||
Top = 11
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 0
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
object KHCode: TEdit
|
||||
Tag = 2
|
||||
Left = 94
|
||||
Top = 35
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 1
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
object KHType: TEdit
|
||||
Tag = 2
|
||||
Left = 332
|
||||
Top = 11
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
object TJKHName: TEdit
|
||||
Tag = 2
|
||||
Left = 332
|
||||
Top = 35
|
||||
Width = 125
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = CustomerNoNameChange
|
||||
end
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 464
|
||||
Top = 160
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 432
|
||||
Top = 200
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 392
|
||||
Top = 200
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 304
|
||||
Top = 152
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = Order_Main
|
||||
Left = 352
|
||||
Top = 160
|
||||
end
|
||||
object Order_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 416
|
||||
Top = 160
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 304
|
||||
Top = 192
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N2Click
|
||||
end
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N1Click
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -1,221 +0,0 @@
|
|||
unit U_GYSSelList;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, StdCtrls, ExtCtrls, ComCtrls, ToolWin, cxStyles, cxCustomData,
|
||||
cxGraphics, cxFilter, cxData, cxDataStorage, cxEdit, DB, cxDBData, ADODB,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxClasses,
|
||||
cxControls, cxGridCustomView, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridDBTableView, cxGrid, DBClient, cxCheckBox, cxCalendar, cxSplitter,
|
||||
RM_Dataset, RM_System, RM_Common, RM_Class, RM_GridReport, RM_e_Xls,
|
||||
Menus, cxButtonEdit, cxDropDownEdit;
|
||||
|
||||
type
|
||||
TfrmGYSSelList = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Tv1: TcxGridDBTableView;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
cxGrid1: TcxGrid;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
Order_Main: TClientDataSet;
|
||||
ToolButton1: TToolButton;
|
||||
Panel1: TPanel;
|
||||
Label9: TLabel;
|
||||
KHNameJC: TEdit;
|
||||
v1Column2: TcxGridDBColumn;
|
||||
v1Column6: TcxGridDBColumn;
|
||||
Label2: TLabel;
|
||||
KHCode: TEdit;
|
||||
v1Column1: TcxGridDBColumn;
|
||||
Label34: TLabel;
|
||||
v1Column7: TcxGridDBColumn;
|
||||
v1Column9: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
v1Column11: TcxGridDBColumn;
|
||||
KHType: TEdit;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
Label1: TLabel;
|
||||
TJKHName: TEdit;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N2: TMenuItem;
|
||||
N1: TMenuItem;
|
||||
TBFind: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure CheckBox1Click(Sender: TObject);
|
||||
procedure CheckBox2Click(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure CustomerNoNameChange(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure Tv1CellDblClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
private
|
||||
canshu1:string;
|
||||
DQdate:TDateTime;
|
||||
procedure InitGrid();
|
||||
procedure InitForm();
|
||||
function DelData():Boolean;
|
||||
{ Private declarations }
|
||||
public
|
||||
FFInt,FCloth:Integer;
|
||||
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmGYSSelList: TfrmGYSSelList;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun,U_ZDYHelp, U_GYSInPutTab, U_ZDYHelpSel;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmGYSSelList.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmGYSSelList:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.FormCreate(Sender: TObject);
|
||||
begin
|
||||
cxgrid1.Align:=alClient;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
WriteCxGrid('供应商登记',Tv1,'供应商管理');
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from ZH_KH_Info A ');
|
||||
sql.Add(' where Type=''GYS'' ');
|
||||
sql.Add(' and Valid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,Order_Main);
|
||||
SInitCDSData20(ADOQueryMain,Order_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
procedure TfrmGYSSelList.InitForm();
|
||||
begin
|
||||
ReadCxGrid('供应商登记',Tv1,'供应商管理');
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.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;
|
||||
|
||||
function TfrmGYSSelList.DelData():Boolean;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update ZH_KH_Info Set Valid=''N'' where ZKId='''+Trim(Order_Main.fieldbyname('ZKId').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result:=True;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result:=False;
|
||||
Application.MessageBox('数据删除异常!','提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.FormShow(Sender: TObject);
|
||||
begin
|
||||
InitForm();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.CheckBox1Click(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.CheckBox2Click(Sender: TObject);
|
||||
begin
|
||||
TBRafresh.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
ModalResult:=1;
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.CustomerNoNameChange(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 TfrmGYSSelList.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(Order_Main,True);
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(Order_Main,False);
|
||||
end;
|
||||
|
||||
procedure TfrmGYSSelList.Tv1CellDblClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
ModalResult:=1;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,904 +0,0 @@
|
|||
unit U_GetDllForm;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, forms, OleCtnrs, DateUtils, SysUtils, ADODB, 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;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_BaoGuanList, U_BaoGuanListZXD, U_BaoGuanXSList, U_BaoGuanCRKCX,
|
||||
U_ContractDCList, U_ContractDCListChk, U_CHList, U_BaoGuanListQR, U_YFGLList,
|
||||
U_JHDMAKELIST, U_XYZMAKELIST, U_CHHZList, U_GJKDList, U_JDDATEManage,
|
||||
U_XSQKList;
|
||||
|
||||
var
|
||||
frmBaoGuanList, frmBaoGuanListGQX, frmBaoGuanListCXGQX, frmBaoGuanListZL: TfrmBaoGuanList;
|
||||
frmBaoGuanListHT, frmBaoGuanListFP, frmBaoGuanListZXD, frmBaoGuanListBGD: TfrmBaoGuanList;
|
||||
frmBaoGuanListSBYS, frmBaoGuanListHD, frmBaoGuanListSH, frmBaoGuanListDJ: TfrmBaoGuanList;
|
||||
frmContractDCListLR, frmContractDCListGL, frmContractDCListZZ, frmContractDCListQR: TfrmContractDCList;
|
||||
frmCHList, frmCHGLList: TfrmCHList;
|
||||
frmCHhzList: TfrmCHhzList;
|
||||
frmYFGLList, frmYFCXList: TfrmYFGLList;
|
||||
frmBaoGuanListQR: TfrmBaoGuanListQR;
|
||||
frmJHDMAKEList: TfrmJHDMAKEList; //结汇单制作
|
||||
frmxyzMAKEList: TfrmxyzMAKEList; //信用证制作
|
||||
frmGJKDList: TfrmGJKDList;
|
||||
frmXSQKLLIST: tfrmXSQKLLIST;
|
||||
/////////////////////////////////////////////////////////////////
|
||||
// 功能说明:取Dll中得窗体 //
|
||||
// 参数说明:App>>调用应用程序; //
|
||||
// FormH>>调用窗口句柄 ; //
|
||||
// FormID>>窗口号; //
|
||||
// Language>>语言种类; //
|
||||
// WinStyle>>窗口类型; //
|
||||
/////////////////////////////////////////////////////////////////
|
||||
|
||||
function GetDllForm(App: Tapplication; FormH: hwnd; FormID: integer; Language: integer; WinStyle: integer; GCode: Pchar; GName: Pchar; DataBase: Pchar; Title: PChar; Parameters1: PChar; Parameters2: PChar; Parameters3: PChar; Parameters4: PChar; Parameters5: PChar; Parameters6: PChar; Parameters7: PChar; Parameters8: PChar; Parameters9: PChar; Parameters10: PChar; DataBaseStr: PChar): hwnd;
|
||||
var
|
||||
i: Integer;
|
||||
bFound: Boolean;
|
||||
mnewHandle: hwnd;
|
||||
mstyle: TFormStyle; // 0:子窗口; 1:普通窗口
|
||||
mstate: TWindowState;
|
||||
mborderstyle: TFormBorderStyle;
|
||||
begin
|
||||
mnewHandle := 0;
|
||||
DName := PChar(GName);
|
||||
DCode := PChar(GCode);
|
||||
DdataBase := DataBase;
|
||||
DTitCaption := Title;
|
||||
DParameters1 := Parameters1;
|
||||
DParameters2 := Parameters2;
|
||||
DParameters3 := Parameters3;
|
||||
DParameters4 := Parameters4;
|
||||
DParameters5 := Parameters5;
|
||||
DParameters6 := Parameters6;
|
||||
DParameters7 := Parameters7;
|
||||
DParameters8 := Parameters8;
|
||||
DParameters9 := Parameters9;
|
||||
DParameters10 := Parameters10;
|
||||
|
||||
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.100.130.130,7781';
|
||||
// server := '.';
|
||||
dtbase := 'zhenyongdata';
|
||||
user := 'zhenyongsa';
|
||||
pswd := 'rightsoft@9101';
|
||||
// pswd := 'rightsoft';
|
||||
DConString := 'Provider=SQLOLEDB.1;Password=' + pswd + ';Persist Security Info=True;User ID=' + user + ';Initial Catalog=' + dtbase + ';Data Source=' + server;
|
||||
DConString := DataBaseStr;
|
||||
// DName:='司洋';
|
||||
//DParameters1:='高权限';
|
||||
//DParameters2:='';
|
||||
if not ConnData() then
|
||||
begin
|
||||
result := 0;
|
||||
exit;
|
||||
end;
|
||||
|
||||
// 定义窗口类型 、状态
|
||||
if WinStyle = 0 then
|
||||
begin
|
||||
mstyle := fsMDIChild;
|
||||
mstate := wsMaximized;
|
||||
mborderstyle := bsSizeable;
|
||||
end
|
||||
else
|
||||
begin
|
||||
mstyle := fsNormal;
|
||||
mstate := wsNormal;
|
||||
mborderstyle := bsSizeable;
|
||||
end;
|
||||
//Title:='报关管理';
|
||||
/////////////////////
|
||||
//调用子模块窗口
|
||||
case FormID of
|
||||
211: //订舱指示书
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '订舱指示书' then
|
||||
begin
|
||||
BringWindowToTop(frmContractDCListLR.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
begin
|
||||
frmContractDCListLR := TfrmContractDCList.Create(application.MainForm);
|
||||
with frmContractDCListLR do
|
||||
begin
|
||||
canshu1 := '录入';
|
||||
Title := '订舱指示书';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmContractDCListLR.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmContractDCListLR.Handle;
|
||||
end;
|
||||
|
||||
212: //订舱指示书(组长)
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '订舱指示书(组长)' then
|
||||
begin
|
||||
BringWindowToTop(frmContractDCListZZ.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
begin
|
||||
frmContractDCListZZ := tfrmContractDCList.Create(application.MainForm);
|
||||
with frmContractDCListZZ do
|
||||
begin
|
||||
canshu1 := '录入';
|
||||
canshu2 := '组长';
|
||||
Title := '订舱指示书(组长)';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmContractDCListZZ.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmContractDCListZZ.Handle;
|
||||
end;
|
||||
|
||||
221: //订舱指示书审核
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '订舱指示书审核' then
|
||||
begin
|
||||
BringWindowToTop(frmContractDCListGL.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
begin
|
||||
frmContractDCListGL := TfrmContractDCList.Create(application.MainForm);
|
||||
with frmContractDCListGL do
|
||||
begin
|
||||
canshu1 := '管理';
|
||||
Title := '订舱指示书';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmContractDCListGL.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmContractDCListGL.Handle;
|
||||
end;
|
||||
|
||||
223: //订舱指示书确认
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '订舱指示书确认' then
|
||||
begin
|
||||
BringWindowToTop(frmContractDCListQR.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
begin
|
||||
frmContractDCListQR := TfrmContractDCList.Create(application.MainForm);
|
||||
with frmContractDCListQR do
|
||||
begin
|
||||
canshu1 := '确认';
|
||||
Title := '订舱指示书确认';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmContractDCListQR.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmContractDCListQR.Handle;
|
||||
end;
|
||||
|
||||
|
||||
|
||||
// 211: //订舱指示书
|
||||
// begin
|
||||
// if frmContractDCList = nil then
|
||||
// begin
|
||||
// frmContractDCList := TfrmContractDCList.Create(application.MainForm);
|
||||
// with frmContractDCList do
|
||||
// begin
|
||||
// caption := Trim(Title);
|
||||
// FormStyle := mstyle;
|
||||
// windowState := mstate;
|
||||
// BorderStyle := mborderstyle;
|
||||
// //show;
|
||||
// end;
|
||||
// end
|
||||
// else
|
||||
// frmContractDCList.BringToFront;
|
||||
// //句柄
|
||||
// mnewHandle := frmContractDCList.Handle;
|
||||
//
|
||||
// end;
|
||||
// 221: //订舱指示书审核
|
||||
// begin
|
||||
// if frmContractDCListChk = nil then
|
||||
// begin
|
||||
// frmContractDCListChk := TfrmContractDCListChk.Create(application.MainForm);
|
||||
// with frmContractDCListChk do
|
||||
// begin
|
||||
// caption := Trim(Title);
|
||||
// FormStyle := mstyle;
|
||||
// windowState := mstate;
|
||||
// BorderStyle := mborderstyle;
|
||||
// //show;
|
||||
// end;
|
||||
// end
|
||||
// else
|
||||
// frmContractDCListChk.BringToFront;
|
||||
// //句柄
|
||||
// mnewHandle := frmContractDCListChk.Handle;
|
||||
//
|
||||
// end;
|
||||
11: //出货清单
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '出货清单' then
|
||||
begin
|
||||
BringWindowToTop(frmCHList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmCHList := TfrmCHList.Create(application.MainForm);
|
||||
with frmCHList do
|
||||
begin
|
||||
Title := '出货清单';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmCHList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmCHList.Handle;
|
||||
end;
|
||||
|
||||
111: //开票确认
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '开票确认' then
|
||||
begin
|
||||
BringWindowToTop(frmCHGLList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmCHGLList := TfrmCHList.Create(application.MainForm);
|
||||
with frmCHGLList do
|
||||
begin
|
||||
Title := '开票确认';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmCHGLList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmCHGLList.Handle;
|
||||
end;
|
||||
12: //运费管理
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '运费管理' then
|
||||
begin
|
||||
BringWindowToTop(frmYFGLList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmYFGLList := TfrmYFGLList.Create(application.MainForm);
|
||||
with frmYFGLList do
|
||||
begin
|
||||
Title := '运费管理';
|
||||
canshu1 := '管理';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmYFGLList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmYFGLList.Handle;
|
||||
end;
|
||||
|
||||
121: //运费查询
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '运费查询' then
|
||||
begin
|
||||
BringWindowToTop(frmYFCXList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmYFCXList := TfrmYFGLList.Create(application.MainForm);
|
||||
with frmYFCXList do
|
||||
begin
|
||||
Title := '运费查询';
|
||||
canshu1 := '查询';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmYFCXList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmYFCXList.Handle;
|
||||
end;
|
||||
|
||||
13: //出货汇总清单
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '出货汇总清单' then
|
||||
begin
|
||||
BringWindowToTop(frmCHhzList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmCHhzList := TfrmCHhzList.Create(application.MainForm);
|
||||
with frmCHhzList do
|
||||
begin
|
||||
Title := '出货汇总清单';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmCHhzList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmCHhzList.Handle;
|
||||
end;
|
||||
131: //销售情况表
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '出货汇总清单' then
|
||||
begin
|
||||
BringWindowToTop(frmXSQKLLIST.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmXSQKLLIST := TfrmXSQKLLIST.Create(application.MainForm);
|
||||
with frmXSQKLLIST do
|
||||
begin
|
||||
Title := '销售情况表';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmXSQKLLIST.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmXSQKLLIST.Handle;
|
||||
end;
|
||||
|
||||
14: //国际快递
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '国际快递' then
|
||||
begin
|
||||
BringWindowToTop(frmGJKDList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmGJKDList := TfrmGJKDList.Create(application.MainForm);
|
||||
with frmGJKDList do
|
||||
begin
|
||||
Title := '国际快递';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmGJKDList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmGJKDList.Handle;
|
||||
end;
|
||||
-1: //报关资料录入
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '报关资料录入' then
|
||||
begin
|
||||
BringWindowToTop(frmBaoGuanList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmBaoGuanList := TfrmBaoGuanList.Create(application.MainForm);
|
||||
with frmBaoGuanList do
|
||||
begin
|
||||
Title := '报关资料录入';
|
||||
canshu3 := '业务员';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanList.Handle;
|
||||
end;
|
||||
-2: //报关资料录入(高权限)
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '报关资料录入(高权限)' then
|
||||
begin
|
||||
BringWindowToTop(frmBaoGuanListGQX.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmBaoGuanListGQX := TfrmBaoGuanList.Create(application.MainForm);
|
||||
with frmBaoGuanListGQX do
|
||||
begin
|
||||
Title := '报关资料录入(高权限)';
|
||||
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanListGQX.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanListGQX.Handle;
|
||||
end;
|
||||
|
||||
-7: //报关资料审核
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '报关资料审核' then
|
||||
begin
|
||||
BringWindowToTop(frmBaoGuanListQR.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanListSBYS=nil then
|
||||
begin
|
||||
frmBaoGuanListQR := TfrmBaoGuanListQR.Create(application.MainForm);
|
||||
with frmBaoGuanListQR do
|
||||
begin
|
||||
Title := '报关资料审核';
|
||||
canshu3 := '单证';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanListQR.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanListQR.Handle;
|
||||
end;
|
||||
-5: //报关资料查询(高权限)
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '报关资料查询(高权限)' then
|
||||
begin
|
||||
BringWindowToTop(frmBaoGuanListCXGQX.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanListBGZL=nil then
|
||||
begin
|
||||
frmBaoGuanListCXGQX := TfrmBaoGuanList.Create(application.MainForm);
|
||||
with frmBaoGuanListCXGQX do
|
||||
begin
|
||||
Title := '报关资料查询(高权限)';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanListCXGQX.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanListCXGQX.Handle;
|
||||
end;
|
||||
-6: //报关销售资料
|
||||
begin
|
||||
if frmBaoGuanXSList = nil then
|
||||
begin
|
||||
frmBaoGuanXSList := TfrmBaoGuanXSList.Create(application.MainForm);
|
||||
with frmBaoGuanXSList do
|
||||
begin
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanXSList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanXSList.Handle;
|
||||
end;
|
||||
|
||||
1: //报关管理(单机)
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '报关管理' then
|
||||
begin
|
||||
BringWindowToTop(frmBaoGuanListDJ.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanList=nil then
|
||||
begin
|
||||
frmBaoGuanListDJ := TfrmBaoGuanList.Create(application.MainForm);
|
||||
with frmBaoGuanListDJ do
|
||||
begin
|
||||
Title := '报关管理';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanListDJ.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanListDJ.Handle;
|
||||
end;
|
||||
|
||||
2: //报关出入库查询
|
||||
begin
|
||||
if frmBaoGuanCRKCX = nil then
|
||||
begin
|
||||
frmBaoGuanCRKCX := TfrmBaoGuanCRKCX.Create(application.MainForm);
|
||||
with frmBaoGuanCRKCX do
|
||||
begin
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanCRKCX.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanCRKCX.Handle;
|
||||
end;
|
||||
-3: //报关资料核对
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '报关资料核对' then
|
||||
begin
|
||||
BringWindowToTop(frmBaoGuanListHD.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanListSBYS=nil then
|
||||
begin
|
||||
frmBaoGuanListHD := TfrmBaoGuanList.Create(application.MainForm);
|
||||
with frmBaoGuanListHD do
|
||||
begin
|
||||
Title := '报关资料核对';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanListHD.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanListHD.Handle;
|
||||
end;
|
||||
-4: //报关资料审核
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '报关资料审核' then
|
||||
begin
|
||||
BringWindowToTop(frmBaoGuanListSH.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanListSBYS=nil then
|
||||
begin
|
||||
frmBaoGuanListSH := TfrmBaoGuanList.Create(application.MainForm);
|
||||
with frmBaoGuanListSH do
|
||||
begin
|
||||
Title := '报关资料审核';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmBaoGuanListSH.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmBaoGuanListSH.Handle;
|
||||
end;
|
||||
|
||||
44: //结汇单制作
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '结汇单制作' then
|
||||
begin
|
||||
BringWindowToTop(frmJHDMAKEList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanListSBYS=nil then
|
||||
begin
|
||||
frmJHDMAKEList := TfrmJHDMAKEList.Create(application.MainForm);
|
||||
with frmJHDMAKEList do
|
||||
begin
|
||||
Title := '结汇单制作';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmJHDMAKEList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmJHDMAKEList.Handle;
|
||||
end;
|
||||
|
||||
51: //信用证管理
|
||||
begin
|
||||
bFound := FALSE;
|
||||
for i := (App.MainForm.MDIChildCount - 1) downto 0 do
|
||||
begin
|
||||
if App.MainForm.MDIChildren[i].Caption = '信用证管理' then
|
||||
begin
|
||||
BringWindowToTop(frmxyzMAKEList.Handle);
|
||||
bFound := TRUE;
|
||||
Break;
|
||||
end;
|
||||
end;
|
||||
if not bFound then
|
||||
//if frmBaoGuanListSBYS=nil then
|
||||
begin
|
||||
frmxyzMAKEList := TfrmxyzMAKEList.Create(application.MainForm);
|
||||
with frmxyzMAKEList do
|
||||
begin
|
||||
Title := '信用证管理';
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmxyzMAKEList.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmxyzMAKEList.Handle;
|
||||
end;
|
||||
|
||||
99: //报单日期管理
|
||||
begin
|
||||
if frmjddateManage = nil then
|
||||
begin
|
||||
frmjddateManage := TfrmjddateManage.Create(application.MainForm);
|
||||
with frmjddateManage do
|
||||
begin
|
||||
caption := Trim(Title);
|
||||
FormStyle := mstyle;
|
||||
windowState := mstate;
|
||||
BorderStyle := mborderstyle;
|
||||
//show;
|
||||
end;
|
||||
end
|
||||
else
|
||||
frmjddateManage.BringToFront;
|
||||
//句柄
|
||||
mnewHandle := frmjddateManage.Handle;
|
||||
end;
|
||||
end; // end case
|
||||
|
||||
Result := mnewHandle;
|
||||
// NewDllApp := Application;
|
||||
end;
|
||||
//===========================================================
|
||||
//建立数据库连接池
|
||||
//===========================================================
|
||||
|
||||
function ConnData(): Boolean;
|
||||
begin
|
||||
if not Assigned(DataLink_DDMD) then
|
||||
DataLink_DDMD := TDataLink_DDMD.Create(Application);
|
||||
try
|
||||
with DataLink_DDMD.ADOLink do
|
||||
begin
|
||||
//if not Connected then
|
||||
begin
|
||||
Connected := false;
|
||||
ConnectionString := DConString;
|
||||
LoginPrompt := false;
|
||||
Connected := true;
|
||||
end;
|
||||
end;
|
||||
Result := true;
|
||||
except
|
||||
Result := false;
|
||||
application.MessageBox('数据库连接失败!', '错误', mb_Ok + MB_ICONERROR);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
initialization
|
||||
CoInitialize(nil);
|
||||
dxUnitsLoader.Initialize;
|
||||
|
||||
|
||||
finalization
|
||||
DataLink_DDMD.Free;
|
||||
application := NewDllApp;
|
||||
dxUnitsLoader.Finalize;
|
||||
//initialization
|
||||
// OldDllApp := Application;
|
||||
//
|
||||
//finalization
|
||||
// DataLink_DDMD.Free;
|
||||
// Application := OldDllApp;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -1,228 +0,0 @@
|
|||
object frmjddateManage: TfrmjddateManage
|
||||
Left = 297
|
||||
Top = 109
|
||||
Width = 1123
|
||||
Height = 706
|
||||
Caption = #25910#27719#26041#24335#31649#29702
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
KeyPreview = True
|
||||
OldCreateOrder = False
|
||||
OnClose = FormClose
|
||||
OnCreate = FormCreate
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1107
|
||||
Height = 31
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object ToolButton4: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #22686#34892
|
||||
ImageIndex = 57
|
||||
OnClick = ToolButton4Click
|
||||
end
|
||||
object ToolButton5: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#34892
|
||||
ImageIndex = 113
|
||||
OnClick = ToolButton5Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 31
|
||||
Width = 1107
|
||||
Height = 636
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 1
|
||||
object Tv1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
Navigator.Buttons.Delete.Enabled = False
|
||||
Navigator.Buttons.Delete.Visible = False
|
||||
DataController.DataSource = DS_HZ
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsData.Deleting = False
|
||||
OptionsData.DeletingConfirmation = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v2Column12: TcxGridDBColumn
|
||||
Caption = ' '#25910' '#27719' '#26041' '#24335' '
|
||||
DataBinding.FieldName = 'ZDYNAME'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = v2Column8PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 419
|
||||
end
|
||||
object Tv1Column1: TcxGridDBColumn
|
||||
Caption = #22825#25968
|
||||
DataBinding.FieldName = 'note'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = Tv1Column1PropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 96
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 299
|
||||
Top = 210
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 261
|
||||
Top = 209
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 229
|
||||
Top = 209
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbExport, pbNavigator]
|
||||
DefaultCollate = False
|
||||
ShowPrintDialog = False
|
||||
SaveReportOptions.RegistryPath = 'Software\ReportMachine\ReportSettings\'
|
||||
PreviewOptions.RulerUnit = rmutScreenPixels
|
||||
PreviewOptions.RulerVisible = False
|
||||
PreviewOptions.DrawBorder = False
|
||||
PreviewOptions.BorderPen.Color = clGray
|
||||
PreviewOptions.BorderPen.Style = psDash
|
||||
Dataset = RMDB_Main
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 355
|
||||
Top = 344
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDB_Main: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = ADOQueryPrt
|
||||
Left = 289
|
||||
Top = 343
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 520
|
||||
Top = 264
|
||||
end
|
||||
object DS_HZ: TDataSource
|
||||
DataSet = CDS_HZ
|
||||
Left = 283
|
||||
Top = 259
|
||||
end
|
||||
object CDS_HZ: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 384
|
||||
Top = 208
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 192
|
||||
Top = 240
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object RMXLSExport2: TRMXLSExport
|
||||
ShowAfterExport = False
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 1
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 420
|
||||
Top = 344
|
||||
end
|
||||
object ADOQueryPrt: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 230
|
||||
Top = 345
|
||||
end
|
||||
end
|
||||
|
|
@ -1,599 +0,0 @@
|
|||
unit U_JDDATEManage;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
|
||||
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls,
|
||||
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
|
||||
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
|
||||
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
|
||||
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
||||
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
||||
cxTextEdit, cxPC, cxCheckComboBox, cxDropDownEdit, Menus, RM_e_Xls, TeEngine,
|
||||
Series, TeeProcs, Chart, DbChart, cxLookAndFeels, cxLookAndFeelPainters,
|
||||
cxNavigator;
|
||||
|
||||
type
|
||||
TfrmjddateManage = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
RM1: TRMGridReport;
|
||||
RMDB_Main: TRMDBDataSet;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DS_HZ: TDataSource;
|
||||
CDS_HZ: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
RMXLSExport2: TRMXLSExport;
|
||||
v2Column12: TcxGridDBColumn;
|
||||
ADOQueryPrt: TADOQuery;
|
||||
ToolButton4: TToolButton;
|
||||
ToolButton5: TToolButton;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
// procedure ToolButton1Click(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
// procedure CustomerChange(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure v2Column8PropertiesEditValueChanged(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
procedure ToolButton4Click(Sender: TObject);
|
||||
procedure ToolButton5Click(Sender: TObject);
|
||||
procedure Tv1Column1PropertiesEditValueChanged(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
procedure PrintReport(FZDYNo: string);
|
||||
procedure InitGrid();
|
||||
public
|
||||
fFlag: integer;
|
||||
{ Public declarations }
|
||||
RKFlag, FCYID, fmanage: string;
|
||||
end;
|
||||
|
||||
var
|
||||
frmjddateManage: TfrmjddateManage;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_Fun, U_ZDYHelp;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmjddateManage.PrintReport(FZDYNo: string);
|
||||
var
|
||||
fPrintFile, FFCYID: string;
|
||||
i, j: Integer;
|
||||
Txt, fImagePath: string;
|
||||
Moudle: THandle;
|
||||
Makebar: TMakebar;
|
||||
Mixtext: TMixtext;
|
||||
begin
|
||||
if CDS_HZ.IsEmpty then
|
||||
Exit;
|
||||
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\机台标签.rmf';
|
||||
with ADOQueryPrt do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add(' select * from Machine where MCNO=''' + Trim(FZDYNo) + '''');
|
||||
open;
|
||||
end;
|
||||
try
|
||||
Moudle := LoadLibrary('MakeQRBarcode.dll');
|
||||
@Makebar := GetProcAddress(Moudle, 'Make');
|
||||
@Mixtext := GetProcAddress(Moudle, 'MixText');
|
||||
Txt := Trim(FZDYNo);
|
||||
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
|
||||
CDS_HZ.EnableControls;
|
||||
application.MessageBox('条形码生成失败!', '提示信息', MB_ICONERROR);
|
||||
exit;
|
||||
end;
|
||||
RMVariables['QRBARCODE'] := fImagePath;
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.PrintReport;
|
||||
// RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + fPrintFile + '!'), '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.InitGrid();
|
||||
begin
|
||||
try
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('update t1 set t1.ZdyFlt1 = t.rn from KH_ZDY t1');
|
||||
sql.Add('join (select *,rn = ROW_NUMBER() OVER(ORDER BY ZdyFlt1) from KH_ZDY where TYPE=''shfs'')t on t1.zdyno = t.zdyno');
|
||||
sql.Add('WHERE t1.TYPE=''shfs'' ');
|
||||
execsql;
|
||||
end;
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('select A.*,ZJM=dbo.getPinYin(A.ZdyName) from KH_ZDY A where A.Type=''SHFS''');
|
||||
SQL.Add('ORDER BY ZdyFlt1');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_HZ);
|
||||
SInitCDSData20(ADOQueryMain, CDS_HZ);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmjddateManage := nil;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid(Trim(Self.Caption), Tv1, '交单日期管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid(Trim(Self.Caption), Tv1, '交单日期管理');
|
||||
// Enddate.DateTime:=SGetServerDate(ADOQueryTemp);
|
||||
// begdate.DateTime:=Enddate.DateTime-30;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.N1Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_HZ.IsEmpty then
|
||||
exit;
|
||||
with CDS_HZ do
|
||||
begin
|
||||
DisableControls;
|
||||
first;
|
||||
while not eof do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('ssel').Value := true;
|
||||
post;
|
||||
next;
|
||||
end;
|
||||
First;
|
||||
EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.N2Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_HZ.IsEmpty then
|
||||
exit;
|
||||
with CDS_HZ do
|
||||
begin
|
||||
DisableControls;
|
||||
first;
|
||||
while not eof do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('ssel').Value := false;
|
||||
post;
|
||||
next;
|
||||
end;
|
||||
First;
|
||||
EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.FormCreate(Sender: TObject);
|
||||
begin
|
||||
fmanage := Trim(DParameters1);
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.v2Column8PropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
maxno, mvalue: string;
|
||||
begin
|
||||
mvalue := TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue) = '' then
|
||||
begin
|
||||
//Application.MessageBox('名称不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
with CDS_HZ do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('ZdyName').Value := Trim(mvalue);
|
||||
//Post;
|
||||
end;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
//ClientDataSet1.DisableControls;
|
||||
//with ClientDataSet1 do
|
||||
//begin
|
||||
//First;
|
||||
//while not eof do
|
||||
//begin
|
||||
if Trim(CDS_HZ.FieldByName('ZDYNO').AsString) = '' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryTemp, maxno, 'SY', 'KH_ZDY', 3, 1) = False then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('取最大编号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
maxno := Trim(CDS_HZ.fieldbyname('ZDYNo').AsString);
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.add('select * from KH_Zdy where Type=''SHFS''');
|
||||
// if Trim(MainType) <> '' then
|
||||
// SQL.Add(' and MainType=''' + Trim(MainType) + '''');
|
||||
sql.Add(' and ZdyName=''' + Trim(CDS_HZ.fieldbyname('ZdyName').AsString) + '''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty = False then
|
||||
begin
|
||||
if ADOQueryTemp.RecordCount > 1 then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
if Trim(CDS_HZ.fieldbyname('ZdyNo').AsString) = '' then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!', '提示', 0);
|
||||
Exit;
|
||||
end
|
||||
else
|
||||
begin
|
||||
if Trim(ADOQueryTemp.fieldbyname('ZdyNo').AsString) <> Trim(CDS_HZ.fieldbyname('ZdyNo').AsString) then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
// with ADOQueryCmd do
|
||||
// begin
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// SQL.Add('delete KH_ZDY where ZDYNO=''' + Trim(ClientDataSet1.fieldbyname('ZDYNO').AsString) + '''');
|
||||
// ExecSQL;
|
||||
// end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from KH_ZDY where ZDYNO=''' + Trim(CDS_HZ.fieldbyname('ZDYNO').AsString) + '''');
|
||||
Open;
|
||||
end;
|
||||
ADOQueryCmd.Edit;
|
||||
ADOQueryCmd.FieldByName('ZDYNo').Value := Trim(maxno);
|
||||
ADOQueryCmd.FieldByName('ZDYName').Value := cds_hz.fieldbyname('ZDYName').AsString;
|
||||
ADOQueryCmd.FieldByName('note').Value := Trim(cds_hz.fieldbyname('NOTE').AsString);
|
||||
//ADOQueryCmd.FieldByName('orderno').Value:=ClientDataSet1.fieldbyname('Name').AsString;
|
||||
ADOQueryCmd.FieldByName('Type').Value := 'SHFS';
|
||||
ADOQueryCmd.FieldByName('valid').Value := 'Y';
|
||||
// if Trim(MainType) <> '' then
|
||||
// ADOQueryCmd.FieldByName('MainType').Value := Trim(MainType);
|
||||
//ADOQueryCmd.FieldByName('sel').Value:=0;
|
||||
ADOQueryCmd.Post;
|
||||
CDS_HZ.Edit;
|
||||
CDS_HZ.FieldByName('ZDYNo').Value := Trim(maxno);
|
||||
//ClientDataSet1.Post;
|
||||
// Next;
|
||||
//end;
|
||||
//end;
|
||||
// ClientDataSet1.EnableControls;
|
||||
end;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
//Application.MessageBox('保存成功!','提示',0);
|
||||
//TV1.OptionsData.Editing:=False;
|
||||
//TV1.OptionsSelection.CellSelect:=False;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('保存失败!', '提示', 0);
|
||||
end;
|
||||
// mvalue := TcxTextEdit(Sender).EditingText;
|
||||
// if Trim(mvalue) = '' then
|
||||
// begin
|
||||
// //Application.MessageBox('名称不能为空!','提示',0);
|
||||
// Exit;
|
||||
// end;
|
||||
// with CDS_HZ do
|
||||
// begin
|
||||
// Edit;
|
||||
// FieldByName('ZdyName').Value := Trim(mvalue);
|
||||
// //Post;
|
||||
// end;
|
||||
//
|
||||
// try
|
||||
// ADOQueryCmd.Connection.BeginTrans;
|
||||
// with ADOQueryTemp do
|
||||
// begin
|
||||
// Close;
|
||||
// SQL.Clear;
|
||||
// SQL.Add('select * from KH_ZDY where ZdyNo=''SHFS''');
|
||||
// open;
|
||||
// end;
|
||||
// if ADOQueryTemp.IsEmpty then
|
||||
// begin
|
||||
// with ADOQueryCmd do
|
||||
// begin
|
||||
// close;
|
||||
// sql.Clear;
|
||||
// sql.Add('insert into KH_ZDY(ZDYNo,ZDYName,Type) select :ZDYNo,:ZDYName,:Type ');
|
||||
// Parameters.ParamByName('ZDYNo').Value := 'SHFS';
|
||||
// Parameters.ParamByName('ZDYName').Value := '收汇方式';
|
||||
// Parameters.ParamByName('Type').Value := 'Main';
|
||||
//// Parameters.ParamByName('MainType').Value := Trim(MainType);
|
||||
// ExecSQL;
|
||||
// end;
|
||||
// end;
|
||||
// with ADOQueryCmd do
|
||||
// begin
|
||||
// //ClientDataSet1.DisableControls;
|
||||
// //with ClientDataSet1 do
|
||||
// //begin
|
||||
// //First;
|
||||
// //while not eof do
|
||||
// //begin
|
||||
// if Trim(CDS_HZ.FieldByName('ZDYNO').AsString) = '' then
|
||||
// begin
|
||||
// if GetLSNo(ADOQueryTemp, maxno, 'SY', 'KH_ZDY', 3, 1) = False then
|
||||
// begin
|
||||
// ADOQueryCmd.Connection.RollbackTrans;
|
||||
// //ClientDataSet1.EnableControls;
|
||||
// Application.MessageBox('取最大编号失败!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
// end
|
||||
// else
|
||||
// begin
|
||||
// maxno := Trim(CDS_HZ.fieldbyname('ZDYNo').AsString);
|
||||
// end;
|
||||
// with ADOQueryTemp do
|
||||
// begin
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// sql.add('select * from KH_Zdy where Type= ''SHFS''');
|
||||
//
|
||||
// sql.Add(' and ZdyName=''' + Trim(CDS_HZ.fieldbyname('ZdyName').AsString) + '''');
|
||||
// Open;
|
||||
// end;
|
||||
// if ADOQueryTemp.IsEmpty = False then
|
||||
// begin
|
||||
// if ADOQueryTemp.RecordCount > 1 then
|
||||
// begin
|
||||
// ADOQueryCmd.Connection.RollbackTrans;
|
||||
//
|
||||
// //ClientDataSet1.EnableControls;
|
||||
// Application.MessageBox('名称重复!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
// if Trim(CDS_HZ.fieldbyname('ZdyNo').AsString) = '' then
|
||||
// begin
|
||||
// ADOQueryCmd.Connection.RollbackTrans;
|
||||
// //ClientDataSet1.EnableControls;
|
||||
// Application.MessageBox('名称重复!', '提示', 0);
|
||||
// Exit;
|
||||
// end
|
||||
// else
|
||||
// begin
|
||||
// if Trim(ADOQueryTemp.fieldbyname('ZdyNo').AsString) <> Trim(CDS_HZ.fieldbyname('ZdyNo').AsString) then
|
||||
// begin
|
||||
// ADOQueryCmd.Connection.RollbackTrans;
|
||||
// //ClientDataSet1.EnableControls;
|
||||
// Application.MessageBox('名称重复!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
// end;
|
||||
// end;
|
||||
// with ADOQueryCmd do
|
||||
// begin
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// SQL.Add('delete KH_ZDY where ZDYNO=''' + Trim(CDS_HZ.fieldbyname('ZDYNO').AsString) + '''');
|
||||
// ExecSQL;
|
||||
// end;
|
||||
// with ADOQueryCmd do
|
||||
// begin
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// sql.Add('select * from KH_ZDY where 1<>1');
|
||||
// Open;
|
||||
// end;
|
||||
// ADOQueryCmd.Append;
|
||||
// ADOQueryCmd.FieldByName('ZDYNo').Value := Trim(maxno);
|
||||
// ADOQueryCmd.FieldByName('ZDYName').Value := CDS_HZ.fieldbyname('ZDYName').AsString;
|
||||
//// ADOQueryCmd.FieldByName('note').Value := Trim(snote);
|
||||
// //ADOQueryCmd.FieldByName('orderno').Value:=ClientDataSet1.fieldbyname('Name').AsString;
|
||||
// ADOQueryCmd.FieldByName('Type').Value := 'SHFS';
|
||||
// ADOQueryCmd.FieldByName('valid').Value := 'Y';
|
||||
//// if Trim(MainType) <> '' then
|
||||
//// ADOQueryCmd.FieldByName('MainType').Value := Trim(MainType);
|
||||
// //ADOQueryCmd.FieldByName('sel').Value:=0;
|
||||
// ADOQueryCmd.Post;
|
||||
// CDS_HZ.Edit;
|
||||
// CDS_HZ.FieldByName('ZDYNo').Value := Trim(maxno);
|
||||
// //ClientDataSet1.Post;
|
||||
// // Next;
|
||||
// //end;
|
||||
// //end;
|
||||
// // ClientDataSet1.EnableControls;
|
||||
// end;
|
||||
// ADOQueryCmd.Connection.CommitTrans;
|
||||
// //Application.MessageBox('保存成功!','提示',0);
|
||||
// //TV1.OptionsData.Editing:=False;
|
||||
// //TV1.OptionsSelection.CellSelect:=False;
|
||||
// except
|
||||
// ADOQueryCmd.Connection.RollbackTrans;
|
||||
// Application.MessageBox('保存失败!', '提示', 0);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.ToolButton3Click(Sender: TObject);
|
||||
begin
|
||||
PrintReport(Trim(CDS_HZ.fieldbyname('MCNO').AsString));
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.ToolButton4Click(Sender: TObject);
|
||||
var
|
||||
i: Integer;
|
||||
maxno: string;
|
||||
fxh: Double;
|
||||
begin
|
||||
|
||||
TV1.OptionsData.Editing := True;
|
||||
TV1.OptionsSelection.CellSelect := True;
|
||||
// for i := 0 to 5 do
|
||||
// begin
|
||||
// with CDS_HZ do
|
||||
// begin
|
||||
// Append;
|
||||
// Post;
|
||||
// end;
|
||||
// end;
|
||||
fxh := CDS_HZ.fieldbyname('ZdyFlt1').Value;
|
||||
if GetLSNo(ADOQueryTemp, maxno, 'SY', 'KH_ZDY', 3, 1) = False then
|
||||
begin
|
||||
// ADOQueryCmd.Connection.RollbackTrans;
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('取最大编号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('insert into KH_ZDY(ZDYNo,ZDYName,Type,ZdyFlt1) select :ZDYNo,:ZDYName,:Type,:ZdyFlt1 ');
|
||||
Parameters.ParamByName('ZDYNo').Value := Trim(maxno);
|
||||
Parameters.ParamByName('ZDYName').Value := '';
|
||||
|
||||
Parameters.ParamByName('Type').Value := 'shfs';
|
||||
// Parameters.ParamByName('MainType').Value := Trim(MainType);
|
||||
Parameters.ParamByName('ZdyFlt1').Value := fxh + 0.1;
|
||||
|
||||
// ADOQueryCmd.FieldByName('valid').Value := 'Y';
|
||||
ExecSQL;
|
||||
end;
|
||||
InitGrid();
|
||||
CDS_HZ.locate('ZdyFlt1', fxh, []);
|
||||
CDS_HZ.Next;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.ToolButton5Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_HZ.IsEmpty then
|
||||
Exit;
|
||||
if (Trim(CDS_HZ.FieldByName('ZDYNo').AsString) <> '') or (Trim(CDS_HZ.FieldByName('ZDYname').AsString) <> '') then
|
||||
begin
|
||||
if application.MessageBox('确定要删除吗?', '提示信息', 1) = 2 then
|
||||
exit;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete KH_ZDY where ZDYNo=''' + Trim(CDS_HZ.fieldbyname('ZDYNo').AsString) + '''');
|
||||
SQL.Add(' and Type=''SHFS''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
CDS_HZ.Delete;
|
||||
end;
|
||||
|
||||
procedure TfrmjddateManage.Tv1Column1PropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
mvalue: string;
|
||||
begin
|
||||
if Trim(CDS_HZ.fieldbyname('ZdyName').AsString) = '' then
|
||||
begin
|
||||
Application.MessageBox('名称不能为空!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
mvalue := TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue) = '' then
|
||||
begin
|
||||
mvalue := '0';
|
||||
end;
|
||||
with CDS_HZ do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('Note').Value := mvalue;
|
||||
Post;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update KH_Zdy Set Note=''' + Trim(mvalue) + '''');
|
||||
sql.Add(' where ZdyNo=''' + Trim(CDS_HZ.fieldbyname('ZdyNo').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -1,515 +0,0 @@
|
|||
object frmCHList: TfrmCHList
|
||||
Left = 132
|
||||
Top = 116
|
||||
Width = 1384
|
||||
Height = 670
|
||||
Caption = #20986#36135#28165#21333
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1368
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 26
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1368
|
||||
Height = 59
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #26597#35810#26102#38388
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 348
|
||||
Top = 12
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #22806#38144#21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 205
|
||||
Top = 35
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #24037#21378
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 522
|
||||
Top = 11
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #23458#25143#21517#31216
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 522
|
||||
Top = 34
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #25253#20851#21697#21517
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 372
|
||||
Top = 36
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #19994#21153#21592
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 181
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #25351#31034#21333#21495
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 31
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 414
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = A4FPNOKeyPress
|
||||
end
|
||||
object GCNAME: TEdit
|
||||
Tag = 2
|
||||
Left = 233
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = GCNAMEKeyPress
|
||||
end
|
||||
object KHName: TEdit
|
||||
Tag = 2
|
||||
Left = 574
|
||||
Top = 7
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 4
|
||||
OnChange = FactoryNameChange
|
||||
end
|
||||
object BGCODENAME: TEdit
|
||||
Tag = 2
|
||||
Left = 574
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnChange = FactoryNameChange
|
||||
OnKeyPress = GCNAMEKeyPress
|
||||
end
|
||||
object YWY: TEdit
|
||||
Tag = 1
|
||||
Left = 414
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 6
|
||||
OnChange = YWYChange
|
||||
end
|
||||
object orderno: TEdit
|
||||
Tag = 1
|
||||
Left = 233
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 7
|
||||
OnChange = YWYChange
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1368
|
||||
Height = 540
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object TV1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Column = cxGridDBColumn7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object tv2Column1: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 68
|
||||
end
|
||||
object TV1Column12: TcxGridDBColumn
|
||||
Caption = #22806#38144#21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 83
|
||||
end
|
||||
object TV1Column11: TcxGridDBColumn
|
||||
Caption = #20844#21496
|
||||
DataBinding.FieldName = 'BGTAITOU'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 82
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25351#31034#21333#21495
|
||||
DataBinding.FieldName = 'orderno'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.Items.Strings = (
|
||||
#26797#32455
|
||||
#38024#32455
|
||||
#32463#32534
|
||||
#21050#32483
|
||||
#38024#32455#32463#32534)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Width = 71
|
||||
end
|
||||
object Tv1Column1: TcxGridDBColumn
|
||||
Caption = #25253#20851#21697#21517
|
||||
DataBinding.FieldName = 'BGCODENAME'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 69
|
||||
end
|
||||
object tv2Column2: TcxGridDBColumn
|
||||
Caption = #26588#22411
|
||||
DataBinding.FieldName = 'guixing'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object cxGridDBColumn7: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #20986#36135#25968#37327
|
||||
DataBinding.FieldName = 'C4BGQty'
|
||||
PropertiesClassName = 'TcxCalcEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Options.Sorting = False
|
||||
Width = 77
|
||||
end
|
||||
object cxGridDBColumn9: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'C5BGUnit'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.Items.Strings = (
|
||||
'MTR'
|
||||
'KG')
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Width = 46
|
||||
end
|
||||
object TV1Column15: TcxGridDBColumn
|
||||
Caption = #37329#39069
|
||||
DataBinding.FieldName = 'C7BGMoney'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 74
|
||||
end
|
||||
object tv2Column5: TcxGridDBColumn
|
||||
Caption = #20986#36135#26085
|
||||
DataBinding.FieldName = 'htdate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
end
|
||||
object TV1Column7: TcxGridDBColumn
|
||||
Caption = #33337#26399
|
||||
DataBinding.FieldName = 'chuandate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
end
|
||||
object tv2Column6: TcxGridDBColumn
|
||||
Caption = #20184#27454#26465#20214
|
||||
HeaderAlignmentHorz = taCenter
|
||||
end
|
||||
object TV1Column8: TcxGridDBColumn
|
||||
Caption = #37096#38376
|
||||
DataBinding.FieldName = 'bm'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 75
|
||||
end
|
||||
object TV1Column9: TcxGridDBColumn
|
||||
Caption = #22269#23478
|
||||
DataBinding.FieldName = 'TOCOUNTRY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object TV1Column14: TcxGridDBColumn
|
||||
Caption = #19994#21153#21592
|
||||
DataBinding.FieldName = 'YWY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 69
|
||||
end
|
||||
object TV1Column10: TcxGridDBColumn
|
||||
Caption = #36135#20195
|
||||
DataBinding.FieldName = 'huodai'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column13: TcxGridDBColumn
|
||||
Caption = #30446#30340#28207
|
||||
DataBinding.FieldName = 'B7DaoHuoGang'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 925
|
||||
Top = 217
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 893
|
||||
Top = 217
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 957
|
||||
Top = 217
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 858
|
||||
Top = 188
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 777
|
||||
Top = 299
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 883
|
||||
Top = 487
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 917
|
||||
Top = 487
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 949
|
||||
Top = 487
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 225
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 252
|
||||
Top = 364
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 300
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 256
|
||||
Top = 336
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 352
|
||||
Top = 208
|
||||
end
|
||||
end
|
||||
|
|
@ -1,734 +0,0 @@
|
|||
unit U_MGFYBB;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||||
cxEdit, DB, cxDBData, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridBandedTableView, cxGridDBBandedTableView, cxGridLevel, cxClasses,
|
||||
cxControls, cxGridCustomView, cxGridDBTableView, cxGrid, StdCtrls, ComCtrls,
|
||||
ExtCtrls, ToolWin, cxGridCustomPopupMenu, cxGridPopupMenu, ADODB, DBClient,
|
||||
cxDropDownEdit, cxCheckBox, RM_Common, RM_Class, RM_e_Xls, RM_Dataset,
|
||||
RM_System, RM_GridReport, Menus, cxCalendar, cxButtonEdit, cxTextEdit, cxPC,
|
||||
BtnEdit, cxSplitter, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator,
|
||||
dxBarBuiltInMenu, MovePanel, cxCalc;
|
||||
|
||||
type
|
||||
TfrmCHList = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
Label1: TLabel;
|
||||
BegDate: TDateTimePicker;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
Label6: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
Label5: TLabel;
|
||||
GCNAME: TEdit;
|
||||
Label8: TLabel;
|
||||
KHName: TEdit;
|
||||
Label3: TLabel;
|
||||
BGCODENAME: TEdit;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
Label2: TLabel;
|
||||
YWY: TEdit;
|
||||
cxGrid2: TcxGrid;
|
||||
TV1: TcxGridDBTableView;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
cxGridDBColumn7: TcxGridDBColumn;
|
||||
cxGridDBColumn9: TcxGridDBColumn;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
tv2Column1: TcxGridDBColumn;
|
||||
tv2Column2: TcxGridDBColumn;
|
||||
tv2Column5: TcxGridDBColumn;
|
||||
tv2Column6: TcxGridDBColumn;
|
||||
TV1Column7: TcxGridDBColumn;
|
||||
TV1Column8: TcxGridDBColumn;
|
||||
TV1Column9: TcxGridDBColumn;
|
||||
TV1Column10: TcxGridDBColumn;
|
||||
TV1Column11: TcxGridDBColumn;
|
||||
TV1Column12: TcxGridDBColumn;
|
||||
TV1Column13: TcxGridDBColumn;
|
||||
TV1Column14: TcxGridDBColumn;
|
||||
Label4: TLabel;
|
||||
orderno: TEdit;
|
||||
TV1Column15: TcxGridDBColumn;
|
||||
ToolButton1: TToolButton;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure GCNAMEKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure KHNameKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure TBCopyClick(Sender: TObject);
|
||||
procedure TBBGZLClick(Sender: TObject);
|
||||
procedure TBHTClick(Sender: TObject);
|
||||
procedure TBFPClick(Sender: TObject);
|
||||
procedure TBZXDClick(Sender: TObject);
|
||||
procedure TBBGDClick(Sender: TObject);
|
||||
procedure TBViewClick(Sender: TObject);
|
||||
procedure TBSBYSClick(Sender: TObject);
|
||||
procedure TBAllClick(Sender: TObject);
|
||||
procedure YWYChange(Sender: TObject);
|
||||
procedure Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
|
||||
procedure huodaiBtnClick(Sender: TObject);
|
||||
procedure B7DaoHuoGangBtnClick(Sender: TObject);
|
||||
procedure BtnEditA1BtnClick(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
private
|
||||
canshu2: string;
|
||||
FDate: TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData(): Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj: string);
|
||||
procedure InitPrtData();
|
||||
{ Private declarations }
|
||||
public
|
||||
canshu1: string;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
//var
|
||||
//frmBaoGuanList: TfrmBaoGuanList;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_RTFun, U_ZDYHelp, U_BaoGuanInPut, U_Fun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmCHList.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
//frmBaoGuanList:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Application := MainApplication;
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||
BegDate.DateTime := SGetServerDateMBeg(ADOQueryTemp);
|
||||
canshu1 := Trim(DParameters1);
|
||||
canshu2 := Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,B.* ');
|
||||
// SQL.Add(',HDNAME=(SELECT HDNAME FROM JYOrderCon_TT C WHERE C.DCNO=A.DCNO)');
|
||||
SQL.Add(',TOCOUNTRY=(SELECT TOCOUNTRY FROM JYOrderCon_TT C WHERE C.DCNO=A.DCNO)');
|
||||
SQL.Add(',BM=(SELECT ISNULL(UDEPT,'''')+USERNAME FROM SY_User C WHERE C.USERNAME=A.FILLER )');
|
||||
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A INNER JOIN JYOrder_BaoGuan_SUB B ON A.BGID=B.BGID ');
|
||||
sql.Add(' where Valid=''Y'' ');
|
||||
SQL.Add('AND bgStatus=''√''');
|
||||
sql.Add(' and filltime>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
sql.Add(' and filltime<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
// ShowMessage(sql.Text);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
BegDate.SetFocus;
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表' + self.Caption, Tv1, '出货清单');
|
||||
// WriteCxGrid('报关明细' + self.Caption, Tv2, '报关管理8');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表' + self.Caption, Tv1, '出货清单');
|
||||
// ReadCxGrid('报关明细' + self.Caption, Tv2, '报关管理8');
|
||||
canshu1 := Trim(DParameters1);
|
||||
// ShowMessage(canshu1);
|
||||
|
||||
InitGrid();
|
||||
RM1.CanExport := true;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
// TcxGridToExcel(Trim(CDS_Main.fieldbyname('A4FPNO').AsString) + Trim(CDS_Main.fieldbyname('A5ConNO').AsString), cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main, True);
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main, False);
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty = False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID=''' + Trim(CDS_Main.fieldbyname('BGID').AsString) + '''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp, ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp, ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmCHList.DelData(): Boolean;
|
||||
begin
|
||||
try
|
||||
Result := false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel', True, []) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer=''' + Trim(DName) + ''',EditTime=getdate()');
|
||||
sql.Add(' where BGId=''' + Trim(CDS_Main.fieldbyname('BGId').AsString) + '''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer=''' + Trim(DName) + ''',SEditTime=getdate() where BGId=''' + Trim(CDS_Main.fieldbyname('BGId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result := True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result := False;
|
||||
Application.MessageBox('数据删除异常!', '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.A4FPNOKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
if Trim(A4FPNO.Text) = '' then
|
||||
Exit;
|
||||
fsj := ' and isnull(A.A4FPNO,'''') like ''' + '%' + Trim(A4FPNO.Text) + '%' + '''';
|
||||
InitGridSql(fsj);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.InitGridSql(var fsj: string);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
if Trim(canshu1) <> '高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode=''' + Trim(DCode) + '''');
|
||||
end;
|
||||
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.GCNAMEKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
// if Key = #13 then
|
||||
// begin
|
||||
// if Trim(A6PONO.Text) = '' then
|
||||
// Exit;
|
||||
// fsj := ' and isnull(A.A6PONO,'''') like ''' + '%' + Trim(A6PONO.Text) + '%' + '''';
|
||||
// InitGridSql(fsj);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.KHNameKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
// if Key = #13 then
|
||||
// begin
|
||||
// if Trim(A5ConNO.Text) = '' then
|
||||
// Exit;
|
||||
// fsj := ' and isnull(A.A5ConNO,'''') like ''' + '%' + Trim(A5ConNO.Text) + '%' + '''';
|
||||
// InitGridSql(fsj);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBCopyClick(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
// if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut := TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId := Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
CopyStr := '99';
|
||||
//TBDel.Visible:=False;
|
||||
//TBAdd.Visible:=False;
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.InitPrtData();
|
||||
begin
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' exec P_View_BaoGuanData :BGID ');
|
||||
Parameters.ParamByName('BGID').Value := Trim(CDS_Main.fieldbyname('BGId').AsString);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint, CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint, CDS_Print);
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBBGZLClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBHTClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBFPClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBZXDClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBBGDClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBViewClick(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
//if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut := TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId := Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible := False;
|
||||
ToolBar2.Visible := False;
|
||||
Panel1.Enabled := False;
|
||||
Tv1.OptionsData.Editing := False;
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBSBYSClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.TBAllClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile, FZMFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\全部报关资料.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
//RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
if RM1.CanExport = true then
|
||||
begin
|
||||
FZMFile := 'C:\Users\Administrator\Desktop';
|
||||
if not DirectoryExists(FZMFile) then
|
||||
begin
|
||||
FZMFile := 'C:\Documents and Settings\Administrator\桌面\' + trim(CDS_Main.fieldbyname('A4FPNO').AsString) + ' ' + trim(CDS_Main.fieldbyname('A5ConNO').AsString) + '.xls';
|
||||
end
|
||||
else
|
||||
begin
|
||||
FZMFile := 'C:\Users\Administrator\Desktop\' + trim(CDS_Main.fieldbyname('A4FPNO').AsString) + ' ' + trim(CDS_Main.fieldbyname('A5ConNO').AsString) + '.XLS';
|
||||
end;
|
||||
RM1.ExportTo(RMXLSExport1, FZMFile);
|
||||
end;
|
||||
RM1.CanExport := true;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
RM1.CanExport := False;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\全部报关资料.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.YWYChange(Sender: TObject);
|
||||
begin
|
||||
SDofilter(ADOQueryTemp, SGetFilters(Panel1, 3, 1));
|
||||
SCreateCDS20(ADOQueryTemp, ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp, ClientDataSet2);
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.huodaiBtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.B7DaoHuoGangBtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.BtnEditA1BtnClick(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
FWZ: Integer;
|
||||
begin
|
||||
fsj := Trim(TEdit(Sender).Hint);
|
||||
FWZ := Pos('/', fsj);
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := Copy(fsj, 1, FWZ - 1);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmCHList.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
// SelExportData(Tv1, ADOQueryMain, '出货清单');
|
||||
|
||||
TcxGridToExcel('出货清单', cxGrid2);
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -1,356 +0,0 @@
|
|||
object frmOrderSel: TfrmOrderSel
|
||||
Left = 196
|
||||
Top = 141
|
||||
Width = 1171
|
||||
Height = 587
|
||||
Caption = #35746#21333#36873#25321
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -18
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
Position = poScreenCenter
|
||||
OnClose = FormClose
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 107
|
||||
TextHeight = 18
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 100
|
||||
Width = 1155
|
||||
Height = 447
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 0
|
||||
object Tv2: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1PRTMF
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v1PRTKZ
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = v2Column1
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Footer = DataLink_TradeManage.Default
|
||||
object v2Column3: TcxGridDBColumn
|
||||
Caption = #36873#20013
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
object v1OrderNo: TcxGridDBColumn
|
||||
Caption = #35746#21333#21495
|
||||
DataBinding.FieldName = 'OrderNoM'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 86
|
||||
end
|
||||
object v2Column2: TcxGridDBColumn
|
||||
Caption = #23458#25143
|
||||
DataBinding.FieldName = 'CustomerNoName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 93
|
||||
end
|
||||
object cxGridDBColumn2: TcxGridDBColumn
|
||||
Caption = #20013#25991#21517#31216
|
||||
DataBinding.FieldName = 'MPRTCodeName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 104
|
||||
end
|
||||
object v2Column9: TcxGridDBColumn
|
||||
Caption = #20844#21496#21697#21517
|
||||
DataBinding.FieldName = 'ComPRTName'
|
||||
Width = 84
|
||||
end
|
||||
object v1Column10: TcxGridDBColumn
|
||||
Caption = #35746#21333#25968#37327
|
||||
DataBinding.FieldName = 'PRTOrderQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 80
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Caption = #35746#21333#21333#20301
|
||||
DataBinding.FieldName = 'OrderUnit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 75
|
||||
end
|
||||
object cxGridDBColumn3: TcxGridDBColumn
|
||||
Caption = #39068#33394
|
||||
DataBinding.FieldName = 'PRTColor'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Width = 80
|
||||
end
|
||||
object v2Column8: TcxGridDBColumn
|
||||
Caption = #33394#21495
|
||||
DataBinding.FieldName = 'SOrddefstr1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 88
|
||||
end
|
||||
object v2Column7: TcxGridDBColumn
|
||||
Caption = #33457#22411#33457#21495
|
||||
DataBinding.FieldName = 'PRTHX'
|
||||
Options.Editing = False
|
||||
Width = 78
|
||||
end
|
||||
object v2Column6: TcxGridDBColumn
|
||||
Caption = #24211#23384#21253'/'#20214#25968#37327
|
||||
DataBinding.FieldName = 'KCBQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 111
|
||||
end
|
||||
object v1PRTMF: TcxGridDBColumn
|
||||
Caption = #24211#23384#21305#25968
|
||||
DataBinding.FieldName = 'KCJQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Styles.Content = cxStyle1
|
||||
Width = 77
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Caption = #24211#23384#27611#37325
|
||||
DataBinding.FieldName = 'KCKgQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 73
|
||||
end
|
||||
object v2Column5: TcxGridDBColumn
|
||||
Caption = #24211#23384#20928#37325
|
||||
DataBinding.FieldName = 'KCKgQtyJ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 69
|
||||
end
|
||||
object v1PRTKZ: TcxGridDBColumn
|
||||
Caption = #24211#23384#38271#24230
|
||||
DataBinding.FieldName = 'KCQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Options.Sorting = False
|
||||
Styles.Content = cxStyle1
|
||||
Width = 79
|
||||
end
|
||||
object v2Column4: TcxGridDBColumn
|
||||
Caption = #21333#20301
|
||||
DataBinding.FieldName = 'KCQtyUnit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 51
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1155
|
||||
Height = 100
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
TabOrder = 1
|
||||
object Label2: TLabel
|
||||
Left = 39
|
||||
Top = 21
|
||||
Width = 54
|
||||
Height = 18
|
||||
Caption = #35746#21333#21495
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 302
|
||||
Top = 21
|
||||
Width = 36
|
||||
Height = 18
|
||||
Caption = #39068#33394
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 525
|
||||
Top = 21
|
||||
Width = 72
|
||||
Height = 18
|
||||
Caption = #23458' '#25143
|
||||
end
|
||||
object OrderNoM: TEdit
|
||||
Tag = 2
|
||||
Left = 93
|
||||
Top = 18
|
||||
Width = 137
|
||||
Height = 26
|
||||
TabOrder = 0
|
||||
OnChange = OrderNoMChange
|
||||
end
|
||||
object PRTColor: TEdit
|
||||
Tag = 2
|
||||
Left = 339
|
||||
Top = 18
|
||||
Width = 125
|
||||
Height = 26
|
||||
TabOrder = 1
|
||||
OnChange = OrderNoMChange
|
||||
end
|
||||
object Button1: TButton
|
||||
Left = 773
|
||||
Top = 18
|
||||
Width = 84
|
||||
Height = 28
|
||||
Caption = #21047#26032
|
||||
TabOrder = 2
|
||||
OnClick = Button1Click
|
||||
end
|
||||
object Button2: TButton
|
||||
Left = 773
|
||||
Top = 54
|
||||
Width = 84
|
||||
Height = 28
|
||||
Caption = #30830#23450
|
||||
TabOrder = 3
|
||||
OnClick = Button2Click
|
||||
end
|
||||
object Button3: TButton
|
||||
Left = 881
|
||||
Top = 54
|
||||
Width = 84
|
||||
Height = 28
|
||||
Caption = #20851#38381
|
||||
TabOrder = 4
|
||||
OnClick = Button3Click
|
||||
end
|
||||
object CustomerNoName: TEdit
|
||||
Tag = 2
|
||||
Left = 600
|
||||
Top = 17
|
||||
Width = 134
|
||||
Height = 26
|
||||
TabOrder = 5
|
||||
OnChange = OrderNoMChange
|
||||
end
|
||||
end
|
||||
object CDS_OrderSel: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 592
|
||||
Top = 208
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_OrderSel
|
||||
Left = 680
|
||||
Top = 224
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 784
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
Parameters = <>
|
||||
Left = 848
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_TradeManage.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 624
|
||||
Top = 208
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 728
|
||||
Top = 272
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 424
|
||||
Top = 248
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object cxStyleRepository1: TcxStyleRepository
|
||||
object cxStyle1: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -16
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clBlue
|
||||
end
|
||||
end
|
||||
object cxStyleRepository2: TcxStyleRepository
|
||||
object cxStyle2: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clRed
|
||||
end
|
||||
end
|
||||
object cxStyleRepository3: TcxStyleRepository
|
||||
object cxStyle3: TcxStyle
|
||||
AssignedValues = [svFont, svTextColor]
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
TextColor = clPurple
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -1,205 +0,0 @@
|
|||
unit U_OrderSel;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, StdCtrls, ADODB, DBClient, ComCtrls,
|
||||
ExtCtrls, cxGridLevel, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridDBTableView, cxClasses, cxControls, cxGridCustomView, cxGrid,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxCheckBox, Menus;
|
||||
|
||||
type
|
||||
TfrmOrderSel = class(TForm)
|
||||
cxGrid1: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
v1OrderNo: TcxGridDBColumn;
|
||||
cxGridDBColumn2: TcxGridDBColumn;
|
||||
v1Column10: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
cxGridDBColumn3: TcxGridDBColumn;
|
||||
v1PRTMF: TcxGridDBColumn;
|
||||
v1PRTKZ: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
Panel1: TPanel;
|
||||
Label2: TLabel;
|
||||
OrderNoM: TEdit;
|
||||
Label3: TLabel;
|
||||
PRTColor: TEdit;
|
||||
CDS_OrderSel: TClientDataSet;
|
||||
DataSource1: TDataSource;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
Button1: TButton;
|
||||
Button2: TButton;
|
||||
Button3: TButton;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
v2Column2: TcxGridDBColumn;
|
||||
Label8: TLabel;
|
||||
CustomerNoName: TEdit;
|
||||
v2Column3: TcxGridDBColumn;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
cxStyleRepository1: TcxStyleRepository;
|
||||
cxStyle1: TcxStyle;
|
||||
cxStyleRepository2: TcxStyleRepository;
|
||||
cxStyle2: TcxStyle;
|
||||
cxStyleRepository3: TcxStyleRepository;
|
||||
cxStyle3: TcxStyle;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v2Column4: TcxGridDBColumn;
|
||||
v2Column5: TcxGridDBColumn;
|
||||
v2Column6: TcxGridDBColumn;
|
||||
v2Column7: TcxGridDBColumn;
|
||||
v2Column8: TcxGridDBColumn;
|
||||
v2Column9: TcxGridDBColumn;
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure Button2Click(Sender: TObject);
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure Button3Click(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure Button1Click(Sender: TObject);
|
||||
procedure OrderNoMChange(Sender: TObject);
|
||||
procedure Tv2CellDblClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
procedure InitGrid();
|
||||
public
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmOrderSel: TfrmOrderSel;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_Fun ;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmOrderSel.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.Button2Click(Sender: TObject);
|
||||
var
|
||||
KHName:String;
|
||||
begin
|
||||
if CDS_OrderSel.Locate('SSel',True,[])=False then
|
||||
begin
|
||||
Application.MessageBox('没有选择数据!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
CDS_OrderSel.DisableControls;
|
||||
KHName:='';
|
||||
with CDS_OrderSel do
|
||||
begin
|
||||
First;
|
||||
while not Eof do
|
||||
begin
|
||||
if FieldByName('SSel').AsBoolean=True then
|
||||
begin
|
||||
if Trim(KHName)='' then
|
||||
begin
|
||||
KHName:=Trim(fieldbyname('CustomerNo').AsString);
|
||||
end else
|
||||
begin
|
||||
if Trim(fieldbyname('CustomerNo').AsString)<>KHName then
|
||||
begin
|
||||
CDS_OrderSel.EnableControls;
|
||||
Application.MessageBox('不能选择不同客户!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
CDS_OrderSel.EnableControls;
|
||||
ModalResult:=1;
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmOrderSel:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.Button3Click(Sender: TObject);
|
||||
begin
|
||||
ModalResult:=-1;
|
||||
WriteCxGrid('订单选择',Tv2,'成品仓库');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('订单选择',Tv2,'成品仓库');
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered:=False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select KC.Mainid,KC.Subid,KC.KCQty,KC.KCQtyUnit,KC.KCkgQty,KC.KCJQty,KC.CRID,KC.KCkgQtyJ,KC.KCBQty,KC.ComPRTName');
|
||||
sql.Add(',A.OrderNo OrderNoM,A.OrderNo,A.CustomerNoName,A.CustomerNo,A.MPRTCodeName,A.MPRTMF,A.MPRTKZ,B.* ');
|
||||
sql.Add('from (select Mainid,SubId,KCQty=Sum(Qty*QtyFlag),KCKgQtyJ=Sum(KgQtyJ*QtyFlag),KCJQty=Sum(JQty*QtyFlag),KCBQty=Sum(BQty*QtyFlag)');
|
||||
sql.Add(' ,QtyUnit KCQtyUnit,CRID,KCkgQty=Sum(KgQty*QtyFlag),Max(ComPRTName) ComPRTName from CK_BanCP_CR where MJID=BCID ');
|
||||
sql.add('Group by Mainid,SubId,QtyUnit,CRID) KC ');
|
||||
|
||||
sql.Add(' inner join JYOrder_Main A on KC.Mainid=A.MainId ');
|
||||
sql.Add(' inner join JYOrder_Sub B on KC.SubId=B.SubId');
|
||||
sql.Add(' where (KC.KCJQty>0 or KC.KCkgQty>0 or KCQty>0)');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,CDS_OrderSel);
|
||||
SInitCDSData20(ADOQueryMain,CDS_OrderSel);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.Button1Click(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.OrderNoMChange(Sender: TObject);
|
||||
begin
|
||||
SDofilter(ADOQueryMain,SGetFilters(Panel1,1,2));
|
||||
SCreateCDS20(ADOQueryMain,CDS_OrderSel);
|
||||
SInitCDSData20(ADOQueryMain,CDS_OrderSel);
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.Tv2CellDblClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
ModalResult:=1;
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_OrderSel,True);
|
||||
end;
|
||||
|
||||
procedure TfrmOrderSel.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_OrderSel,False);
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,322 +0,0 @@
|
|||
object frmProductOrderList_Sel: TfrmProductOrderList_Sel
|
||||
Left = 195
|
||||
Top = 125
|
||||
Width = 1121
|
||||
Height = 593
|
||||
Caption = #29983#20135#25351#31034#21333#36873#25321
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1105
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object ToolButton3: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
Caption = #36873#25321
|
||||
ImageIndex = 31
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 59
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1105
|
||||
Height = 54
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label3: TLabel
|
||||
Left = 35
|
||||
Top = 22
|
||||
Width = 52
|
||||
Height = 12
|
||||
Caption = #35745#21010#21333#21495
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object OrderNo: TEdit
|
||||
Tag = 2
|
||||
Left = 91
|
||||
Top = 18
|
||||
Width = 149
|
||||
Height = 20
|
||||
TabOrder = 0
|
||||
OnKeyPress = OrderNoKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 86
|
||||
Width = 1105
|
||||
Height = 369
|
||||
Align = alTop
|
||||
TabOrder = 2
|
||||
object Tv1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object v1Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.NullStyle = nssUnchecked
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 44
|
||||
end
|
||||
object v1OrderNo: TcxGridDBColumn
|
||||
Caption = #35745#21010#21333#21495
|
||||
DataBinding.FieldName = 'OrderNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 96
|
||||
end
|
||||
object v1ConNo: TcxGridDBColumn
|
||||
Caption = #21512#21516#21495
|
||||
DataBinding.FieldName = 'ConNo'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 68
|
||||
end
|
||||
object v1OrdPerson1: TcxGridDBColumn
|
||||
Caption = #19994#21153#21592
|
||||
DataBinding.FieldName = 'YWY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 73
|
||||
end
|
||||
object v1CustomerNoName: TcxGridDBColumn
|
||||
Caption = #23458#25143#21517#31216
|
||||
DataBinding.FieldName = 'CustomerNoName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 79
|
||||
end
|
||||
object v1DeliveryDate: TcxGridDBColumn
|
||||
Caption = #20132#36135#26085#26399
|
||||
DataBinding.FieldName = 'DlyDate'
|
||||
PropertiesClassName = 'TcxDateEditProperties'
|
||||
Properties.ShowTime = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 77
|
||||
end
|
||||
object v1JGForctyName: TcxGridDBColumn
|
||||
Caption = #21152#24037#21378
|
||||
DataBinding.FieldName = 'JGForctyName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 83
|
||||
end
|
||||
object v1MPRTCodeName: TcxGridDBColumn
|
||||
Caption = #20013#25991#21517#31216
|
||||
DataBinding.FieldName = 'MPRTCodeName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 81
|
||||
end
|
||||
object v1MPRTSpec: TcxGridDBColumn
|
||||
Caption = #35268#26684
|
||||
DataBinding.FieldName = 'MPRTSpec'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 78
|
||||
end
|
||||
object v1MPRTMF: TcxGridDBColumn
|
||||
Caption = #38376#24133
|
||||
DataBinding.FieldName = 'MPRTMF'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 84
|
||||
end
|
||||
object v1MPRTKZ: TcxGridDBColumn
|
||||
Caption = #20811#37325
|
||||
DataBinding.FieldName = 'MPRTKZ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Width = 71
|
||||
end
|
||||
object v1MPRTOrderQty: TcxGridDBColumn
|
||||
Caption = #25968#37327
|
||||
DataBinding.FieldName = 'PRTOrderQty'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Focusing = False
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
Width = 73
|
||||
end
|
||||
object v1OrderUnit: TcxGridDBColumn
|
||||
Caption = #25968#37327#21333#20301
|
||||
DataBinding.FieldName = 'OrderUnit'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Width = 70
|
||||
end
|
||||
object Tv1Column1: TcxGridDBColumn
|
||||
Caption = #20135#21697#22823#31867
|
||||
DataBinding.FieldName = 'BPBigType'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 544
|
||||
Top = 176
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 576
|
||||
Top = 280
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 552
|
||||
Top = 216
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 312
|
||||
Top = 248
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = Order_Main
|
||||
Left = 440
|
||||
Top = 184
|
||||
end
|
||||
object Order_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 464
|
||||
Top = 208
|
||||
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
|
||||
object RMDBMain: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 392
|
||||
Top = 200
|
||||
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 = 528
|
||||
Top = 280
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 288
|
||||
Top = 184
|
||||
object N2: TMenuItem
|
||||
Caption = #26377#20379#24212#21830
|
||||
end
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 360
|
||||
Top = 240
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 344
|
||||
Top = 288
|
||||
end
|
||||
end
|
||||
|
|
@ -1,159 +0,0 @@
|
|||
unit U_ProductOrderList_Sel;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, StdCtrls, ExtCtrls, ComCtrls, ToolWin, cxStyles, cxCustomData,
|
||||
cxGraphics, cxFilter, cxData, cxDataStorage, cxEdit, DB, cxDBData, ADODB,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, cxGridLevel, cxClasses, cxControls,
|
||||
cxGridCustomView, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||
cxGrid, DBClient, cxCheckBox, cxCalendar, cxSplitter, RM_Dataset, RM_System,
|
||||
RM_Common, RM_Class, RM_GridReport, RM_e_Xls, Menus, cxLookAndFeels,
|
||||
cxLookAndFeelPainters, cxNavigator;
|
||||
|
||||
type
|
||||
TfrmProductOrderList_Sel = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
Tv1: TcxGridDBTableView;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
cxGrid1: TcxGrid;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
Label3: TLabel;
|
||||
OrderNo: TEdit;
|
||||
v1OrderNo: TcxGridDBColumn;
|
||||
v1DeliveryDate: TcxGridDBColumn;
|
||||
v1OrdPerson1: TcxGridDBColumn;
|
||||
v1ConNo: TcxGridDBColumn;
|
||||
v1MPRTSpec: TcxGridDBColumn;
|
||||
Order_Main: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBMain: TRMDBDataSet;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
v1MPRTCodeName: TcxGridDBColumn;
|
||||
v1MPRTMF: TcxGridDBColumn;
|
||||
v1MPRTOrderQty: TcxGridDBColumn;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N2: TMenuItem;
|
||||
v1MPRTKZ: TcxGridDBColumn;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
CDS_Print: TClientDataSet;
|
||||
ToolButton3: TToolButton;
|
||||
v1Column4: TcxGridDBColumn;
|
||||
v1CustomerNoName: TcxGridDBColumn;
|
||||
v1JGForctyName: TcxGridDBColumn;
|
||||
v1OrderUnit: TcxGridDBColumn;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
procedure OrderNoKeyPress(Sender: TObject; var Key: Char);
|
||||
private
|
||||
DQdate: TDateTime;
|
||||
procedure InitGrid();
|
||||
procedure InitForm();
|
||||
{ Private declarations }
|
||||
public
|
||||
FFInt, FCloth: Integer;
|
||||
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmProductOrderList_Sel: TfrmProductOrderList_Sel;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_Fun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmProductOrderList_Sel.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmProductOrderList_Sel := nil;
|
||||
end;
|
||||
|
||||
procedure TfrmProductOrderList_Sel.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmProductOrderList_Sel.FormCreate(Sender: TObject);
|
||||
begin
|
||||
cxgrid1.Align := alClient;
|
||||
end;
|
||||
|
||||
procedure TfrmProductOrderList_Sel.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
Close;
|
||||
WriteCxGrid('指示单列表选择', Tv1, '生产指示单管理');
|
||||
end;
|
||||
|
||||
procedure TfrmProductOrderList_Sel.InitGrid();
|
||||
begin
|
||||
// if Length(Trim(self.ConNO.Text)) < 3 then
|
||||
// Exit;
|
||||
|
||||
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select PRTORDERQTY=(SELECT SUM(PRTORDERQTY) FROM JYOrder_SUB B where A.MAINID=B.MAINID GROUP BY B.MAINID ) ');
|
||||
SQL.Add(',YWNAME=(SELECT TOP 1 CYENAME FROM CP_YDANG C WHERE C.CYNO=A.MPRTCODE)');
|
||||
sql.Add(',orderunit=(SELECT TOP 1 orderunit FROM JYOrder_sub d WHERE d.mainid=A.mainid)');
|
||||
SQL.Add(',SCSKX=(SELECT TOP 1 SCSKX FROM SalesContract_Sub E INNER JOIN SalesContract_MAIN F ON E.MAINID=F.MAINID WHERE E.SCSCode=A.MPRTCODE AND F.CONNO=A.CONNO)');
|
||||
SQL.Add(',SCSHX=(SELECT TOP 1 SCSHX FROM SalesContract_Sub E INNER JOIN SalesContract_MAIN F ON E.MAINID=F.MAINID WHERE E.SCSCode=A.MPRTCODE AND F.CONNO=A.CONNO)');
|
||||
sql.add(',A.*,A.OrderNo OrderNoM ');
|
||||
sql.add(' from JYOrder_Main A ');
|
||||
SQL.Add('where A.orderno like ''' + '%' + Trim(self.orderno.Text) + '%' + '''');
|
||||
sql.Add('and filltime>=''2022-01-01''');
|
||||
//ShowMessage(SQL.Text);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, Order_Main);
|
||||
SInitCDSData20(ADOQueryMain, Order_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmProductOrderList_Sel.InitForm();
|
||||
begin
|
||||
ReadCxGrid('指示单列表选择', Tv1, '生产指示单管理');
|
||||
// InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmProductOrderList_Sel.FormShow(Sender: TObject);
|
||||
begin
|
||||
InitForm();
|
||||
end;
|
||||
|
||||
procedure TfrmProductOrderList_Sel.ToolButton3Click(Sender: TObject);
|
||||
begin
|
||||
ModalResult := 1;
|
||||
end;
|
||||
|
||||
procedure TfrmProductOrderList_Sel.OrderNoKeyPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -1,239 +0,0 @@
|
|||
object frmRTZDYHelp: TfrmRTZDYHelp
|
||||
Left = 466
|
||||
Top = 188
|
||||
Width = 461
|
||||
Height = 528
|
||||
Caption = #39033#30446#32500#25252
|
||||
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 cxGrid1: TcxGrid
|
||||
Left = 8
|
||||
Top = 88
|
||||
Width = 417
|
||||
Height = 200
|
||||
TabOrder = 0
|
||||
object TV1: TcxGridDBTableView
|
||||
NavigatorButtons.ConfirmDelete = False
|
||||
OnCellDblClick = TV1CellDblClick
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.FocusCellOnCycle = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsData.Editing = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.GroupByBox = False
|
||||
object V1Code: TcxGridDBColumn
|
||||
Caption = #32534#21495
|
||||
DataBinding.FieldName = 'ZDYNo'
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 97
|
||||
end
|
||||
object V1OrderNo: TcxGridDBColumn
|
||||
Caption = #39034#24207#21495
|
||||
DataBinding.FieldName = 'OrderNo'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = V1OrderNoPropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 46
|
||||
end
|
||||
object V1Name: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #21517#31216
|
||||
DataBinding.FieldName = 'ZDYName'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = V1NamePropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 146
|
||||
end
|
||||
object V1Note: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'Note'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = V1NotePropertiesEditValueChanged
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 113
|
||||
end
|
||||
object V1ZdyFlag: TcxGridDBColumn
|
||||
Caption = #26631#24535
|
||||
DataBinding.FieldName = 'ZdyFlag'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = V1Column1PropertiesEditValueChanged
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 57
|
||||
end
|
||||
object V1HelpType: TcxGridDBColumn
|
||||
Caption = #24110#21161#31867#27604
|
||||
DataBinding.FieldName = 'HelpType'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Properties.OnEditValueChanged = V1HelpTypePropertiesEditValueChanged
|
||||
Visible = False
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 55
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 445
|
||||
Height = 29
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_CYZZ.ThreeImgList
|
||||
List = True
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 1
|
||||
object ToolButton1: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
Caption = #36873#25321
|
||||
ImageIndex = 10
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBAdd: TToolButton
|
||||
Left = 59
|
||||
Top = 0
|
||||
Caption = #22686#34892
|
||||
ImageIndex = 12
|
||||
OnClick = TBAddClick
|
||||
end
|
||||
object TBDel: TToolButton
|
||||
Left = 118
|
||||
Top = 0
|
||||
Caption = #21024#34892
|
||||
ImageIndex = 13
|
||||
OnClick = TBDelClick
|
||||
end
|
||||
object TBEdit: TToolButton
|
||||
Left = 177
|
||||
Top = 0
|
||||
Caption = #20462#25913
|
||||
ImageIndex = 11
|
||||
OnClick = TBEditClick
|
||||
end
|
||||
object TBSave: TToolButton
|
||||
Left = 236
|
||||
Top = 0
|
||||
Caption = #20445#23384
|
||||
ImageIndex = 15
|
||||
Visible = False
|
||||
OnClick = TBSaveClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 295
|
||||
Top = 0
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 29
|
||||
Width = 445
|
||||
Height = 44
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
TabOrder = 2
|
||||
object Label1: TLabel
|
||||
Left = 18
|
||||
Top = 17
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #21517#31216
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 240
|
||||
Top = 11
|
||||
Width = 120
|
||||
Height = 24
|
||||
Caption = #27880#65306#28966#28857#31163#24320#24403#21069#32534#36753#13#10' '#21333#20803#26684#20445#23384#25968#25454#12290
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
end
|
||||
object ZDYName: TEdit
|
||||
Tag = 2
|
||||
Left = 53
|
||||
Top = 12
|
||||
Width = 169
|
||||
Height = 20
|
||||
TabOrder = 0
|
||||
OnChange = ZDYNameChange
|
||||
end
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = ADOConnection1
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 48
|
||||
Top = 136
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = ADOConnection1
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 80
|
||||
Top = 144
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = ADOConnection1
|
||||
Parameters = <>
|
||||
Left = 112
|
||||
Top = 152
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = ClientDataSet1
|
||||
Left = 280
|
||||
Top = 144
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 208
|
||||
Top = 144
|
||||
end
|
||||
object ADOConnection1: TADOConnection
|
||||
LoginPrompt = False
|
||||
Left = 80
|
||||
Top = 232
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid1
|
||||
PopupMenus = <>
|
||||
Left = 168
|
||||
Top = 152
|
||||
end
|
||||
end
|
||||
|
|
@ -1,685 +0,0 @@
|
|||
unit U_RTZDYHelp;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
|
||||
cxDataStorage, cxEdit, DB, cxDBData, ToolWin, ComCtrls,
|
||||
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, cxGridLevel,
|
||||
cxClasses, cxControls, cxGridCustomView, cxGrid, DBClient, ADODB, ImgList,
|
||||
StdCtrls, ExtCtrls, cxTextEdit, cxGridCustomPopupMenu, cxGridPopupMenu;
|
||||
|
||||
type
|
||||
TfrmRTZDYHelp = class(TForm)
|
||||
TV1: TcxGridDBTableView;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
cxGrid1: TcxGrid;
|
||||
V1Code: TcxGridDBColumn;
|
||||
V1Name: TcxGridDBColumn;
|
||||
ToolBar1: TToolBar;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
TBAdd: TToolButton;
|
||||
TBSave: TToolButton;
|
||||
TBDel: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
ToolButton1: TToolButton;
|
||||
TBEdit: TToolButton;
|
||||
V1Note: TcxGridDBColumn;
|
||||
V1OrderNo: TcxGridDBColumn;
|
||||
ADOConnection1: TADOConnection;
|
||||
Panel1: TPanel;
|
||||
Label1: TLabel;
|
||||
ZDYName: TEdit;
|
||||
Label2: TLabel;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
V1ZdyFlag: TcxGridDBColumn;
|
||||
V1HelpType: TcxGridDBColumn;
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBAddClick(Sender: TObject);
|
||||
procedure TBSaveClick(Sender: TObject);
|
||||
procedure TBDelClick(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure TBEditClick(Sender: TObject);
|
||||
procedure TV1CellDblClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure ZDYNameChange(Sender: TObject);
|
||||
procedure V1NamePropertiesEditValueChanged(Sender: TObject);
|
||||
procedure V1OrderNoPropertiesEditValueChanged(Sender: TObject);
|
||||
procedure V1NotePropertiesEditValueChanged(Sender: TObject);
|
||||
procedure V1Column1PropertiesEditValueChanged(Sender: TObject);
|
||||
procedure V1HelpTypePropertiesEditValueChanged(Sender: TObject);
|
||||
private
|
||||
procedure InitGrid();
|
||||
{ Private declarations }
|
||||
public
|
||||
flag,flagname,snote,MainType:string;
|
||||
fnote,forderno,fZdyFlag,ViewFlag:Boolean;
|
||||
PPSTE:integer;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
var
|
||||
frmRTZDYHelp: TfrmRTZDYHelp;
|
||||
|
||||
implementation
|
||||
uses
|
||||
U_DataLink,U_RTFun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmRTZDYHelp.FormCreate(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
cxGrid1.Align:=alClient;
|
||||
with ADOConnection1 do
|
||||
begin
|
||||
Connected:=false;
|
||||
ConnectionString:=DConString;
|
||||
//ConnectionString:='';
|
||||
Connected:=true;
|
||||
end;
|
||||
except
|
||||
{if Application.MessageBox('网络连接失败,是否要再次连接?','提示',32+4)=IDYES then
|
||||
begin
|
||||
try
|
||||
with ADOConnection1 do
|
||||
begin
|
||||
Connected:=false;
|
||||
ConnectionString:=DConString;
|
||||
//ConnectionString:='23242';
|
||||
Connected:=true;
|
||||
end;
|
||||
except
|
||||
end;
|
||||
end; }
|
||||
|
||||
frmRTZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.FormClose(Sender: TObject;
|
||||
var Action: TCloseAction);
|
||||
begin
|
||||
ZDYName.SetFocus;
|
||||
Action:=caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.*,ZJM=dbo.getPinYin(A.ZdyName) from KH_ZDY A where A.Type='''+flag+'''');
|
||||
if Trim(MainType)<>'' then
|
||||
begin
|
||||
sql.Add(' and A.MainType='''+Trim(MainType)+'''');
|
||||
end;
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,ClientDataSet1);
|
||||
SInitCDSData20(ADOQueryMain,ClientDataSet1);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
procedure TfrmRTZDYHelp.TBAddClick(Sender: TObject);
|
||||
var
|
||||
i:Integer;
|
||||
begin
|
||||
ZDYName.SetFocus;
|
||||
TV1.OptionsData.Editing:=True;
|
||||
TV1.OptionsSelection.CellSelect:=True;
|
||||
for i:=0 to 5 do
|
||||
begin
|
||||
with ClientDataSet1 do
|
||||
begin
|
||||
Append;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
|
||||
end;
|
||||
procedure TfrmRTZDYHelp.TBSaveClick(Sender: TObject);
|
||||
var
|
||||
maxno:string;
|
||||
begin
|
||||
if ClientDataSet1.IsEmpty then Exit;
|
||||
ZDYName.SetFocus;
|
||||
|
||||
if ClientDataSet1.Locate('ZDYName',null,[]) then
|
||||
begin
|
||||
Application.MessageBox('名称不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if ClientDataSet1.Locate('ZDYName','',[]) then
|
||||
begin
|
||||
Application.MessageBox('名称不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select * from KH_ZDY where ZdyNo='''+Trim(flag)+'''');
|
||||
open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty then
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('insert into KH_ZDY(ZDYNo,ZDYName,Type,MainType) select :ZDYNo,:ZDYName,:Type,:MainType ');
|
||||
Parameters.ParamByName('ZDYNo').Value:=Trim(flag);
|
||||
Parameters.ParamByName('ZDYName').Value:=Trim(flagname);
|
||||
Parameters.ParamByName('Type').Value:='Main';
|
||||
Parameters.ParamByName('MainType').Value:=Trim(MainType);
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
ClientDataSet1.DisableControls;
|
||||
with ClientDataSet1 do
|
||||
begin
|
||||
First;
|
||||
while not eof do
|
||||
begin
|
||||
if Trim(ClientDataSet1.FieldByName('ZDYNO').AsString)='' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryTemp,maxno,'SY','KH_ZDY',3,1)=False then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('取最大编号失败!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
maxno:=Trim(ClientDataSet1.fieldbyname('ZDYNo').AsString);
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.add('select * from KH_Zdy where Type='''+Trim(flag)+'''');
|
||||
if Trim(MainType)<>'' then
|
||||
SQL.Add(' and MainType='''+Trim(MainType)+'''');
|
||||
sql.Add(' and ZdyName='''+Trim(ClientDataSet1.fieldbyname('ZdyName').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty=False then
|
||||
begin
|
||||
if ADOQueryTemp.RecordCount>1 then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Trim(ClientDataSet1.fieldbyname('ZdyNo').AsString)='' then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!','提示',0);
|
||||
Exit;
|
||||
end else
|
||||
begin
|
||||
if Trim(ADOQueryTemp.fieldbyname('ZdyNo').AsString)<>Trim(ClientDataSet1.fieldbyname('ZdyNo').AsString) then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
SQL.Add('delete KH_ZDY where ZDYNO='''+Trim(ClientDataSet1.fieldbyname('ZDYNO').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from KH_ZDY where 1<>1');
|
||||
Open;
|
||||
end;
|
||||
ADOQueryCmd.Append;
|
||||
ADOQueryCmd.FieldByName('ZDYNo').Value:=Trim(maxno);
|
||||
ADOQueryCmd.FieldByName('ZDYName').Value:=ClientDataSet1.fieldbyname('ZDYName').Value;
|
||||
ADOQueryCmd.FieldByName('note').Value:=Trim(snote);
|
||||
//ADOQueryCmd.FieldByName('orderno').Value:=ClientDataSet1.fieldbyname('Name').AsString;
|
||||
ADOQueryCmd.FieldByName('Type').Value:=flag;
|
||||
ADOQueryCmd.FieldByName('valid').Value:='Y';
|
||||
if Trim(MainType)<>'' then
|
||||
ADOQueryCmd.FieldByName('MainType').Value:=Trim(MainType);
|
||||
//ADOQueryCmd.FieldByName('sel').Value:=0;
|
||||
ADOQueryCmd.Post;
|
||||
ClientDataSet1.Edit;
|
||||
ClientDataSet1.FieldByName('ZDYNo').Value:=Trim(maxno);
|
||||
ClientDataSet1.Post;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
ClientDataSet1.EnableControls;
|
||||
end;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Application.MessageBox('保存成功!','提示',0);
|
||||
TV1.OptionsData.Editing:=False;
|
||||
TV1.OptionsSelection.CellSelect:=False;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('保存失败!','提示',0);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.TBDelClick(Sender: TObject);
|
||||
begin
|
||||
if ClientDataSet1.IsEmpty then Exit;
|
||||
if (Trim(ClientDataSet1.FieldByName('ZDYNo').AsString)<>'') or
|
||||
(Trim(ClientDataSet1.FieldByName('ZDYname').AsString)<>'') then
|
||||
begin
|
||||
if application.MessageBox('确定要删除吗?','提示信息',1)=2 then exit;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('delete KH_ZDY where ZDYNo='''+Trim(ClientDataSet1.fieldbyname('ZDYNo').AsString)+'''');
|
||||
SQL.Add(' and Type='''+Trim(flag)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
ClientDataSet1.Delete;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
ModalResult:=2;
|
||||
ZDYName.SetFocus;
|
||||
WriteCxGrid('自定义'+Trim(flag),TV1,'自定义数据');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.FormShow(Sender: TObject);
|
||||
var
|
||||
fsj,fsj1:string;
|
||||
begin
|
||||
{if PPSTE=1 then
|
||||
begin
|
||||
Application.Terminate;
|
||||
Exit;
|
||||
end; }
|
||||
InitGrid();
|
||||
fsj:=Trim(flag)+'01';
|
||||
fsj1:=Trim(flagname)+'01';
|
||||
{if ClientDataSet1.IsEmpty then
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('insert into KH_ZDY(ZDYNo,ZDYname,Type,note)');
|
||||
sql.Add('select '''+Trim(fsj)+'''');
|
||||
sql.Add(','''+Trim(fsj1)+'''');
|
||||
SQL.Add(','''+Trim(flag)+'''');
|
||||
sql.Add(','''+Trim(snote)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
InitGrid();
|
||||
end;}
|
||||
//frmZDYHelp.Caption:=Trim(flagname)+'<'+Trim(flag)+'>';
|
||||
//ReadCxGrid('自定义',TV1,'自定义数据');
|
||||
ReadCxGrid('自定义'+Trim(flag),TV1,'自定义数据');
|
||||
frmRTZDYHelp.Caption:=Trim(flagname);
|
||||
V1Note.Visible:=fnote;
|
||||
V1ZdyFlag.Visible:=fZdyFlag;
|
||||
V1OrderNo.Visible:=forderno;
|
||||
if ViewFlag=True then
|
||||
begin
|
||||
TBAdd.Visible:=False;
|
||||
TBSave.Visible:=False;
|
||||
TBDel.Visible:=False;
|
||||
TBEdit.Visible:=False;
|
||||
Label2.Visible:=False;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
ZDYName.SetFocus;
|
||||
WriteCxGrid('自定义'+Trim(flag),TV1,'自定义数据');
|
||||
ModalResult:=1;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.TBEditClick(Sender: TObject);
|
||||
begin
|
||||
TV1.OptionsData.Editing:=True;
|
||||
TV1.OptionsSelection.CellSelect:=True;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.TV1CellDblClick(Sender: TcxCustomGridTableView;
|
||||
ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton;
|
||||
AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
if TV1.OptionsData.Editing=False then
|
||||
begin
|
||||
ModalResult:=1;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.ZDYNameChange(Sender: TObject);
|
||||
var
|
||||
fsj:String;
|
||||
begin
|
||||
if Trim(ZDYName.Text)<>'' then
|
||||
begin
|
||||
fsj:=' zdyname like '''+'%'+Trim(ZDYName.Text)+'%'+''''
|
||||
+' or Note like '''+'%'+Trim(ZDYName.Text)+'%'+''''
|
||||
+' or ZJM like '''+'%'+Trim(ZDYName.Text)+'%'+'''';
|
||||
end;
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
// SDofilter(ADOQueryMain,fsj);
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
if Trim(fsj)='' then
|
||||
begin
|
||||
Filtered:=False;
|
||||
end else
|
||||
begin
|
||||
Filtered:=False;
|
||||
Filter:=fsj;
|
||||
Filtered:=True;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain,ClientDataSet1);
|
||||
SInitCDSData20(ADOQueryMain,ClientDataSet1);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.V1NamePropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
maxno,mvalue:string;
|
||||
begin
|
||||
mvalue:=TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue)='' then
|
||||
begin
|
||||
//Application.MessageBox('名称不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
with ClientDataSet1 do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('ZdyName').Value:=Trim(mvalue);
|
||||
//Post;
|
||||
end;
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
SQL.Add('select * from KH_ZDY where ZdyNo='''+Trim(flag)+'''');
|
||||
open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty then
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
close;
|
||||
sql.Clear;
|
||||
sql.Add('insert into KH_ZDY(ZDYNo,ZDYName,Type,MainType) select :ZDYNo,:ZDYName,:Type,:MainType ');
|
||||
Parameters.ParamByName('ZDYNo').Value:=Trim(flag);
|
||||
Parameters.ParamByName('ZDYName').Value:=Trim(flagname);
|
||||
Parameters.ParamByName('Type').Value:='Main';
|
||||
Parameters.ParamByName('MainType').Value:=Trim(MainType);
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
//ClientDataSet1.DisableControls;
|
||||
//with ClientDataSet1 do
|
||||
//begin
|
||||
//First;
|
||||
//while not eof do
|
||||
//begin
|
||||
if Trim(ClientDataSet1.FieldByName('ZDYNO').AsString)='' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryTemp,maxno,'SY','KH_ZDY',3,1)=False then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('取最大编号失败!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end else
|
||||
begin
|
||||
maxno:=Trim(ClientDataSet1.fieldbyname('ZDYNo').AsString);
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.add('select * from KH_Zdy where Type='''+Trim(flag)+'''');
|
||||
if Trim(MainType)<>'' then
|
||||
SQL.Add(' and MainType='''+Trim(MainType)+'''');
|
||||
sql.Add(' and ZdyName='''+Trim(ClientDataSet1.fieldbyname('ZdyName').AsString)+'''');
|
||||
Open;
|
||||
end;
|
||||
if ADOQueryTemp.IsEmpty=False then
|
||||
begin
|
||||
if ADOQueryTemp.RecordCount>1 then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
if Trim(ClientDataSet1.fieldbyname('ZdyNo').AsString)='' then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!','提示',0);
|
||||
Exit;
|
||||
end else
|
||||
begin
|
||||
if Trim(ADOQueryTemp.fieldbyname('ZdyNo').AsString)<>Trim(ClientDataSet1.fieldbyname('ZdyNo').AsString) then
|
||||
begin
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
//ClientDataSet1.EnableControls;
|
||||
Application.MessageBox('名称重复!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
SQL.Add('delete KH_ZDY where ZDYNO='''+Trim(ClientDataSet1.fieldbyname('ZDYNO').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from KH_ZDY where 1<>1');
|
||||
Open;
|
||||
end;
|
||||
ADOQueryCmd.Append;
|
||||
ADOQueryCmd.FieldByName('ZDYNo').Value:=Trim(maxno);
|
||||
ADOQueryCmd.FieldByName('ZDYName').Value:=ClientDataSet1.fieldbyname('ZDYName').AsString;
|
||||
ADOQueryCmd.FieldByName('note').Value:=Trim(snote);
|
||||
//ADOQueryCmd.FieldByName('orderno').Value:=ClientDataSet1.fieldbyname('Name').AsString;
|
||||
ADOQueryCmd.FieldByName('Type').Value:=flag;
|
||||
ADOQueryCmd.FieldByName('valid').Value:='Y';
|
||||
if Trim(MainType)<>'' then
|
||||
ADOQueryCmd.FieldByName('MainType').Value:=Trim(MainType);
|
||||
//ADOQueryCmd.FieldByName('sel').Value:=0;
|
||||
ADOQueryCmd.Post;
|
||||
ClientDataSet1.Edit;
|
||||
ClientDataSet1.FieldByName('ZDYNo').Value:=Trim(maxno);
|
||||
//ClientDataSet1.Post;
|
||||
// Next;
|
||||
//end;
|
||||
//end;
|
||||
// ClientDataSet1.EnableControls;
|
||||
end;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
//Application.MessageBox('保存成功!','提示',0);
|
||||
//TV1.OptionsData.Editing:=False;
|
||||
//TV1.OptionsSelection.CellSelect:=False;
|
||||
except
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('保存失败!','提示',0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.V1OrderNoPropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
mvalue:string;
|
||||
begin
|
||||
if Trim(ClientDataSet1.fieldbyname('ZdyName').AsString)='' then
|
||||
begin
|
||||
Application.MessageBox('名称不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
mvalue:=TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue)='' then
|
||||
begin
|
||||
mvalue:='0';
|
||||
end;
|
||||
with ClientDataSet1 do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('OrderNo').Value:=mvalue;
|
||||
Post;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update KH_Zdy Set OrderNo='+mvalue);
|
||||
sql.Add(' where ZdyNo='''+Trim(ClientDataSet1.fieldbyname('ZdyNo').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.V1NotePropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
mvalue:string;
|
||||
begin
|
||||
if Trim(ClientDataSet1.fieldbyname('ZdyName').AsString)='' then
|
||||
begin
|
||||
Application.MessageBox('名称不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
mvalue:=TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue)='' then
|
||||
begin
|
||||
mvalue:='0';
|
||||
end;
|
||||
with ClientDataSet1 do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('Note').Value:=mvalue;
|
||||
Post;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update KH_Zdy Set Note='''+Trim(mvalue)+'''');
|
||||
sql.Add(' where ZdyNo='''+Trim(ClientDataSet1.fieldbyname('ZdyNo').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.V1Column1PropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
mvalue:String;
|
||||
begin
|
||||
if Trim(ClientDataSet1.fieldbyname('ZdyName').AsString)='' then
|
||||
begin
|
||||
Application.MessageBox('名称不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
mvalue:=TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue)='' then
|
||||
begin
|
||||
mvalue:='0';
|
||||
end;
|
||||
with ClientDataSet1 do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('ZdyFlag').Value:=StrToInt(mvalue);
|
||||
Post;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update KH_Zdy Set ZdyFlag='+Trim(mvalue));
|
||||
sql.Add(' where ZdyNo='''+Trim(ClientDataSet1.fieldbyname('ZdyNo').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmRTZDYHelp.V1HelpTypePropertiesEditValueChanged(
|
||||
Sender: TObject);
|
||||
var
|
||||
mvalue:string;
|
||||
begin
|
||||
if Trim(ClientDataSet1.fieldbyname('ZdyName').AsString)='' then
|
||||
begin
|
||||
Application.MessageBox('名称不能为空!','提示',0);
|
||||
Exit;
|
||||
end;
|
||||
mvalue:=TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue)='' then
|
||||
begin
|
||||
mvalue:='0';
|
||||
end;
|
||||
with ClientDataSet1 do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('HelpType').Value:=mvalue;
|
||||
Post;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add('Update KH_Zdy Set HelpType='''+Trim(mvalue)+'''');
|
||||
sql.Add(' where ZdyNo='''+Trim(ClientDataSet1.fieldbyname('ZdyNo').AsString)+'''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
|
@ -1,202 +0,0 @@
|
|||
object frmUserSel: TfrmUserSel
|
||||
Left = 660
|
||||
Top = 154
|
||||
Width = 409
|
||||
Height = 527
|
||||
Caption = #29992#25143#36873#25321
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
OnClose = FormClose
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 393
|
||||
Height = 31
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
DisabledImages = DataLink_DDMD.ThreeImgList
|
||||
Flat = True
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #30830#35748
|
||||
ImageIndex = 10
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 31
|
||||
Width = 393
|
||||
Height = 39
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label3: TLabel
|
||||
Left = 202
|
||||
Top = 13
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #20379#24212#21830#21517#31216
|
||||
end
|
||||
object Label1: TLabel
|
||||
Left = 22
|
||||
Top = 13
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #20379#24212#21830#32534#21495
|
||||
end
|
||||
object CoName: TEdit
|
||||
Tag = 2
|
||||
Left = 263
|
||||
Top = 9
|
||||
Width = 89
|
||||
Height = 20
|
||||
ImeName = #20013#25991' - QQ'#25340#38899#36755#20837#27861
|
||||
TabOrder = 1
|
||||
OnChange = CoNameChange
|
||||
end
|
||||
object CoCode: TEdit
|
||||
Tag = 2
|
||||
Left = 82
|
||||
Top = 9
|
||||
Width = 89
|
||||
Height = 20
|
||||
ImeName = #20013#25991' - QQ'#25340#38899#36755#20837#27861
|
||||
TabOrder = 0
|
||||
OnChange = CoNameChange
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 70
|
||||
Width = 393
|
||||
Height = 418
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object Tv2: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
Navigator.Buttons.Delete.Enabled = False
|
||||
Navigator.Buttons.Delete.Visible = False
|
||||
DataController.DataSource = DS_HZ
|
||||
DataController.Options = [dcoAssignGroupingValues, dcoAssignMasterDetailKeys, dcoSaveExpanding, dcoImmediatePost]
|
||||
DataController.Summary.DefaultGroupSummaryItems = <>
|
||||
DataController.Summary.FooterSummaryItems = <>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.handBlack
|
||||
object v2Column4: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
PropertiesClassName = 'TcxCheckBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
HeaderAlignmentHorz = taCenter
|
||||
end
|
||||
object v2Column1: TcxGridDBColumn
|
||||
Caption = #32534#21495
|
||||
DataBinding.FieldName = 'UserID'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
end
|
||||
object v2Column2: TcxGridDBColumn
|
||||
Caption = #21517#31216
|
||||
DataBinding.FieldName = 'UserName'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 171
|
||||
end
|
||||
object v2Column3: TcxGridDBColumn
|
||||
Caption = #37096#38376
|
||||
DataBinding.FieldName = 'Udept'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = Tv2
|
||||
end
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 92
|
||||
Top = 224
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 132
|
||||
Top = 224
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 54
|
||||
Top = 224
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 211
|
||||
Top = 124
|
||||
end
|
||||
object DS_HZ: TDataSource
|
||||
DataSet = CDS_User
|
||||
Left = 222
|
||||
Top = 176
|
||||
end
|
||||
object CDS_User: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 190
|
||||
Top = 176
|
||||
end
|
||||
end
|
||||
|
|
@ -1,141 +0,0 @@
|
|||
unit U_UserSel;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxGraphics, cxCustomData, cxStyles, cxTL, cxMaskEdit, DB, ADODB,
|
||||
cxInplaceContainer, cxDBTL, cxControls, cxTLData, ComCtrls, ToolWin, StdCtrls,
|
||||
cxFilter, cxData, cxDataStorage, cxEdit, cxDBData, DBClient,
|
||||
cxGridCustomTableView, cxGridTableView, cxGridDBTableView, ExtCtrls,
|
||||
cxSplitter, cxGridLevel, cxClasses, cxGridCustomView, cxGrid,
|
||||
cxGridCustomPopupMenu, cxGridPopupMenu, RM_Dataset, RM_System, RM_Common,
|
||||
RM_Class, RM_GridReport, IdBaseComponent, IdComponent, IdTCPConnection,
|
||||
IdTCPClient, IdFTP, ShellAPI, IniFiles, cxCheckBox, cxCalendar, cxButtonEdit,
|
||||
cxTextEdit, cxDBLookupComboBox, ComObj, cxLookAndFeels,
|
||||
cxLookAndFeelPainters, cxNavigator;
|
||||
|
||||
type
|
||||
FdDy = record
|
||||
inc: integer; //客户端套接字句柄
|
||||
FDdys: string[32]; //客户端套接字
|
||||
FdDysName: string[32]; //客户端套接字
|
||||
end;
|
||||
|
||||
TfrmUserSel = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
Panel1: TPanel;
|
||||
ToolButton2: TToolButton;
|
||||
ADOQueryMain: TADOQuery;
|
||||
Label3: TLabel;
|
||||
CoName: TEdit;
|
||||
cxGrid2: TcxGrid;
|
||||
Tv2: TcxGridDBTableView;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DS_HZ: TDataSource;
|
||||
CDS_User: TClientDataSet;
|
||||
Label1: TLabel;
|
||||
CoCode: TEdit;
|
||||
ToolButton1: TToolButton;
|
||||
v2Column1: TcxGridDBColumn;
|
||||
v2Column2: TcxGridDBColumn;
|
||||
v2Column3: TcxGridDBColumn;
|
||||
v2Column4: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
procedure CoNameChange(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
private
|
||||
|
||||
{ Private declarations }
|
||||
procedure InitGrid();
|
||||
public
|
||||
end;
|
||||
|
||||
var
|
||||
frmUserSel: TfrmUserSel;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_Fun;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmUserSel.InitGrid();
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
SQL.Clear;
|
||||
sql.Add(' select * from SY_User where wxid is not null ');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_User);
|
||||
SInitCDSData20(ADOQueryMain, CDS_User);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmUserSel.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
frmUserSel := nil;
|
||||
end;
|
||||
|
||||
procedure TfrmUserSel.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmUserSel.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid(trim(self.caption), Tv2, '供应商管理');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmUserSel.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid(trim(self.Caption), Tv2, '供应商管理管理');
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmUserSel.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmUserSel.ToolButton2Click(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_User);
|
||||
SInitCDSData20(ADOQueryMain, CDS_User);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmUserSel.CoNameChange(Sender: TObject);
|
||||
begin
|
||||
ToolButton2.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmUserSel.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
ModalResult := 1;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -1,718 +0,0 @@
|
|||
object frmXSQKLLIST: TfrmXSQKLLIST
|
||||
Left = 171
|
||||
Top = 92
|
||||
Width = 1341
|
||||
Height = 614
|
||||
Caption = #38144#21806#24773#20917#34920
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1325
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
Visible = False
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 26
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #35774#23450
|
||||
ImageIndex = 22
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1325
|
||||
Height = 49
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 42
|
||||
Top = 11
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #26085#26399
|
||||
end
|
||||
object Label16: TLabel
|
||||
Left = 371
|
||||
Top = 11
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #37096#38376
|
||||
end
|
||||
object Label17: TLabel
|
||||
Left = 523
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #21161' '#29702
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 674
|
||||
Top = 10
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #32452#38271
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 69
|
||||
Top = 6
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object bm: TEdit
|
||||
Tag = 2
|
||||
Left = 403
|
||||
Top = 7
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 1
|
||||
OnChange = bmChange
|
||||
end
|
||||
object YWY: TEdit
|
||||
Tag = 2
|
||||
Left = 564
|
||||
Top = 7
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 2
|
||||
OnChange = YWYChange
|
||||
end
|
||||
object zz: TEdit
|
||||
Tag = 2
|
||||
Left = 706
|
||||
Top = 6
|
||||
Width = 100
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 3
|
||||
OnChange = YWYChange
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 141
|
||||
Width = 1325
|
||||
Height = 389
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object TV1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OnCustomDrawCell = TV1CustomDrawCell
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z3'
|
||||
Column = TV1Column4
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z2'
|
||||
Column = TV1Column2
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = Z1
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = TV1Column12
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = TV1Column13
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Column = TV1Column16
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z4'
|
||||
Column = TV1Column6
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z5'
|
||||
Column = TV1Column7
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z6'
|
||||
Column = TV1Column10
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z7'
|
||||
Column = TV1Column17
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z8'
|
||||
Column = TV1Column18
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z9'
|
||||
Column = TV1Column19
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z10'
|
||||
Column = TV1Column20
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z11'
|
||||
Column = TV1Column21
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z12'
|
||||
Column = TV1Column22
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
FieldName = 'Z1'
|
||||
Column = TV1Column15
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsSelection.CellSelect = False
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Content = cxStyle3
|
||||
Styles.Inactive = cxStyle3
|
||||
Styles.IncSearch = cxStyle3
|
||||
Styles.Selection = cxStyle3
|
||||
Styles.Header = cxStyle3
|
||||
object TV1Column8: TcxGridDBColumn
|
||||
Caption = #37096#38376
|
||||
DataBinding.FieldName = 'bm'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.CellMerging = True
|
||||
Width = 75
|
||||
end
|
||||
object TV1Column11: TcxGridDBColumn
|
||||
Caption = #32452#38271
|
||||
DataBinding.FieldName = 'zz'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.CellMerging = True
|
||||
Width = 78
|
||||
OnCompareRowValuesForCellMerging = TV1Column11CompareRowValuesForCellMerging
|
||||
end
|
||||
object TV1Column14: TcxGridDBColumn
|
||||
Caption = #21161#29702
|
||||
DataBinding.FieldName = 'YWY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 69
|
||||
end
|
||||
object TV1Column9: TcxGridDBColumn
|
||||
Caption = #24066#22330
|
||||
DataBinding.FieldName = 'TOCOUNTRY1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object TV1Column15: TcxGridDBColumn
|
||||
Caption = #19968#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH1'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object TV1Column2: TcxGridDBColumn
|
||||
Caption = #20108#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH2'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object TV1Column4: TcxGridDBColumn
|
||||
Caption = #19977#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH3'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object TV1Column6: TcxGridDBColumn
|
||||
Caption = #22235#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH4'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
OnCompareRowValuesForCellMerging = TV1Column10CompareRowValuesForCellMerging
|
||||
end
|
||||
object TV1Column7: TcxGridDBColumn
|
||||
Caption = #20116#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH5'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
OnCompareRowValuesForCellMerging = TV1Column10CompareRowValuesForCellMerging
|
||||
end
|
||||
object TV1Column10: TcxGridDBColumn
|
||||
Caption = #20845#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH6'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
HeaderGlyphAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
OnCompareRowValuesForCellMerging = TV1Column10CompareRowValuesForCellMerging
|
||||
end
|
||||
object TV1Column5: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'WEEKUSD'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Visible = False
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column1: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'YEARUSD'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Visible = False
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column3: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'MONTHUSD'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Visible = False
|
||||
Width = 70
|
||||
end
|
||||
object TV1Column12: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'nfrmbw'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Visible = False
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column13: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'nfrmbm'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Visible = False
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column16: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'nfrmby'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
Visible = False
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column17: TcxGridDBColumn
|
||||
Caption = #19971#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH7'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object TV1Column18: TcxGridDBColumn
|
||||
Caption = #20843#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH8'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object TV1Column19: TcxGridDBColumn
|
||||
Caption = #20061#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH9'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object TV1Column20: TcxGridDBColumn
|
||||
Caption = #21313#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH10'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 80
|
||||
end
|
||||
object TV1Column21: TcxGridDBColumn
|
||||
Caption = #21313#19968#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH11'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 90
|
||||
end
|
||||
object TV1Column22: TcxGridDBColumn
|
||||
Caption = #21313#20108#26376#38144#21806
|
||||
DataBinding.FieldName = 'MONTH12'
|
||||
PropertiesClassName = 'TcxTextEditProperties'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 101
|
||||
end
|
||||
object Z1: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z1'
|
||||
Visible = False
|
||||
end
|
||||
object Z2: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z2'
|
||||
Visible = False
|
||||
end
|
||||
object Z3: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z3'
|
||||
Visible = False
|
||||
end
|
||||
object Z4: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z4'
|
||||
Visible = False
|
||||
end
|
||||
object Z5: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z5'
|
||||
Visible = False
|
||||
end
|
||||
object Z6: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z6'
|
||||
Visible = False
|
||||
end
|
||||
object Z7: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z7'
|
||||
Visible = False
|
||||
end
|
||||
object Z8: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z8'
|
||||
Visible = False
|
||||
end
|
||||
object Z9: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z9'
|
||||
Visible = False
|
||||
end
|
||||
object Z10: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z10'
|
||||
Visible = False
|
||||
end
|
||||
object Z11: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z11'
|
||||
Visible = False
|
||||
end
|
||||
object Z12: TcxGridDBColumn
|
||||
DataBinding.FieldName = 'Z12'
|
||||
Visible = False
|
||||
end
|
||||
object TV1Column23: TcxGridDBColumn
|
||||
Caption = '2022'#24180#38144#21806#30446#26631#65288#32654#37329#65289
|
||||
DataBinding.FieldName = 'ZdyFlt1'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 124
|
||||
end
|
||||
object TV1Column24: TcxGridDBColumn
|
||||
Caption = #23436#25104#30446#26631#38144#21806#30334#20998#27604
|
||||
DataBinding.FieldName = 'MBBFB'
|
||||
HeaderAlignmentHorz = taRightJustify
|
||||
Width = 147
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object Panel2: TPanel
|
||||
Left = 0
|
||||
Top = 530
|
||||
Width = 1325
|
||||
Height = 45
|
||||
Align = alBottom
|
||||
TabOrder = 3
|
||||
object Label6: TLabel
|
||||
Left = 27
|
||||
Top = 6
|
||||
Width = 144
|
||||
Height = 24
|
||||
Caption = #24180#24230#24635#35745'USD:'
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clRed
|
||||
Font.Height = -24
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
end
|
||||
object Panel3: TPanel
|
||||
Left = 0
|
||||
Top = 81
|
||||
Width = 1325
|
||||
Height = 60
|
||||
Align = alTop
|
||||
Caption = #38144' '#21806' '#24773' '#20917' '#27719' '#24635' '#34920
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -27
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
TabOrder = 4
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 888
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 925
|
||||
Top = 217
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 893
|
||||
Top = 217
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 957
|
||||
Top = 217
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 858
|
||||
Top = 188
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 777
|
||||
Top = 299
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 883
|
||||
Top = 487
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 917
|
||||
Top = 487
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 949
|
||||
Top = 487
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowDialog = False
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 1013
|
||||
Top = 212
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 251
|
||||
Top = 364
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 255
|
||||
Top = 300
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = ADOQueryMain
|
||||
Left = 255
|
||||
Top = 336
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 984
|
||||
Top = 212
|
||||
end
|
||||
object cxStyleRepository1: TcxStyleRepository
|
||||
PixelsPerInch = 96
|
||||
object cxStyle1: TcxStyle
|
||||
AssignedValues = [svFont]
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Name = #24494#36719#38597#40657
|
||||
Font.Style = [fsBold]
|
||||
end
|
||||
object cxStyle3: TcxStyle
|
||||
AssignedValues = [svFont]
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -15
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
end
|
||||
end
|
||||
object cxStyleRepository2: TcxStyleRepository
|
||||
PixelsPerInch = 96
|
||||
object cxStyle2: TcxStyle
|
||||
end
|
||||
end
|
||||
object IdHTTP1: TIdHTTP
|
||||
MaxLineAction = maException
|
||||
ReadTimeout = 0
|
||||
AllowCookies = True
|
||||
ProxyParams.BasicAuthentication = False
|
||||
ProxyParams.ProxyPort = 0
|
||||
Request.ContentLength = -1
|
||||
Request.ContentRangeEnd = 0
|
||||
Request.ContentRangeStart = 0
|
||||
Request.ContentType = 'text/html'
|
||||
Request.Accept = 'text/html, */*'
|
||||
Request.BasicAuthentication = False
|
||||
Request.UserAgent = 'Mozilla/3.0 (compatible; Indy Library)'
|
||||
HTTPOptions = [hoForceEncodeParams]
|
||||
Left = 348
|
||||
Top = 172
|
||||
end
|
||||
end
|
||||
|
|
@ -1,795 +0,0 @@
|
|||
unit U_XSQKList;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||||
cxEdit, DB, cxDBData, cxGridCustomTableView, cxGridTableView,
|
||||
cxGridBandedTableView, cxGridDBBandedTableView, cxGridLevel, cxClasses,
|
||||
cxControls, cxGridCustomView, cxGridDBTableView, cxGrid, StdCtrls, ComCtrls,
|
||||
ExtCtrls, ToolWin, cxGridCustomPopupMenu, cxGridPopupMenu, ADODB, DBClient,
|
||||
cxDropDownEdit, cxCheckBox, RM_Common, RM_Class, RM_e_Xls, RM_Dataset,
|
||||
RM_System, RM_GridReport, Menus, cxCalendar, cxButtonEdit, cxTextEdit, cxPC,
|
||||
BtnEdit, cxSplitter, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator,
|
||||
dxBarBuiltInMenu, MovePanel, cxCalc, Registry, cxCurrencyEdit, IdBaseComponent,
|
||||
IdComponent, IdTCPConnection, IdTCPClient, IdHTTP;
|
||||
|
||||
type
|
||||
TfrmXSQKLLIST = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBRafresh: TToolButton;
|
||||
TBFind: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
Panel1: TPanel;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
DataSource1: TDataSource;
|
||||
cxGridPopupMenu1: TcxGridPopupMenu;
|
||||
EndDate: TDateTimePicker;
|
||||
CDS_Main: TClientDataSet;
|
||||
PopupMenu1: TPopupMenu;
|
||||
N1: TMenuItem;
|
||||
N2: TMenuItem;
|
||||
ClientDataSet1: TClientDataSet;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
DataSource2: TDataSource;
|
||||
ClientDataSet2: TClientDataSet;
|
||||
RMXLSExport1: TRMXLSExport;
|
||||
CDS_Print: TClientDataSet;
|
||||
RM1: TRMGridReport;
|
||||
RMDBDataSet1: TRMDBDataSet;
|
||||
ADOQueryPrint: TADOQuery;
|
||||
cxGrid2: TcxGrid;
|
||||
TV1: TcxGridDBTableView;
|
||||
cxGridLevel1: TcxGridLevel;
|
||||
TV1Column8: TcxGridDBColumn;
|
||||
TV1Column9: TcxGridDBColumn;
|
||||
TV1Column14: TcxGridDBColumn;
|
||||
TV1Column15: TcxGridDBColumn;
|
||||
ToolButton1: TToolButton;
|
||||
Label1: TLabel;
|
||||
TV1Column2: TcxGridDBColumn;
|
||||
TV1Column4: TcxGridDBColumn;
|
||||
TV1Column6: TcxGridDBColumn;
|
||||
TV1Column7: TcxGridDBColumn;
|
||||
TV1Column10: TcxGridDBColumn;
|
||||
Label16: TLabel;
|
||||
Label17: TLabel;
|
||||
bm: TEdit;
|
||||
YWY: TEdit;
|
||||
TV1Column11: TcxGridDBColumn;
|
||||
Label2: TLabel;
|
||||
zz: TEdit;
|
||||
TV1Column1: TcxGridDBColumn;
|
||||
TV1Column3: TcxGridDBColumn;
|
||||
TV1Column5: TcxGridDBColumn;
|
||||
TV1Column12: TcxGridDBColumn;
|
||||
TV1Column13: TcxGridDBColumn;
|
||||
TV1Column16: TcxGridDBColumn;
|
||||
Panel2: TPanel;
|
||||
Label6: TLabel;
|
||||
Panel3: TPanel;
|
||||
cxStyleRepository1: TcxStyleRepository;
|
||||
cxStyle1: TcxStyle;
|
||||
cxStyleRepository2: TcxStyleRepository;
|
||||
cxStyle2: TcxStyle;
|
||||
IdHTTP1: TIdHTTP;
|
||||
TV1Column17: TcxGridDBColumn;
|
||||
TV1Column18: TcxGridDBColumn;
|
||||
TV1Column19: TcxGridDBColumn;
|
||||
TV1Column20: TcxGridDBColumn;
|
||||
TV1Column21: TcxGridDBColumn;
|
||||
TV1Column22: TcxGridDBColumn;
|
||||
Z1: TcxGridDBColumn;
|
||||
Z2: TcxGridDBColumn;
|
||||
Z3: TcxGridDBColumn;
|
||||
Z4: TcxGridDBColumn;
|
||||
Z5: TcxGridDBColumn;
|
||||
Z6: TcxGridDBColumn;
|
||||
Z7: TcxGridDBColumn;
|
||||
Z8: TcxGridDBColumn;
|
||||
Z9: TcxGridDBColumn;
|
||||
Z10: TcxGridDBColumn;
|
||||
Z11: TcxGridDBColumn;
|
||||
Z12: TcxGridDBColumn;
|
||||
cxStyle3: TcxStyle;
|
||||
ToolButton2: TToolButton;
|
||||
TV1Column23: TcxGridDBColumn;
|
||||
TV1Column24: TcxGridDBColumn;
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure TBRafreshClick(Sender: TObject);
|
||||
procedure ConNoMChange(Sender: TObject);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBExportClick(Sender: TObject);
|
||||
procedure TBFindClick(Sender: TObject);
|
||||
procedure N1Click(Sender: TObject);
|
||||
procedure N2Click(Sender: TObject);
|
||||
procedure FactoryNameChange(Sender: TObject);
|
||||
procedure cxTabControl1Change(Sender: TObject);
|
||||
procedure CRTypeChange(Sender: TObject);
|
||||
procedure Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
procedure GCNAMEKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure KHNameKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure TBCopyClick(Sender: TObject);
|
||||
procedure TBBGZLClick(Sender: TObject);
|
||||
procedure TBHTClick(Sender: TObject);
|
||||
procedure TBFPClick(Sender: TObject);
|
||||
procedure TBZXDClick(Sender: TObject);
|
||||
procedure TBBGDClick(Sender: TObject);
|
||||
procedure TBViewClick(Sender: TObject);
|
||||
procedure TBSBYSClick(Sender: TObject);
|
||||
procedure TBAllClick(Sender: TObject);
|
||||
procedure YWYChange(Sender: TObject);
|
||||
procedure Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure ComboBox1Change(Sender: TObject);
|
||||
procedure bmKeyPress(Sender: TObject; var Key: Char);
|
||||
procedure bmChange(Sender: TObject);
|
||||
procedure TV1Column10CompareRowValuesForCellMerging(Sender: TcxGridColumn; ARow1: TcxGridDataRow; AProperties1: TcxCustomEditProperties; const AValue1: Variant; ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties; const AValue2: Variant; var AAreEqual: Boolean);
|
||||
procedure TV1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||
procedure TV1Column11CompareRowValuesForCellMerging(Sender: TcxGridColumn; ARow1: TcxGridDataRow; AProperties1: TcxCustomEditProperties; const AValue1: Variant; ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties; const AValue2: Variant; var AAreEqual: Boolean);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
private
|
||||
canshu2: string;
|
||||
FDate: TDateTime;
|
||||
procedure InitGrid();
|
||||
function DelData(): Boolean;
|
||||
procedure InitSubGrid();
|
||||
procedure InitGridSql(var fsj: string);
|
||||
function GetShellFolders(strDir: string): string;
|
||||
procedure InitPrtData();
|
||||
{ Private declarations }
|
||||
public
|
||||
canshu1: string;
|
||||
{ Public declarations }
|
||||
end;
|
||||
|
||||
//var
|
||||
//frmBaoGuanList: TfrmBaoGuanList;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_RTFun, U_ZDYHelp9, U_BaoGuanInPut, U_Fun, U_UserSel;
|
||||
|
||||
{$R *.dfm}
|
||||
function TfrmXSQKLLIST.GetShellFolders(strDir: string): string;
|
||||
const
|
||||
regPath = '\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders';
|
||||
var
|
||||
Reg: TRegistry;
|
||||
strFolders: string;
|
||||
begin
|
||||
Reg := TRegistry.Create;
|
||||
try
|
||||
Reg.RootKey := HKEY_CURRENT_USER;
|
||||
if Reg.OpenKey(regPath, false) then
|
||||
begin
|
||||
strFolders := Reg.ReadString(strDir);
|
||||
end;
|
||||
finally
|
||||
Reg.Free;
|
||||
end;
|
||||
result := strFolders;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.FormDestroy(Sender: TObject);
|
||||
begin
|
||||
//frmBaoGuanList:=nil;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Application := MainApplication;
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.FormCreate(Sender: TObject);
|
||||
begin
|
||||
//cxGrid1.Align:=alClient;
|
||||
EndDate.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||
|
||||
canshu1 := Trim(DParameters1);
|
||||
canshu2 := Trim(DParameters2);
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.InitGrid();
|
||||
var
|
||||
fwhere, Pwhere: string;
|
||||
begin
|
||||
Pwhere := SGetFilters(Panel1, 1, 2);
|
||||
|
||||
begin
|
||||
if trim(Pwhere) <> '' then
|
||||
fwhere := fwhere + ' and ' + trim(Pwhere);
|
||||
end;
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
// SQL.Add('select * from (');
|
||||
|
||||
sql.Add('EXEC P_CHQD_XSList @lzyear=' + QuotedStr(FormatDateTime('yyyy-MM-dd', ENDDate.DateTime)));
|
||||
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
Label6.Caption := '年度总计USD:' + FloatToStr(ADOQueryMain.fieldbyname('hz').asfloat);
|
||||
// FloatToCurr()
|
||||
// ShowMessage(CurrToStr(FloatToCurr(tV1.DataController.Summary.FooterSummaryValues[10])));
|
||||
// ShowMessage(VarToStr(FloatToCurr(1234)));
|
||||
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBRafreshClick(Sender: TObject);
|
||||
begin
|
||||
|
||||
InitGrid();
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.ConNoMChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('报关主表' + self.Caption, Tv1, '出货清单34');
|
||||
// WriteCxGrid('报关明细' + self.Caption, Tv2, '报关管理8');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('报关主表' + self.Caption, Tv1, '出货清单34');
|
||||
// ReadCxGrid('报关明细' + self.Caption, Tv2, '报关管理8');
|
||||
canshu1 := Trim(DParameters1);
|
||||
// ShowMessage(canshu1);
|
||||
|
||||
InitGrid();
|
||||
RM1.CanExport := true;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBExportClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
// TcxGridToExcel(Trim(CDS_Main.fieldbyname('A4FPNO').AsString) + Trim(CDS_Main.fieldbyname('A5ConNO').AsString), cxGrid1);
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBFindClick(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.N1Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main, True);
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.N2Click(Sender: TObject);
|
||||
begin
|
||||
SelOKNo(CDS_Main, False);
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.InitSubGrid();
|
||||
begin
|
||||
if CDS_Main.IsEmpty = False then
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where BGID=''' + Trim(CDS_Main.fieldbyname('BGID').AsString) + '''');
|
||||
sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from JYOrder_BaoGuan_Sub where 1=2');
|
||||
Open;
|
||||
end;
|
||||
end;
|
||||
|
||||
SCreateCDS20(ADOQueryTemp, ClientDataSet2);
|
||||
SInitCDSData20(ADOQueryTemp, ClientDataSet2);
|
||||
end;
|
||||
|
||||
function TfrmXSQKLLIST.DelData(): Boolean;
|
||||
begin
|
||||
try
|
||||
Result := false;
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
CDS_Main.DisableControls;
|
||||
with CDS_Main do
|
||||
begin
|
||||
First;
|
||||
while CDS_Main.Locate('SSel', True, []) do
|
||||
begin
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Valid=''N'',C7BGMoneyHZ=Null,E1BZQtyHZ=Null, E2ChiMaQtyHZ=Null,E3MaoZHZ=Null,E4JingZHZ=Null');
|
||||
sql.Add(',Editer=''' + Trim(DName) + ''',EditTime=getdate()');
|
||||
sql.Add(' where BGId=''' + Trim(CDS_Main.fieldbyname('BGId').AsString) + '''');
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer=''' + Trim(DName) + ''',SEditTime=getdate() where BGId=''' + Trim(CDS_Main.fieldbyname('BGId').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
Result := True;
|
||||
except
|
||||
CDS_Main.EnableControls;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Result := False;
|
||||
Application.MessageBox('数据删除异常!', '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.FactoryNameChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.cxTabControl1Change(Sender: TObject);
|
||||
begin
|
||||
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.CRTypeChange(Sender: TObject);
|
||||
begin
|
||||
TBFind.Click;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.InitGridSql(var fsj: string);
|
||||
begin
|
||||
try
|
||||
ADOQueryMain.DisableControls;
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Filtered := False;
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select A.* ');
|
||||
sql.Add(' from JYOrder_BaoGuan_Main A ');
|
||||
sql.Add(' where 1=1 ');
|
||||
if Trim(canshu1) <> '高权限' then
|
||||
begin
|
||||
SQL.Add(' and FillerCode=''' + Trim(DCode) + '''');
|
||||
end;
|
||||
|
||||
sql.Add(fsj);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
finally
|
||||
ADOQueryMain.EnableControls;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.Tv1CellClick(Sender: TcxCustomGridTableView; ACellViewInfo: TcxGridTableDataCellViewInfo; AButton: TMouseButton; AShift: TShiftState; var AHandled: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.GCNAMEKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
// if Key = #13 then
|
||||
// begin
|
||||
// if Trim(A6PONO.Text) = '' then
|
||||
// Exit;
|
||||
// fsj := ' and isnull(A.A6PONO,'''') like ''' + '%' + Trim(A6PONO.Text) + '%' + '''';
|
||||
// InitGridSql(fsj);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.KHNameKeyPress(Sender: TObject; var Key: Char);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
// if Key = #13 then
|
||||
// begin
|
||||
// if Trim(A5ConNO.Text) = '' then
|
||||
// Exit;
|
||||
// fsj := ' and isnull(A.A5ConNO,'''') like ''' + '%' + Trim(A5ConNO.Text) + '%' + '''';
|
||||
// InitGridSql(fsj);
|
||||
// end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBCopyClick(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
// if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut := TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId := Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
CopyStr := '99';
|
||||
//TBDel.Visible:=False;
|
||||
//TBAdd.Visible:=False;
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.InitPrtData();
|
||||
begin
|
||||
with ADOQueryPrint do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' exec P_View_BaoGuanData :BGID ');
|
||||
Parameters.ParamByName('BGID').Value := Trim(CDS_Main.fieldbyname('BGId').AsString);
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryPrint, CDS_Print);
|
||||
SInitCDSData20(ADOQueryPrint, CDS_Print);
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBBGZLClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关资料.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBHTClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关合同.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBFPClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关发票.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBZXDClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关装箱单.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBBGDClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\报关单.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBViewClick(Sender: TObject);
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
//if cxTabControl1.TabIndex<>0 then Exit;
|
||||
try
|
||||
frmBaoGuanInPut := TfrmBaoGuanInPut.Create(Application);
|
||||
with frmBaoGuanInPut do
|
||||
begin
|
||||
FBCId := Trim(CDS_Main.fieldbyname('BGID').AsString);
|
||||
TBSave.Visible := False;
|
||||
ToolBar2.Visible := False;
|
||||
Panel1.Enabled := False;
|
||||
Tv1.OptionsData.Editing := False;
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
Self.InitGrid();
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmBaoGuanInPut.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBSBYSClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
RMXLSExport1 := TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
//RMVariables['enddate']:=enddate.DateTime;
|
||||
//RMVariables['printtime']:=Now;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\申报要素.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TBAllClick(Sender: TObject);
|
||||
var
|
||||
fPrintFile: string;
|
||||
EngMoney, BZZH, FimageFile, FZMFile: string;
|
||||
begin
|
||||
if CDS_Main.IsEmpty then
|
||||
Exit;
|
||||
fPrintFile := ExtractFilePath(Application.ExeName) + 'Report\全部报关资料.rmf';
|
||||
InitPrtData();
|
||||
FimageFile := ExtractFilePath(Application.ExeName) + 'Image\' + Trim(CDS_Print.FieldByName('A1ChuKouShang').AsString) + '.jpg';
|
||||
//RMXLSExport1:= TRMXLSExport.Create(RMXLSExport1);
|
||||
if FileExists(fPrintFile) then
|
||||
begin
|
||||
if RM1.CanExport = true then
|
||||
begin
|
||||
FZMFile := 'C:\Users\Administrator\Desktop';
|
||||
if not DirectoryExists(FZMFile) then
|
||||
begin
|
||||
FZMFile := 'C:\Documents and Settings\Administrator\桌面\' + trim(CDS_Main.fieldbyname('A4FPNO').AsString) + ' ' + trim(CDS_Main.fieldbyname('A5ConNO').AsString) + '.xls';
|
||||
end
|
||||
else
|
||||
begin
|
||||
FZMFile := 'C:\Users\Administrator\Desktop\' + trim(CDS_Main.fieldbyname('A4FPNO').AsString) + ' ' + trim(CDS_Main.fieldbyname('A5ConNO').AsString) + '.XLS';
|
||||
end;
|
||||
RM1.ExportTo(RMXLSExport1, FZMFile);
|
||||
end;
|
||||
RM1.CanExport := true;
|
||||
RMVariables['ImageFile'] := trim(FimageFile);
|
||||
RM1.LoadFromFile(fPrintFile);
|
||||
RM1.ShowReport;
|
||||
RM1.CanExport := False;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Application.MessageBox(PChar('没有找' + ExtractFilePath(Application.ExeName) + 'Report\全部报关资料.rmf'), '提示', 0);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.YWYChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.Tv1FocusedRecordChanged(Sender: TcxCustomGridTableView; APrevFocusedRecord, AFocusedRecord: TcxCustomGridRecord; ANewItemRecordFocusingChanged: Boolean);
|
||||
begin
|
||||
InitSubGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.IsEmpty then
|
||||
exit;
|
||||
// SelExportData(Tv1, ADOQueryMain, '出货清单');
|
||||
// with ADOQueryMain do
|
||||
// begin
|
||||
// Filtered := False;
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// sql.Add('select A.*,B.* ');
|
||||
//// SQL.Add(',HDNAME=(SELECT HDNAME FROM JYOrderCon_TT C WHERE C.DCNO=A.DCNO)');
|
||||
// SQL.Add(',TOCOUNTRY1=(SELECT TOP 1 ISNULL(note,zdyname) FROM KH_ZDY D WHERE D.ZDYNAME=A.TOCOUNTRY)');
|
||||
// SQL.Add(',BM=(SELECT ISNULL(UDEPT,'''')+USERNAME FROM SY_User C WHERE C.USERNAME=A.FILLER )');
|
||||
//
|
||||
// sql.Add(' from JYOrder_BaoGuan_Main A INNER JOIN JYOrder_BaoGuan_SUB B ON A.BGID=B.BGID ');
|
||||
// sql.Add(' where A.Valid=''Y'' and B.SValid=''Y'' ');
|
||||
// SQL.Add('AND bgStatus=''√''');
|
||||
// sql.Add(' and filltime>=''' + Trim(FormatDateTime('yyyy-MM-dd', BegDate.Date)) + '''');
|
||||
// sql.Add(' and filltime<''' + Trim(FormatDateTime('yyyy-MM-dd', EndDate.Date + 1)) + '''');
|
||||
// sql.Add('order by YWY');
|
||||
//// ShowMessage(sql.Text);
|
||||
// Open;
|
||||
// end;
|
||||
// SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
// SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
// TBFind.Click();
|
||||
TcxGridToExcel('出货合计清单', cxGrid2);
|
||||
|
||||
InitGrid();
|
||||
TBFind.Click();
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.ComboBox1Change(Sender: TObject);
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.bmKeyPress(Sender: TObject; var Key: Char);
|
||||
begin
|
||||
if Key = #13 then
|
||||
begin
|
||||
InitGrid();
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.bmChange(Sender: TObject);
|
||||
begin
|
||||
if ADOQueryMain.Active then
|
||||
begin
|
||||
SDofilter(ADOQueryMain, SGetFilters(Panel1, 1, 2));
|
||||
SCreateCDS20(ADOQueryMain, CDS_Main);
|
||||
SInitCDSData20(ADOQueryMain, CDS_Main);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TV1Column10CompareRowValuesForCellMerging(Sender: TcxGridColumn; ARow1: TcxGridDataRow; AProperties1: TcxCustomEditProperties; const AValue1: Variant; ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties; const AValue2: Variant; var AAreEqual: Boolean);
|
||||
begin
|
||||
if ARow1.Values[TV1Column8.Index] = ARow2.Values[TV1Column8.Index] then
|
||||
AAreEqual := True
|
||||
else
|
||||
AAreEqual := False;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TV1CustomDrawCell(Sender: TcxCustomGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||
begin
|
||||
if (AViewInfo.GridRecord.Values[tv1.GetColumnByFieldName('TOCOUNTRY1').Index] = '合计') then
|
||||
ACanvas.Brush.Color := $004080FF;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.TV1Column11CompareRowValuesForCellMerging(Sender: TcxGridColumn; ARow1: TcxGridDataRow; AProperties1: TcxCustomEditProperties; const AValue1: Variant; ARow2: TcxGridDataRow; AProperties2: TcxCustomEditProperties; const AValue2: Variant; var AAreEqual: Boolean);
|
||||
begin
|
||||
if ARow1.Values[TV1Column8.Index] = ARow2.Values[TV1Column8.Index] then
|
||||
AAreEqual := True
|
||||
else
|
||||
AAreEqual := False;
|
||||
end;
|
||||
|
||||
procedure TfrmXSQKLLIST.ToolButton2Click(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp9 := TfrmZDYHelp9.Create(Application);
|
||||
with frmZDYHelp9 do
|
||||
begin
|
||||
flag := 'XSMB';
|
||||
flagname := '销售目标';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
// Self.KHPM.Text := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp9.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,876 +0,0 @@
|
|||
unit U_XYZInPut;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||||
cxEdit, DB, cxDBData, cxCalendar, cxDropDownEdit, ComCtrls, ToolWin,
|
||||
cxGridLevel, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||
cxClasses, cxControls, cxGridCustomView, cxGrid, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxButtonEdit, cxTextEdit, StdCtrls, BtnEdit,
|
||||
ExtCtrls, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator;
|
||||
|
||||
type
|
||||
TfrmXYZInPut = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBSave: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
DataSource3: TDataSource;
|
||||
CDS_Sub: TClientDataSet;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
Panel1: TPanel;
|
||||
Label13: TLabel;
|
||||
XYNO: TEdit;
|
||||
Label4: TLabel;
|
||||
XMONEY: TEdit;
|
||||
Label5: TLabel;
|
||||
XGSMC: TBtnEditA;
|
||||
XQYD: TBtnEditA;
|
||||
XMDD: TBtnEditA;
|
||||
Label15: TLabel;
|
||||
Label16: TLabel;
|
||||
Label19: TLabel;
|
||||
Label18: TLabel;
|
||||
FKTS: TEdit;
|
||||
Label28: TLabel;
|
||||
XKHNAME: TBtnEditA;
|
||||
Label30: TLabel;
|
||||
XKZRQ: TDateTimePicker;
|
||||
Label1: TLabel;
|
||||
XTBYQ: TMemo;
|
||||
Label3: TLabel;
|
||||
XHWMS: TMemo;
|
||||
NOTE: TMemo;
|
||||
Label6: TLabel;
|
||||
XYWDB: TComboBox;
|
||||
Label11: TLabel;
|
||||
XSDRQ: TDateTimePicker;
|
||||
XUNIT: TComboBox;
|
||||
Label12: TLabel;
|
||||
ZUSDHL: TEdit;
|
||||
Label14: TLabel;
|
||||
ZUSDJE: TEdit;
|
||||
Label20: TLabel;
|
||||
XYJBL: TEdit;
|
||||
Label21: TLabel;
|
||||
XTZRQ: TDateTimePicker;
|
||||
Label23: TLabel;
|
||||
XTZH: TComboBox;
|
||||
Label24: TLabel;
|
||||
XTZYHH: TEdit;
|
||||
Label25: TLabel;
|
||||
XYXQX: TDateTimePicker;
|
||||
Label26: TLabel;
|
||||
XKZH: TMemo;
|
||||
Label29: TLabel;
|
||||
Label32: TLabel;
|
||||
XKZFS: TComboBox;
|
||||
Label33: TLabel;
|
||||
XXGCS: TEdit;
|
||||
Label34: TLabel;
|
||||
XZYQX: TDateTimePicker;
|
||||
Label35: TLabel;
|
||||
XXYZZT: TComboBox;
|
||||
Label36: TLabel;
|
||||
XYWY: TComboBox;
|
||||
Label37: TLabel;
|
||||
XBM: TEdit;
|
||||
Label38: TLabel;
|
||||
XXYTZRQ: TDateTimePicker;
|
||||
Label7: TLabel;
|
||||
XSFZY: TComboBox;
|
||||
Label8: TLabel;
|
||||
XFP: TComboBox;
|
||||
Label9: TLabel;
|
||||
XSFTZ: TComboBox;
|
||||
Label10: TLabel;
|
||||
XDBYH: TComboBox;
|
||||
Label17: TLabel;
|
||||
XSLGC: TEdit;
|
||||
Label2: TLabel;
|
||||
TTR: TMemo;
|
||||
Label22: TLabel;
|
||||
TZR: TMemo;
|
||||
Label27: TLabel;
|
||||
SHREN: TMemo;
|
||||
Label31: TLabel;
|
||||
FKR: TMemo;
|
||||
XORDERNO: TEdit;
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBSaveClick(Sender: TObject);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
procedure v1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column14PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column16PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column17PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure ToolButton4Click(Sender: TObject);
|
||||
procedure v1ZZJGouPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column12PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure TCXLJClick(Sender: TObject);
|
||||
procedure XQYDBtnClick(Sender: TObject);
|
||||
procedure KHNameBtnClick(Sender: TObject);
|
||||
procedure Tv1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column12PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column14PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column13PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column9PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column6PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure XKHNAMEBtnClick(Sender: TObject);
|
||||
procedure XUNITChange(Sender: TObject);
|
||||
procedure XMONEYChange(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
function SaveCKData(): Boolean;
|
||||
public
|
||||
{ Public declarations }
|
||||
FBCId, canshu3: string;
|
||||
CopyStr: string;
|
||||
end;
|
||||
|
||||
var
|
||||
frmXYZInPut: TfrmXYZInPut;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_RTFun, U_ZDYHelp, U_ZdyAttachment, U_ProductOrderList_Sel,
|
||||
U_DCDList_Sel, U_ZdyAttachGYS;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmXYZInPut.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
function TfrmXYZInPut.SaveCKData(): Boolean;
|
||||
var
|
||||
FJMID, Maxno, MaxSubNo, FSCID: string;
|
||||
begin
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from XYZ_MAIN where XYID=''' + Trim(FBCId) + '''');
|
||||
Open;
|
||||
end;
|
||||
FBCId := Trim(ADOQueryTemp.fieldbyname('XYID').AsString);
|
||||
if Trim(FBCId) = '' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryCmd, Maxno, 'XY', 'XYZ_MAIN', 3, 1) = False then
|
||||
begin
|
||||
Result := False;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取主编号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Maxno := Trim(FBCId);
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from XYZ_MAIN where XYID=''' + Trim(Maxno) + '''');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
if Trim(FBCId) = '' then
|
||||
begin
|
||||
Append;
|
||||
FieldByName('Filler').Value := Trim(DName);
|
||||
FieldByName('FillerCode').Value := Trim(DCode);
|
||||
FieldByName('XXGCS').Value := 0;
|
||||
// FieldByName('status').Value := Trim(DCode);
|
||||
end
|
||||
else
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('Editer').Value := Trim(DName);
|
||||
FieldByName('EditerCode').Value := Trim(DCode);
|
||||
FieldByName('EditTime').Value := SGetServerDate(ADOQueryTemp);
|
||||
|
||||
end;
|
||||
FieldByName('XYID').Value := Trim(Maxno);
|
||||
RTSetsavedata(ADOQueryCmd, 'XYZ_MAIN', Panel1, 1);
|
||||
RTSetsavedata(ADOQueryCmd, 'XYZ_MAIN', Panel1, 2);
|
||||
// if Trim(FBCId) <> '' then
|
||||
// begin
|
||||
// FieldByName('XXGCS').Value := StrToFloatDEF(XXGCS.Text, 0) + 1;
|
||||
// end;
|
||||
|
||||
Post;
|
||||
end;
|
||||
// with ADOQueryTemp do
|
||||
// begin
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// sql.Add('select * from XYZ_MAIN where XYNO=''' + Trim(XYNO.Text) + ''' and Valid=''Y'' ');
|
||||
// Open;
|
||||
// end;
|
||||
// if ADOQueryTemp.RecordCount > 1 then
|
||||
// begin
|
||||
// ADOQueryCmd.Connection.RollbackTrans;
|
||||
// Application.MessageBox('此发票号已经被使用,不能保存!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
FBCId := Trim(Maxno);
|
||||
Result := True;
|
||||
except
|
||||
Result := False;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('保存异常!', '提示', 0);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.FormShow(Sender: TObject);
|
||||
begin
|
||||
|
||||
with ADOQueryMain do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' select A.* ');
|
||||
sql.Add(' from XYZ_MAIN A');
|
||||
sql.Add(' where XYID=''' + Trim(FBCId) + '''');
|
||||
Open;
|
||||
end;
|
||||
SCSHDataNew(ADOQueryMain, Panel1, 1);
|
||||
SCSHDataNew(ADOQueryMain, Panel1, 2);
|
||||
|
||||
if CopyStr = '99' then
|
||||
begin
|
||||
FBCId := '';
|
||||
|
||||
end;
|
||||
|
||||
if Trim(FBCId) = '' then
|
||||
begin
|
||||
XYWY.Text := Trim(DName);
|
||||
XKZRQ.DateTime := SGetServerDate10(ADOQueryTemp);
|
||||
XSDRQ.DateTime := XKZRQ.DateTime;
|
||||
XTZRQ.DateTime := XKZRQ.DateTime;
|
||||
XYXQX.DateTime := XKZRQ.DateTime;
|
||||
XZYQX.DateTime := XKZRQ.DateTime;
|
||||
|
||||
XXYTZRQ.DateTime := XKZRQ.DateTime;
|
||||
// XZYQX.DateTime := XKZRQ.DateTime;
|
||||
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.TBSaveClick(Sender: TObject);
|
||||
var
|
||||
FReal: Double;
|
||||
i: Integer;
|
||||
begin
|
||||
with Panel1 do
|
||||
begin
|
||||
for i := 0 to ControlCount - 1 do
|
||||
begin
|
||||
if Controls[i].Tag = 1 then
|
||||
begin
|
||||
if Controls[i] is TLabel then
|
||||
continue;
|
||||
if Controls[i].Tag <> 1 then
|
||||
continue;
|
||||
if Controls[i] is TEdit then
|
||||
begin
|
||||
if Trim(TEdit(Controls[i]).Text) = '' then
|
||||
begin
|
||||
Application.MessageBox('蓝色标注的信息为必填,请填写!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
if Controls[i] is TBtnEditA then
|
||||
begin
|
||||
if Trim(TBtnEditA(Controls[i]).Text) = '' then
|
||||
begin
|
||||
Application.MessageBox('蓝色标注的信息为必填,请填写!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
if Controls[i] is TComboBox then
|
||||
begin
|
||||
if Trim(TComboBox(Controls[i]).Text) = '' then
|
||||
begin
|
||||
Application.MessageBox('蓝色标注的信息为必填,请填写!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
ToolBar1.SetFocus;
|
||||
if SaveCKData() then
|
||||
begin
|
||||
Application.MessageBox('保存成功!', '提示', 0);
|
||||
ModalResult := 1;
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.ToolButton2Click(Sender: TObject);
|
||||
var
|
||||
i: Integer;
|
||||
begin
|
||||
//CopyAddRowCDS(CDS_Sub);
|
||||
{with CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('BGID').Value:=Null;
|
||||
FieldByName('BSID').Value:=Null;
|
||||
Post;
|
||||
end; }
|
||||
|
||||
|
||||
frmProductOrderList_Sel := TfrmProductOrderList_Sel.Create(self);
|
||||
with frmProductOrderList_Sel do
|
||||
begin
|
||||
if showmodal = 1 then
|
||||
begin
|
||||
while frmProductOrderList_Sel.Order_Main.Locate('SSel', True, []) do
|
||||
begin
|
||||
Self.CDS_Sub.Append;
|
||||
i := CDS_Sub.RecordCount;
|
||||
Self.CDS_Sub.FieldByName('XHInt').Value := i + 1;
|
||||
Self.CDS_Sub.FieldbyName('C6BGPrice').Value := 0;
|
||||
// Self.CDS_Sub.FieldbyName('Money').Value := 0;
|
||||
Self.CDS_Sub.fieldbyname('orderno').Value := Order_Main.fieldbyname('Orderno').asstring;
|
||||
Self.CDS_Sub.fieldbyname('FromMainId').Value := Order_Main.fieldbyname('MainId').asstring;
|
||||
Self.CDS_Sub.fieldbyname('C3BGNameEng').Value := Order_Main.fieldbyname('YWNAME').asstring;
|
||||
Self.CDS_Sub.fieldbyname('C3BGName').Value := Order_Main.fieldbyname('MPRTCODENAME').asstring;
|
||||
Self.CDS_Sub.fieldbyname('YSFuKuan').Value := Order_Main.fieldbyname('MPRTMF').asstring;
|
||||
Self.CDS_Sub.fieldbyname('YSKeZhong').Value := Order_Main.fieldbyname('MPRTKZ').asstring;
|
||||
Self.CDS_Sub.fieldbyname('YSChenFen').Value := Order_Main.fieldbyname('MPRTCF').asstring;
|
||||
Self.CDS_Sub.fieldbyname('C4BGQty').Value := Order_Main.fieldbyname('PRTORDERQTY').ASFLOAT;
|
||||
|
||||
Self.CDS_Sub.fieldbyname('C5BGUnit').Value := Order_Main.fieldbyname('orderunit').asstring;
|
||||
|
||||
Self.CDS_Sub.fieldbyname('ZZFF').Value := Order_Main.fieldbyname('BPBigType').asstring;
|
||||
Self.CDS_Sub.fieldbyname('ZDDATE').Value := Order_Main.fieldbyname('filltime').AsDateTime;
|
||||
Self.CDS_Sub.fieldbyname('GYLX').Value := Order_Main.fieldbyname('JGType').asstring;
|
||||
Self.CDS_Sub.fieldbyname('JSUNIT').Value := '件';
|
||||
Self.CDS_Sub.fieldbyname('WL').Value := '平纹';
|
||||
Self.CDS_Sub.fieldbyname('sj').Value := '是';
|
||||
|
||||
Self.CDS_Sub.Post;
|
||||
frmProductOrderList_Sel.Order_Main.Delete;
|
||||
end;
|
||||
end;
|
||||
free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.ToolButton3Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Sub.IsEmpty then
|
||||
Exit;
|
||||
if Trim(CDS_Sub.fieldbyname('BSID').AsString) <> '' then
|
||||
begin
|
||||
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('Update JYOrder_BaoGuan_Sub Set SValid=''N'',SEditer=''' + Trim(DName) + ''',SEditTime=getdate() ');
|
||||
sql.Add(' where BSID=''' + Trim(CDS_Sub.fieldbyname('BSID').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set ');
|
||||
sql.Add(' C7BGMoneyHZ=(select Sum(C7BGMoney) from JYOrder_BaoGuan_Sub A where A.BGID=JYOrder_BaoGuan_Main.BGID and A.SValid=''Y'' )');
|
||||
sql.Add(',E1BZQtyHZ=(select Sum(E1BZQty) from JYOrder_BaoGuan_Sub A where A.BGID=JYOrder_BaoGuan_Main.BGID and A.SValid=''Y'' )');
|
||||
sql.Add(',E2ChiMaQtyHZ=(select Sum(E2ChiMaQty) from JYOrder_BaoGuan_Sub A where A.BGID=JYOrder_BaoGuan_Main.BGID and A.SValid=''Y'' )');
|
||||
sql.Add(',E3MaoZHZ=(select Sum(E3MaoZ) from JYOrder_BaoGuan_Sub A where A.BGID=JYOrder_BaoGuan_Main.BGID and A.SValid=''Y'' )');
|
||||
sql.Add(',E4JingZHZ=(select Sum(E4JingZ) from JYOrder_BaoGuan_Sub A where A.BGID=JYOrder_BaoGuan_Main.BGID and A.SValid=''Y'' )');
|
||||
sql.Add(' where BGID=''' + Trim(CDS_Sub.fieldbyname('BGID').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
end;
|
||||
CDS_Sub.Delete;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.v1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'C3BGName';
|
||||
flagname := '报关品名';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('C3BGName').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select Top 1 * from JYOrder_BaoGuan_Sub where C3BGName=''' + Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZDYName').AsString) + '''');
|
||||
sql.add(' and isnull(C2HSNO,'''')<>'''' ');
|
||||
sql.Add(' order by SFillTime desc');
|
||||
Open;
|
||||
end;
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('C2HSNO').Value := Trim(ADOQueryTemp.fieldbyname('C2HSNO').asstring);
|
||||
FieldByName('C3BGNameEng').Value := Trim(ADOQueryTemp.fieldbyname('C3BGNameEng').asstring);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.v1Column14PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'YSChenFen';
|
||||
flagname := '成分含量';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('YSChenFen').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.v1Column16PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'YSPinPai';
|
||||
flagname := '品牌';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('YSPinPai').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.v1Column17PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'YSShengChanShang';
|
||||
flagname := '生产商';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('YSShengChanShang').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Sub.IsEmpty then
|
||||
Exit;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.ToolButton4Click(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
if FBCId = '' then
|
||||
Exit;
|
||||
if Application.MessageBox('确定要执行审核操作吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
|
||||
try
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Status=''已审核'',ChkTime=getdate(),Chker=''' + Trim(DName) + '''');
|
||||
sql.Add(' where BGID=''' + Trim(FBCId) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
Application.MessageBox('操作成功!', '提示', 0);
|
||||
except
|
||||
|
||||
Application.MessageBox('操作异常!', '提示', 0);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.v1ZZJGouPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'ZZJGou';
|
||||
flagname := '组织结构';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('ZZJGou').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.v1Column12PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'E5MaiTou';
|
||||
flagname := '唛头';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('E5MaiTou').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.TCXLJClick(Sender: TObject);
|
||||
begin
|
||||
if not Assigned(DataLink_DDMD) then
|
||||
DataLink_DDMD := TDataLink_DDMD.Create(Application);
|
||||
try
|
||||
with DataLink_DDMD.ADOLink do
|
||||
begin
|
||||
//if not Connected then
|
||||
begin
|
||||
Connected := false;
|
||||
ConnectionString := DConString;
|
||||
LoginPrompt := false;
|
||||
Connected := true;
|
||||
end;
|
||||
end;
|
||||
except
|
||||
application.MessageBox('数据库连接失败!', '错误', mb_Ok + MB_ICONERROR);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.XQYDBtnClick(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);
|
||||
// ShowMessage(flag);
|
||||
flagname := Copy(fsj, FWZ + 1, Length(fsj) - FWZ);
|
||||
if flag = 'TOCOUNTRY' then
|
||||
begin
|
||||
fnote := True;
|
||||
V1Note.Caption := '中文名称';
|
||||
V1Name.Caption := '英文名称';
|
||||
end
|
||||
else if (flag = 'LCTOPlace') or (flag = 'LCFromPlace') or (flag = 'YSFS') then
|
||||
begin
|
||||
fnote := True;
|
||||
V1Note.Caption := '备注';
|
||||
V1Name.Caption := '名称';
|
||||
// V1Name.Caption := '英文名称';
|
||||
end
|
||||
else
|
||||
begin
|
||||
fnote := false;
|
||||
end;
|
||||
// if (flag = 'B6ChuYunGang') or (flag = 'B7DaoHuoGang') or (flag = 'ZMXingZhi') then
|
||||
// begin
|
||||
// fnote := True;
|
||||
// V1Note.Caption := '备注';
|
||||
//// V1Name.Caption := '英文名称';
|
||||
// end
|
||||
// else
|
||||
// begin
|
||||
// fnote := false;
|
||||
// end;
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.KHNameBtnClick(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmZdyAttachment := TfrmZdyAttachment.Create(Application);
|
||||
with frmZdyAttachment do
|
||||
begin
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
|
||||
self.XKHName.Text := Trim(CDS_HZ.fieldbyname('CoName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZdyAttachment.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.Tv1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZdyAttachGYS := tfrmZdyAttachGYS.Create(Application);
|
||||
with frmZdyAttachGYS do
|
||||
begin
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
fieldbyname('gcdm').Value := Trim(CDS_HZ.fieldbyname('CoCode').AsString);
|
||||
fieldbyname('gcname').Value := Trim(CDS_HZ.fieldbyname('CoName').AsString);
|
||||
fieldbyname('gcaddress').Value := Trim(CDS_HZ.fieldbyname('Coaddress').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZdyAttachment.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.Tv1Column12PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'zzff';
|
||||
flagname := '织造方法';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('zzff').AsString := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.Tv1Column14PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'wenlu';
|
||||
flagname := '纹路';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('wl').AsString := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.Tv1Column13PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'GYLX';
|
||||
flagname := '工艺类型';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('gylx').AsString := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.Tv1Column9PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'JSUNIT';
|
||||
flagname := '件数单位';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('JSUNIT').AsString := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.Tv1Column6PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZdyAttachGYS := tfrmZdyAttachGYS.Create(Application);
|
||||
with frmZdyAttachGYS do
|
||||
begin
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
fieldbyname('gcdm').Value := Trim(CDS_HZ.fieldbyname('CoCode').AsString);
|
||||
fieldbyname('gcname').Value := Trim(CDS_HZ.fieldbyname('CoName').AsString);
|
||||
fieldbyname('gcaddress').Value := Trim(CDS_HZ.fieldbyname('Coaddress').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZdyAttachment.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.XKHNAMEBtnClick(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
frmZdyAttachment := TfrmZdyAttachment.Create(Application);
|
||||
with frmZdyAttachment do
|
||||
begin
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
|
||||
self.XKHName.Text := Trim(CDS_HZ.fieldbyname('CoName').AsString);
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZdyAttachment.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.XUNITChange(Sender: TObject);
|
||||
begin
|
||||
if XUNIT.Text = '美元' then
|
||||
begin
|
||||
ZUSDHL.Text := '1';
|
||||
end;
|
||||
if XUNIT.Text = '人民币' then
|
||||
begin
|
||||
ZUSDHL.Text := '0.156250';
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmXYZInPut.XMONEYChange(Sender: TObject);
|
||||
begin
|
||||
// ZUSDJE.Text := FloatToStr();
|
||||
|
||||
ZUSDJE.Text := FloatToStr(RoundFloat(StrToFloatDEF(XMONEY.Text, 0) * StrToFloatDEF(ZUSDHL.Text, 0), 2));
|
||||
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -1,531 +0,0 @@
|
|||
object frmXYZMAKEList: TfrmXYZMAKEList
|
||||
Left = 165
|
||||
Top = 123
|
||||
Width = 1364
|
||||
Height = 670
|
||||
Caption = #20449#29992#35777#21046#20316#21015#34920
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1348
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
Visible = False
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object TBAdd: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26032#22686
|
||||
ImageIndex = 1
|
||||
OnClick = TBAddClick
|
||||
end
|
||||
object TBEdit: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20462#25913
|
||||
ImageIndex = 11
|
||||
OnClick = TBEditClick
|
||||
end
|
||||
object TBCopy: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #22797#21046
|
||||
ImageIndex = 38
|
||||
OnClick = TBCopyClick
|
||||
end
|
||||
object TBView: TToolButton
|
||||
Left = 315
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26597#30475
|
||||
ImageIndex = 55
|
||||
OnClick = TBViewClick
|
||||
end
|
||||
object TBDel: TToolButton
|
||||
Left = 378
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#38500
|
||||
ImageIndex = 3
|
||||
OnClick = TBDelClick
|
||||
end
|
||||
object TBExport: TToolButton
|
||||
Left = 441
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
Visible = False
|
||||
OnClick = TBExportClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 504
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1348
|
||||
Height = 59
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label1: TLabel
|
||||
Left = 28
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #25910#21040#26102#38388
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 376
|
||||
Top = 12
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #24320#35777#34892
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 196
|
||||
Top = 35
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #35746#21333#21495
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 388
|
||||
Top = 35
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #23458#25143
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 172
|
||||
Top = 12
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #20449#29992#35777#21495#30721
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 77
|
||||
Top = 31
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object XKZH: TEdit
|
||||
Tag = 2
|
||||
Left = 414
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnKeyPress = XORDERNOKeyPress
|
||||
end
|
||||
object XORDERNO: TEdit
|
||||
Tag = 2
|
||||
Left = 233
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnKeyPress = XORDERNOKeyPress
|
||||
end
|
||||
object XKHNAME: TEdit
|
||||
Tag = 2
|
||||
Left = 414
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 4
|
||||
OnKeyPress = XORDERNOKeyPress
|
||||
end
|
||||
object XYNO: TEdit
|
||||
Tag = 2
|
||||
Left = 233
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnKeyPress = XORDERNOKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1348
|
||||
Height = 540
|
||||
Align = alClient
|
||||
PopupMenu = PopupMenu1
|
||||
TabOrder = 2
|
||||
object TV1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object tv2Column1: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = cxStyle1
|
||||
Width = 68
|
||||
end
|
||||
object TV1Column7: TcxGridDBColumn
|
||||
Caption = #25910#21040#26085#26399
|
||||
DataBinding.FieldName = 'XSDRQ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = cxStyle1
|
||||
Width = 81
|
||||
end
|
||||
object TV1Column12: TcxGridDBColumn
|
||||
Caption = #20449#29992#35777#21495#30721
|
||||
DataBinding.FieldName = 'XYNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = cxStyle1
|
||||
Width = 107
|
||||
end
|
||||
object tv2Column3: TcxGridDBColumn
|
||||
Caption = #24320#35777#34892
|
||||
DataBinding.FieldName = 'XKZH'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = cxStyle1
|
||||
Width = 91
|
||||
end
|
||||
object TV1Column10: TcxGridDBColumn
|
||||
Caption = #23458#25143
|
||||
DataBinding.FieldName = 'XKHNAME'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = cxStyle1
|
||||
Width = 90
|
||||
end
|
||||
object TV1Column11: TcxGridDBColumn
|
||||
Caption = #20323#37329#27604#20363
|
||||
DataBinding.FieldName = 'XYJBL'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = cxStyle1
|
||||
Width = 85
|
||||
end
|
||||
object TV1Column9: TcxGridDBColumn
|
||||
Caption = #35746#21333#21495
|
||||
DataBinding.FieldName = 'XORDERNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = cxStyle1
|
||||
Width = 86
|
||||
end
|
||||
object tv2Column2: TcxGridDBColumn
|
||||
Caption = #35013#36816#26399#38480
|
||||
DataBinding.FieldName = 'XZYQX'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Editing = False
|
||||
Styles.Header = cxStyle1
|
||||
Width = 89
|
||||
end
|
||||
object TV1Column2: TcxGridDBColumn
|
||||
Caption = #36215#36816#22320
|
||||
DataBinding.FieldName = 'XQYD'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = cxStyle1
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column3: TcxGridDBColumn
|
||||
Caption = #30446#30340#22320
|
||||
DataBinding.FieldName = 'XMDD'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = cxStyle1
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column5: TcxGridDBColumn
|
||||
Caption = #26159#21542#20998#25209
|
||||
DataBinding.FieldName = 'XFP'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = cxStyle1
|
||||
Width = 79
|
||||
end
|
||||
object TV1Column1: TcxGridDBColumn
|
||||
Caption = #25968#37327#20844#24046
|
||||
DataBinding.FieldName = 'XSLGC'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = cxStyle1
|
||||
Width = 85
|
||||
end
|
||||
object XTBYQ: TcxGridDBColumn
|
||||
Caption = #29305#21035#35201#27714
|
||||
DataBinding.FieldName = 'XTBYQ'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = cxStyle1
|
||||
Width = 84
|
||||
end
|
||||
object XXYZZT: TcxGridDBColumn
|
||||
Caption = #20449#29992#35777#29366#24577
|
||||
DataBinding.FieldName = 'XXYZZT'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = cxStyle1
|
||||
Width = 119
|
||||
end
|
||||
object TV1Column4: TcxGridDBColumn
|
||||
Caption = #20462#25913#27425#25968
|
||||
DataBinding.FieldName = 'XXGCS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Styles.Header = cxStyle1
|
||||
Width = 82
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 920
|
||||
Top = 184
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 1000
|
||||
Top = 228
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 952
|
||||
Top = 184
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 925
|
||||
Top = 217
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 785
|
||||
Top = 173
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 957
|
||||
Top = 217
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 350
|
||||
Top = 252
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 777
|
||||
Top = 299
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
Grid = cxGrid2
|
||||
PopupMenus = <>
|
||||
Left = 883
|
||||
Top = 487
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 917
|
||||
Top = 487
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 949
|
||||
Top = 487
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 609
|
||||
Top = 296
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 536
|
||||
Top = 316
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 548
|
||||
Top = 300
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 524
|
||||
Top = 284
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 616
|
||||
Top = 316
|
||||
end
|
||||
object cxStyleRepository1: TcxStyleRepository
|
||||
PixelsPerInch = 96
|
||||
object cxStyle1: TcxStyle
|
||||
AssignedValues = [svFont]
|
||||
Font.Charset = DEFAULT_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -16
|
||||
Font.Name = #40657#20307
|
||||
Font.Style = [fsBold]
|
||||
end
|
||||
end
|
||||
end
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,519 +0,0 @@
|
|||
object frmYFGLInPut: TfrmYFGLInPut
|
||||
Left = 160
|
||||
Top = 92
|
||||
Width = 779
|
||||
Height = 708
|
||||
Caption = #36816#36153#24405#20837
|
||||
Color = clBtnFace
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
OldCreateOrder = False
|
||||
Position = poScreenCenter
|
||||
OnClose = FormClose
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 763
|
||||
Height = 33
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 59
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBSave: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20445#23384
|
||||
ImageIndex = 15
|
||||
OnClick = TBSaveClick
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object cxGrid1: TcxGrid
|
||||
Left = 0
|
||||
Top = 266
|
||||
Width = 763
|
||||
Height = 403
|
||||
Align = alClient
|
||||
TabOrder = 3
|
||||
object Tv1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
DataController.DataSource = DataSource3
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
OptionsView.Indicator = True
|
||||
OptionsView.IndicatorWidth = 25
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
OnCustomDrawIndicatorCell = Tv1CustomDrawIndicatorCell
|
||||
object v1Column13: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #36153#29992#39033#30446
|
||||
DataBinding.FieldName = 'FYXM'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.ImmediatePost = True
|
||||
Properties.Items.Strings = (
|
||||
#28023#36816#36153
|
||||
#31354#36816#36153
|
||||
#20869#38470#36816#36153
|
||||
#36135#20195#36816#36153
|
||||
#21333#35777#36153#29992
|
||||
#20445#38505#36153)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Width = 71
|
||||
end
|
||||
object v1Column5: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #25903#20184#24065#31181
|
||||
DataBinding.FieldName = 'FYBZ'
|
||||
PropertiesClassName = 'TcxComboBoxProperties'
|
||||
Properties.Items.Strings = (
|
||||
#20154#27665#24065
|
||||
#32654#20803)
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Width = 108
|
||||
end
|
||||
object v1Column20: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #37329#39069
|
||||
DataBinding.FieldName = 'FYMONEY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Width = 108
|
||||
end
|
||||
object v1Column14: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #26412#26041#25903#20184
|
||||
DataBinding.FieldName = 'FYYFMONEY'
|
||||
PropertiesClassName = 'TcxButtonEditProperties'
|
||||
Properties.Buttons = <
|
||||
item
|
||||
Default = True
|
||||
Kind = bkEllipsis
|
||||
end>
|
||||
Properties.OnButtonClick = v1Column14PropertiesButtonClick
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Options.Sorting = False
|
||||
Width = 109
|
||||
end
|
||||
object v1YSKeZhong: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'FYNOTE'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 73
|
||||
end
|
||||
object Tv1Column1: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24322#24120#36153#29992
|
||||
DataBinding.FieldName = 'YCMONEY'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 76
|
||||
end
|
||||
object Tv1Column2: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #24322#24120#21407#22240
|
||||
DataBinding.FieldName = 'YCREASON'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 70
|
||||
end
|
||||
object Tv1Column3: TcxGridDBColumn
|
||||
Tag = 2
|
||||
Caption = #36131#20219#20154
|
||||
DataBinding.FieldName = 'ZRREN'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 72
|
||||
end
|
||||
end
|
||||
object cxGrid1Level1: TcxGridLevel
|
||||
GridView = Tv1
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 33
|
||||
Width = 763
|
||||
Height = 200
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
TabOrder = 1
|
||||
object Label13: TLabel
|
||||
Left = 17
|
||||
Top = 15
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #21457#31080#21495#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 289
|
||||
Top = 13
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #36135#20195#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 5
|
||||
Top = 39
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #21457#31080#25260#22836#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 241
|
||||
Top = 40
|
||||
Width = 84
|
||||
Height = 12
|
||||
Caption = #36135#20195#21457#31080#21495#30721#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label15: TLabel
|
||||
Left = 443
|
||||
Top = 40
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #19994' '#21153' '#21592#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label22: TLabel
|
||||
Left = 5
|
||||
Top = 72
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #25351#31034#21333#21495#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label28: TLabel
|
||||
Left = 443
|
||||
Top = 9
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #25903#20184#26041#24335#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label30: TLabel
|
||||
Left = 443
|
||||
Top = 71
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #24320#31080#26085#26399#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 31
|
||||
Top = 113
|
||||
Width = 13
|
||||
Height = 24
|
||||
Caption = #22791#13#10#27880
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = [fsBold]
|
||||
ParentFont = False
|
||||
end
|
||||
object Label7: TLabel
|
||||
Left = 289
|
||||
Top = 71
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #33337#26399#65306
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clBlue
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 60
|
||||
Top = 11
|
||||
Width = 90
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 0
|
||||
end
|
||||
object huodai: TEdit
|
||||
Tag = 2
|
||||
Left = 324
|
||||
Top = 9
|
||||
Width = 90
|
||||
Height = 20
|
||||
CharCase = ecUpperCase
|
||||
TabOrder = 1
|
||||
end
|
||||
object BGTAITOU: TBtnEditA
|
||||
Tag = 2
|
||||
Left = 60
|
||||
Top = 36
|
||||
Width = 169
|
||||
Height = 20
|
||||
Hint = 'BGTT/'#20844#21496
|
||||
TabOrder = 3
|
||||
Text = #32461#20852#24066#25391#27704#32442#32455#21697#26377#38480#20844#21496
|
||||
OnBtnClick = B6ChuYunGangBtnClick
|
||||
end
|
||||
object HUODAIFPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 324
|
||||
Top = 36
|
||||
Width = 90
|
||||
Height = 20
|
||||
TabOrder = 4
|
||||
end
|
||||
object SHFS: TBtnEditA
|
||||
Tag = 1
|
||||
Left = 500
|
||||
Top = 6
|
||||
Width = 113
|
||||
Height = 20
|
||||
Hint = 'SHFS/'#25910#27719#26041#24335
|
||||
TabOrder = 2
|
||||
Text = '[T/T]'#21069#30005#27719
|
||||
OnBtnClick = B6ChuYunGangBtnClick
|
||||
end
|
||||
object HTDate: TDateTimePicker
|
||||
Tag = 2
|
||||
Left = 500
|
||||
Top = 67
|
||||
Width = 116
|
||||
Height = 20
|
||||
Date = 42296.498237581020000000
|
||||
Time = 42296.498237581020000000
|
||||
TabOrder = 5
|
||||
end
|
||||
object NOTE: TMemo
|
||||
Tag = 2
|
||||
Left = 59
|
||||
Top = 110
|
||||
Width = 397
|
||||
Height = 64
|
||||
Hint = 'WZhiLiangNote/'#36136#37327#35201#27714
|
||||
ScrollBars = ssVertical
|
||||
TabOrder = 6
|
||||
end
|
||||
object YWY: TComboBox
|
||||
Tag = 2
|
||||
Left = 500
|
||||
Top = 37
|
||||
Width = 115
|
||||
Height = 20
|
||||
ItemHeight = 12
|
||||
TabOrder = 7
|
||||
OnDropDown = YWYDropDown
|
||||
end
|
||||
object chuandate: TDateTimePicker
|
||||
Tag = 2
|
||||
Left = 324
|
||||
Top = 67
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 42296.498237581020000000
|
||||
Time = 42296.498237581020000000
|
||||
TabOrder = 8
|
||||
end
|
||||
object ORDERNO: TBtnEditA
|
||||
Tag = 1
|
||||
Left = 60
|
||||
Top = 67
|
||||
Width = 113
|
||||
Height = 20
|
||||
TabOrder = 9
|
||||
OnBtnClick = ORDERNOBtnClick
|
||||
end
|
||||
end
|
||||
object ToolBar2: TToolBar
|
||||
Left = 0
|
||||
Top = 233
|
||||
Width = 763
|
||||
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 = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 2
|
||||
object ToolButton2: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26032#22686
|
||||
ImageIndex = 12
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #19968#38190#26367#25442
|
||||
ImageIndex = 19
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 150
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#34892
|
||||
ImageIndex = 13
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
end
|
||||
object DataSource3: TDataSource
|
||||
DataSet = CDS_Sub
|
||||
Left = 501
|
||||
Top = 431
|
||||
end
|
||||
object CDS_Sub: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 464
|
||||
Top = 440
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 1080
|
||||
Top = 272
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 1112
|
||||
Top = 272
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 1144
|
||||
Top = 272
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 424
|
||||
Top = 429
|
||||
end
|
||||
end
|
||||
|
|
@ -1,878 +0,0 @@
|
|||
unit U_YFGLInPut;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||
Dialogs, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData, cxDataStorage,
|
||||
cxEdit, DB, cxDBData, cxCalendar, cxDropDownEdit, ComCtrls, ToolWin,
|
||||
cxGridLevel, cxGridCustomTableView, cxGridTableView, cxGridDBTableView,
|
||||
cxClasses, cxControls, cxGridCustomView, cxGrid, cxGridCustomPopupMenu,
|
||||
cxGridPopupMenu, ADODB, DBClient, cxButtonEdit, cxTextEdit, StdCtrls, BtnEdit,
|
||||
ExtCtrls, cxLookAndFeels, cxLookAndFeelPainters, cxNavigator;
|
||||
|
||||
type
|
||||
TfrmYFGLInPut = class(TForm)
|
||||
ToolBar1: TToolBar;
|
||||
TBSave: TToolButton;
|
||||
TBClose: TToolButton;
|
||||
DataSource3: TDataSource;
|
||||
CDS_Sub: TClientDataSet;
|
||||
ADOQueryCmd: TADOQuery;
|
||||
ADOQueryMain: TADOQuery;
|
||||
ADOQueryTemp: TADOQuery;
|
||||
cxGridPopupMenu2: TcxGridPopupMenu;
|
||||
cxGrid1: TcxGrid;
|
||||
Tv1: TcxGridDBTableView;
|
||||
v1Column5: TcxGridDBColumn;
|
||||
cxGrid1Level1: TcxGridLevel;
|
||||
Panel1: TPanel;
|
||||
ToolBar2: TToolBar;
|
||||
ToolButton2: TToolButton;
|
||||
ToolButton3: TToolButton;
|
||||
Label13: TLabel;
|
||||
A4FPNO: TEdit;
|
||||
Label4: TLabel;
|
||||
huodai: TEdit;
|
||||
Label5: TLabel;
|
||||
BGTAITOU: TBtnEditA;
|
||||
Label8: TLabel;
|
||||
HUODAIFPNO: TEdit;
|
||||
Label15: TLabel;
|
||||
SHFS: TBtnEditA;
|
||||
Label22: TLabel;
|
||||
v1Column13: TcxGridDBColumn;
|
||||
v1Column14: TcxGridDBColumn;
|
||||
ToolButton1: TToolButton;
|
||||
v1Column20: TcxGridDBColumn;
|
||||
Label28: TLabel;
|
||||
Label30: TLabel;
|
||||
HTDate: TDateTimePicker;
|
||||
v1YSKeZhong: TcxGridDBColumn;
|
||||
NOTE: TMemo;
|
||||
Label6: TLabel;
|
||||
YWY: TComboBox;
|
||||
Label7: TLabel;
|
||||
chuandate: TDateTimePicker;
|
||||
ORDERNO: TBtnEditA;
|
||||
Tv1Column1: TcxGridDBColumn;
|
||||
Tv1Column2: TcxGridDBColumn;
|
||||
Tv1Column3: TcxGridDBColumn;
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure TBCloseClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
procedure TBSaveClick(Sender: TObject);
|
||||
procedure ToolButton2Click(Sender: TObject);
|
||||
procedure ToolButton3Click(Sender: TObject);
|
||||
procedure v1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column14PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column16PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column17PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column3PropertiesEditValueChanged(Sender: TObject);
|
||||
procedure ToolButton1Click(Sender: TObject);
|
||||
procedure ToolButton4Click(Sender: TObject);
|
||||
procedure v1ZZJGouPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure v1Column12PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure TCXLJClick(Sender: TObject);
|
||||
procedure B6ChuYunGangBtnClick(Sender: TObject);
|
||||
procedure YWYDropDown(Sender: TObject);
|
||||
procedure Tv1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column12PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column14PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column13PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column9PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
procedure Tv1Column7PropertiesEditValueChanged(Sender: TObject);
|
||||
procedure Tv1CustomDrawIndicatorCell(Sender: TcxGridTableView; ACanvas: TcxCanvas; AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
|
||||
procedure ORDERNOBtnClick(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
function SaveCKData(): Boolean;
|
||||
public
|
||||
{ Public declarations }
|
||||
FBCId, canshu3: string;
|
||||
CopyStr: string;
|
||||
end;
|
||||
|
||||
var
|
||||
frmYFGLInPut: TfrmYFGLInPut;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
U_DataLink, U_RTFun, U_ZDYHelp, U_ZdyAttachment, U_ProductOrderList_Sel,
|
||||
U_DCDList_Sel, U_ZdyAttachGYS;
|
||||
|
||||
{$R *.dfm}
|
||||
|
||||
procedure TfrmYFGLInPut.FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
begin
|
||||
Action := caFree;
|
||||
end;
|
||||
|
||||
function TfrmYFGLInPut.SaveCKData(): Boolean;
|
||||
var
|
||||
FJMID, Maxno, MaxSubNo, FSCID: string;
|
||||
begin
|
||||
try
|
||||
ADOQueryCmd.Connection.BeginTrans;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from FP_MAIN where FPID=''' + Trim(FBCId) + '''');
|
||||
Open;
|
||||
end;
|
||||
FBCId := Trim(ADOQueryTemp.fieldbyname('FPID').AsString);
|
||||
if Trim(FBCId) = '' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryCmd, Maxno, 'FP', 'FP_MAIN', 3, 1) = False then
|
||||
begin
|
||||
Result := False;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取主编号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
Maxno := Trim(FBCId);
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from FP_MAIN where FPID=''' + Trim(Maxno) + '''');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
if Trim(FBCId) = '' then
|
||||
begin
|
||||
Append;
|
||||
FieldByName('Filler').Value := Trim(DName);
|
||||
FieldByName('FillerCode').Value := Trim(DCode);
|
||||
FieldByName('FKstatus').Value := '未付款';
|
||||
end
|
||||
else
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('Editer').Value := Trim(DName);
|
||||
FieldByName('EditerCode').Value := Trim(DCode);
|
||||
FieldByName('EditTime').Value := SGetServerDate(ADOQueryTemp);
|
||||
end;
|
||||
FieldByName('FPID').Value := Trim(Maxno);
|
||||
RTSetsavedata(ADOQueryCmd, 'JYOrder_BaoGuan_Main', Panel1, 1);
|
||||
RTSetsavedata(ADOQueryCmd, 'JYOrder_BaoGuan_Main', Panel1, 2);
|
||||
Post;
|
||||
end;
|
||||
// with ADOQueryTemp do
|
||||
// begin
|
||||
// Close;
|
||||
// sql.Clear;
|
||||
// sql.Add('select * from FP_MAIN where A4FPNO=''' + Trim(A4FPNO.Text) + ''' and Valid=''Y'' ');
|
||||
// Open;
|
||||
// end;
|
||||
// if ADOQueryTemp.RecordCount > 1 then
|
||||
// begin
|
||||
// ADOQueryCmd.Connection.RollbackTrans;
|
||||
// Application.MessageBox('此发票号已经被使用,不能保存!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
CDS_Sub.DisableControls;
|
||||
with CDS_Sub do
|
||||
begin
|
||||
First;
|
||||
while not eof do
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from FP_SUB where FPSId=''' + Trim(CDS_Sub.fieldbyname('FPSId').AsString) + '''');
|
||||
Open;
|
||||
end;
|
||||
FSCID := Trim(ADOQueryTemp.fieldbyname('FPSId').AsString);
|
||||
if Trim(FSCID) = '' then
|
||||
begin
|
||||
if GetLSNo(ADOQueryCmd, MaxSubNo, 'FPS', 'FP_SUB', 3, 1) = False then
|
||||
begin
|
||||
Result := False;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('取子编号失败!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
end
|
||||
else
|
||||
begin
|
||||
MaxSubNo := Trim(FSCID);
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select * from FP_SUB where FPSId=''' + Trim(MaxSubNo) + '''');
|
||||
Open;
|
||||
end;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
if Trim(FSCID) = '' then
|
||||
begin
|
||||
Append;
|
||||
// FieldByName('SFiller').Value := Trim(DName);
|
||||
end
|
||||
else
|
||||
begin
|
||||
Edit;
|
||||
// FieldByName('SEditer').Value := Trim(DName);
|
||||
// FieldByName('SEditTime').Value := SGetServerDate(ADOQueryTemp);
|
||||
end;
|
||||
FieldByName('FPId').Value := Trim(Maxno);
|
||||
FieldByName('FPSId').Value := Trim(MaxSubNo);
|
||||
RTSetSaveDataCDS(ADOQueryCmd, Tv1, CDS_Sub, 'FP_SUB', 2);
|
||||
Post;
|
||||
end;
|
||||
Edit;
|
||||
FieldByName('FPId').Value := Trim(Maxno);
|
||||
FieldByName('FPSId').Value := Trim(MaxSubNo);
|
||||
Post;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate FP_MAIN Set ');
|
||||
sql.Add(' SCDJDate= getdate()');
|
||||
sql.Add(' where isnull(SCDJDate,'''')='''' and FPId=''' + Trim(Maxno) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
CDS_Sub.EnableControls;
|
||||
ADOQueryCmd.Connection.CommitTrans;
|
||||
FBCId := Trim(Maxno);
|
||||
Result := True;
|
||||
except
|
||||
Result := False;
|
||||
ADOQueryCmd.Connection.RollbackTrans;
|
||||
Application.MessageBox('保存异常!', '提示', 0);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.TBCloseClick(Sender: TObject);
|
||||
begin
|
||||
WriteCxGrid('运费管理录入', Tv1, '报关管理13');
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.FormShow(Sender: TObject);
|
||||
begin
|
||||
ReadCxGrid('运费管理录入', Tv1, '报关管理13');
|
||||
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' select A.* ');
|
||||
sql.Add(' from FP_MAIN A');
|
||||
sql.Add(' where FPID=''' + Trim(FBCId) + '''');
|
||||
Open;
|
||||
end;
|
||||
SCSHDataNew(ADOQueryTemp, Panel1, 1);
|
||||
SCSHDataNew(ADOQueryTemp, Panel1, 2);
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add(' select A.* ');
|
||||
sql.Add(' from FP_SUB A');
|
||||
sql.Add(' where FPID=''' + Trim(FBCId) + '''');
|
||||
// sql.Add(' and SValid=''Y'' ');
|
||||
Open;
|
||||
end;
|
||||
SCreateCDS20(ADOQueryTemp, CDS_Sub);
|
||||
SInitCDSData20(ADOQueryTemp, CDS_Sub);
|
||||
if CopyStr = '99' then
|
||||
begin
|
||||
FBCId := '';
|
||||
CDS_Sub.DisableControls;
|
||||
with CDS_Sub do
|
||||
begin
|
||||
First;
|
||||
while not Eof do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('FPID').Value := Null;
|
||||
FieldByName('FPSID').Value := Null;
|
||||
Post;
|
||||
Next;
|
||||
end;
|
||||
end;
|
||||
CDS_Sub.EnableControls;
|
||||
end;
|
||||
if Trim(FBCId) = '' then
|
||||
begin
|
||||
YWY.Text := Trim(DName);
|
||||
HTDate.Date := SGetServerDate(ADOQueryTemp);
|
||||
chuandate.Date := SGetServerDate(ADOQueryTemp);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.TBSaveClick(Sender: TObject);
|
||||
var
|
||||
FReal: Double;
|
||||
i: Integer;
|
||||
begin
|
||||
//
|
||||
// if TryStrToFloat(F2YunFee.Text, FReal) = False then
|
||||
// begin
|
||||
// Application.MessageBox('运费非法数字!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
// if TryStrToFloat(F3BaoFee.Text, FReal) = False then
|
||||
// begin
|
||||
// Application.MessageBox('保费非法数字!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
// if CDS_Sub.IsEmpty then
|
||||
// begin
|
||||
// Application.MessageBox('明细不能为空!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
// if CDS_Sub.Locate('C3BGName', Null, []) then
|
||||
// begin
|
||||
// Application.MessageBox('品名不能为空!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
if Trim(A4FPNO.Text) = '' then
|
||||
begin
|
||||
Application.MessageBox('发票号不能为空!', '提示', 0);
|
||||
Exit;
|
||||
end;
|
||||
// if CDS_Sub.Locate('C4BGQty', Null, []) then
|
||||
// begin
|
||||
// Application.MessageBox('数量不能为空!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
// if CDS_Sub.Locate('C5BGUnit', Null, []) then
|
||||
// begin
|
||||
// Application.MessageBox('单位不能为空!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
// if CDS_Sub.Locate('C6BGPrice', Null, []) then
|
||||
// begin
|
||||
// Application.MessageBox('单价不能为空!', '提示', 0);
|
||||
// Exit;
|
||||
// end;
|
||||
|
||||
|
||||
ToolBar1.SetFocus;
|
||||
if SaveCKData() then
|
||||
begin
|
||||
Application.MessageBox('保存成功!', '提示', 0);
|
||||
//ModalResult:=1;
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.ToolButton2Click(Sender: TObject);
|
||||
var
|
||||
i: Integer;
|
||||
begin
|
||||
// CopyAddRowCDS(CDS_Sub);
|
||||
with CDS_Sub do
|
||||
begin
|
||||
Append;
|
||||
FieldByName('FPID').Value := Null;
|
||||
FieldByName('FPSID').Value := Null;
|
||||
FieldByName('FYMONEY').Value := 0;
|
||||
FieldByName('FYYFMONEY').Value := 0;
|
||||
FieldByName('FYBZ').Value := '人民币';
|
||||
FieldByName('FYXM').Value := '海运费';
|
||||
FieldByName('YCMONEY').Value := 0;
|
||||
|
||||
Post;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.ToolButton3Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Sub.IsEmpty then
|
||||
Exit;
|
||||
if Trim(CDS_Sub.fieldbyname('FPSID').AsString) <> '' then
|
||||
begin
|
||||
if Application.MessageBox('确定要删除数据吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
SQL.Add('DELETE FP_SUB ');
|
||||
sql.Add(' where FPSID=''' + Trim(CDS_Sub.fieldbyname('BSID').AsString) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
|
||||
end;
|
||||
CDS_Sub.Delete;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.v1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'C3BGName';
|
||||
flagname := '报关品名';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('C3BGName').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('select Top 1 * from JYOrder_BaoGuan_Sub where C3BGName=''' + Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZDYName').AsString) + '''');
|
||||
sql.add(' and isnull(C2HSNO,'''')<>'''' ');
|
||||
sql.Add(' order by SFillTime desc');
|
||||
Open;
|
||||
end;
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('C2HSNO').Value := Trim(ADOQueryTemp.fieldbyname('C2HSNO').asstring);
|
||||
FieldByName('C3BGNameEng').Value := Trim(ADOQueryTemp.fieldbyname('C3BGNameEng').asstring);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.v1Column14PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'YSChenFen';
|
||||
flagname := '成分含量';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('YSChenFen').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.v1Column16PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'YSPinPai';
|
||||
flagname := '品牌';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('YSPinPai').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.v1Column17PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'YSShengChanShang';
|
||||
flagname := '生产商';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('YSShengChanShang').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.v1Column3PropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
mvalue, FName, FPrice, FQty, FBaoGangFee: string;
|
||||
begin
|
||||
FName := Trim(Tv1.Controller.FocusedColumn.DataBinding.FilterFieldName);
|
||||
mvalue := TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue) = '' then
|
||||
begin
|
||||
mvalue := '0';
|
||||
end;
|
||||
with CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName(FName).Value := mvalue;
|
||||
Post;
|
||||
end;
|
||||
FPrice := Trim(CDS_Sub.fieldbyname('C6BGPrice').AsString);
|
||||
FQty := Trim(CDS_Sub.fieldbyname('C4BGQty').AsString);
|
||||
if Trim(FPrice) = '' then
|
||||
begin
|
||||
FPrice := '0';
|
||||
end;
|
||||
if Trim(FQty) = '' then
|
||||
begin
|
||||
FQty := '0';
|
||||
end;
|
||||
with CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('C7BGMoney').Value := StrToFloat(FPrice) * StrToFloat(FQty);
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.ToolButton1Click(Sender: TObject);
|
||||
begin
|
||||
if CDS_Sub.IsEmpty then
|
||||
Exit;
|
||||
OneKeyPost(Tv1, CDS_Sub);
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.ToolButton4Click(Sender: TObject);
|
||||
var
|
||||
fsj: string;
|
||||
begin
|
||||
if FBCId = '' then
|
||||
Exit;
|
||||
if Application.MessageBox('确定要执行审核操作吗?', '提示', 32 + 4) <> IDYES then
|
||||
Exit;
|
||||
|
||||
try
|
||||
|
||||
with ADOQueryCmd do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('UPdate JYOrder_BaoGuan_Main Set Status=''已审核'',ChkTime=getdate(),Chker=''' + Trim(DName) + '''');
|
||||
sql.Add(' where BGID=''' + Trim(FBCId) + '''');
|
||||
ExecSQL;
|
||||
end;
|
||||
Application.MessageBox('操作成功!', '提示', 0);
|
||||
except
|
||||
|
||||
Application.MessageBox('操作异常!', '提示', 0);
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.v1ZZJGouPropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'ZZJGou';
|
||||
flagname := '组织结构';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('ZZJGou').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.v1Column12PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'E5MaiTou';
|
||||
flagname := '唛头';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with Self.CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName('E5MaiTou').Value := Trim(frmZDYHelp.ClientDataSet1.fieldbyname('ZdyName').AsString);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.TCXLJClick(Sender: TObject);
|
||||
begin
|
||||
if not Assigned(DataLink_DDMD) then
|
||||
DataLink_DDMD := TDataLink_DDMD.Create(Application);
|
||||
try
|
||||
with DataLink_DDMD.ADOLink do
|
||||
begin
|
||||
//if not Connected then
|
||||
begin
|
||||
Connected := false;
|
||||
ConnectionString := DConString;
|
||||
LoginPrompt := false;
|
||||
Connected := true;
|
||||
end;
|
||||
end;
|
||||
except
|
||||
application.MessageBox('数据库连接失败!', '错误', mb_Ok + MB_ICONERROR);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.B6ChuYunGangBtnClick(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 flag = 'TOCOUNTRY' then
|
||||
begin
|
||||
fnote := True;
|
||||
V1Note.Caption := '中文名称';
|
||||
V1Name.Caption := '英文名称';
|
||||
end
|
||||
else
|
||||
begin
|
||||
fnote := false;
|
||||
end;
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
TEdit(Sender).Text := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.YWYDropDown(Sender: TObject);
|
||||
begin
|
||||
with ADOQueryTemp do
|
||||
begin
|
||||
Close;
|
||||
sql.Clear;
|
||||
sql.Add('SELECT * FROM SY_User WHERE Udept LIKE ''%客服%'' ');
|
||||
|
||||
Open;
|
||||
end;
|
||||
YWY.Items.Clear;
|
||||
while not ADOQueryTemp.eof do
|
||||
begin
|
||||
YWY.Items.Add(Trim(ADOQueryTemp.fieldbyname('username').AsString));
|
||||
ADOQueryTemp.next;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.Tv1Column5PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZdyAttachGYS := tfrmZdyAttachGYS.Create(Application);
|
||||
with frmZdyAttachGYS do
|
||||
begin
|
||||
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
fieldbyname('gcdm').Value := Trim(CDS_HZ.fieldbyname('CoCode').AsString);
|
||||
fieldbyname('gcname').Value := Trim(CDS_HZ.fieldbyname('CoName').AsString);
|
||||
fieldbyname('gcaddress').Value := Trim(CDS_HZ.fieldbyname('Coaddress').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZdyAttachment.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.Tv1Column12PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'zzff';
|
||||
flagname := '织造方法';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('zzff').AsString := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.Tv1Column14PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'wenlu';
|
||||
flagname := '纹路';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('wl').AsString := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.Tv1Column13PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'GYLX';
|
||||
flagname := '工艺类型';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('gylx').AsString := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.Tv1Column9PropertiesButtonClick(Sender: TObject; AButtonIndex: Integer);
|
||||
begin
|
||||
try
|
||||
frmZDYHelp := TfrmZDYHelp.Create(Application);
|
||||
with frmZDYHelp do
|
||||
begin
|
||||
flag := 'JSUNIT';
|
||||
flagname := '件数单位';
|
||||
if ShowModal = 1 then
|
||||
begin
|
||||
with CDS_Sub do
|
||||
begin
|
||||
edit;
|
||||
fieldbyname('JSUNIT').AsString := Trim(ClientDataSet1.fieldbyname('ZDYName').AsString);
|
||||
end;
|
||||
|
||||
end;
|
||||
end;
|
||||
finally
|
||||
frmZDYHelp.Free;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.Tv1Column7PropertiesEditValueChanged(Sender: TObject);
|
||||
var
|
||||
mvalue, FName, FPrice, FQty, FBaoGangFee: string;
|
||||
begin
|
||||
FName := Trim(Tv1.Controller.FocusedColumn.DataBinding.FilterFieldName);
|
||||
mvalue := TcxTextEdit(Sender).EditingText;
|
||||
if Trim(mvalue) = '' then
|
||||
begin
|
||||
mvalue := '0';
|
||||
end;
|
||||
with CDS_Sub do
|
||||
begin
|
||||
Edit;
|
||||
FieldByName(FName).Value := mvalue;
|
||||
Post;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.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); //Platform specific. May not work on Linux.
|
||||
ACanvas.Font.Color := clBlack;
|
||||
ACanvas.Brush.Style := bsClear;
|
||||
ACanvas.DrawText(FValue, FBounds, cxAlignCenter or cxAlignTop);
|
||||
ADone := True;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmYFGLInPut.ORDERNOBtnClick(Sender: TObject);
|
||||
begin
|
||||
frmProductOrderList_Sel := TfrmProductOrderList_Sel.Create(self);
|
||||
with frmProductOrderList_Sel do
|
||||
begin
|
||||
if showmodal = 1 then
|
||||
begin
|
||||
Self.OrderNo.Text := Order_Main.fieldbyname('Orderno').asstring;
|
||||
end;
|
||||
free;
|
||||
end;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -1,570 +0,0 @@
|
|||
object frmYFGLList: TfrmYFGLList
|
||||
Left = 209
|
||||
Top = 118
|
||||
Width = 1384
|
||||
Height = 670
|
||||
Caption = #36816#36153#31649#29702
|
||||
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
|
||||
OnDestroy = FormDestroy
|
||||
OnShow = FormShow
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 12
|
||||
object ToolBar1: TToolBar
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 1368
|
||||
AutoSize = True
|
||||
ButtonHeight = 30
|
||||
ButtonWidth = 107
|
||||
Caption = 'ToolBar1'
|
||||
Color = clSkyBlue
|
||||
Flat = True
|
||||
Font.Charset = GB2312_CHARSET
|
||||
Font.Color = clWindowText
|
||||
Font.Height = -12
|
||||
Font.Name = #23435#20307
|
||||
Font.Style = []
|
||||
Images = DataLink_DDMD.ThreeImgList
|
||||
List = True
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
ShowCaptions = True
|
||||
TabOrder = 0
|
||||
object TBRafresh: TToolButton
|
||||
Left = 0
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21047#26032
|
||||
ImageIndex = 0
|
||||
OnClick = TBRafreshClick
|
||||
end
|
||||
object TBFind: TToolButton
|
||||
Left = 63
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #36807#28388
|
||||
ImageIndex = 20
|
||||
Visible = False
|
||||
OnClick = TBFindClick
|
||||
end
|
||||
object ToolButton3: TToolButton
|
||||
Left = 126
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #26032#22686
|
||||
ImageIndex = 2
|
||||
Visible = False
|
||||
OnClick = ToolButton3Click
|
||||
end
|
||||
object ToolButton1: TToolButton
|
||||
Left = 189
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20462#25913
|
||||
ImageIndex = 11
|
||||
Visible = False
|
||||
OnClick = ToolButton1Click
|
||||
end
|
||||
object ToolButton2: TToolButton
|
||||
Left = 252
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21024#38500
|
||||
ImageIndex = 3
|
||||
Visible = False
|
||||
OnClick = ToolButton2Click
|
||||
end
|
||||
object ToolButton4: TToolButton
|
||||
Left = 315
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20184#27454#30830#35748
|
||||
ImageIndex = 31
|
||||
Visible = False
|
||||
OnClick = ToolButton4Click
|
||||
end
|
||||
object ToolButton5: TToolButton
|
||||
Left = 402
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #21462#28040#20184#27454#30830#35748
|
||||
ImageIndex = 52
|
||||
Visible = False
|
||||
OnClick = ToolButton5Click
|
||||
end
|
||||
object ToolButton6: TToolButton
|
||||
Left = 513
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20184#27454#30003#35831#21333
|
||||
ImageIndex = 4
|
||||
OnClick = ToolButton6Click
|
||||
end
|
||||
object ToolButton7: TToolButton
|
||||
Left = 612
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #23548#20986
|
||||
ImageIndex = 68
|
||||
OnClick = ToolButton7Click
|
||||
end
|
||||
object TBClose: TToolButton
|
||||
Left = 675
|
||||
Top = 0
|
||||
AutoSize = True
|
||||
Caption = #20851#38381
|
||||
ImageIndex = 21
|
||||
OnClick = TBCloseClick
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 32
|
||||
Width = 1368
|
||||
Height = 59
|
||||
Align = alTop
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
Color = clSkyBlue
|
||||
TabOrder = 1
|
||||
object Label6: TLabel
|
||||
Left = 379
|
||||
Top = 12
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #22806#38144#21457#31080#21495
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 236
|
||||
Top = 35
|
||||
Width = 24
|
||||
Height = 12
|
||||
Caption = #36135#20195
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 403
|
||||
Top = 36
|
||||
Width = 36
|
||||
Height = 12
|
||||
Caption = #19994#21153#21592
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 212
|
||||
Top = 12
|
||||
Width = 48
|
||||
Height = 12
|
||||
Caption = #35745#21010#21333#21495
|
||||
end
|
||||
object Label1: TLabel
|
||||
Left = 559
|
||||
Top = 12
|
||||
Width = 60
|
||||
Height = 12
|
||||
Caption = #36135#20195#21457#31080#21495
|
||||
end
|
||||
object BegDate: TDateTimePicker
|
||||
Left = 88
|
||||
Top = 8
|
||||
Width = 87
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 0
|
||||
end
|
||||
object EndDate: TDateTimePicker
|
||||
Left = 88
|
||||
Top = 31
|
||||
Width = 86
|
||||
Height = 20
|
||||
Date = 40768.458268587970000000
|
||||
Time = 40768.458268587970000000
|
||||
TabOrder = 1
|
||||
end
|
||||
object A4FPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 445
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 2
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object huodai: TEdit
|
||||
Tag = 2
|
||||
Left = 264
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 3
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object YWY: TEdit
|
||||
Tag = 2
|
||||
Left = 445
|
||||
Top = 31
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 4
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object orderno: TEdit
|
||||
Tag = 2
|
||||
Left = 264
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 5
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
object ComboBox1: TComboBox
|
||||
Left = 8
|
||||
Top = 8
|
||||
Width = 73
|
||||
Height = 20
|
||||
ItemHeight = 12
|
||||
ItemIndex = 0
|
||||
TabOrder = 6
|
||||
Text = #21046#21333#26085#26399
|
||||
OnChange = ComboBox1Change
|
||||
Items.Strings = (
|
||||
#21046#21333#26085#26399
|
||||
#33337#26399)
|
||||
end
|
||||
object HUODAIFPNO: TEdit
|
||||
Tag = 2
|
||||
Left = 625
|
||||
Top = 8
|
||||
Width = 100
|
||||
Height = 20
|
||||
TabOrder = 7
|
||||
OnKeyPress = ordernoKeyPress
|
||||
end
|
||||
end
|
||||
object cxGrid2: TcxGrid
|
||||
Left = 0
|
||||
Top = 91
|
||||
Width = 1368
|
||||
Height = 540
|
||||
Align = alClient
|
||||
TabOrder = 2
|
||||
object TV1: TcxGridDBTableView
|
||||
Navigator.Buttons.CustomButtons = <>
|
||||
OnCustomDrawCell = TV1CustomDrawCell
|
||||
DataController.DataSource = DataSource1
|
||||
DataController.Summary.DefaultGroupSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
Position = spFooter
|
||||
end>
|
||||
DataController.Summary.FooterSummaryItems = <
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end
|
||||
item
|
||||
Kind = skSum
|
||||
end>
|
||||
DataController.Summary.SummaryGroups = <>
|
||||
OptionsBehavior.GoToNextCellOnEnter = True
|
||||
OptionsCustomize.ColumnFiltering = False
|
||||
OptionsView.Footer = True
|
||||
OptionsView.GroupByBox = False
|
||||
OptionsView.GroupFooters = gfAlwaysVisible
|
||||
Styles.Inactive = DataLink_DDMD.SHuangSe
|
||||
Styles.IncSearch = DataLink_DDMD.SHuangSe
|
||||
Styles.Selection = DataLink_DDMD.SHuangSe
|
||||
Styles.Header = DataLink_DDMD.Default
|
||||
object tv2Column1: TcxGridDBColumn
|
||||
Caption = #36873#25321
|
||||
DataBinding.FieldName = 'SSel'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 68
|
||||
end
|
||||
object TV1Column1: TcxGridDBColumn
|
||||
Caption = #20184#27454#30830#35748
|
||||
DataBinding.FieldName = 'FKSTATUS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column2: TcxGridDBColumn
|
||||
Caption = #21457#31080#21495
|
||||
DataBinding.FieldName = 'A4FPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column3: TcxGridDBColumn
|
||||
Caption = #24320#31080#25260#22836
|
||||
DataBinding.FieldName = 'BGTAITOU'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column4: TcxGridDBColumn
|
||||
Caption = #36135#20195#21457#31080#21495
|
||||
DataBinding.FieldName = 'HUODAIFPNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 85
|
||||
end
|
||||
object TV1Column5: TcxGridDBColumn
|
||||
Caption = #36135#36816#20844#21496
|
||||
DataBinding.FieldName = 'huodai'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column6: TcxGridDBColumn
|
||||
Caption = #36816#36755#26041#24335
|
||||
DataBinding.FieldName = 'ZMXingZhi'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column7: TcxGridDBColumn
|
||||
Caption = #26588#22411
|
||||
DataBinding.FieldName = 'GUIXING'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column8: TcxGridDBColumn
|
||||
Caption = #25552#21333#21495
|
||||
DataBinding.FieldName = 'TDNO'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column9: TcxGridDBColumn
|
||||
Caption = #20184#27454#26041#24335
|
||||
DataBinding.FieldName = 'SHFS'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column10: TcxGridDBColumn
|
||||
Caption = #35745#21010#21333#21495
|
||||
DataBinding.FieldName = 'orderno'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column11: TcxGridDBColumn
|
||||
Caption = #24320#31080#26085#26399
|
||||
DataBinding.FieldName = 'HTDate'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column12: TcxGridDBColumn
|
||||
Caption = #24320#33337#26085#26399
|
||||
DataBinding.FieldName = 'chuandate'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column13: TcxGridDBColumn
|
||||
Caption = #24635'USD'#37329#39069
|
||||
DataBinding.FieldName = 'ZUSD'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 78
|
||||
end
|
||||
object TV1Column14: TcxGridDBColumn
|
||||
Caption = #24635'RMB'#37329#39069
|
||||
DataBinding.FieldName = 'ZRMB'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column15: TcxGridDBColumn
|
||||
Caption = #22791#27880
|
||||
DataBinding.FieldName = 'note'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column16: TcxGridDBColumn
|
||||
Caption = #21046#21333#26085#26399
|
||||
DataBinding.FieldName = 'filltime'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 66
|
||||
end
|
||||
object TV1Column17: TcxGridDBColumn
|
||||
Caption = #30331#35760#26085#26399
|
||||
DataBinding.FieldName = 'SCDJDate'
|
||||
HeaderAlignmentHorz = taCenter
|
||||
Width = 84
|
||||
end
|
||||
end
|
||||
object cxGridLevel1: TcxGridLevel
|
||||
GridView = TV1
|
||||
end
|
||||
end
|
||||
object ADOQueryCmd: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
Parameters = <>
|
||||
Left = 310
|
||||
Top = 329
|
||||
end
|
||||
object ADOQueryMain: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 312
|
||||
Top = 305
|
||||
end
|
||||
object ADOQueryTemp: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 342
|
||||
Top = 278
|
||||
end
|
||||
object DataSource1: TDataSource
|
||||
DataSet = CDS_Main
|
||||
Left = 283
|
||||
Top = 354
|
||||
end
|
||||
object cxGridPopupMenu1: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 284
|
||||
Top = 328
|
||||
end
|
||||
object CDS_Main: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 311
|
||||
Top = 352
|
||||
end
|
||||
object PopupMenu1: TPopupMenu
|
||||
Left = 314
|
||||
Top = 276
|
||||
object N1: TMenuItem
|
||||
Caption = #20840#36873
|
||||
OnClick = N1Click
|
||||
end
|
||||
object N2: TMenuItem
|
||||
Caption = #20840#24323
|
||||
OnClick = N2Click
|
||||
end
|
||||
end
|
||||
object ClientDataSet1: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 777
|
||||
Top = 299
|
||||
end
|
||||
object cxGridPopupMenu2: TcxGridPopupMenu
|
||||
PopupMenus = <>
|
||||
Left = 883
|
||||
Top = 487
|
||||
end
|
||||
object DataSource2: TDataSource
|
||||
DataSet = ClientDataSet2
|
||||
Left = 917
|
||||
Top = 487
|
||||
end
|
||||
object ClientDataSet2: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 949
|
||||
Top = 487
|
||||
end
|
||||
object RMXLSExport1: TRMXLSExport
|
||||
ShowAfterExport = True
|
||||
ExportPrecision = 1
|
||||
PagesOfSheet = 100
|
||||
ExportImages = True
|
||||
ExportFrames = True
|
||||
ExportImageFormat = ifBMP
|
||||
JPEGQuality = 0
|
||||
ScaleX = 1.000000000000000000
|
||||
ScaleY = 1.000000000000000000
|
||||
CompressFile = False
|
||||
Left = 225
|
||||
Top = 208
|
||||
end
|
||||
object CDS_Print: TClientDataSet
|
||||
Aggregates = <>
|
||||
Params = <>
|
||||
Left = 256
|
||||
Top = 357
|
||||
end
|
||||
object RM1: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDBDataSet1
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 256
|
||||
Top = 300
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDBDataSet1: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Print
|
||||
Left = 256
|
||||
Top = 328
|
||||
end
|
||||
object ADOQueryPrint: TADOQuery
|
||||
Connection = DataLink_DDMD.ADOLink
|
||||
LockType = ltReadOnly
|
||||
Parameters = <>
|
||||
Left = 256
|
||||
Top = 276
|
||||
end
|
||||
object RM2: TRMGridReport
|
||||
ThreadPrepareReport = True
|
||||
InitialZoom = pzDefault
|
||||
PreviewButtons = [pbZoom, pbLoad, pbSave, pbPrint, pbFind, pbPageSetup, pbExit, pbSaveToXLS, 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 = RMDB_2
|
||||
CompressLevel = rmzcFastest
|
||||
CompressThread = False
|
||||
LaterBuildEvents = True
|
||||
OnlyOwnerDataSet = False
|
||||
Left = 284
|
||||
Top = 303
|
||||
ReportData = {}
|
||||
end
|
||||
object RMDB_2: TRMDBDataSet
|
||||
Visible = True
|
||||
DataSet = CDS_Main
|
||||
Left = 285
|
||||
Top = 277
|
||||
end
|
||||
end
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user