You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1339 lines
53 KiB
Plaintext

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

unit u_op_seae_query;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, RxLookup, StdCtrls, Mask, wwdbedit, Wwdotdot, Wwdbcomb,Registry,
wwdbdatetimepicker, wwdblook, bsSkinCtrls, BusinessSkinForm, DB, ComCtrls,
bsSkinTabs, ADODB, DBCtrls, RxMemDS, dxExEdtr, dxCntner, dxTL, dxDBCtrl,
dxDBGrid, dxDBTLCl, dxGrClms;
type
Tfrm_op_seae_query = class(TForm)
bsBusinessSkinForm1: TbsBusinessSkinForm;
bsSkinPageControl1: TbsSkinPageControl;
bsSkinTabSheet1: TbsSkinTabSheet;
bsSkinTabSheet2: TbsSkinTabSheet;
Label10: TLabel;
Label9: TLabel;
Label14: TLabel;
Label15: TLabel;
Label6: TLabel;
Label7: TLabel;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Label4: TLabel;
Label5: TLabel;
Label8: TLabel;
Label11: TLabel;
Label12: TLabel;
Label20: TLabel;
Label124: TLabel;
Label16: TLabel;
Label28: TLabel;
Label17: TLabel;
Label18: TLabel;
Label19: TLabel;
Label21: TLabel;
Label24: TLabel;
Label22: TLabel;
Label23: TLabel;
Label25: TLabel;
Label26: TLabel;
Label27: TLabel;
Label29: TLabel;
Label125: TLabel;
Label30: TLabel;
Label31: TLabel;
Label32: TLabel;
Edit1: TEdit;
RxDBLookupCombo2: TRxDBLookupCombo;
RxDBLookupCombo3: TRxDBLookupCombo;
RxDBLookupCombo4: TRxDBLookupCombo;
Edit2: TEdit;
Edit3: TEdit;
Edit4: TEdit;
wwDBComboBox1: TwwDBComboBox;
wwDBComboBox2: TwwDBComboBox;
wwDBDateTimePicker1: TwwDBDateTimePicker;
wwDBDateTimePicker2: TwwDBDateTimePicker;
wwDBDateTimePicker3: TwwDBDateTimePicker;
wwDBDateTimePicker4: TwwDBDateTimePicker;
RxDBLookupCombo1: TRxDBLookupCombo;
wwDBLookupCombo3: TwwDBLookupCombo;
wwDBLookupCombo52: TwwDBLookupCombo;
RxDBLookupCombo6: TRxDBLookupCombo;
bsSkinButton10: TbsSkinButton;
bsSkinButton5: TbsSkinButton;
bsSkinButton1: TbsSkinButton;
RxDBLookupCombo7: TRxDBLookupCombo;
RxDBLookupCombo8: TRxDBLookupCombo;
RxDBLookupCombo9: TRxDBLookupCombo;
RxDBLookupCombo11: TRxDBLookupCombo;
RxDBLookupCombo20: TRxDBLookupCombo;
wwDBComboBox3: TwwDBComboBox;
wwDBComboBox4: TwwDBComboBox;
wwDBComboBox5: TwwDBComboBox;
wwDBComboBox6: TwwDBComboBox;
wwDBComboBox7: TwwDBComboBox;
wwDBComboBox8: TwwDBComboBox;
wwDBComboBox9: TwwDBComboBox;
wwDBComboBox10: TwwDBComboBox;
wwDBComboBox11: TwwDBComboBox;
wwDBComboBox12: TwwDBComboBox;
wwDBComboBox14: TwwDBComboBox;
wwDBComboBox15: TwwDBComboBox;
wwDBComboBox16: TwwDBComboBox;
wwDBComboBox17: TwwDBComboBox;
wwDBComboBox18: TwwDBComboBox;
wwDBComboBox19: TwwDBComboBox;
wwDBComboBox20: TwwDBComboBox;
wwDBComboBox21: TwwDBComboBox;
wwDBComboBox22: TwwDBComboBox;
wwDBComboBox23: TwwDBComboBox;
wwDBComboBox24: TwwDBComboBox;
wwDBComboBox25: TwwDBComboBox;
wwDBComboBox26: TwwDBComboBox;
wwDBComboBox27: TwwDBComboBox;
wwDBComboBox28: TwwDBComboBox;
RxDBLookupCombo10: TRxDBLookupCombo;
RxDBLookupCombo12: TRxDBLookupCombo;
wwDBComboBox29: TwwDBComboBox;
wwDBComboBox30: TwwDBComboBox;
wwDBComboBox31: TwwDBComboBox;
wwDBComboBox32: TwwDBComboBox;
RxDBLookupCombo13: TRxDBLookupCombo;
wwDBComboBox33: TwwDBComboBox;
Edit5: TEdit;
wwDBComboBox34: TwwDBComboBox;
Edit6: TEdit;
wwDBLookupCombo49: TwwDBLookupCombo;
wwDBComboBox35: TwwDBComboBox;
Edit7: TEdit;
wwDBComboBox36: TwwDBComboBox;
wwDBComboBox37: TwwDBComboBox;
Edit8: TEdit;
Edit9: TEdit;
wwDBComboBox38: TwwDBComboBox;
t_sys_queryfields: TADOQuery;
t_sys_queryfields1: TDataSource;
bsSkinGroupBox1: TbsSkinGroupBox;
bsSkinPanel1: TbsSkinPanel;
bsSkinButton2: TbsSkinButton;
bsSkinButton4: TbsSkinButton;
bsSkinPanel2: TbsSkinPanel;
Label33: TLabel;
RxDBLookupList1: TRxDBLookupList;
RxDBLookupCombo14: TRxDBLookupCombo;
Label34: TLabel;
wwDBComboBox39: TwwDBComboBox;
Label35: TLabel;
wwDBComboBox40: TwwDBComboBox;
Label36: TLabel;
bsSkinGroupBox2: TbsSkinGroupBox;
bsSkinPanel3: TbsSkinPanel;
bsSkinButton3: TbsSkinButton;
bsSkinButton7: TbsSkinButton;
t_sys_query_detail1: TDataSource;
dxDBGrid1: TdxDBGrid;
dxDBGrid1Column2: TdxDBGridMaskColumn;
dxDBGrid1Column4: TdxDBGridMaskColumn;
query_bit: TwwDBComboBox;
query_str_int: TEdit;
query_date: TwwDBDateTimePicker;
t_sys_query: TADOQuery;
t_sys_query1: TDataSource;
t_sys_query_detail: TADOQuery;
dxDBGrid2: TdxDBGrid;
dxDBGrid2SQ_ID: TdxDBGridMaskColumn;
bsSkinButton6: TbsSkinButton;
bsSkinButton9: TbsSkinButton;
dxDBGrid1Column1: TdxDBGridPickColumn;
dxDBGrid1Column3: TdxDBGridPickColumn;
Label37: TLabel;
wwDBComboBox41: TwwDBComboBox;
Edit10: TEdit;
Label38: TLabel;
wwDBComboBox42: TwwDBComboBox;
Edit11: TEdit;
Label39: TLabel;
wwDBComboBox43: TwwDBComboBox;
RxDBLookupCombo15: TRxDBLookupCombo;
Label40: TLabel;
wwDBComboBox44: TwwDBComboBox;
RxDBLookupCombo16: TRxDBLookupCombo;
Label41: TLabel;
wwDBComboBox45: TwwDBComboBox;
Label42: TLabel;
wwDBComboBox46: TwwDBComboBox;
wwDBDateTimePicker5: TwwDBDateTimePicker;
Label43: TLabel;
wwDBComboBox47: TwwDBComboBox;
wwDBDateTimePicker6: TwwDBDateTimePicker;
Label44: TLabel;
wwDBComboBox48: TwwDBComboBox;
Edit12: TEdit;
Label45: TLabel;
wwDBComboBox49: TwwDBComboBox;
Label13: TLabel;
RxDBLookupCombo5: TRxDBLookupCombo;
wwDBComboBox13: TwwDBComboBox;
Label46: TLabel;
RxDBLookupCombo17: TRxDBLookupCombo;
wwDBComboBox50: TwwDBComboBox;
lbl1: TLabel;
wdbcmbx4: TwwDBComboBox;
lbl2: TLabel;
wdbcmbx3: TwwDBComboBox;
Label47: TLabel;
wwDBComboBox51: TwwDBComboBox;
Edit13: TEdit;
Label48: TLabel;
wwDBComboBox52: TwwDBComboBox;
Edit14: TEdit;
Label49: TLabel;
wwDBComboBox53: TwwDBComboBox;
RxDBLookupCombo18: TRxDBLookupCombo;
Edit15: TEdit;
wwDBComboBox54: TwwDBComboBox;
Label50: TLabel;
Label51: TLabel;
wwDBComboBox55: TwwDBComboBox;
wwDBDateTimePicker7: TwwDBDateTimePicker;
Label52: TLabel;
wwDBComboBox56: TwwDBComboBox;
wwDBDateTimePicker8: TwwDBDateTimePicker;
Label53: TLabel;
wwDBComboBox57: TwwDBComboBox;
wwDBComboBox58: TwwDBComboBox;
Label54: TLabel;
wwDBComboBox59: TwwDBComboBox;
wwDBDateTimePicker9: TwwDBDateTimePicker;
Label55: TLabel;
wwDBComboBox60: TwwDBComboBox;
wwDBDateTimePicker10: TwwDBDateTimePicker;
Label56: TLabel;
wwDBComboBox61: TwwDBComboBox;
wwDBDateTimePicker11: TwwDBDateTimePicker;
Label57: TLabel;
wwDBComboBox62: TwwDBComboBox;
wwDBDateTimePicker12: TwwDBDateTimePicker;
Label58: TLabel;
wwDBComboBox63: TwwDBComboBox;
wwDBDateTimePicker13: TwwDBDateTimePicker;
Label59: TLabel;
wwDBComboBox64: TwwDBComboBox;
wwDBDateTimePicker14: TwwDBDateTimePicker;
Label60: TLabel;
wwDBComboBox65: TwwDBComboBox;
wwDBComboBox66: TwwDBComboBox;
Label61: TLabel;
wwDBComboBox67: TwwDBComboBox;
wwDBComboBox68: TwwDBComboBox;
Label62: TLabel;
wwDBComboBox69: TwwDBComboBox;
wwDBDateTimePicker15: TwwDBDateTimePicker;
Label63: TLabel;
wwDBComboBox70: TwwDBComboBox;
wwDBDateTimePicker16: TwwDBDateTimePicker;
wwDBComboBox71: TwwDBComboBox;
wwDBComboBox72: TwwDBComboBox;
Label64: TLabel;
Label65: TLabel;
wwDBComboBox73: TwwDBComboBox;
wwDBComboBox74: TwwDBComboBox;
Label66: TLabel;
wwDBComboBox75: TwwDBComboBox;
wwDBComboBox76: TwwDBComboBox;
Label67: TLabel;
wwDBComboBox77: TwwDBComboBox;
wwDBComboBox78: TwwDBComboBox;
Label68: TLabel;
wwDBComboBox79: TwwDBComboBox;
wwDBComboBox80: TwwDBComboBox;
Label69: TLabel;
wwDBComboBox81: TwwDBComboBox;
wwDBComboBox82: TwwDBComboBox;
Label70: TLabel;
wwDBComboBox83: TwwDBComboBox;
wwDBComboBox84: TwwDBComboBox;
Label71: TLabel;
wwDBComboBox85: TwwDBComboBox;
Edit16: TEdit;
Label72: TLabel;
wwDBComboBox86: TwwDBComboBox;
Edit17: TEdit;
Label73: TLabel;
wwDBComboBox87: TwwDBComboBox;
Edit18: TEdit;
wwDBComboBox88: TwwDBComboBox;
wwDBComboBox89: TwwDBComboBox;
Label74: TLabel;
Label75: TLabel;
RxDBLookupCombo19: TRxDBLookupCombo;
Label76: TLabel;
wwDBComboBox90: TwwDBComboBox;
wwDBDateTimePicker17: TwwDBDateTimePicker;
Label77: TLabel;
wwDBComboBox91: TwwDBComboBox;
wwDBDateTimePicker18: TwwDBDateTimePicker;
Label78: TLabel;
wwDBComboBox92: TwwDBComboBox;
Edit19: TEdit;
Label79: TLabel;
wwDBComboBox93: TwwDBComboBox;
Edit20: TEdit;
dxDBGrid1Column5: TdxDBGridColumn;
dxDBGrid2Column2: TdxDBGridColumn;
procedure bsSkinButton5Click(Sender: TObject);
procedure bsSkinButton10Click(Sender: TObject);
procedure bsSkinButton1Click(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure RxDBLookupCombo14Change(Sender: TObject);
procedure bsSkinButton2Click(Sender: TObject);
procedure bsSkinButton4Click(Sender: TObject);
procedure RxDBLookupList1DblClick(Sender: TObject);
procedure wwDBComboBox15KeyPress(Sender: TObject; var Key: Char);
procedure t_sys_queryAfterInsert(DataSet: TDataSet);
procedure bsSkinButton6Click(Sender: TObject);
procedure bsSkinButton9Click(Sender: TObject);
procedure t_sys_query_detailBeforePost(DataSet: TDataSet);
procedure t_sys_query_detailAfterScroll(DataSet: TDataSet);
private
{ Private declarations }
public
{ Public declarations }
end;
var
frm_op_seae_query: Tfrm_op_seae_query;
seae_query_limited:string;
seae_query_table:integer;
implementation
uses my_sys_function, u_op_seae, u_ch_fee_sea_sales, u_ch_fee_check_seae,
u_op_seae_close, u_rp_tai_seae, u_rp_rp_seae, u_rp_zou_seae,
u_rp_fen_seae, u_rp_fee_modify, u_data_share, u_main, u_rp_fen_seae_ctn,
u_op_seae_apply, u_rp_no_histry, u_rp_sales_profit2022, u_op_seae_trace,
u_op_seae_feeunclose, u_rp_zou_linehistry;
{$R *.dfm}
procedure Tfrm_op_seae_query.bsSkinButton5Click(Sender: TObject);
begin
close;
end;
procedure Tfrm_op_seae_query.bsSkinButton10Click(Sender: TObject);
begin
Edit1.text:='';
Edit2.text:='';
Edit3.text:='';
Edit4.text:='';
Edit5.text:='';
Edit6.text:='';
Edit14.text:='';
Edit15.text:='';
Edit19.text:='';
wwDBComboBox1.text:='';
wwDBComboBox2.text:='';
wwDBDateTimePicker1.Clear;
wwDBDateTimePicker2.Clear;
wwDBDateTimePicker3.Clear;
wwDBDateTimePicker4.Clear;
wwDBComboBox3.text:='';
RxDBLookupCombo20.ClearValue;
RxDBLookupCombo2.ClearValue;
RxDBLookupCombo1.ClearValue;
RxDBLookupCombo9.ClearValue;
RxDBLookupCombo8.ClearValue;
RxDBLookupCombo11.ClearValue;
RxDBLookupCombo7.ClearValue;
wwDBLookupCombo3.text:='';
wwDBLookupCombo52.text:='';
RxDBLookupCombo4.ClearValue;
RxDBLookupCombo3.ClearValue;
RxDBLookupCombo6.ClearValue;
RxDBLookupCombo5.ClearValue;
RxDBLookupCombo10.ClearValue;
RxDBLookupCombo12.ClearValue;
RxDBLookupCombo18.ClearValue;
RxDBLookupCombo17.ClearValue;
wwDBComboBox31.text:='';
RxDBLookupCombo13.ClearValue;
wwDBDateTimePicker7.Clear;
wwDBDateTimePicker8.Clear;
wwDBComboBox58.text:='';
wwDBDateTimePicker9.Clear;
wwDBDateTimePicker10.Clear;
wwDBDateTimePicker11.Clear;
wwDBDateTimePicker12.Clear;
wwDBDateTimePicker13.Clear;
wwDBDateTimePicker14.Clear;
wwDBDateTimePicker15.Clear;
wwDBDateTimePicker16.Clear;
wwDBComboBox66.text:='';
wwDBComboBox68.text:='';
wwDBComboBox71.text:='';
wwDBComboBox78.text:='';
wwDBComboBox74.text:='';
wwDBComboBox76.text:='';
wwDBComboBox80.text:='';
wwDBComboBox82.text:='';
wwDBComboBox84.text:='';
Edit16.text:='';
Edit17.text:='';
Edit18.text:='';
end;
procedure Tfrm_op_seae_query.bsSkinButton1Click(Sender: TObject);
var
str,str2,str_fee,ctnstr:widestring;
str_date:string;
strsort:string;
i:integer;
ExeFileName:String;
begin
str:='';
if bsSkinTabSheet2.Showing then
begin
str:=query_tiaojian(1,str,'t_op_seae.ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox15.text,Edit1.text);
str:=query_tiaojian(1,str,'t_op_seae.ί<>б<EFBFBD><D0B1><EFBFBD>',wwDBComboBox4.text,Edit4.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><E1B5A5>',wwDBComboBox16.text,Edit2.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><E1B5A5>',wwDBComboBox5.text,Edit3.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><E1B5A5>',wwDBComboBox51.text,Edit13.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD>ص<EFBFBD><D8B5><EFBFBD>',wwDBComboBox41.text,Edit10.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><ECB5A5>',wwDBComboBox42.text,Edit11.text);
str:=query_tiaojian(1,str,'t_op_seae.ί<>е<EFBFBD>λ',wwDBComboBox92.text,Edit19.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox93.text,Edit20.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><>Ʊ<EFBFBD><C6B1>',wwDBComboBox33.text,Edit5.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox34.text,Edit6.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><>ͬ<EFBFBD>ű<EFBFBD>ע',wwDBComboBox52.text,Edit14.text);
// str:=query_tiaojian(1,str,'t_op_seae.ҵ<><D2B5>״̬',wwDBComboBox17.text,wwDBComboBox1.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD>״̬',wwDBComboBox7.text,wwDBComboBox2.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox18.text,wwDBDateTimePicker1.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox6.text,wwDBDateTimePicker2.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD>ڼ<EFBFBD>',wwDBComboBox19.text,wwDBDateTimePicker3.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD>ڼ<EFBFBD>',wwDBComboBox11.text,wwDBDateTimePicker4.text);
str:=query_tiaojian(1,str,'t_op_seae.װ<>˷<EFBFBD>ʽ',wwDBComboBox20.text,wwDBComboBox3.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD>',wwDBComboBox10.text,RxDBLookupCombo20.DisplayValues[1]);
str:=query_tiaojian(1,str,'t_op_seae.ί<>е<EFBFBD>λ',wwDBComboBox21.text,RxDBLookupCombo2.DisplayValues[1]);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD>˾',wwDBComboBox9.text,RxDBLookupCombo1.DisplayValues[1]);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox22.text,RxDBLookupCombo9.DisplayValues[1]);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾',wwDBComboBox8.text,RxDBLookupCombo8.DisplayValues[1]);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD>˳<EFBFBD><CBB3><EFBFBD>',wwDBComboBox23.text,RxDBLookupCombo11.DisplayValues[1]);
str:=query_tiaojian(1,str,'t_op_seae.<2E><>վ',wwDBComboBox12.text,RxDBLookupCombo7.DisplayValues[1]);
str:=query_tiaojian(1,str,'t_op_seae.װ<><D7B0><EFBFBD><EFBFBD>',wwDBComboBox26.text,wwDBLookupCombo3.text);
str:=query_tiaojian(1,str,'t_op_seae.ж<><D0B6><EFBFBD><EFBFBD>',wwDBComboBox27.text,wwDBLookupCombo52.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E>ͷ<EFBFBD>Ա',wwDBComboBox24.text,RxDBLookupCombo4.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox14.text,RxDBLookupCombo3.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD>Ա',wwDBComboBox25.text,RxDBLookupCombo6.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD>߲<EFBFBD><DFB2><EFBFBD>',wwDBComboBox43.text,RxDBLookupCombo15.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.ҵ<><D2B5><EFBFBD><EFBFBD>Դ',wwDBComboBox44.text,RxDBLookupCombo16.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.¼<><C2BC><EFBFBD><EFBFBD>',wwDBComboBox13.text,RxDBLookupCombo5.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox53.text,RxDBLookupCombo18.DisplayValues[1]);
str:=query_tiaojian(1,str,'t_op_seae.<2E><>֤Ա',wwDBComboBox50.text,RxDBLookupCombo17.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox32.text,RxDBLookupCombo13.DisplayValues[1]);
str:=query_tiaojian(3,str,'t_op_seae.<2E><><EFBFBD>ط<EFBFBD><D8B7><EFBFBD>',wwDBComboBox30.text,wwDBComboBox31.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD>۲<EFBFBD><DBB2><EFBFBD>',wwDBComboBox28.text,RxDBLookupCombo10.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox29.text,RxDBLookupCombo12.DisplayValue);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD>',wwDBComboBox36.text,wwDBLookupCombo49.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD>',wwDBComboBox35.text,Edit7.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox48.text,Edit12.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox54.text,Edit15.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD>ŷ<EFBFBD><C5B7><EFBFBD>',wwDBComboBox37.text,Edit8.text);
str:=query_tiaojian(2,str,'t_op_seae.<2E>ܴ<EFBFBD>',wwDBComboBox38.text,Edit9.text);
str:=query_tiaojian(1,str,'t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox46.text,wwDBDateTimePicker5.text);
str:=query_tiaojian(1,str,'t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox47.text,wwDBDateTimePicker6.text);
str:=query_tiaojian(3,str,'t_op_seae.FEE2',wdbcmbx4.text,wdbcmbx3.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox55.text,wwDBDateTimePicker7.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox56.text,wwDBDateTimePicker8.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E>Ƿ<EFBFBD>ռ<EFBFBD><D5BC>',wwDBComboBox57.text,wwDBComboBox58.Value);
str:=query_tiaojian(1,str,'t_op_seae.ETA',wwDBComboBox59.text,wwDBDateTimePicker9.text);
str:=query_tiaojian(1,str,'t_op_seae.ETA',wwDBComboBox60.text,wwDBDateTimePicker10.text);
str:=query_tiaojian(1,str,'t_op_seae.ATA',wwDBComboBox61.text,wwDBDateTimePicker11.text);
str:=query_tiaojian(1,str,'t_op_seae.ATA',wwDBComboBox62.text,wwDBDateTimePicker12.text);
str:=query_tiaojian(1,str,'t_op_seae.ETD',wwDBComboBox63.text,wwDBDateTimePicker13.text);
str:=query_tiaojian(1,str,'t_op_seae.ETD',wwDBComboBox64.text,wwDBDateTimePicker14.text);
str:=query_tiaojian(1,str,'t_op_seae.Ӧ<><D3A6><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox69.text,wwDBDateTimePicker15.text);
str:=query_tiaojian(1,str,'t_op_seae.Ӧ<><D3A6><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox70.text,wwDBDateTimePicker16.text);
str:=query_tiaojian(3,str,'t_op_seae.֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD>',wwDBComboBox65.text,wwDBComboBox66.text);
str:=query_tiaojian(3,str,'t_op_seae.<2E>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox67.text,wwDBComboBox68.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',wwDBComboBox72.text,wwDBComboBox71.text);
str:=query_tiaojian(3,str,'t_op_seae.<2E>Ƿ<EFBFBD>AMS¼<53><C2BC>',wwDBComboBox77.text,wwDBComboBox78.text);
str:=query_tiaojian(3,str,'t_op_seae.<2E>Ƿ<EFBFBD>1Y',wwDBComboBox73.text,wwDBComboBox74.text);
str:=query_tiaojian(3,str,'t_op_seae.<2E>Ƿ<EFBFBD>3Z',wwDBComboBox75.text,wwDBComboBox76.text);
str:=query_tiaojian(3,str,'t_op_seae.<2E>Ƿ<EFBFBD><C7B7>ύVGM',wwDBComboBox79.text,wwDBComboBox80.text);
str:=query_tiaojian(3,str,'t_op_seae.<2E>Ƿ<EFBFBD><C7B7><EFBFBD>յ<EFBFBD>',wwDBComboBox81.text,wwDBComboBox82.text);
str:=query_tiaojian(3,str,'t_op_seae.<2E>Ƿ<EFBFBD>װ<EFBFBD>ط<EFBFBD><D8B7><EFBFBD>',wwDBComboBox83.text,wwDBComboBox84.text);
str:=query_tiaojian(3,str,'t_op_seae.<2E>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD>ý<EFBFBD><C3BD><EFBFBD>',wwDBComboBox89.text,wwDBComboBox88.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ע',wwDBComboBox85.text,Edit16.text);
str:=query_tiaojian(1,str,'t_op_seae.ռ<>ձ<EFBFBD>ע',wwDBComboBox86.text,Edit17.text);
str:=query_tiaojian(1,str,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>к<EFBFBD>',wwDBComboBox87.text,Edit18.text);
if wwDBComboBox1.text<>'' then
begin
if str='' then
str:='where t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_op_state where ҵ<><D2B5>״̬ like ''%'+wwDBComboBox1.text+'%'') '
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_op_state where ҵ<><D2B5>״̬ like ''%'+wwDBComboBox1.text+'%'') '
end;
if RxDBLookupCombo19.DisplayValues[1]<>'' then
begin
if str='' then
str:='where t_op_seae.ί<>е<EFBFBD>λ in (select <20>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD> from t_crm_client where <20>ͻ<EFBFBD>ȫ<EFBFBD><C8AB>='''+RxDBLookupCombo19.DisplayValues[1]+''') '
else
str:=str+' and t_op_seae.ί<>е<EFBFBD>λ in (select <20>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD> from t_crm_client where <20>ͻ<EFBFBD>ȫ<EFBFBD><C8AB>='''+RxDBLookupCombo19.DisplayValues[1]+''') '
end;
if wwDBComboBox45.Text<>'' then begin
if wwDBComboBox45.Text='δ<><CEB4><EFBFBD><EFBFBD>ҵ<EFBFBD><D2B5>' then begin
if str='' then
str:=' t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_op_state where <20>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD><>1)) '
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_op_state where <20>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD><>1)) ';
end else if wwDBComboBox45.Text='δ¼<CEB4><C2BC><EFBFBD>շ<EFBFBD>' then begin
if str='' then
str:=' t_op_seae.<2E><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD>÷<EFBFBD><C3B7><EFBFBD>'+''''+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> not in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>='+''''+'<27><>'+''''+')'
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD>÷<EFBFBD><C3B7><EFBFBD>'+''''+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> not in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>='+''''+'<27><>'+''''+')';
end else if wwDBComboBox45.Text='δ¼<CEB4><EFBFBD><EBB8B6>' then begin
if str='' then
str:=' t_op_seae.<2E><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD>÷<EFBFBD><C3B7><EFBFBD>'+''''+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> not in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>='+''''+'<27><>'+''''+')'
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD>÷<EFBFBD><C3B7><EFBFBD>'+''''+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> not in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>='+''''+'<27><>'+''''+')';
end else if wwDBComboBox45.Text='δ¼<CEB4><C2BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>' then begin
if str='' then
str:=' t_op_seae.<2E><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD>÷<EFBFBD><C3B7><EFBFBD>'+''''+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> not in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee)'
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD>÷<EFBFBD><C3B7><EFBFBD>'+''''+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> not in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee)';
end else if wwDBComboBox45.Text='δ<><EFBFBD><E1BDBB><EFBFBD><EFBFBD>' then begin
if str='' then
str:=' t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>״̬='+''''+'¼<><C2BC>״̬'+''''+')) '
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>״̬='+''''+'¼<><C2BC>״̬'+''''+')) ';
end else if wwDBComboBox45.Text='<27><><EFBFBD><EFBFBD><EFBFBD>ط<EFBFBD><D8B7><EFBFBD>' then begin
if str='' then
str:=' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>״̬ in ('+''''+'<27><><EFBFBD><EFBFBD><EFBFBD>ύ'+''''+','+''''+'<27><>ֹ<EFBFBD>޸<EFBFBD>'+''''+','+''''+'<27><>ֹɾ<D6B9><C9BE>'+''''+'))) '
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>״̬ in ('+''''+'<27><><EFBFBD><EFBFBD><EFBFBD>ύ'+''''+','+''''+'<27><>ֹ<EFBFBD>޸<EFBFBD>'+''''+','+''''+'<27><>ֹɾ<D6B9><C9BE>'+''''+'))) ';
end else if wwDBComboBox45.Text='δ<><CEB4><EFBFBD>˷<EFBFBD><CBB7><EFBFBD>' then begin
if str='' then
str:=' t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>״̬ in ('+''''+'<27><EFBFBD><E1BDBB><EFBFBD><EFBFBD>'+''''+','+''''+'<27><><EFBFBD><EFBFBD><EFBFBD>޸<EFBFBD>'+''''+','+''''+'<27><><EFBFBD><EFBFBD>ɾ<EFBFBD><C9BE>'+''''+'))) '
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>״̬ in ('+''''+'<27><EFBFBD><E1BDBB><EFBFBD><EFBFBD>'+''''+','+''''+'<27><><EFBFBD><EFBFBD><EFBFBD>޸<EFBFBD>'+''''+','+''''+'<27><><EFBFBD><EFBFBD>ɾ<EFBFBD><C9BE>'+''''+'))) ';
end else if wwDBComboBox45.Text='δ<><CEB4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>' then begin
if str='' then
str:=' t_op_seae.<2E><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD>÷<EFBFBD><C3B7><EFBFBD>'+''''+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'+''''+')'
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD>÷<EFBFBD><C3B7><EFBFBD>'+''''+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD>״̬<>'+''''+'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'+''''+')';
end;
end;
if wwDBComboBox49.Text<>'' then
begin
if wwDBComboBox49.Text='<27><><EFBFBD><EFBFBD>' then begin
if str='' then
str:=' where t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><>''''))'
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><>''''))';
end
else if wwDBComboBox49.Text='<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>' then begin
if str='' then
str:=' where t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where (<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>='''' or <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> is null)))'
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee where (<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>='''' or <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> is null )))';
end;
end;
if (wwDBDateTimePicker17.Text<>'') or (wwDBDateTimePicker18.Text<>'') then begin
if (seae_query_table=6) then begin
str:=query_tiaojian(1,str,'v_op_gain.<2E><><EFBFBD><EFBFBD><EFBFBD>·<EFBFBD>',wwDBComboBox90.text,wwDBDateTimePicker17.text);
str:=query_tiaojian(1,str,'v_op_gain.<2E><><EFBFBD><EFBFBD><EFBFBD>·<EFBFBD>',wwDBComboBox91.text,wwDBDateTimePicker18.text);
end else begin
str_fee:=query_tiaojian(1,str_fee,'t_ch_fee.<2E><><EFBFBD><EFBFBD><EFBFBD>·<EFBFBD>',wwDBComboBox90.text,wwDBDateTimePicker17.text);
str_fee:=query_tiaojian(1,str_fee,'t_ch_fee.<2E><><EFBFBD><EFBFBD><EFBFBD>·<EFBFBD>',wwDBComboBox91.text,wwDBDateTimePicker18.text);
if str='' then
str:=' t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee '+str_fee+')'
else
str:=str+' and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> in (select distinct <20><><EFBFBD><EFBFBD> from t_ch_fee '+str_fee+')';
end;
end;
end
else
begin
if query_wanneng_error(t_sys_query_detail)then
begin
showmessage('<27><><EFBFBD>򡯵<EFBFBD><F2A1AFB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2<EFBFBD><32><EFBFBD><EFBFBD><EFBFBD>ϣ<EFBFBD><CFA3><EFBFBD>');
exit;
end;
str:=query_wanneng(t_sys_query_detail);
end;
case seae_query_table of
1,11:
begin
if seae_query_limited<>'no'then
begin
if trim(str)='' then
begin
str:='where ('+open_data(seae_query_limited,'t_op_seae.¼<><C2BC><EFBFBD><EFBFBD>','t_op_seae.<2E><><EFBFBD><EFBFBD>Ա','t_op_seae.<2E>ͷ<EFBFBD>Ա','t_op_seae.<2E><>֤Ա','no','no')+' or t_op_seae.<2E><><EFBFBD>߲<EFBFBD><DFB2><EFBFBD>='''+employee+''' or t_op_seae.<2E><><EFBFBD>߹<EFBFBD><DFB9><EFBFBD>='''+employee+''')';
end
else
begin
str:=str+' and ('+open_data(seae_query_limited,'t_op_seae.¼<><C2BC><EFBFBD><EFBFBD>','t_op_seae.<2E><><EFBFBD><EFBFBD>Ա','t_op_seae.<2E>ͷ<EFBFBD>Ա','t_op_seae.<2E><>֤Ա','no','no')+' or t_op_seae.<2E><><EFBFBD>߲<EFBFBD><DFB2><EFBFBD>='''+employee+''' or t_op_seae.<2E><><EFBFBD>߹<EFBFBD><DFB9><EFBFBD>='''+employee+''')';
end;
end;
end;
2:
begin
if seae_query_limited<>'no'then
begin
if trim(str)='' then
begin
str:='where '+open_data(seae_query_limited,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>','no','no','no','no');
end
else
begin
str:=str+' and '+open_data(seae_query_limited,'t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>','no','no','no','no');
end;
end;
end;
3,5,6,7,8,9,10:
begin
if seae_query_limited<>'no'then
begin
if trim(str)='' then
begin
str:='where ('+open_data(seae_query_limited,'t_op_seae.¼<><C2BC><EFBFBD><EFBFBD>','t_op_seae.<2E><><EFBFBD><EFBFBD>Ա','t_op_seae.<2E>ͷ<EFBFBD>Ա','t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>','no','no')+' or t_op_seae.<2E><><EFBFBD>߲<EFBFBD><DFB2><EFBFBD>='''+employee+''' or t_op_seae.<2E><><EFBFBD>߹<EFBFBD><DFB9><EFBFBD>='''+employee+''')';
end
else
begin
str:=str+' and ('+open_data(seae_query_limited,'t_op_seae.¼<><C2BC><EFBFBD><EFBFBD>','t_op_seae.<2E><><EFBFBD><EFBFBD>Ա','t_op_seae.<2E>ͷ<EFBFBD>Ա','t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>','no','no')+' or t_op_seae.<2E><><EFBFBD>߲<EFBFBD><DFB2><EFBFBD>='''+employee+''' or t_op_seae.<2E><><EFBFBD>߹<EFBFBD><DFB9><EFBFBD>='''+employee+''')';
end;
end;
end;
101:
begin
if seae_query_limited<>'no'then
begin
if trim(str)='' then
begin
str:='where ('+open_data(seae_query_limited,'t_op_seae.¼<><C2BC><EFBFBD><EFBFBD>','t_op_seae.<2E><><EFBFBD><EFBFBD>Ա','t_op_seae.<2E>ͷ<EFBFBD>Ա','t_op_seae.<2E><>֤Ա','no','no')+' or t_op_seae.<2E><><EFBFBD>߲<EFBFBD><DFB2><EFBFBD>='''+employee+''' or t_op_seae.<2E><><EFBFBD>߹<EFBFBD><DFB9><EFBFBD>='''+employee+''' or '+open_data('0021','t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>','no','no','no','no')+')';
end
else
begin
str:=str+' and ('+open_data(seae_query_limited,'t_op_seae.¼<><C2BC><EFBFBD><EFBFBD>','t_op_seae.<2E><><EFBFBD><EFBFBD>Ա','t_op_seae.<2E>ͷ<EFBFBD>Ա','t_op_seae.<2E><>֤Ա','no','no')+' or t_op_seae.<2E><><EFBFBD>߲<EFBFBD><DFB2><EFBFBD>='''+employee+''' or t_op_seae.<2E><><EFBFBD>߹<EFBFBD><DFB9><EFBFBD>='''+employee+''' or '+open_data('0021','t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>','no','no','no','no')+')';
end;
end;
end;
end;
case seae_query_table of
1,3:
begin
str:='select *,(select top 1 <20>ͻ<EFBFBD>ȫ<EFBFBD><C8AB> from t_crm_client where <20>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD>=t_op_seae.ί<>е<EFBFBD>λ) ί<>е<EFBFBD>λȫ<CEBB><C8AB> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>=<3D><><EFBFBD><EFBFBD>'+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> from t_op_seae '
+str+')'+' order by <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> DESC,<2C><><EFBFBD><EFBFBD>,<2C><><EFBFBD><EFBFBD>,<2C><><EFBFBD><EFBFBD><E1B5A5>';
end;
2,4,11,14:
begin
str:='select *,case isnull(T_OP_SEAE.FEE2,0) when 0 then '''' else ''<27>ѷ<EFBFBD><D1B7><EFBFBD><EFBFBD><EFBFBD>'' end FEE2REF from t_op_seae '+str+default_sort(53,'t_op_seae','','desc');
end;
5:
begin
str:='SELECT t_op_seae.*,case isnull(T_OP_SEAE.FEE2,0) when 0 then '''' else ''<27>ѷ<EFBFBD><D1B7><EFBFBD><EFBFBD><EFBFBD>'' end FEE2REF '
+',t_op_gain.Ӧ<><D3A6>USD, t_op_gain.<2E><><EFBFBD><EFBFBD>USD,(t_op_gain.Ӧ<><D3A6>USD-t_op_gain.<2E><><EFBFBD><EFBFBD>USD)'
+' AS δ<><CEB4>USD,t_op_gain.Ӧ<><D3A6>RMB, t_op_gain.<2E><><EFBFBD><EFBFBD>RMB,(t_op_gain.Ӧ<><D3A6>RMB-t_op_gain.<2E><><EFBFBD><EFBFBD>RMB)'
+' AS δ<><CEB4>RMB, t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,t_op_gain.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>,(t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-t_op_gain.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,t_op_gain.Ӧ<><D3A6>USD, t_op_gain.<2E>Ѹ<EFBFBD>USD, (t_op_gain.Ӧ<><D3A6>USD-t_op_gain.<2E>Ѹ<EFBFBD>USD)'
+' AS δ<><CEB4>USD,t_op_gain.Ӧ<><D3A6>RMB, t_op_gain.<2E>Ѹ<EFBFBD>RMB,(t_op_gain.Ӧ<><D3A6>RMB- t_op_gain.<2E>Ѹ<EFBFBD>RMB)'
+' AS δ<><CEB4>RMB,t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,t_op_gain.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>,(t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-t_op_gain.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,t_op_gain.<2E><><EFBFBD><EFBFBD>USD, t_op_gain.<2E><><EFBFBD><EFBFBD>RMB, t_op_gain.ë<><C3AB><EFBFBD><EFBFBD>, t_op_gain.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,t_crm_client_class.<2E>ͻ<EFBFBD><CDBB>ȼ<EFBFBD>,(select top 1 <20>ͻ<EFBFBD>ȫ<EFBFBD><C8AB> from t_crm_client where <20>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD>=t_op_seae.ί<>е<EFBFBD>λ) ί<>е<EFBFBD>λȫ<CEBB><C8AB> '
+' FROM t_op_seae left JOIN t_op_gain ON t_op_seae.<2E><><EFBFBD><EFBFBD> = t_op_gain.<2E><><EFBFBD><EFBFBD> '
+' left join t_crm_client_class on t_op_seae.ί<>е<EFBFBD>λ=t_crm_client_class.<2E>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD> and t_crm_client_class.<2E><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><=t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD> and convert(varchar(100),t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,23)<=t_crm_client_class.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> and t_crm_client_class.״̬=''<27><><EFBFBD><EFBFBD>'' '
+str
+' order by (case when t_op_seae.<2E><><EFBFBD><EFBFBD><>t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> then '+''''+'ƴ<><C6B4><EFBFBD><EFBFBD>Ʊ'+''''+' else t_op_seae.װ<>˷<EFBFBD>ʽ end)'
+',<2C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><>˷<EFBFBD>ʽ desc,<2C><><EFBFBD><EFBFBD><E1B5A5>';
end;
101:
begin
ctnstr:='select t_op_seae_trace_ctn.* from t_op_seae_trace_ctn left join t_op_seae on (t_op_seae_trace_ctn.<2E><><EFBFBD><EFBFBD>=t_op_seae.<2E><><EFBFBD><EFBFBD>) ' + str + default_sort(53, 't_op_seae', '', 'desc');
str:='select t_op_seae_trace.*,t_op_seae.<2E><><EFBFBD><EFBFBD><E1B5A5>,t_op_seae.<2E><><EFBFBD><EFBFBD>˾,t_op_seae.ί<>е<EFBFBD>λ,t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,t_op_seae.<2E><><EFBFBD><EFBFBD><E1B5A5>,t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,t_op_seae.ж<><D0B6><EFBFBD><EFBFBD>,t_op_seae.Ŀ<>ĵ<EFBFBD>, '
+'t_op_seae.ETD from t_op_seae left join t_op_seae_trace on (t_op_seae_trace.<2E><><EFBFBD><EFBFBD>=t_op_seae.<2E><><EFBFBD><EFBFBD>) '
+str+' order by t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> DESC,t_op_seae.<2E><><EFBFBD><EFBFBD>,t_op_seae.<2E><><EFBFBD><EFBFBD>,t_op_seae.<2E><><EFBFBD><EFBFBD><E1B5A5>';
end;
end;
case seae_query_table of
1:
begin
frm_op_seae.t_op_seae.close;
frm_op_seae.t_op_seae.sql.clear;
frm_op_seae.t_op_seae.sql.add(str);
frm_op_seae.t_op_seae.Open;
if frm_op_seae.t_op_seae.IsEmpty then
begin
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
exit;
end;
ExeFileName:='\SoftWare\DongSheng\<5C><>ʤ<EFBFBD><CAA4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD>ϵͳ\Grid';
try
frm_op_seae.t_op_seae.DisableControls;
for i:=0 to frm_op_seae.dxdbgrid1.ColumnCount-1 do
begin
frm_op_seae.dxdbgrid1.Columns[i].Sorted:=csNone;
end;
with TRegIniFile.Create do
try
RootKey:=HKEY_LOCAL_MACHINE;
strsort:=ReadString(ExeFileName,'Sort','');
if strsort<>'' then
frm_op_seae.t_op_seae.Sort:=strSort;
finally
Free;
end;
finally
frm_op_seae.t_op_seae.First;
frm_op_seae.t_op_seae.EnableControls;
end;
end;
2:
begin
frm_ch_fee_seae_sales.t_op_seae.Close;
frm_ch_fee_seae_sales.t_op_seae.Parameters.ParamByName('SQLStr').value:=str;
frm_ch_fee_seae_sales.t_op_seae.Open;
if frm_ch_fee_seae_sales.t_op_seae.IsEmpty then
begin
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
exit;
end;
end;
3:
begin
frm_ch_fee_check_seae.t_op_seae.Close;
frm_ch_fee_check_seae.t_op_seae.Parameters.ParamByName('SQLStr').value:=str;
frm_ch_fee_check_seae.t_op_seae.Open;
if frm_ch_fee_check_seae.t_op_seae.IsEmpty then
begin
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
exit;
end;
end;
4:
begin
frm_op_seae_close.t_op_seae.Close;
frm_op_seae_close.t_op_seae.Parameters.ParamByName('SQLStr').value:=str;
frm_op_seae_close.t_op_seae.Open;
frm_op_seae_close.t_ch_accept.open;
frm_op_seae_close.t_ch_pay.open;
frm_op_seae_close.t_op_gain.OPEN;
if frm_op_seae_close.t_op_seae.IsEmpty then
begin
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
exit;
end;
end;
14:
begin
frm_op_seae_feeunclose.t_op_seae.Close;
frm_op_seae_feeunclose.t_op_seae.Parameters.ParamByName('SQLStr').value:=str;
frm_op_seae_feeunclose.t_op_seae.Open;
frm_op_seae_feeunclose.t_ch_accept.open;
frm_op_seae_feeunclose.t_ch_pay.open;
frm_op_seae_feeunclose.t_op_gain.OPEN;
if frm_op_seae_feeunclose.t_op_seae.IsEmpty then
begin
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
exit;
end;
end;
5:
begin
frm_rp_tai_seae.p_query_table.close;
frm_rp_tai_seae.p_query_table.Parameters.ParamByName('SQLStr').value:=str;
frm_rp_tai_seae.p_query_table.Open;
if frm_rp_tai_seae.p_query_table.IsEmpty then
begin
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
exit;
end;
end;
6:
begin
{
frm_rp_rp_seae.p_detail.close;
frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value:=
'SELECT t_op_seae.*, t_op_gain_main.Ӧ<><D3A6>USD, t_op_gain_main.<2E><><EFBFBD><EFBFBD>USD,(t_op_gain_main.Ӧ<><D3A6>USD-t_op_gain_main.<2E><><EFBFBD><EFBFBD>USD)'
+' AS δ<><CEB4>USD,t_op_gain_main.Ӧ<><D3A6>RMB, t_op_gain_main.<2E><><EFBFBD><EFBFBD>RMB,(t_op_gain_main.Ӧ<><D3A6>RMB-t_op_gain_main.<2E><><EFBFBD><EFBFBD>RMB)'
+' AS δ<><CEB4>RMB, t_op_gain_main.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,t_op_gain_main.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>,(t_op_gain_main.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-t_op_gain_main.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,t_op_gain_main.Ӧ<><D3A6>USD, t_op_gain_main.<2E>Ѹ<EFBFBD>USD, (t_op_gain_main.Ӧ<><D3A6>USD-t_op_gain_main.<2E>Ѹ<EFBFBD>USD)'
+' AS δ<><CEB4>USD,t_op_gain_main.Ӧ<><D3A6>RMB, t_op_gain_main.<2E>Ѹ<EFBFBD>RMB,(t_op_gain_main.Ӧ<><D3A6>RMB- t_op_gain_main.<2E>Ѹ<EFBFBD>RMB)'
+' AS δ<><CEB4>RMB,t_op_gain_main.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,t_op_gain_main.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>,(t_op_gain_main.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-t_op_gain_main.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,t_op_gain_main.<2E><><EFBFBD><EFBFBD>USD, t_op_gain_main.<2E><><EFBFBD><EFBFBD>RMB, t_op_gain_main.ë<><C3AB><EFBFBD><EFBFBD>, t_op_gain_main.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
+' FROM t_op_seae left JOIN t_op_gain_main ON t_op_seae.<2E><><EFBFBD><EFBFBD> = t_op_gain_main.<2E><><EFBFBD><EFBFBD> '
+str+' and t_op_seae.<2E><><EFBFBD><EFBFBD>=t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> '+default_sort(53,'t_op_seae','','desc');
rp_rp_seae_str:=str;
frm_rp_rp_seae.p_detail.Open;
}
{
frm_rp_rp_seae.p_detail.close;
frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value:=
'SELECT t_op_seae.*,case t_op_seae.װ<>˷<EFBFBD>ʽ when ''ƴ<>䵥Ʊ'' THEN (case when isnull((CASE WHEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 > t_op_seae.<2E><><EFBFBD><EFBFBD> THEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 ELSE t_op_seae.<2E><><EFBFBD><EFBFBD> END), 0)>1 then '
+' isnull((CASE WHEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 > t_op_seae.<2E><><EFBFBD><EFBFBD> THEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 ELSE t_op_seae.<2E><><EFBFBD><EFBFBD> END), 0) else 1 end) ELSE '
+' case t_op_seae.װ<>˷<EFBFBD>ʽ when ''ƴ<><C6B4><EFBFBD><EFBFBD>Ʊ'' THEN (case when isnull((CASE WHEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 > t_op_seae.<2E><><EFBFBD><EFBFBD> THEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 ELSE t_op_seae.<2E><><EFBFBD><EFBFBD> END), 0)>1 then '
+' isnull((CASE WHEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 > t_op_seae.<2E><><EFBFBD><EFBFBD> THEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 ELSE t_op_seae.<2E><><EFBFBD><EFBFBD> END), 0) else 1 end) ELSE 0 END END '
+'AS <20>ƷѶ<C6B7>, t_op_gain.Ӧ<><D3A6>USD, t_op_gain.<2E><><EFBFBD><EFBFBD>USD,(t_op_gain.Ӧ<><D3A6>USD-t_op_gain.<2E><><EFBFBD><EFBFBD>USD)'
+' AS δ<><CEB4>USD,t_op_gain.Ӧ<><D3A6>RMB, t_op_gain.<2E><><EFBFBD><EFBFBD>RMB,(t_op_gain.Ӧ<><D3A6>RMB-t_op_gain.<2E><><EFBFBD><EFBFBD>RMB)'
+' AS δ<><CEB4>RMB, t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,t_op_gain.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>,(t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-t_op_gain.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,t_op_gain.Ӧ<><D3A6>USD, t_op_gain.<2E>Ѹ<EFBFBD>USD, (t_op_gain.Ӧ<><D3A6>USD-t_op_gain.<2E>Ѹ<EFBFBD>USD)'
+' AS δ<><CEB4>USD,t_op_gain.Ӧ<><D3A6>RMB, t_op_gain.<2E>Ѹ<EFBFBD>RMB,(t_op_gain.Ӧ<><D3A6>RMB- t_op_gain.<2E>Ѹ<EFBFBD>RMB)'
+' AS δ<><CEB4>RMB,t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,t_op_gain.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>,(t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-t_op_gain.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,t_op_gain.<2E><><EFBFBD><EFBFBD>USD, t_op_gain.<2E><><EFBFBD><EFBFBD>RMB, t_op_gain.ë<><C3AB><EFBFBD><EFBFBD>, t_op_gain.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
+' FROM t_op_seae left JOIN t_op_gain ON t_op_seae.<2E><><EFBFBD><EFBFBD> = t_op_gain.<2E><><EFBFBD><EFBFBD> '
+str+default_sort(53,'t_op_seae','','desc');
rp_rp_seae_str:=str;
frm_rp_rp_seae.p_detail.Open;
}
frm_rp_rp_seae.p_detail.close;
frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value:=
'SELECT t_op_seae.*,case t_op_seae.װ<>˷<EFBFBD>ʽ when ''ƴ<>䵥Ʊ'' THEN (case when isnull((CASE WHEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 > t_op_seae.<2E><><EFBFBD><EFBFBD> THEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 ELSE t_op_seae.<2E><><EFBFBD><EFBFBD> END), 0)>1 then '
+' isnull((CASE WHEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 > t_op_seae.<2E><><EFBFBD><EFBFBD> THEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 ELSE t_op_seae.<2E><><EFBFBD><EFBFBD> END), 0) else 1 end) ELSE '
+' case t_op_seae.װ<>˷<EFBFBD>ʽ when ''ƴ<><C6B4><EFBFBD><EFBFBD>Ʊ'' THEN (case when isnull((CASE WHEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 > t_op_seae.<2E><><EFBFBD><EFBFBD> THEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 ELSE t_op_seae.<2E><><EFBFBD><EFBFBD> END), 0)>1 then '
+' isnull((CASE WHEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 > t_op_seae.<2E><><EFBFBD><EFBFBD> THEN t_op_seae.<2E><><EFBFBD><EFBFBD> / 1000 ELSE t_op_seae.<2E><><EFBFBD><EFBFBD> END), 0) else 1 end) ELSE 0 END END ';
if (wwDBDateTimePicker17.Text<>'') or (wwDBDateTimePicker18.Text<>'') then begin
frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value:=frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value+'AS <20>ƷѶ<C6B7>, v_op_gain.<2E><><EFBFBD><EFBFBD><EFBFBD>·<EFBFBD>,v_op_gain.Ӧ<><D3A6>USD, v_op_gain.<2E><><EFBFBD><EFBFBD>USD,(v_op_gain.Ӧ<><D3A6>USD-v_op_gain.<2E><><EFBFBD><EFBFBD>USD)'
+' AS δ<><CEB4>USD,v_op_gain.Ӧ<><D3A6>RMB, v_op_gain.<2E><><EFBFBD><EFBFBD>RMB,(v_op_gain.Ӧ<><D3A6>RMB-v_op_gain.<2E><><EFBFBD><EFBFBD>RMB)'
+' AS δ<><CEB4>RMB, v_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,v_op_gain.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>,(v_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-v_op_gain.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,v_op_gain.Ӧ<><D3A6>USD, v_op_gain.<2E>Ѹ<EFBFBD>USD, (v_op_gain.Ӧ<><D3A6>USD-v_op_gain.<2E>Ѹ<EFBFBD>USD)'
+' AS δ<><CEB4>USD,v_op_gain.Ӧ<><D3A6>RMB, v_op_gain.<2E>Ѹ<EFBFBD>RMB,(v_op_gain.Ӧ<><D3A6>RMB- v_op_gain.<2E>Ѹ<EFBFBD>RMB)'
+' AS δ<><CEB4>RMB,v_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,v_op_gain.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>,(v_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-v_op_gain.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,v_op_gain.<2E><><EFBFBD><EFBFBD>USD, v_op_gain.<2E><><EFBFBD><EFBFBD>RMB, v_op_gain.ë<><C3AB><EFBFBD><EFBFBD>, v_op_gain.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
+',isnull(v_op_feestatus.Ӧ<><D3A6>YF,0) Ӧ<><D3A6>YF,isnull(v_op_feestatus.Ӧ<><D3A6>YF,0) Ӧ<><D3A6>YF,t_crm_client_class.<2E>ͻ<EFBFBD><CDBB>ȼ<EFBFBD>,(select top 1 <20>ͻ<EFBFBD>ȫ<EFBFBD><C8AB> from t_crm_client where <20>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD>=t_op_seae.ί<>е<EFBFBD>λ) ί<>е<EFBFBD>λȫ<CEBB><C8AB>'
+' ,CAST(CASE WHEN CAST(t_op_seae.<2E><>TEU AS DECIMAL)=0 THEN 0 ELSE CAST(v_op_gain.ë<><C3AB><EFBFBD><EFBFBD> AS DECIMAL)/CAST(t_op_seae.<2E><>TEU AS DECIMAL) END AS decimal(10,2)) <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
+' FROM t_op_seae left JOIN v_op_gain ON t_op_seae.<2E><><EFBFBD><EFBFBD> = v_op_gain.<2E><><EFBFBD><EFBFBD> left JOIN v_op_feestatus ON t_op_seae.<2E><><EFBFBD><EFBFBD> = v_op_feestatus.<2E><><EFBFBD><EFBFBD> '
+' left join t_crm_client_class on t_op_seae.ί<>е<EFBFBD>λ=t_crm_client_class.<2E>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD> and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>=t_crm_client_class.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> '
+' and t_crm_client_class.<2E><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><=t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD> and convert(varchar(100),t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,23)<=t_crm_client_class.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> and t_crm_client_class.״̬=''<27><><EFBFBD><EFBFBD>'' '
end else begin
frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value:=frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value+'AS <20>ƷѶ<C6B7>,'''' <20><><EFBFBD><EFBFBD><EFBFBD>·<EFBFBD>,t_op_gain.Ӧ<><D3A6>USD, t_op_gain.<2E><><EFBFBD><EFBFBD>USD,(t_op_gain.Ӧ<><D3A6>USD-t_op_gain.<2E><><EFBFBD><EFBFBD>USD)'
+' AS δ<><CEB4>USD,t_op_gain.Ӧ<><D3A6>RMB, t_op_gain.<2E><><EFBFBD><EFBFBD>RMB,(t_op_gain.Ӧ<><D3A6>RMB-t_op_gain.<2E><><EFBFBD><EFBFBD>RMB)'
+' AS δ<><CEB4>RMB, t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,t_op_gain.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>,(t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-t_op_gain.<2E>ϼ<EFBFBD><CFBC><EFBFBD><EFBFBD><EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,t_op_gain.Ӧ<><D3A6>USD, t_op_gain.<2E>Ѹ<EFBFBD>USD, (t_op_gain.Ӧ<><D3A6>USD-t_op_gain.<2E>Ѹ<EFBFBD>USD)'
+' AS δ<><CEB4>USD,t_op_gain.Ӧ<><D3A6>RMB, t_op_gain.<2E>Ѹ<EFBFBD>RMB,(t_op_gain.Ӧ<><D3A6>RMB- t_op_gain.<2E>Ѹ<EFBFBD>RMB)'
+' AS δ<><CEB4>RMB,t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>,t_op_gain.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>,(t_op_gain.<2E>ϼ<EFBFBD>Ӧ<EFBFBD><D3A6>-t_op_gain.<2E>ϼ<EFBFBD><CFBC>Ѹ<EFBFBD>)'
+' AS <20>ϼ<EFBFBD>δ<EFBFBD><CEB4>,t_op_gain.<2E><><EFBFBD><EFBFBD>USD, t_op_gain.<2E><><EFBFBD><EFBFBD>RMB, t_op_gain.ë<><C3AB><EFBFBD><EFBFBD>, t_op_gain.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
+',isnull(v_op_feestatus.Ӧ<><D3A6>YF,0) Ӧ<><D3A6>YF,isnull(v_op_feestatus.Ӧ<><D3A6>YF,0) Ӧ<><D3A6>YF,t_crm_client_class.<2E>ͻ<EFBFBD><CDBB>ȼ<EFBFBD>,(select top 1 <20>ͻ<EFBFBD>ȫ<EFBFBD><C8AB> from t_crm_client where <20>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD>=t_op_seae.ί<>е<EFBFBD>λ) ί<>е<EFBFBD>λȫ<CEBB><C8AB>'
+' ,CAST(CASE WHEN CAST(t_op_seae.<2E><>TEU AS DECIMAL)=0 THEN 0 ELSE CAST(t_op_gain.ë<><C3AB><EFBFBD><EFBFBD> AS DECIMAL)/CAST(t_op_seae.<2E><>TEU AS DECIMAL) END AS decimal(10,2)) <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
+' FROM t_op_seae left JOIN t_op_gain ON t_op_seae.<2E><><EFBFBD><EFBFBD> = t_op_gain.<2E><><EFBFBD><EFBFBD> left JOIN v_op_feestatus ON t_op_seae.<2E><><EFBFBD><EFBFBD> = v_op_feestatus.<2E><><EFBFBD><EFBFBD> '
+' left join t_crm_client_class on t_op_seae.ί<>е<EFBFBD>λ=t_crm_client_class.<2E>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD> and t_op_seae.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>=t_crm_client_class.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> '
+' and t_crm_client_class.<2E><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><=t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD> and convert(varchar(100),t_op_seae.Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,23)<=t_crm_client_class.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> and t_crm_client_class.״̬=''<27><><EFBFBD><EFBFBD>'' '
end;
frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value:=frm_rp_rp_seae.p_detail.Parameters.ParamByName('SQLStr').value+str+default_sort(53,'t_op_seae','','desc');
rp_rp_seae_str:=str;
frm_rp_rp_seae.p_detail.Open;
if frm_rp_rp_seae.p_detail.IsEmpty then
begin
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
exit;
end;
end;
7:
begin
if frm_rp_zou_seae.bsSkinCheckRadioBox3.Checked then
str_date:='<27><><EFBFBD><EFBFBD><EFBFBD>ڼ<EFBFBD>'
else if frm_rp_zou_seae.bsSkinCheckRadioBox1.Checked then
str_date:='Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'
else
str_date:='<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>';
frm_rp_zou_seae.p_lirun.close;
frm_rp_zou_seae.p_lirun.SQL.Text:=
// frm_rp_zou_seae.p_lirun.Parameters.ParamByName('SQLStr').value:=
'SELECT SUBSTRING(CONVERT(char(15),t_op_seae.'+str_date+',111),1,7) AS <20>·<EFBFBD>,'
+'SUM(dbo.t_op_gain_main.ë<><C3AB><EFBFBD><EFBFBD>) AS ë<><C3AB><EFBFBD><EFBFBD>,'
+'sum(t_op_seae.<2E><>TEU) as <20><>TEU,count(t_op_seae.<2E><><EFBFBD><EFBFBD>) as Ʊ<><C6B1>'
+' FROM t_op_seae inner JOIN t_op_gain_main'
+' ON t_op_seae.<2E><><EFBFBD><EFBFBD> =t_op_gain_main.<2E><><EFBFBD><EFBFBD> '
+str
+' GROUP BY SUBSTRING(CONVERT(char(15),t_op_seae.'+str_date+',111),1,7)'
+' order by SUBSTRING(CONVERT(char(15),'+str_date+', 111), 1, 7)';
frm_rp_zou_seae.p_lirun.Open;
end;
8:
begin
fen_seae_str:=str;
end;
9:
begin
{frm_rp_fee_modify.t_ch_fee_modify.close;
frm_rp_fee_modify.a_shen_delete.close;
frm_rp_fee_modify.a_shen_modify_old.close;
frm_rp_fee_modify.a_shen_modify_new.close;
frm_rp_fee_modify.p_seae.close;
frm_rp_fee_modify.p_seae.Parameters.ParamByName('SQLStr').value:=
'SELECT t_op_seae.*, v_ch_fee_modify_sum.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> AS <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> '
+'FROM t_op_seae INNER JOIN '
+'v_ch_fee_modify_sum ON t_op_seae.<2E><><EFBFBD><EFBFBD> = v_ch_fee_modify_sum.<2E><><EFBFBD><EFBFBD> '+str+default_sort(53,'t_op_seae','','desc');
frm_rp_fee_modify.p_seae.open;
frm_rp_fee_modify.t_ch_fee_modify.open;
frm_rp_fee_modify.a_shen_delete.open;
frm_rp_fee_modify.a_shen_modify_old.open;
frm_rp_fee_modify.a_shen_modify_new.open;}
end;
10:
begin
fen_seae_ctn_str:=str;
end;
11:
begin
frm_op_seae_apply.t_op_seae.close;
frm_op_seae_apply.t_op_seae.sql.clear;
frm_op_seae_apply.t_op_seae.sql.add(str);
frm_op_seae_apply.t_op_seae.Open;
if frm_op_seae_apply.t_op_seae.IsEmpty then
begin
showmessage('û<>м<EFBFBD><D0BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
exit;
end;
end;
12:
begin
frm_rp_no_histry.sqlstr:=str;
end;
22:
begin
frm_rp_sales_profit2022.sqlstr:=str;
end;
26:
begin
frm_rp_zou_linehistry.linesqlstr:=str;
end;
101:
begin
frm_op_seae_trace.t_op_seae_trace.close;
frm_op_seae_trace.t_op_seae_trace.sql.clear;
frm_op_seae_trace.t_op_seae_trace.sql.add(str);
frm_op_seae_trace.t_op_seae_trace.Open;
frm_op_seae_trace.t_op_seae_trace_ctn.Close;
frm_op_seae_trace.t_op_seae_trace_ctn.SQL.Clear;
frm_op_seae_trace.t_op_seae_trace_ctn.SQL.Add(ctnstr);
frm_op_seae_trace.t_op_seae_trace_ctn.Open;
end;
end;
close;
end;
procedure Tfrm_op_seae_query.FormShow(Sender:TObject);
begin
wwDBComboBox15.text:='ģ<><C4A3>';
wwDBComboBox16.text:='ģ<><C4A3>';
wwDBComboBox51.text:='ģ<><C4A3>';
wwDBComboBox41.text:='ģ<><C4A3>';
wwDBComboBox42.text:='ģ<><C4A3>';
wwDBComboBox33.text:='ģ<><C4A3>';
wwDBComboBox34.text:='ģ<><C4A3>';
wwDBComboBox52.text:='ģ<><C4A3>';
wwDBComboBox4.text:='ģ<><C4A3>';
wwDBComboBox5.text:='ģ<><C4A3>';
wwDBComboBox35.text:='ģ<><C4A3>';
wwDBComboBox36.text:='ģ<><C4A3>';
wwDBComboBox37.text:='ģ<><C4A3>';
wwDBComboBox17.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox7.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox18.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox6.text:='С<><D0A1>';
wwDBComboBox46.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox47.text:='С<><D0A1>';
wwDBComboBox48.text:='ģ<><C4A3>';
wwDBComboBox11.text:='С<><D0A1>';
wwDBComboBox19.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox10.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox20.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox21.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox22.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox23.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox24.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox25.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox26.text:='ģ<><C4A3>';
wwDBComboBox27.text:='ģ<><C4A3>';
wwDBComboBox9.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox8.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox12.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox13.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox14.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox28.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox29.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox30.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox32.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox38.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox43.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox44.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox50.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox53.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox54.Text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox55.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox56.text:='С<><D0A1>';
wwDBComboBox57.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox89.text:='<27><><EFBFBD><EFBFBD>';
// wwDBComboBox49.text:='<27><><EFBFBD><EFBFBD>';
// wwDBComboBox90.Text:='<27><><EFBFBD><EFBFBD>';
frm_data_share.t_code_state.Filtered:=false;
frm_data_share.t_code_state.Filter:='ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>='+''''+'<27><><EFBFBD>˳<EFBFBD><CBB3><EFBFBD>'+'''';
frm_data_share.t_code_state.Filtered:=true;
frm_data_share.t_crm_client_ship.requery;
frm_data_share.t_crm_client_changzhan.requery;
frm_data_share.t_crm_client_truck.requery;
frm_data_share.t_crm_client_baoguan.requery;
frm_data_share.t_crm_client_weituo.requery;
frm_data_share.t_crm_client_daili.requery;
frm_data_share.t_crm_client_huodai.requery;
frm_data_share.t_code_state.first;
while not frm_data_share.t_code_state.eof do
begin
wwDBComboBox1.Items.Add(frm_data_share.t_code_state.fieldbyname('ҵ<><D2B5>״̬').asstring);
frm_data_share.t_code_state.next;
end;
wwDBComboBox1.Items.Add('ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
t_sys_queryfields.open;
t_sys_query.Parameters.ParamByName('<27><>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>').Value:='<27><><EFBFBD>˳<EFBFBD><CBB3><EFBFBD>';
t_sys_query.Parameters.ParamByName('¼<><C2BC><EFBFBD><EFBFBD>').Value:=employee;
t_sys_query.open;
t_sys_query_detail.open;
wwDBComboBox39.ItemIndex:=0;
wwDBComboBox59.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox60.text:='С<><D0A1>';
wwDBComboBox61.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox62.text:='С<><D0A1>';
wwDBComboBox63.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox64.text:='С<><D0A1>';
wwDBComboBox69.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox70.text:='С<><D0A1>';
wwDBComboBox65.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox67.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox72.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox77.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox73.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox75.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox79.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox81.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox83.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox85.text:='ģ<><C4A3>';
wwDBComboBox86.text:='ģ<><C4A3>';
wwDBComboBox87.text:='ģ<><C4A3>';
wwDBComboBox90.text:='<27><><EFBFBD><EFBFBD>';
wwDBComboBox91.text:='С<><D0A1>';
wwDBComboBox92.Text:='ģ<><C4A3>';
wwDBComboBox93.Text:='ģ<><C4A3>';
end;
procedure Tfrm_op_seae_query.RxDBLookupCombo14Change(Sender: TObject);
begin
query_str_int.text:='';
query_bit.text:='';
query_date.text:='';
if t_sys_queryfields.Locate('<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>',RxDBLookupCombo14.DisplayValue,[])then
begin
wwDBComboBox40.ItemIndex:=-1;
wwDBComboBox40.Items.Clear;
if (t_sys_queryfields.FieldByName('<27><><EFBFBD><EFBFBD>').asstring='varchar') then
begin
query_str_int.Visible:=true;
query_bit.Visible:=false;
query_date.Visible:=false;
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('ģ<><C4A3>');
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
wwDBComboBox40.ItemIndex:=2;
end;
if (t_sys_queryfields.FieldByName('<27><><EFBFBD><EFBFBD>').asstring='int') then
begin
query_str_int.Visible:=true;
query_bit.Visible:=false;
query_date.Visible:=false;
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('С<><D0A1>');
wwDBComboBox40.ItemIndex:=0;
end;
if (t_sys_queryfields.FieldByName('<27><><EFBFBD><EFBFBD>').asstring='bit') then
begin
query_str_int.Visible:=false;
query_bit.Visible:=true;
query_date.Visible:=false;
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
wwDBComboBox40.ItemIndex:=0;
end;
if (t_sys_queryfields.FieldByName('<27><><EFBFBD><EFBFBD>').asstring='date') then
begin
query_str_int.Visible:=false;
query_bit.Visible:=false;
query_date.Visible:=true;
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('<27><><EFBFBD><EFBFBD>');
wwDBComboBox40.Items.Add('С<><D0A1>');
wwDBComboBox40.ItemIndex:=0;
end;
end
else
begin
query_str_int.Visible:=false;
query_bit.Visible:=false;
query_date.Visible:=false;
end;
end;
procedure Tfrm_op_seae_query.bsSkinButton2Click(Sender: TObject);
begin
if RxDBLookupCombo14.DisplayValue='' then
begin
showmessage('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƣ<EFBFBD><C6A3><EFBFBD>');
exit;
end;
if wwDBComboBox39.ItemIndex=-1 then
begin
showmessage('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵ<EFBFBD><CFB5><EFBFBD><EFBFBD>');
exit;
end;
if wwDBComboBox40.ItemIndex=-1 then
begin
showmessage('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѯ<EFBFBD><D1AF><EFBFBD>ͣ<EFBFBD><CDA3><EFBFBD>');
exit;
end;
if query_str_int.Visible then
begin
if query_str_int.text='' then
begin
showmessage('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֵ<EFBFBD><D6B5><EFBFBD><EFBFBD>');
exit;
end;
if (t_sys_queryfields.FieldByName('<27><><EFBFBD><EFBFBD>').asstring='int') then
begin
try
strtoint(query_str_int.text);
except
showmessage('<27><><EFBFBD><EFBFBD>ֵֻ<D6B5><D6BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>֣<EFBFBD><D6A3><EFBFBD>');
exit;
end;
end;
end;
if query_bit.Visible then
begin
if query_bit.ItemIndex=-1 then
begin
showmessage('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֵ<EFBFBD><D6B5><EFBFBD><EFBFBD>');
exit;
end;
end;
if query_date.Visible then
begin
if query_date.text='' then
begin
showmessage('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֵ<EFBFBD><D6B5><EFBFBD><EFBFBD>');
exit;
end;
end;
if t_sys_query.IsEmpty then
begin
t_sys_query.Insert;
t_sys_query.post;
end;
t_sys_query_detail.Append;
t_sys_query_detail['<27><>']:=t_sys_queryfields['<27><>'];
t_sys_query_detail['<27>ֶ<EFBFBD><D6B6><EFBFBD>']:=t_sys_queryfields['<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>'];
if query_str_int.Visible then
begin
t_sys_query_detail['<27><><EFBFBD><EFBFBD>ֵ']:=query_str_int.text;
end;
if query_bit.Visible then
begin
t_sys_query_detail['<27><><EFBFBD><EFBFBD>ֵ']:=query_bit.text;
end;
if query_date.Visible then
begin
t_sys_query_detail['<27><><EFBFBD><EFBFBD>ֵ']:=query_date.text;
end;
t_sys_query_detail['<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>']:=t_sys_queryfields['<27><><EFBFBD><EFBFBD>'];
t_sys_query_detail['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵ']:=wwDBComboBox39.text;
t_sys_query_detail['<27><>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>']:=wwDBComboBox40.text;
t_sys_query_detail.post;
end;
procedure Tfrm_op_seae_query.bsSkinButton4Click(Sender: TObject);
begin
if not t_sys_query_detail.IsEmpty then
t_sys_query_detail.Delete;
end;
procedure Tfrm_op_seae_query.RxDBLookupList1DblClick(Sender: TObject);
begin
RxDBLookupCombo14.DisplayValue:=RxDBLookupList1.DisplayValue;
end;
procedure Tfrm_op_seae_query.wwDBComboBox15KeyPress(Sender: TObject;
var Key: Char);
begin
if key=#13 then
begin
key:=#0;
frm_op_seae_query.bsSkinButton1Click(Sender);
end;
end;
procedure Tfrm_op_seae_query.t_sys_queryAfterInsert(DataSet: TDataSet);
begin
t_sys_query['<27><>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>']:='<27><><EFBFBD>˳<EFBFBD><CBB3><EFBFBD>';
t_sys_query['¼<><C2BC><EFBFBD><EFBFBD>']:=employee;
t_sys_query['¼<><C2BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=date;
end;
procedure Tfrm_op_seae_query.bsSkinButton6Click(Sender: TObject);
begin
t_sys_query.Insert;
t_sys_query.post;
end;
procedure Tfrm_op_seae_query.bsSkinButton9Click(Sender: TObject);
begin
if MessageDlg('ȷʵҪɾ<D2AA><C9BE><EFBFBD>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>?',mtWarning,[mbYes,mbNo],0)<>mryes then
exit;
while not t_sys_query_detail.eof do
begin
t_sys_query_detail.Delete;
end;
if not t_sys_query.Eof then
t_sys_query.delete;
end;
procedure Tfrm_op_seae_query.t_sys_query_detailBeforePost(
DataSet: TDataSet);
begin
if t_sys_query_detail.fieldbyname('<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>').asstring='int' then
begin
try
strtoint(t_sys_query_detail.fieldbyname('<27><><EFBFBD><EFBFBD>ֵ').asstring);
except
showmessage('<27><><EFBFBD><EFBFBD>ֵֻ<D6B5><D6BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>֣<EFBFBD><D6A3><EFBFBD>');
abort;
end;
end;
if t_sys_query_detail.fieldbyname('<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>').asstring='date' then
begin
try
strtodate(t_sys_query_detail.fieldbyname('<27><><EFBFBD><EFBFBD>ֵ').asstring);
except
showmessage('<27><><EFBFBD><EFBFBD>ֵֻ<D6B5><D6BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڣ<EFBFBD><DAA3><EFBFBD>');
abort;
end;
end;
if t_sys_query_detail.fieldbyname('<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>').asstring='bit' then
begin
if (t_sys_query_detail.fieldbyname('<27><><EFBFBD><EFBFBD>ֵ').asstring<>'<27><>')
and(t_sys_query_detail.fieldbyname('<27><><EFBFBD><EFBFBD>ֵ').asstring<>'<27><>')then
begin
showmessage('<27><><EFBFBD><EFBFBD>ֵֻ<D6B5><D6BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>\<5C>񣡣<EFBFBD>');
abort;
end;
end;
if (t_sys_query_detail.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵ').asstring<>'<27><>')
and(t_sys_query_detail.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵ').asstring<>'<27><>')then
begin
showmessage('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵֻ<CFB5><D6BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>\<5C>򣡣<EFBFBD>');
abort;
end;
if (dxDBGrid1Column3.Items.IndexOf(t_sys_query_detail.fieldbyname('<27><>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>').asstring)=-1)
and (t_sys_query_detail.state<>dsinsert) then
begin
showmessage('<27><>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>ֻ<EFBFBD><D6BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'+dxDBGrid1Column3.Items.text+'<27><><EFBFBD><EFBFBD>');
abort;
end;
end;
procedure Tfrm_op_seae_query.t_sys_query_detailAfterScroll(
DataSet: TDataSet);
begin
if (t_sys_query_detail.fieldbyname('<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>').asstring='varchar') then
begin
dxDBGrid1Column3.Items.Clear;
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('ģ<><C4A3>');
end;
if (t_sys_query_detail.fieldbyname('<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>').asstring='int') then
begin
dxDBGrid1Column3.Items.Clear;
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('С<><D0A1>');
end;
if (t_sys_query_detail.fieldbyname('<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>').asstring='bit') then
begin
dxDBGrid1Column3.Items.Clear;
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
end;
if (t_sys_query_detail.fieldbyname('<27>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD><EFBFBD>').asstring='date') then
begin
dxDBGrid1Column3.Items.Clear;
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('<27><><EFBFBD><EFBFBD>');
dxDBGrid1Column3.Items.Add('С<><D0A1>');
end;
end;
end.