|
|
|
|
unit u_op_seae_tdqr;
|
|
|
|
|
|
|
|
|
|
interface
|
|
|
|
|
|
|
|
|
|
uses
|
|
|
|
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
|
|
|
|
Dialogs, StdCtrls, bsSkinCtrls, ExtCtrls, dxExEdtr, dxCntner, dxTL,inifiles,
|
|
|
|
|
dxDBCtrl, dxDBGrid, ComCtrls, Grids, DBGridEh, DB, ADODB, Menus, dxmdaset,
|
|
|
|
|
kbmMemTable, RxMemDS, dxDBTLCl, dxGrClms, DBCtrls, cxControls,
|
|
|
|
|
cxContainer, cxEdit, cxTextEdit, cxMaskEdit, cxButtonEdit, cxDBEdit, Mask,
|
|
|
|
|
RxRichEd, bsSkinBoxCtrls, bsdbctrls, wwdbedit, Wwdotdot, Wwdbcomb,
|
|
|
|
|
wwdbdatetimepicker;
|
|
|
|
|
|
|
|
|
|
type
|
|
|
|
|
Tfrm_op_seae_tdqr = class(TForm)
|
|
|
|
|
bsSkinPanel9: TbsSkinPanel;
|
|
|
|
|
Label130: TLabel;
|
|
|
|
|
Label131: TLabel;
|
|
|
|
|
Edit4: TEdit;
|
|
|
|
|
Edit2: TEdit;
|
|
|
|
|
bsSkinButton44: TbsSkinButton;
|
|
|
|
|
dsrtd_qr: TDataSource;
|
|
|
|
|
qrytd_qr: TADOQuery;
|
|
|
|
|
bsSkinPanel1: TbsSkinPanel;
|
|
|
|
|
bsSkinButton7: TbsSkinButton;
|
|
|
|
|
bsSkinButton6: TbsSkinButton;
|
|
|
|
|
bsSkinButton5: TbsSkinButton;
|
|
|
|
|
bsSkinButton38: TbsSkinButton;
|
|
|
|
|
Notebook1: TNotebook;
|
|
|
|
|
dxDBGrid1: TdxDBGrid;
|
|
|
|
|
bsSkinPanel2: TbsSkinPanel;
|
|
|
|
|
bsSkinPanel3: TbsSkinPanel;
|
|
|
|
|
dxDBGrid1Column1: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column2: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column3: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column4: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column5: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column6: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column7: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column8: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column9: TdxDBGridColumn;
|
|
|
|
|
bsSkinSplitter1: TbsSkinSplitter;
|
|
|
|
|
bsSkinDBMemo21: TbsSkinDBMemo2;
|
|
|
|
|
bsSkinMemo21: TbsSkinMemo2;
|
|
|
|
|
bsSkinButton1: TbsSkinButton;
|
|
|
|
|
dxDBGrid1Column10: TdxDBGridColumn;
|
|
|
|
|
Label10: TLabel;
|
|
|
|
|
Label5: TLabel;
|
|
|
|
|
wwDBDateTimePicker1: TwwDBDateTimePicker;
|
|
|
|
|
wwDBDateTimePicker2: TwwDBDateTimePicker;
|
|
|
|
|
wwDBComboBox6: TwwDBComboBox;
|
|
|
|
|
wwDBComboBox18: TwwDBComboBox;
|
|
|
|
|
Label1: TLabel;
|
|
|
|
|
Edit1: TEdit;
|
|
|
|
|
procedure bsSkinButton5Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton7Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton6Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton38Click(Sender: TObject);
|
|
|
|
|
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
|
|
|
|
procedure bsSkinPanel1Resize(Sender: TObject);
|
|
|
|
|
procedure FormShow(Sender: TObject);
|
|
|
|
|
procedure dsrtd_qrDataChange(Sender: TObject; Field: TField);
|
|
|
|
|
procedure pop0Click(Sender: TObject);
|
|
|
|
|
procedure pop2Click(Sender: TObject);
|
|
|
|
|
procedure pop3Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton44Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton1Click(Sender: TObject);
|
|
|
|
|
private
|
|
|
|
|
{ Private declarations }
|
|
|
|
|
procedure setdiffcolor ;
|
|
|
|
|
public
|
|
|
|
|
{ Public declarations }
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
var
|
|
|
|
|
frm_op_seae_tdqr: Tfrm_op_seae_tdqr;
|
|
|
|
|
|
|
|
|
|
implementation
|
|
|
|
|
|
|
|
|
|
{$R *.dfm}
|
|
|
|
|
uses u_main,my_sys_function, u_op_seae_assistant, u_data_share,
|
|
|
|
|
u_op_seaetd_query,u_op_seae_difftd, u_send_msg;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.bsSkinButton5Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
close ;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.bsSkinButton7Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
qrytd_qr.Prior ;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.bsSkinButton6Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
qrytd_qr.Next ;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.bsSkinButton38Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
if bsSkinButton38.Caption='<27><>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD>' then
|
|
|
|
|
begin
|
|
|
|
|
bsSkinButton38.Caption:='<27><><EFBFBD><EFBFBD><EFBFBD>б<EFBFBD>';
|
|
|
|
|
Notebook1.PageIndex:=0;
|
|
|
|
|
exit;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
if bsSkinButton38.Caption='<27><><EFBFBD><EFBFBD><EFBFBD>б<EFBFBD>' then
|
|
|
|
|
begin
|
|
|
|
|
bsSkinButton38.Caption:='<27><>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD>';
|
|
|
|
|
Notebook1.PageIndex:=1;
|
|
|
|
|
exit;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.FormClose(Sender: TObject;
|
|
|
|
|
var Action: TCloseAction);
|
|
|
|
|
begin
|
|
|
|
|
frm_op_seae_tdqr.Hide;
|
|
|
|
|
frm_op_seae_tdqr.ManualFloat(frm_op_seae_tdqr.BoundsRect );
|
|
|
|
|
frm_main.freeTabs('frm_op_seae_tdqr');
|
|
|
|
|
action:=cafree;
|
|
|
|
|
frm_op_seae_tdqr:=nil;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.bsSkinPanel1Resize(Sender: TObject);
|
|
|
|
|
var
|
|
|
|
|
i:integer;
|
|
|
|
|
begin
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.FormShow(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
Notebook1.PageIndex:=1 ;
|
|
|
|
|
with qrytd_qr,sql do
|
|
|
|
|
begin
|
|
|
|
|
close ; clear ;
|
|
|
|
|
add('SELECT * from t_op_Edi_Log ');
|
|
|
|
|
add('where 1=2');
|
|
|
|
|
open;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
wwDBComboBox18.text:='<27><><EFBFBD><EFBFBD>';
|
|
|
|
|
wwDBComboBox6.text:='С<><D0A1>';
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.dsrtd_qrDataChange(Sender: TObject;
|
|
|
|
|
Field: TField);
|
|
|
|
|
begin
|
|
|
|
|
setdiffcolor ;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.pop0Click(Sender: TObject);
|
|
|
|
|
begin //<2F><><EFBFBD><EFBFBD><EFBFBD>ύȷ<E1BDBB><C8B7>
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.pop2Click(Sender: TObject);
|
|
|
|
|
begin // <20><><EFBFBD>ܿͻ<DCBF>ȷ<EFBFBD><C8B7>
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.pop3Click(Sender: TObject);
|
|
|
|
|
begin // <20><><EFBFBD>ͻ<EFBFBD><CDBB><EFBFBD>
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.setdiffcolor;
|
|
|
|
|
begin
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.bsSkinButton44Click(Sender: TObject);
|
|
|
|
|
var
|
|
|
|
|
str:widestring;
|
|
|
|
|
begin
|
|
|
|
|
str:='';
|
|
|
|
|
|
|
|
|
|
str:=query_tiaojian(1,str,'t_op_Edi_Log.ί<>б<EFBFBD><D0B1><EFBFBD>','ģ<><C4A3>',Edit4.text);
|
|
|
|
|
str:=query_tiaojian(1,str,'t_op_Edi_Log.<2E><><EFBFBD>ᵥ<EFBFBD><E1B5A5>','ģ<><C4A3>',Edit2.text);
|
|
|
|
|
str:=query_tiaojian(1,str,'t_op_Edi_Log.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox18.text,wwDBDateTimePicker1.text);
|
|
|
|
|
str:=query_tiaojian(1,str,'t_op_Edi_Log.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox6.text,wwDBDateTimePicker2.text);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if trim(str)='' then
|
|
|
|
|
begin
|
|
|
|
|
str:='where '+open_data('0001','t_op_Edi_Log.¼<><C2BC><EFBFBD><EFBFBD>','no','no','no','no');
|
|
|
|
|
end
|
|
|
|
|
else
|
|
|
|
|
begin
|
|
|
|
|
str:=str+' and '+open_data('0001','t_op_Edi_Log.¼<><C2BC><EFBFBD><EFBFBD>','no','no','no','no');
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
if Trim(Edit1.Text)<>'' then begin
|
|
|
|
|
str:='select t_op_Edi_Log.* from t_op_Edi_Log left Join t_op_seae on t_op_seae.<2E><><EFBFBD>ᵥ<EFBFBD><E1B5A5>= t_op_Edi_Log.<2E><><EFBFBD>ᵥ<EFBFBD><E1B5A5> ' +str;
|
|
|
|
|
str:=str+ ' and t_op_seae.<2E>ͷ<EFBFBD>Ա='+''''+Edit1.Text+'''';
|
|
|
|
|
end
|
|
|
|
|
else
|
|
|
|
|
begin
|
|
|
|
|
str:='select t_op_Edi_Log.* from t_op_Edi_Log ' +str;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
qrytd_qr.close;
|
|
|
|
|
qrytd_qr.sql.clear;
|
|
|
|
|
qrytd_qr.sql.add(str);
|
|
|
|
|
qrytd_qr.Open;
|
|
|
|
|
if qrytd_qr.IsEmpty then
|
|
|
|
|
begin
|
|
|
|
|
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
|
|
|
|
|
exit;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_op_seae_tdqr.bsSkinButton1Click(Sender: TObject);
|
|
|
|
|
var str:Tstringlist;
|
|
|
|
|
i:Integer;
|
|
|
|
|
begin
|
|
|
|
|
exit;
|
|
|
|
|
str:=Tstringlist.Create;
|
|
|
|
|
str.Clear;
|
|
|
|
|
str.Text:=qrytd_qr.FieldByName('EDI<44><49><EFBFBD><EFBFBD>').Value;
|
|
|
|
|
for i:=0 to str.Count-1 do
|
|
|
|
|
begin
|
|
|
|
|
if Pos('UNB+UNOC:2+',str[i])>0 then
|
|
|
|
|
begin
|
|
|
|
|
bsSkinMemo21.Lines.Add(StringReplace(str[i], 'UNB+UNOC:2', '<27><><EFBFBD>ͷ<EFBFBD><CDB7><EFBFBD>ʶ',[rfReplaceAll, rfIgnoreCase]));
|
|
|
|
|
end;
|
|
|
|
|
if Pos('UNH+',str[i])>0 then
|
|
|
|
|
begin
|
|
|
|
|
bsSkinMemo21.Lines.Add(StringReplace(str[i], 'UNH+', '<27><>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD>',[rfReplaceAll, rfIgnoreCase]));
|
|
|
|
|
end;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
// bsSkinMemo21.Lines.Text:=str.Text;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
end.
|