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.

1038 lines
36 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_aire_assistant;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, DB, ADODB, dxExEdtr, dxCntner, dxTL, dxDBCtrl, dxDBGrid,
StdCtrls, DBCtrls, RxLookup, bsSkinCtrls, Mask, wwdbedit, Wwdotdot,
Wwdbcomb, wwdbdatetimepicker, wwdblook, ComCtrls, bsSkinTabs, ExtCtrls;
type
Tfrm_op_aire_assistant = class(TForm)
t_op_aire_assistant: TADOQuery;
t_op_aire_assistant1: TDataSource;
dxDBGrid1: TdxDBGrid;
bsSkinPanel1: TbsSkinPanel;
bsSkinPanel2: TbsSkinPanel;
Label122: TLabel;
RxDBLookupCombo2: TRxDBLookupCombo;
DBMemo33: TDBMemo;
DBMemo34: TDBMemo;
RxDBLookupCombo3: TRxDBLookupCombo;
Label121: TLabel;
RxDBLookupCombo4: TRxDBLookupCombo;
Label123: TLabel;
DBMemo35: TDBMemo;
dxDBGrid1Column1: TdxDBGridMaskColumn;
dxDBGrid1Column2: TdxDBGridMaskColumn;
Label38: TLabel;
DBEdit9: TDBEdit;
Label36: TLabel;
DBEdit7: TDBEdit;
bsSkinButton9: TbsSkinButton;
bsSkinButton1: TbsSkinButton;
bsSkinButton2: TbsSkinButton;
bsSkinButton4: TbsSkinButton;
bsSkinButton3: TbsSkinButton;
bsSkinButton8: TbsSkinButton;
Label33: TLabel;
RxDBLookupCombo19: TRxDBLookupCombo;
DBMemo6: TDBMemo;
wwDBLookupCombo2: TwwDBLookupCombo;
wwDBLookupCombo5: TwwDBLookupCombo;
wwDBLookupCombo6: TwwDBLookupCombo;
wwDBLookupCombo1: TwwDBLookupCombo;
Label2: TLabel;
DBEdit1: TDBEdit;
Label25: TLabel;
Label26: TLabel;
Label164: TLabel;
Label96: TLabel;
Label97: TLabel;
Label99: TLabel;
Label100: TLabel;
Label101: TLabel;
Label102: TLabel;
Label103: TLabel;
Label104: TLabel;
Label105: TLabel;
Label106: TLabel;
Label109: TLabel;
Label110: TLabel;
wwDBDateTimePicker2: TwwDBDateTimePicker;
DBEdit13: TDBEdit;
RxDBLookupCombo11: TRxDBLookupCombo;
DBEdit30: TDBEdit;
DBEdit31: TDBEdit;
DBEdit57: TDBEdit;
DBEdit63: TDBEdit;
DBEdit70: TDBEdit;
DBEdit71: TDBEdit;
DBEdit72: TDBEdit;
DBEdit73: TDBEdit;
DBEdit74: TDBEdit;
DBEdit75: TDBEdit;
DBMemo17: TDBMemo;
DBMemo18: TDBMemo;
Label28: TLabel;
DBEdit5: TDBEdit;
Label98: TLabel;
DBEdit56: TDBEdit;
Label107: TLabel;
DBEdit76: TDBEdit;
Label108: TLabel;
DBEdit77: TDBEdit;
bsSkinPanel10: TbsSkinPanel;
lblhbl: TLabel;
bsSkinPanel4: TbsSkinPanel;
lblwt: TLabel;
bsSkinPageControl1: TbsSkinPageControl;
bsSkinTabSheet1: TbsSkinTabSheet;
bsSkinTabSheet2: TbsSkinTabSheet;
bsSkinGroupBox1: TbsSkinGroupBox;
Label88: TLabel;
Label8: TLabel;
Label74: TLabel;
DBEdit22: TDBEdit;
wwDBDateTimePicker3: TwwDBDateTimePicker;
wwDBLookupCombo3: TwwDBLookupCombo;
Label85: TLabel;
Label86: TLabel;
Label45: TLabel;
Label46: TLabel;
Label47: TLabel;
Label48: TLabel;
wwDBLookupCombo52: TwwDBLookupCombo;
DBEdit10: TDBEdit;
DBEdit12: TDBEdit;
DBEdit19: TDBEdit;
DBEdit20: TDBEdit;
wwDBLookupCombo15: TwwDBLookupCombo;
Label89: TLabel;
DBMemo9: TDBMemo;
Label3: TLabel;
wwDBComboBox1: TwwDBComboBox;
Label4: TLabel;
DBEdit2: TDBEdit;
Label5: TLabel;
wwDBComboBox2: TwwDBComboBox;
wwDBComboBox3: TwwDBComboBox;
Label6: TLabel;
DBEdit3: TDBEdit;
Label9: TLabel;
DBEdit33: TDBEdit;
Label70: TLabel;
bsSkinGroupBox3: TbsSkinGroupBox;
Label14: TLabel;
Label15: TLabel;
Label18: TLabel;
DBEdit11: TDBEdit;
wwDBDateTimePicker4: TwwDBDateTimePicker;
wwDBLookupCombo8: TwwDBLookupCombo;
bsSkinGroupBox4: TbsSkinGroupBox;
Label20: TLabel;
Label21: TLabel;
Label22: TLabel;
DBEdit16: TDBEdit;
wwDBDateTimePicker5: TwwDBDateTimePicker;
wwDBLookupCombo7: TwwDBLookupCombo;
bsSkinGroupBox2: TbsSkinGroupBox;
Label11: TLabel;
Label12: TLabel;
Label13: TLabel;
DBEdit6: TDBEdit;
wwDBDateTimePicker1: TwwDBDateTimePicker;
wwDBLookupCombo4: TwwDBLookupCombo;
Label93: TLabel;
RxDBLookupCombo9: TRxDBLookupCombo;
RxDBLookupCombo1: TRxDBLookupCombo;
Label1: TLabel;
Label7: TLabel;
RxDBLookupCombo5: TRxDBLookupCombo;
Label10: TLabel;
RxDBLookupCombo6: TRxDBLookupCombo;
Label16: TLabel;
RxDBLookupCombo15: TRxDBLookupCombo;
bsSkinPageControl2: TbsSkinPageControl;
tab1: TbsSkinTabSheet;
tab2: TbsSkinTabSheet;
DBMemo19: TDBMemo;
Label79: TLabel;
Label80: TLabel;
Label81: TLabel;
Label82: TLabel;
Label83: TLabel;
Label84: TLabel;
Bevel2: TBevel;
Bevel3: TBevel;
DBEdit38: TDBEdit;
DBEdit39: TDBEdit;
DBEdit40: TDBEdit;
DBEdit41: TDBEdit;
DBEdit42: TDBEdit;
DBEdit43: TDBEdit;
DBEdit44: TDBEdit;
DBEdit45: TDBEdit;
DBEdit46: TDBEdit;
DBEdit47: TDBEdit;
DBEdit48: TDBEdit;
DBEdit49: TDBEdit;
DBEdit50: TDBEdit;
DBEdit51: TDBEdit;
DBEdit52: TDBEdit;
DBEdit53: TDBEdit;
Label17: TLabel;
DBEdit4: TDBEdit;
Label19: TLabel;
DBEdit8: TDBEdit;
Label23: TLabel;
DBEdit14: TDBEdit;
procedure bsSkinPanel2Resize(Sender: TObject);
procedure bsSkinButton1Click(Sender: TObject);
procedure bsSkinButton2Click(Sender: TObject);
procedure bsSkinButton4Click(Sender: TObject);
procedure bsSkinButton3Click(Sender: TObject);
procedure bsSkinButton9Click(Sender: TObject);
procedure t_op_aire_assistantAfterInsert(DataSet: TDataSet);
procedure t_op_aire_assistantBeforeInsert(DataSet: TDataSet);
procedure bsSkinButton8Click(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure FormShow(Sender: TObject);
procedure DBEdit9KeyPress(Sender: TObject; var Key: Char);
procedure DBEdit7KeyPress(Sender: TObject; var Key: Char);
procedure wwDBLookupCombo49KeyPress(Sender: TObject; var Key: Char);
procedure DBEdit63KeyPress(Sender: TObject; var Key: Char);
procedure wwDBDateTimePicker2KeyPress(Sender: TObject; var Key: Char);
procedure wwDBLookupCombo3KeyPress(Sender: TObject; var Key: Char);
procedure RxDBLookupCombo2Change(Sender: TObject);
procedure RxDBLookupCombo3Change(Sender: TObject);
procedure RxDBLookupCombo4Change(Sender: TObject);
procedure RxDBLookupCombo19Change(Sender: TObject);
procedure wwDBLookupCombo2Enter(Sender: TObject);
procedure wwDBLookupCombo5Enter(Sender: TObject);
procedure wwDBLookupCombo6Enter(Sender: TObject);
procedure wwDBLookupCombo2Change(Sender: TObject);
procedure wwDBLookupCombo5Change(Sender: TObject);
procedure wwDBLookupCombo6Change(Sender: TObject);
procedure wwDBLookupCombo2Exit(Sender: TObject);
procedure wwDBLookupCombo5Exit(Sender: TObject);
procedure wwDBLookupCombo6Exit(Sender: TObject);
procedure wwDBLookupCombo2KeyPress(Sender: TObject; var Key: Char);
procedure wwDBLookupCombo5KeyPress(Sender: TObject; var Key: Char);
procedure wwDBLookupCombo6KeyPress(Sender: TObject; var Key: Char);
procedure RxDBLookupCombo2KeyPress(Sender: TObject; var Key: Char);
procedure RxDBLookupCombo3KeyPress(Sender: TObject; var Key: Char);
procedure RxDBLookupCombo4KeyPress(Sender: TObject; var Key: Char);
procedure dxDBGrid1ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
procedure t_op_aire_assistantBeforePost(DataSet: TDataSet);
procedure wwDBLookupCombo1KeyPress(Sender: TObject; var Key: Char);
procedure RxDBLookupCombo19KeyPress(Sender: TObject; var Key: Char);
procedure wwDBLookupCombo1Enter(Sender: TObject);
procedure wwDBLookupCombo1Exit(Sender: TObject);
procedure wwDBLookupCombo1Change(Sender: TObject);
procedure DBEdit7DblClick(Sender: TObject);
procedure DBEdit7Exit(Sender: TObject);
procedure DBEdit1DblClick(Sender: TObject);
procedure DBEdit1Exit(Sender: TObject);
procedure t_op_aire_assistantAfterPost(DataSet: TDataSet);
procedure wwDBLookupCombo52Change(Sender: TObject);
procedure wwDBLookupCombo15Change(Sender: TObject);
procedure t_op_aire_assistantBeforeEdit(DataSet: TDataSet);
private
updates:boolean;
procedure t_billfeecharge(Sender: TField);
procedure t_billOTfeecharge(Sender: TField);
procedure t_billfeettlcharge(Sender: TField);
procedure t_billfeedecharge(Sender: TField);
procedure t_billfeededcharge(Sender:TField);
{ Private declarations }
public
{ Public declarations }
end;
var
frm_op_aire_assistant: Tfrm_op_aire_assistant;
implementation
uses u_op_aire, u_main, my_sys_function, u_data_share,
u_code_fee_project_localair;
{$R *.dfm}
procedure Tfrm_op_aire_assistant.t_billfeecharge(Sender: TField);
begin
if sender.DataSet.State in [dsedit,dsinsert] then begin
if (not sender.DataSet.fieldbyname('<27>Ƽ<EFBFBD><C6BC><EFBFBD><EFBFBD><EFBFBD>').IsNull) and (not sender.DataSet.fieldbyname('<27>˼<EFBFBD>').IsNull) then
sender.DataSet.fieldbyname('<27>˷<EFBFBD>').Asfloat:=sender.DataSet.fieldbyname('<27>Ƽ<EFBFBD><C6BC><EFBFBD><EFBFBD><EFBFBD>').Asfloat*sender.DataSet.fieldbyname('<27>˼<EFBFBD>').Asfloat;
end;
end;
procedure Tfrm_op_aire_assistant.t_billfeedecharge(Sender: TField);
var
OT,YF,ZF:double;
begin
if sender.DataSet.State in [dsedit,dsinsert] then begin
if sender.DataSet.fieldbyname('<27><><EFBFBD><EFBFBD>Ԥ<EFBFBD><D4A4>').IsNull then
OT:=0
else
OT:=sender.DataSet.fieldbyname('<27><><EFBFBD><EFBFBD>Ԥ<EFBFBD><D4A4>').asfloat;
if sender.DataSet.fieldbyname('<27>˷<EFBFBD>Ԥ<EFBFBD><D4A4>').IsNull then
YF:=0
else
YF:=sender.DataSet.fieldbyname('<27>˷<EFBFBD>Ԥ<EFBFBD><D4A4>').asfloat;
if sender.DataSet.fieldbyname('<27>ӷ<EFBFBD>Ԥ<EFBFBD><D4A4>').IsNull then
ZF:=0
else
ZF:=sender.DataSet.fieldbyname('<27>ӷ<EFBFBD>Ԥ<EFBFBD><D4A4>').asfloat;
sender.DataSet.fieldbyname('<27>ϼ<EFBFBD>Ԥ<EFBFBD><D4A4>').Asfloat:=OT+YF+ZF;
end;
end;
procedure Tfrm_op_aire_assistant.t_billOTfeecharge(Sender: TField);
var
s:WideString;
begin
if sender.DataSet.FieldByName('<27>ӷѸ<D3B7><D1B8>ʽ').AsString='' then exit;
if sender.DataSet.FieldByName('<27>ӷѸ<D3B7><D1B8>ʽ').AsString='PP' then begin
sender.DataSet.FieldByName('<27>ӷѵ<D3B7><D1B5><EFBFBD>').AsFloat:=0;
sender.DataSet.FieldByName('<27>ӷ<EFBFBD>Ԥ<EFBFBD><D4A4>').AsFloat:=sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').AsFloat
+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').AsFloat
+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>8').AsFloat;
end;
if sender.DataSet.FieldByName('<27>ӷѸ<D3B7><D1B8>ʽ').AsString='CC' then begin
sender.DataSet.FieldByName('<27>ӷ<EFBFBD>Ԥ<EFBFBD><D4A4>').AsFloat:=0;
sender.DataSet.FieldByName('<27>ӷѵ<D3B7><D1B5><EFBFBD>').AsFloat:=sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').AsFloat
+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').AsFloat
+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').AsFloat+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>8').AsFloat;
end;
if (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').AsFloat<>0) and (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').Asstring<>'') then
S:=S+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').Asstring+':'+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').AsString+';';
if (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').AsFloat<>0) and (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').Asstring<>'') then
S:=S+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').Asstring+':'+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').AsString+';';
if (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').AsFloat<>0) and (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').Asstring<>'') then
S:=S+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').Asstring+':'+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').AsString+';';
if (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').AsFloat<>0) and (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').Asstring<>'') then
S:=S+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').Asstring+':'+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').AsString+';';
if (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').AsFloat<>0) and (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').Asstring<>'') then
S:=S+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').Asstring+':'+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').AsString+';';
if (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').AsFloat<>0) and (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').Asstring<>'') then
S:=S+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').Asstring+':'+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').AsString+';';
if (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').AsFloat<>0) and (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').Asstring<>'') then
S:=S+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').Asstring+':'+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').AsString+';';
if (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>8').AsFloat<>0) and (sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>8').Asstring<>'') then
S:=S+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>8').Asstring+':'+sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>8').AsString+';';
sender.DataSet.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').Asstring:=S;
end;
procedure Tfrm_op_aire_assistant.t_billfeettlcharge(Sender: TField);
begin
if sender.DataSet.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='' then exit;
if sender.DataSet.FieldByName('<27>˷<EFBFBD>').AsFloat=0 then exit;
if sender.DataSet.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='PP' then begin
sender.DataSet.FieldByName('<27>˷<EFBFBD>Ԥ<EFBFBD><D4A4>').AsFloat:=sender.DataSet.FieldByName('<27>˷<EFBFBD>').AsFloat;
sender.DataSet.FieldByName('<27>˷ѵ<CBB7><D1B5><EFBFBD>').AsFloat:=0;
end;
if sender.DataSet.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='CC' then begin
sender.DataSet.FieldByName('<27>˷<EFBFBD>Ԥ<EFBFBD><D4A4>').AsFloat:=0;
sender.DataSet.FieldByName('<27>˷ѵ<CBB7><D1B5><EFBFBD>').AsFloat:=sender.DataSet.FieldByName('<27>˷<EFBFBD>').AsFloat;
end;
end;
procedure Tfrm_op_aire_assistant.t_billfeededcharge(Sender: TField);
var
OT,YF,ZF:double;
begin
if sender.DataSet.State in [dsedit,dsinsert] then begin
if sender.DataSet.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').IsNull then
OT:=0
else
OT:=sender.DataSet.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').asfloat;
if sender.DataSet.fieldbyname('<27>˷ѵ<CBB7><D1B5><EFBFBD>').IsNull then
YF:=0
else
YF:=sender.DataSet.fieldbyname('<27>˷ѵ<CBB7><D1B5><EFBFBD>').asfloat;
if sender.DataSet.fieldbyname('<27>ӷѵ<D3B7><D1B5><EFBFBD>').IsNull then
ZF:=0
else
ZF:=sender.DataSet.fieldbyname('<27>ӷѵ<D3B7><D1B5><EFBFBD>').asfloat;
sender.DataSet.fieldbyname('<27>ϼƵ<CFBC><C6B5><EFBFBD>').Asfloat:=OT+YF+ZF;
end;
end;
procedure Tfrm_op_aire_assistant.bsSkinPanel2Resize(Sender: TObject);
var
i:integer;
begin
i:=round(bsSkinPanel2.width/6);
bsSkinButton9.width:=i;
bsSkinButton1.width:=i;
bsSkinButton2.width:=i;
bsSkinButton4.width:=i;
bsSkinButton3.width:=i;
end;
procedure Tfrm_op_aire_assistant.bsSkinButton1Click(Sender: TObject);
begin
t_op_aire_assistant.insert;
end;
procedure Tfrm_op_aire_assistant.bsSkinButton2Click(Sender: TObject);
begin
table_post(t_op_aire_assistant);
end;
procedure Tfrm_op_aire_assistant.bsSkinButton4Click(Sender: TObject);
begin
table_delete(t_op_aire_assistant);
end;
procedure Tfrm_op_aire_assistant.bsSkinButton3Click(Sender: TObject);
begin
table_cancel(t_op_aire_assistant);
end;
procedure Tfrm_op_aire_assistant.bsSkinButton9Click(Sender: TObject);
begin
sys_print('<27><><EFBFBD>˳<EFBFBD><CBB3>ڵ<EFBFBD>֤',2,t_op_aire_assistant1,t_op_aire_assistant.DataSource,nil,nil,nil,nil,nil,nil,nil,nil,nil);
if strtobool(get_parameters_value(308,'false')) then
begin
if t_op_aire_assistant.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='PP' then
begin
if trim(t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').AsString)='' then
begin
MessageDlg('<27><><EFBFBD><EFBFBD><EFBFBD>˴<EFBFBD><CBB4><EFBFBD><EBB2BB>Ϊ<EFBFBD>գ<EFBFBD><D5A3><EFBFBD>',mtWarning,[mbyes],0);
Exit;
end;
end
else
if t_op_aire_assistant.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='CC' then
begin
if trim(t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').AsString)='' then
begin
MessageDlg('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EBB2BB>Ϊ<EFBFBD>գ<EFBFBD><D5A3><EFBFBD>',mtWarning,[mbyes],0);
Exit;
end;
end;
InsertProjectFeeItems('<27><>','<27>ֵ<EFBFBD>',t_op_aire_assistant1);
end;
end;
procedure Tfrm_op_aire_assistant.t_op_aire_assistantAfterInsert(
DataSet: TDataSet);
var
afield : variant;
V: Integer;
begin
if application.MessageBox('<27><><EFBFBD>Ƿ<EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD><EFBFBD><EBB7A2><EFBFBD><EFBFBD>\<5C>ջ<EFBFBD><D5BB><EFBFBD>\֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD>Ϣ?','<27><><EFBFBD><EFBFBD>:',MB_OKCANCEL)=IDOK then
begin
for V:=0 to (t_op_aire_assistant.DataSource.DataSet.fieldcount-1) do
begin
try
if t_op_aire_assistant.Fields.FindField(t_op_aire_assistant.DataSource.DataSet.Fields[V].FieldName)<>nil then
t_op_aire_assistant.FieldByName(t_op_aire_assistant.DataSource.DataSet.Fields[V].FieldName).Value:=t_op_aire_assistant.DataSource.DataSet.Fields[V].Value;
except
;
end;
end;
end
else
begin
for V:=0 to (t_op_aire_assistant.DataSource.DataSet.fieldcount-1) do
begin
try
if (t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'<27><><EFBFBD><EFBFBD><EFBFBD>˴<EFBFBD><CBB4><EFBFBD>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'<27>ջ<EFBFBD><D5BB><EFBFBD>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'<27>ջ<EFBFBD><D5BB>˴<EFBFBD><CBB4><EFBFBD>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'֪ͨ<CDA8><D6AA>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'֪ͨ<CDA8>˴<EFBFBD><CBB4><EFBFBD>')then
if t_op_aire_assistant.Fields.FindField(t_op_aire_assistant.DataSource.DataSet.Fields[V].FieldName)<>nil then
t_op_aire_assistant.FieldByName(t_op_aire_assistant.DataSource.DataSet.Fields[V].FieldName).Value:=t_op_aire_assistant.DataSource.DataSet.Fields[V].Value;
except
;
end;
end;
end;
dataset.FieldByName('<27>Ƽ<EFBFBD><C6BC><EFBFBD><EFBFBD><EFBFBD>').OnChange:=t_billfeecharge;
dataset.FieldByName('<27>˼<EFBFBD>').OnChange:=t_billfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD>Ԥ<EFBFBD><D4A4>').OnChange:=t_billfeedecharge;
dataset.FieldByName('<27>˷<EFBFBD>Ԥ<EFBFBD><D4A4>').OnChange:=t_billfeedecharge;
dataset.FieldByName('<27>ӷ<EFBFBD>Ԥ<EFBFBD><D4A4>').OnChange:=t_billfeedecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').OnChange:=t_billfeededcharge;
dataset.FieldByName('<27>˷ѵ<CBB7><D1B5><EFBFBD>').OnChange:=t_billfeededcharge;
dataset.FieldByName('<27>ӷѵ<D3B7><D1B5><EFBFBD>').OnChange:=t_billfeededcharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>8').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27>ӷѸ<D3B7><D1B8>ʽ').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27>˷<EFBFBD>').OnChange:=t_billfeettlcharge;
dataset.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').OnChange:=t_billfeettlcharge;
end;
procedure Tfrm_op_aire_assistant.t_op_aire_assistantBeforeInsert(
DataSet: TDataSet);
begin
if t_op_aire_assistant.DataSource.DataSet.State=dsinsert then
t_op_aire_assistant.DataSource.DataSet.post;
if t_op_aire_assistant.DataSource.DataSet.ISEMPTY then
abort;
end;
procedure Tfrm_op_aire_assistant.bsSkinButton8Click(Sender: TObject);
var
afield : variant;
V: Integer;
begin
if t_op_aire_assistant.IsEmpty then
exit;
t_op_aire_assistant.edit;
if application.MessageBox('<27><><EFBFBD>Ƿ<EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD><EFBFBD><EBB7A2><EFBFBD><EFBFBD>\<5C>ջ<EFBFBD><D5BB><EFBFBD>\֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD>Ϣ?','<27><><EFBFBD><EFBFBD>:',MB_OKCANCEL)=IDOK then
begin
for V:=0 to (t_op_aire_assistant.DataSource.DataSet.fieldcount-1) do
begin
try
if t_op_aire_assistant.Fields.FindField(t_op_aire_assistant.DataSource.DataSet.Fields[V].FieldName)<>nil then
t_op_aire_assistant.FieldByName(t_op_aire_assistant.DataSource.DataSet.Fields[V].FieldName).Value:=t_op_aire_assistant.DataSource.DataSet.Fields[V].Value;
except
;
end;
end;
end
else
begin
for V:=0 to (t_op_aire_assistant.DataSource.DataSet.fieldcount-1) do
begin
try
if (t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'<27><><EFBFBD><EFBFBD><EFBFBD>˴<EFBFBD><CBB4><EFBFBD>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'<27>ջ<EFBFBD><D5BB><EFBFBD>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'<27>ջ<EFBFBD><D5BB>˴<EFBFBD><CBB4><EFBFBD>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'֪ͨ<CDA8><D6AA>')
and(t_op_aire_assistant.DataSource.DataSet.fields[V].FieldName<>'֪ͨ<CDA8>˴<EFBFBD><CBB4><EFBFBD>')then
if t_op_aire_assistant.Fields.FindField(t_op_aire_assistant.DataSource.DataSet.Fields[V].FieldName)<>nil then
t_op_aire_assistant.FieldByName(t_op_aire_assistant.DataSource.DataSet.Fields[V].FieldName).Value:=t_op_aire_assistant.DataSource.DataSet.Fields[V].Value;
except
;
end;
end;
end;
end;
procedure Tfrm_op_aire_assistant.FormClose(Sender: TObject;
var Action: TCloseAction);
begin
frm_op_aire_assistant.Hide;
frm_op_aire_assistant.ManualFloat(frm_op_aire_assistant.BoundsRect );
action:=cafree;
frm_op_aire_assistant:=nil;
end;
procedure Tfrm_op_aire_assistant.FormShow(Sender: TObject);
begin
t_op_aire_assistant.open;
end;
procedure Tfrm_op_aire_assistant.DBEdit9KeyPress(Sender: TObject;
var Key: Char);
begin
key_dbedit(Key,DBEdit7);
end;
procedure Tfrm_op_aire_assistant.DBEdit7KeyPress(Sender: TObject;
var Key: Char);
begin
key_dbedit(Key,DBEdit1);
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo49KeyPress(Sender: TObject;
var Key: Char);
begin
key_dbedit(Key,DBEdit63);
end;
procedure Tfrm_op_aire_assistant.DBEdit63KeyPress(Sender: TObject;
var Key: Char);
var aAdoQuery:TAdoQuery;
s,corpName,portname:string;
begin
s:='';
if strtobool(get_parameters_value(308,'false')) then
begin
if Key=#13 then
begin
if (t_op_aire_assistant.FieldByName('Ŀ<>ĸ۴<C4B8><DBB4><EFBFBD>').AsString='') then
if Trim(s)='' then
s:='Ŀ<>ĸ<EFBFBD>'
else s:=s+' Ŀ<>ĸ<EFBFBD>';
if (t_op_aire_assistant.FieldByName('һ<>̺<EFBFBD><CCBA>չ<EFBFBD>˾<EFBFBD><CBBE><EFBFBD><EFBFBD>').AsString='') then
if Trim(s)='' then
s:='<27><><EFBFBD>չ<EFBFBD>˾'
else s:=s+' <20><><EFBFBD>չ<EFBFBD>˾';
if Trim(s)<>'' then
begin
MessageDlg(s+'<27><><EFBFBD><EFBFBD>Ϊ<EFBFBD>գ<EFBFBD><D5A3><EFBFBD>',mtWarning,[mbyes],0);
Exit;
end;
if t_op_aire_assistant.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='PP' then
begin
if trim(t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').AsString)='' then
begin
MessageDlg('<27><><EFBFBD><EFBFBD><EFBFBD>˴<EFBFBD><CBB4><EFBFBD><EBB2BB>Ϊ<EFBFBD>գ<EFBFBD><D5A3><EFBFBD>',mtWarning,[mbyes],0);
Exit;
end;
end
else
if t_op_aire_assistant.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='CC' then
begin
if trim(t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').AsString)='' then
begin
MessageDlg('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EBB2BB>Ϊ<EFBFBD>գ<EFBFBD><D5A3><EFBFBD>',mtWarning,[mbyes],0);
Exit;
end;
end;
if frm_data_share.t_crm_client_hangkong1.DataSet.Locate('<27><><EFBFBD><EFBFBD>',t_op_aire_assistant.FieldByName('һ<>̺<EFBFBD><CCBA>չ<EFBFBD>˾<EFBFBD><CBBE><EFBFBD><EFBFBD>').AsString,[]) then
corpName:=frm_data_share.t_crm_client_hangkong1.DataSet.FieldByName('<27>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD>').AsString;
if frm_data_share.t_code_port_air1.DataSet.Locate('<27><><EFBFBD><EFBFBD>',t_op_aire_assistant.FieldByName('Ŀ<>ĸ۴<C4B8><DBB4><EFBFBD>').AsString,[]) then
portname:=frm_data_share.t_code_port_air1.DataSet.FieldByName('Ӣ<><D3A2><EFBFBD><EFBFBD>').AsString;
t_op_aire_assistant.edit;
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').Asstring:='<27><><EFBFBD>˷<EFBFBD>';
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').AsFloat:=0;
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').Asstring:='<27><><EFBFBD>ͷ<EFBFBD>';
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').AsFloat:=0;
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').Asstring:='<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>';
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').AsFloat:=0;
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').Asstring:='<27><>װ<EFBFBD><D7B0>';
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').AsFloat:=0;
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').Asstring:='<27><><EFBFBD>ط<EFBFBD>';
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').AsFloat:=0;
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').Asstring:='<27><><EFBFBD>շ<EFBFBD>';
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').AsFloat:=0;
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').Asstring:='ȼ<>ͷ<EFBFBD>';
t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').AsFloat:=0;
t_op_aire_assistant.post;
aAdoQuery:=CreateAdoQuery;
with aAdoQuery do
try
Close;sql.Clear;
SQL.Add('Select * from t_ch_project_localair');
SQL.Add('where <20><><EFBFBD>չ<EFBFBD>˾=:<3A><><EFBFBD>չ<EFBFBD>˾ and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>=''<27>շ<EFBFBD>''');
if t_op_aire_assistant.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='PP' then
begin
if trim(t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').AsString)='' then
begin
MessageDlg('<27><><EFBFBD><EFBFBD><EFBFBD>˴<EFBFBD><CBB4><EFBFBD><EBB2BB>Ϊ<EFBFBD>գ<EFBFBD><D5A3><EFBFBD>',mtWarning,[mbyes],0);
Exit;
end;
end
else
if t_op_aire_assistant.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').AsString='CC' then
begin
if trim(t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').AsString)='' then
begin
MessageDlg('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EBB2BB>Ϊ<EFBFBD>գ<EFBFBD><D5A3><EFBFBD>',mtWarning,[mbyes],0);
Exit;
end;
end;
Parameters.ParamByName('<27><><EFBFBD>չ<EFBFBD>˾').Value:=corpName;
Open;First;
if IsEmpty then
begin
MessageDlg('<27><><EFBFBD>չ<EFBFBD>˾:'+corpName+' <20><><EFBFBD><EFBFBD><EFBFBD>ڷ<EFBFBD><DAB7><EFBFBD>ģ<EFBFBD><C4A3>,<2C><><EFBFBD><EFBFBD> ϵͳά<CDB3><CEAC>-><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>-><3E><><EFBFBD>ں<EFBFBD><DABA>շ<EFBFBD><D5B7><EFBFBD><EFBFBD><EFBFBD>ά<EFBFBD><CEAC>',mtWarning,[mbyes],0);
Exit;
end;
if recordcount>=2 then
begin
MessageDlg('<27><><EFBFBD>չ<EFBFBD>˾:'+corpName+' <20><><EFBFBD>ڶ<EFBFBD><DAB6><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ģ<EFBFBD><C4A3>,<2C><>ѡ<EFBFBD><D1A1>һ<EFBFBD><D2BB>ģ<EFBFBD><C4A3>',mtWarning,[mbyes],0);
Exit;
end;
if recordcount=1 then
InsertProjectFee(FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').AsInteger,'<27><>',FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').AsString,'<27>ֵ<EFBFBD>',t_op_aire_assistant1);
finally
Free;
end;
end;
end;
key_wwDBDateTimePicker(Key,wwDBDateTimePicker2);
end;
procedure Tfrm_op_aire_assistant.wwDBDateTimePicker2KeyPress(
Sender: TObject; var Key: Char);
begin
key_wwDBLookupCombo(Key,wwDBLookupCombo3);
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo3KeyPress(Sender: TObject;
var Key: Char);
begin
key_wwDBLookupCombo(Key,wwDBLookupCombo52);
end;
procedure Tfrm_op_aire_assistant.RxDBLookupCombo2Change(Sender: TObject);
begin
if (t_op_aire_assistant.State=dsinsert)or(t_op_aire_assistant.State=dsedit)then
begin
if RxDBLookupCombo2.DisplayValue<>'' then
t_op_aire_assistant['<27><><EFBFBD><EFBFBD><EFBFBD>˴<EFBFBD><CBB4><EFBFBD>']:=frm_data_share.t_crm_client_shiper.fieldbyname('<27><><EFBFBD>˿<EFBFBD><CBBF>ݴ<EFBFBD><DDB4><EFBFBD>').asstring;
end;
end;
procedure Tfrm_op_aire_assistant.RxDBLookupCombo3Change(Sender: TObject);
begin
if (t_op_aire_assistant.State=dsinsert)or(t_op_aire_assistant.State=dsedit)then
begin
if RxDBLookupCombo3.DisplayValue<>'' then
t_op_aire_assistant['<27>ջ<EFBFBD><D5BB>˴<EFBFBD><CBB4><EFBFBD>']:=frm_data_share.t_crm_client_shouhuo.fieldbyname('<27><><EFBFBD>˿<EFBFBD><CBBF>ݴ<EFBFBD><DDB4><EFBFBD>').asstring;
end;
end;
procedure Tfrm_op_aire_assistant.RxDBLookupCombo4Change(Sender: TObject);
begin
if (t_op_aire_assistant.State=dsinsert)or(t_op_aire_assistant.State=dsedit)then
begin
if RxDBLookupCombo4.DisplayValue<>'' then
t_op_aire_assistant['֪ͨ<CDA8>˴<EFBFBD><CBB4><EFBFBD>']:=frm_data_share.t_crm_client_tongzhi.fieldbyname('<27><><EFBFBD>˿<EFBFBD><CBBF>ݴ<EFBFBD><DDB4><EFBFBD>').asstring;
end;
end;
procedure Tfrm_op_aire_assistant.RxDBLookupCombo19Change(Sender: TObject);
begin
if (t_op_aire_assistant.state=dsinsert)or(t_op_aire_assistant.state=dsedit)then
begin
if RxDBLookupCombo19.DisplayValue<>'' then
t_op_aire_assistant['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=frm_data_share.t_crm_client_daili['<27><><EFBFBD>˿<EFBFBD><CBBF>ݴ<EFBFBD><DDB4><EFBFBD>'];
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo2Enter(Sender: TObject);
begin
with frm_data_share do
begin
t_code_code.Filtered:=false;
t_code_code.Filter:='<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>=1';
t_code_code.Filtered:=true;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo5Enter(Sender: TObject);
begin
with frm_data_share do
begin
t_code_code.Filtered:=false;
t_code_code.Filter:='<27>ջ<EFBFBD><D5BB><EFBFBD>=1';
t_code_code.Filtered:=true;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo6Enter(Sender: TObject);
begin
with frm_data_share do
begin
t_code_code.Filtered:=false;
t_code_code.Filter:='֪ͨ<CDA8><D6AA>=1';
t_code_code.Filtered:=true;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo2Change(Sender: TObject);
begin
if frm_data_share.t_code_code.locate('<27><><EFBFBD><EFBFBD>',wwDBLookupCombo2.text,[]) then
begin
t_op_aire_assistant.edit;
t_op_aire_assistant['<27><><EFBFBD><EFBFBD><EFBFBD>˴<EFBFBD><CBB4><EFBFBD>']:=frm_data_share.t_code_code.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo5Change(Sender: TObject);
begin
if frm_data_share.t_code_code.locate('<27><><EFBFBD><EFBFBD>',wwDBLookupCombo5.text,[]) then
begin
t_op_aire_assistant.edit;
t_op_aire_assistant['<27>ջ<EFBFBD><D5BB>˴<EFBFBD><CBB4><EFBFBD>']:=frm_data_share.t_code_code.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo6Change(Sender: TObject);
begin
if frm_data_share.t_code_code.locate('<27><><EFBFBD><EFBFBD>',wwDBLookupCombo6.text,[]) then
begin
t_op_aire_assistant.edit;
t_op_aire_assistant['֪ͨ<CDA8>˴<EFBFBD><CBB4><EFBFBD>']:=frm_data_share.t_code_code.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo2Exit(Sender: TObject);
begin
wwDBLookupCombo2.Clear;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo5Exit(Sender: TObject);
begin
wwDBLookupCombo5.Clear;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo6Exit(Sender: TObject);
begin
wwDBLookupCombo6.Clear;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo2KeyPress(Sender: TObject;
var Key: Char);
begin
key_DBMemo(Key,DBMemo33);
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo5KeyPress(Sender: TObject;
var Key: Char);
begin
key_DBMemo(Key,DBMemo34);
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo6KeyPress(Sender: TObject;
var Key: Char);
begin
key_DBMemo(Key,DBMemo35);
end;
procedure Tfrm_op_aire_assistant.RxDBLookupCombo2KeyPress(Sender: TObject;
var Key: Char);
begin
key_wwDBLookupCombo(Key,wwDBLookupCombo2);
end;
procedure Tfrm_op_aire_assistant.RxDBLookupCombo3KeyPress(Sender: TObject;
var Key: Char);
begin
key_wwDBLookupCombo(Key,wwDBLookupCombo5);
end;
procedure Tfrm_op_aire_assistant.RxDBLookupCombo4KeyPress(Sender: TObject;
var Key: Char);
begin
key_wwDBLookupCombo(Key,wwDBLookupCombo6);
end;
procedure Tfrm_op_aire_assistant.dxDBGrid1ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
begin
Column_sort(Column,t_op_aire_assistant,'<27><><EFBFBD>˵<EFBFBD><CBB5><EFBFBD>');
end;
procedure Tfrm_op_aire_assistant.t_op_aire_assistantBeforePost(
DataSet: TDataSet);
begin
t_op_aire_assistant['Ӣ<>ĺ<EFBFBD><C4BA><EFBFBD>']:=date_eng(t_op_aire_assistant.fieldbyname('һ<>̿<EFBFBD><CCBF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').AsDateTime);
try
if t_op_aire_assistant.state in [dsedit] then
if (t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').Value<>t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').oldValue) or (t_op_aire_assistant.FieldByName('<27><>λ').Value<>t_op_aire_assistant.FieldByName('<27><>λ').oldValue)
or (t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').Value<>t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').oldValue) or (t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').Value<>t_op_aire_assistant.FieldByName('<27><><EFBFBD><EFBFBD>').oldValue)
or (t_op_aire_assistant.FieldByName('<27><>ͷ').Value<>t_op_aire_assistant.FieldByName('<27><>ͷ').oldValue)
then begin
updates:=true;
end;
except
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo1KeyPress(Sender: TObject;
var Key: Char);
begin
key_DBMemo(Key,DBMemo6);
end;
procedure Tfrm_op_aire_assistant.RxDBLookupCombo19KeyPress(Sender: TObject;
var Key: Char);
begin
key_wwDBLookupCombo(Key,wwDBLookupCombo1);
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo1Enter(Sender: TObject);
begin
with frm_data_share do
begin
t_code_code.Filtered:=false;
t_code_code.Filter:='<27><><EFBFBD><EFBFBD>=1';
t_code_code.Filtered:=true;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo1Exit(Sender: TObject);
begin
wwDBLookupCombo1.Clear;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo1Change(Sender: TObject);
begin
if frm_data_share.t_code_code.locate('<27><><EFBFBD><EFBFBD>',wwDBLookupCombo1.text,[]) then
begin
t_op_aire_assistant.edit;
t_op_aire_assistant['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=frm_data_share.t_code_code.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
end;
end;
procedure Tfrm_op_aire_assistant.DBEdit7DblClick(Sender: TObject);
begin
with frm_data_share.P_GetMaxHblno do begin
close;
Parameters.ParamByName('@hblhead').value:=DBEdit7.text+'%';
open;
if (not IsEmpty) and (FieldByName('<27><><EFBFBD><EFBFBD><E1B5A5>').AsString<>'') then begin
lblhbl.Caption:=FieldByName('<27><><EFBFBD><EFBFBD><E1B5A5>').AsString;
bsSkinPanel10.Visible:=true;
end;
end;
end;
procedure Tfrm_op_aire_assistant.DBEdit7Exit(Sender: TObject);
begin
bsSkinPanel10.Visible:=false;
end;
procedure Tfrm_op_aire_assistant.DBEdit1DblClick(Sender: TObject);
begin
with frm_data_share.P_GetMaxWTno do begin
close;
Parameters.ParamByName('@hblhead').value:=DBEdit1.text+'%';
open;
if (not IsEmpty) and (FieldByName('ί<>б<EFBFBD><D0B1><EFBFBD>').AsString<>'') then begin
lblwt.Caption:=FieldByName('ί<>б<EFBFBD><D0B1><EFBFBD>').AsString;
bsSkinPanel4.Visible:=true;
end;
end;
end;
procedure Tfrm_op_aire_assistant.DBEdit1Exit(Sender: TObject);
begin
bsSkinPanel4.Visible:=false;
end;
procedure Tfrm_op_aire_assistant.t_op_aire_assistantAfterPost(
DataSet: TDataSet);
begin
try
if updates then
if MessageDlg('<27><><EFBFBD><EFBFBD><EFBFBD>ء<EFBFBD><D8A1>߻<EFBFBD><DFBB><EFBFBD>ͷ<EFBFBD>ѷ<EFBFBD><D1B7><EFBFBD><EFBFBD>ı<EFBFBD>,<2C>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD><EFBFBD><E1B5A5>',mtWarning,[mbYes,mbNo],0)=mrYes then begin
t_op_aire_assistant.DataSource.DataSet.Edit;
t_op_aire_assistant.DataSource.DataSet['<27><><EFBFBD><EFBFBD>']:=t_op_aire_assistant['<27><><EFBFBD><EFBFBD>'];
t_op_aire_assistant.DataSource.DataSet['<27><>λ']:=t_op_aire_assistant['<27><>λ'];
t_op_aire_assistant.DataSource.DataSet['<27><><EFBFBD><EFBFBD>']:=t_op_aire_assistant['<27><><EFBFBD><EFBFBD>'];
t_op_aire_assistant.DataSource.DataSet['<27><><EFBFBD><EFBFBD>']:=t_op_aire_assistant['<27><><EFBFBD><EFBFBD>'];
t_op_aire_assistant.DataSource.DataSet['<27><>ͷ']:=t_op_aire_assistant['<27><>ͷ'];
frm_op_aire.airassup:=true;
t_op_aire_assistant.DataSource.DataSet.post;
updates:=false;
end;
finally
frm_op_aire.airassup:=false;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo52Change(Sender: TObject);
begin
if (t_op_aire_assistant.state=dsinsert)or(t_op_aire_assistant.state=dsedit)then
begin
if wwDBLookupCombo52.text='' then
exit;
if frm_data_share.t_code_port_air.locate('<27><><EFBFBD><EFBFBD>',wwDBLookupCombo52.text,[]) then begin
t_op_aire_assistant['ʼ<><CABC><EFBFBD><EFBFBD>']:=frm_data_share.t_code_port_air['Ӣ<><D3A2><EFBFBD><EFBFBD>'];
t_op_aire_assistant['ʼ<><CABC><EFBFBD>۹<EFBFBD><DBB9><EFBFBD>']:=frm_data_share.t_code_port_air['<27><><EFBFBD><EFBFBD>'];
end;
end;
end;
procedure Tfrm_op_aire_assistant.wwDBLookupCombo15Change(Sender: TObject);
begin
if (t_op_aire_assistant.state=dsinsert)or(t_op_aire_assistant.state=dsedit)then
begin
if wwDBLookupCombo15.text='' then
exit;
if frm_data_share.t_code_port_air.locate('<27><><EFBFBD><EFBFBD>',wwDBLookupCombo15.text,[]) then begin
t_op_aire_assistant['Ŀ<>ĸ<EFBFBD>']:=frm_data_share.t_code_port_air['Ӣ<><D3A2><EFBFBD><EFBFBD>'];
t_op_aire_assistant['Ŀ<>ĸ۹<C4B8><DBB9><EFBFBD>']:=frm_data_share.t_code_port_air['<27><><EFBFBD><EFBFBD>'];
end else begin
t_op_aire_assistant['Ŀ<>ĸ<EFBFBD>']:='';
t_op_aire_assistant['Ŀ<>ĸ۹<C4B8><DBB9><EFBFBD>']:='';
end;
end;
end;
procedure Tfrm_op_aire_assistant.t_op_aire_assistantBeforeEdit(
DataSet: TDataSet);
begin
dataset.FieldByName('<27>Ƽ<EFBFBD><C6BC><EFBFBD><EFBFBD><EFBFBD>').OnChange:=t_billfeecharge;
dataset.FieldByName('<27>˼<EFBFBD>').OnChange:=t_billfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD>Ԥ<EFBFBD><D4A4>').OnChange:=t_billfeedecharge;
dataset.FieldByName('<27>˷<EFBFBD>Ԥ<EFBFBD><D4A4>').OnChange:=t_billfeedecharge;
dataset.FieldByName('<27>ӷ<EFBFBD>Ԥ<EFBFBD><D4A4>').OnChange:=t_billfeedecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').OnChange:=t_billfeededcharge;
dataset.FieldByName('<27>˷ѵ<CBB7><D1B5><EFBFBD>').OnChange:=t_billfeededcharge;
dataset.FieldByName('<27>ӷѵ<D3B7><D1B5><EFBFBD>').OnChange:=t_billfeededcharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>3').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>4').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>5').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>6').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>8').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27>ӷѸ<D3B7><D1B8>ʽ').OnChange:=t_billOTfeecharge;
dataset.FieldByName('<27>˷<EFBFBD>').OnChange:=t_billfeettlcharge;
dataset.FieldByName('<27>˷Ѹ<CBB7><D1B8>ʽ').OnChange:=t_billfeettlcharge;
end;
end.