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.

578 lines
20 KiB
Plaintext

11 months ago
unit u_rp_truck_du;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, dxExEdtr, XPMenu, Menus, DB, ADODB, dxDBTLCl, dxGrClms,
dxDBCtrl, dxDBGrid, dxTL, dxCntner, Mask, wwdbedit, Wwdotdot, Wwdbcomb,
wwdblook, RxLookup, wwdbdatetimepicker, StdCtrls, bsSkinCtrls, ExtCtrls,
ComCtrls, bsSkinTabs;
type
Tfrm_rp_truck_du = class(TForm)
Panel2: TPanel;
Panel3: TPanel;
bsSkinButton10: TbsSkinButton;
bsSkinButton6: TbsSkinButton;
bsSkinButton9: TbsSkinButton;
bsSkinButton5: TbsSkinButton;
bsSkinPanel1: TbsSkinPanel;
Label6: TLabel;
Label3: TLabel;
Label1: TLabel;
Label2: TLabel;
Label10: TLabel;
Label5: TLabel;
Label9: TLabel;
Label8: TLabel;
Label11: TLabel;
Label30: TLabel;
Label125: TLabel;
Label13: TLabel;
Edit1: TEdit;
Edit4: TEdit;
Edit2: TEdit;
Edit3: TEdit;
wwDBDateTimePicker1: TwwDBDateTimePicker;
wwDBDateTimePicker2: TwwDBDateTimePicker;
RxDBLookupCombo2: TRxDBLookupCombo;
wwDBDateTimePicker3: TwwDBDateTimePicker;
wwDBDateTimePicker4: TwwDBDateTimePicker;
Edit7: TEdit;
wwDBLookupCombo49: TwwDBLookupCombo;
RxDBLookupCombo1: TRxDBLookupCombo;
t_op_truck_detail1: TDataSource;
PopupMenu2: TPopupMenu;
N10: TMenuItem;
N11: TMenuItem;
N14: TMenuItem;
N13: TMenuItem;
N12: TMenuItem;
N15: TMenuItem;
N16: TMenuItem;
XPMenu1: TXPMenu;
Label4: TLabel;
RxDBLookupCombo3: TRxDBLookupCombo;
Label7: TLabel;
RxDBLookupCombo4: TRxDBLookupCombo;
RxDBLookupCombo5: TRxDBLookupCombo;
Label12: TLabel;
Label14: TLabel;
RxDBLookupCombo6: TRxDBLookupCombo;
t_op_truck_detail: TADOStoredProc;
bsSkinPageControl1: TbsSkinPageControl;
bsSkinTabSheet1: TbsSkinTabSheet;
dxDBGrid1: TdxDBGrid;
dxDBGrid1Column3: TdxDBGridColumn;
dxDBGrid1Column49: TdxDBGridColumn;
dxDBGrid1Column50: TdxDBGridColumn;
dxDBGrid1Column52: TdxDBGridColumn;
dxDBGrid1Column53: TdxDBGridColumn;
dxDBGrid1Column55: TdxDBGridColumn;
dxDBGrid1Column51: TdxDBGridColumn;
dxDBGrid1Column54: TdxDBGridColumn;
dxDBGrid1Column56: TdxDBGridColumn;
dxDBGrid1Column57: TdxDBGridColumn;
dxDBGrid1Column4: TdxDBGridColumn;
dxDBGrid1Column6: TdxDBGridColumn;
dxDBGrid1Column7: TdxDBGridColumn;
dxDBGrid1Column8: TdxDBGridColumn;
dxDBGrid1Column9: TdxDBGridColumn;
dxDBGrid1Column10: TdxDBGridColumn;
dxDBGrid1Column13: TdxDBGridColumn;
dxDBGrid1Column14: TdxDBGridColumn;
dxDBGrid1Column15: TdxDBGridColumn;
dxDBGrid1Column16: TdxDBGridColumn;
dxDBGrid1Column17: TdxDBGridColumn;
dxDBGrid1Column18: TdxDBGridColumn;
dxDBGrid1Column19: TdxDBGridColumn;
dxDBGrid1Column20: TdxDBGridColumn;
dxDBGrid1Column21: TdxDBGridColumn;
dxDBGrid1Column22: TdxDBGridColumn;
dxDBGrid1Column23: TdxDBGridColumn;
dxDBGrid1Column24: TdxDBGridColumn;
dxDBGrid11: TdxDBGridColumn;
dxDBGrid12: TdxDBGridColumn;
dxDBGrid13: TdxDBGridColumn;
dxDBGrid14: TdxDBGridColumn;
dxDBGrid15: TdxDBGridColumn;
dxDBGrid16: TdxDBGridColumn;
dxDBGrid17: TdxDBGridColumn;
dxDBGrid18: TdxDBGridColumn;
dxDBGrid19: TdxDBGridColumn;
dxDBGrid110: TdxDBGridColumn;
dxDBGrid1Column35: TdxDBGridColumn;
dxDBGrid1TEU: TdxDBGridColumn;
dxDBGrid1Column37: TdxDBGridColumn;
dxDBGrid1Column38: TdxDBGridColumn;
dxDBGrid1Column39: TdxDBGridColumn;
dxDBGrid1Column40: TdxDBGridColumn;
dxDBGrid1Column41: TdxDBGridColumn;
dxDBGrid1Column42: TdxDBGridColumn;
dxDBGrid1Column43: TdxDBGridColumn;
dxDBGrid1Column44: TdxDBGridColumn;
dxDBGrid1Column45: TdxDBGridColumn;
dxDBGrid1Column46: TdxDBGridColumn;
dxDBGrid1Column47: TdxDBGridColumn;
dxDBGrid1Column48: TdxDBGridColumn;
bsSkinTabSheet2: TbsSkinTabSheet;
bsSkinTabSheet3: TbsSkinTabSheet;
t_op_truck_accept1: TDataSource;
t_op_truck_accept: TADOStoredProc;
t_op_truck_pay1: TDataSource;
t_op_truck_pay: TADOStoredProc;
t_op_truck_sum_accept1: TDataSource;
t_op_truck_sum_accept: TADOStoredProc;
t_op_truck_sum_pay1: TDataSource;
t_op_truck_sum_pay: TADOStoredProc;
t_op_truck_sum_fukuan1: TDataSource;
t_op_truck_sum_fukuan: TADOStoredProc;
Memo2: TMemo;
Memo3: TMemo;
t_op_truck_fukuan: TADOStoredProc;
t_op_truck_fukuan1: TDataSource;
bsSkinTabSheet4: TbsSkinTabSheet;
Memo1: TMemo;
dxDBGrid2: TdxDBGrid;
dxDBGridColumn3: TdxDBGridColumn;
dxDBGridColumn7: TdxDBGridColumn;
dxDBGridColumn8: TdxDBGridColumn;
dxDBGridColumn9: TdxDBGridColumn;
dxDBGrid4: TdxDBGrid;
dxDBGridColumn109: TdxDBGridColumn;
dxDBGridColumn111: TdxDBGridColumn;
dxDBGridColumn112: TdxDBGridColumn;
dxDBGridColumn113: TdxDBGridColumn;
dxDBGrid5: TdxDBGrid;
dxDBGridColumn157: TdxDBGridColumn;
dxDBGridColumn161: TdxDBGridColumn;
dxDBGridColumn162: TdxDBGridColumn;
dxDBGridColumn163: TdxDBGridColumn;
dxDBGridColumn164: TdxDBGridColumn;
dxDBGridColumn165: TdxDBGridColumn;
dxDBGridColumn166: TdxDBGridColumn;
dxDBGridColumn167: TdxDBGridColumn;
dxDBGridColumn168: TdxDBGridColumn;
dxDBGridColumn169: TdxDBGridColumn;
dxDBGridColumn170: TdxDBGridColumn;
dxDBGridColumn171: TdxDBGridColumn;
dxDBGridColumn172: TdxDBGridColumn;
dxDBGridColumn173: TdxDBGridColumn;
dxDBGridColumn174: TdxDBGridColumn;
dxDBGridColumn175: TdxDBGridColumn;
dxDBGridColumn176: TdxDBGridColumn;
dxDBGridColumn177: TdxDBGridColumn;
dxDBGridColumn178: TdxDBGridColumn;
dxDBGridColumn179: TdxDBGridColumn;
dxDBGridColumn180: TdxDBGridColumn;
dxDBGridColumn181: TdxDBGridColumn;
dxDBGridColumn182: TdxDBGridColumn;
dxDBGridColumn183: TdxDBGridColumn;
dxDBGridColumn184: TdxDBGridColumn;
dxDBGridColumn185: TdxDBGridColumn;
dxDBGridColumn186: TdxDBGridColumn;
dxDBGridColumn187: TdxDBGridColumn;
dxDBGridColumn188: TdxDBGridColumn;
dxDBGridColumn189: TdxDBGridColumn;
dxDBGridColumn190: TdxDBGridColumn;
dxDBGridColumn191: TdxDBGridColumn;
dxDBGridColumn192: TdxDBGridColumn;
dxDBGridColumn193: TdxDBGridColumn;
dxDBGridColumn194: TdxDBGridColumn;
dxDBGridColumn195: TdxDBGridColumn;
dxDBGridColumn196: TdxDBGridColumn;
dxDBGridColumn197: TdxDBGridColumn;
dxDBGridColumn198: TdxDBGridColumn;
dxDBGridColumn199: TdxDBGridColumn;
dxDBGridColumn200: TdxDBGridColumn;
dxDBGridColumn201: TdxDBGridColumn;
dxDBGridColumn202: TdxDBGridColumn;
dxDBGridColumn203: TdxDBGridColumn;
dxDBGridColumn204: TdxDBGridColumn;
dxDBGridColumn205: TdxDBGridColumn;
dxDBGridColumn206: TdxDBGridColumn;
dxDBGridColumn207: TdxDBGridColumn;
dxDBGridColumn208: TdxDBGridColumn;
dxDBGrid6: TdxDBGrid;
dxDBGridColumn214: TdxDBGridColumn;
dxDBGridColumn215: TdxDBGridColumn;
dxDBGridColumn216: TdxDBGridColumn;
dxDBGridColumn217: TdxDBGridColumn;
dxDBGrid7: TdxDBGrid;
dxDBGridColumn261: TdxDBGridColumn;
dxDBGridColumn263: TdxDBGridColumn;
dxDBGridColumn265: TdxDBGridColumn;
dxDBGridColumn266: TdxDBGridColumn;
dxDBGridColumn267: TdxDBGridColumn;
dxDBGridColumn268: TdxDBGridColumn;
dxDBGridColumn269: TdxDBGridColumn;
dxDBGridColumn271: TdxDBGridColumn;
dxDBGridColumn272: TdxDBGridColumn;
dxDBGridColumn273: TdxDBGridColumn;
dxDBGridColumn274: TdxDBGridColumn;
dxDBGridColumn275: TdxDBGridColumn;
dxDBGridColumn276: TdxDBGridColumn;
dxDBGridColumn277: TdxDBGridColumn;
dxDBGridColumn278: TdxDBGridColumn;
dxDBGridColumn279: TdxDBGridColumn;
dxDBGridColumn280: TdxDBGridColumn;
dxDBGridColumn281: TdxDBGridColumn;
dxDBGridColumn282: TdxDBGridColumn;
dxDBGridColumn283: TdxDBGridColumn;
dxDBGridColumn284: TdxDBGridColumn;
dxDBGridColumn285: TdxDBGridColumn;
dxDBGridColumn286: TdxDBGridColumn;
dxDBGridColumn287: TdxDBGridColumn;
dxDBGridColumn288: TdxDBGridColumn;
dxDBGridColumn289: TdxDBGridColumn;
dxDBGridColumn290: TdxDBGridColumn;
dxDBGridColumn291: TdxDBGridColumn;
dxDBGridColumn292: TdxDBGridColumn;
dxDBGridColumn293: TdxDBGridColumn;
dxDBGridColumn294: TdxDBGridColumn;
dxDBGridColumn295: TdxDBGridColumn;
dxDBGridColumn296: TdxDBGridColumn;
dxDBGridColumn297: TdxDBGridColumn;
dxDBGridColumn298: TdxDBGridColumn;
dxDBGridColumn299: TdxDBGridColumn;
dxDBGridColumn300: TdxDBGridColumn;
dxDBGridColumn301: TdxDBGridColumn;
dxDBGridColumn302: TdxDBGridColumn;
dxDBGridColumn303: TdxDBGridColumn;
dxDBGridColumn304: TdxDBGridColumn;
dxDBGridColumn305: TdxDBGridColumn;
dxDBGridColumn306: TdxDBGridColumn;
dxDBGridColumn307: TdxDBGridColumn;
dxDBGridColumn308: TdxDBGridColumn;
dxDBGridColumn309: TdxDBGridColumn;
dxDBGridColumn310: TdxDBGridColumn;
dxDBGridColumn311: TdxDBGridColumn;
dxDBGridColumn312: TdxDBGridColumn;
dxDBGrid3: TdxDBGrid;
dxDBGridColumn1: TdxDBGridColumn;
dxDBGridColumn4: TdxDBGridColumn;
dxDBGridColumn10: TdxDBGridColumn;
dxDBGridColumn11: TdxDBGridColumn;
dxDBGridColumn12: TdxDBGridColumn;
dxDBGridColumn13: TdxDBGridColumn;
dxDBGridColumn15: TdxDBGridColumn;
dxDBGridColumn16: TdxDBGridColumn;
dxDBGridColumn17: TdxDBGridColumn;
dxDBGridColumn18: TdxDBGridColumn;
dxDBGridColumn19: TdxDBGridColumn;
dxDBGridColumn20: TdxDBGridColumn;
dxDBGridColumn21: TdxDBGridColumn;
dxDBGridColumn22: TdxDBGridColumn;
dxDBGridColumn23: TdxDBGridColumn;
dxDBGridColumn24: TdxDBGridColumn;
dxDBGridColumn25: TdxDBGridColumn;
dxDBGridColumn26: TdxDBGridColumn;
dxDBGridColumn27: TdxDBGridColumn;
dxDBGridColumn28: TdxDBGridColumn;
dxDBGridColumn29: TdxDBGridColumn;
dxDBGridColumn30: TdxDBGridColumn;
dxDBGridColumn31: TdxDBGridColumn;
dxDBGridColumn32: TdxDBGridColumn;
dxDBGridColumn33: TdxDBGridColumn;
dxDBGridColumn34: TdxDBGridColumn;
dxDBGridColumn35: TdxDBGridColumn;
dxDBGridColumn36: TdxDBGridColumn;
dxDBGridColumn37: TdxDBGridColumn;
dxDBGridColumn38: TdxDBGridColumn;
dxDBGridColumn39: TdxDBGridColumn;
dxDBGridColumn40: TdxDBGridColumn;
dxDBGridColumn41: TdxDBGridColumn;
dxDBGridColumn42: TdxDBGridColumn;
dxDBGridColumn43: TdxDBGridColumn;
dxDBGridColumn44: TdxDBGridColumn;
dxDBGridColumn45: TdxDBGridColumn;
dxDBGridColumn46: TdxDBGridColumn;
dxDBGridColumn47: TdxDBGridColumn;
dxDBGridColumn48: TdxDBGridColumn;
dxDBGridColumn49: TdxDBGridColumn;
dxDBGridColumn50: TdxDBGridColumn;
dxDBGridColumn51: TdxDBGridColumn;
dxDBGridColumn52: TdxDBGridColumn;
dxDBGridColumn53: TdxDBGridColumn;
dxDBGridColumn54: TdxDBGridColumn;
dxDBGridColumn55: TdxDBGridColumn;
dxDBGridColumn56: TdxDBGridColumn;
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure bsSkinButton5Click(Sender: TObject);
procedure bsSkinButton10Click(Sender: TObject);
procedure bsSkinButton6Click(Sender: TObject);
procedure dxDBGrid1ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
procedure N10Click(Sender: TObject);
procedure N14Click(Sender: TObject);
procedure N12Click(Sender: TObject);
procedure N16Click(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure bsSkinButton9Click(Sender: TObject);
procedure dxDBGrid3ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
procedure dxDBGrid5ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
procedure dxDBGrid7ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
private
{ Private declarations }
public
{ Public declarations }
end;
var
frm_rp_truck_du: Tfrm_rp_truck_du;
implementation
uses u_data_share, my_sys_function, u_main;
{$R *.dfm}
procedure Tfrm_rp_truck_du.FormClose(Sender: TObject;
var Action: TCloseAction);
begin
savereggrid(dxdbgrid1,caption+'1');
savereggrid(dxdbgrid3,caption+'2');
savereggrid(dxdbgrid5,caption+'3');
savereggrid(dxdbgrid7,caption+'4');
frm_rp_truck_du.Hide;
frm_rp_truck_du.ManualFloat(frm_rp_truck_du.BoundsRect );
frm_main.freeTabs('frm_rp_truck_du');
action:=cafree;
frm_rp_truck_du:=nil;
end;
procedure Tfrm_rp_truck_du.bsSkinButton5Click(Sender: TObject);
begin
close;
end;
procedure Tfrm_rp_truck_du.bsSkinButton10Click(Sender: TObject);
var
str:widestring;
begin
if Edit1.text<>''then
str:=str+' and v_sea.ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD> like '+''''+'%'+Edit1.text+'%'+'''';
if Edit4.text<>''then
str:=str+' and v_sea.ί<>б<EFBFBD><D0B1><EFBFBD> like '+''''+'%'+Edit4.text+'%'+'''';
if Edit2.text<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD><E1B5A5> like '+''''+'%'+Edit2.text+'%'+'''';
if Edit3.text<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD><E1B5A5> like '+''''+'%'+Edit3.text+'%'+'''';
if wwDBDateTimePicker1.text<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD>>='+''''+wwDBDateTimePicker1.text+'''';
if wwDBDateTimePicker2.text<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD><='+''''+wwDBDateTimePicker2.text+'''';
if wwDBDateTimePicker3.text<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD><EFBFBD>ڼ<EFBFBD>>='+''''+wwDBDateTimePicker3.text+'''';
if wwDBDateTimePicker4.text<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD><EFBFBD>ڼ<EFBFBD><='+''''+wwDBDateTimePicker4.text+'''';
if RxDBLookupCombo2.DisplayValues[1]<>''then
str:=str+' and v_sea.ί<>е<EFBFBD>λ='+''''+RxDBLookupCombo2.DisplayValues[1]+'''';
if RxDBLookupCombo6.DisplayValues[0]<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>='+''''+RxDBLookupCombo6.DisplayValues[0]+'''';
if wwDBLookupCombo49.text<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD> like '+''''+'%'+wwDBLookupCombo49.text+'%'+'''';
if Edit7.text<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD> like '+''''+'%'+Edit7.text+'%'+'''';
if RxDBLookupCombo1.DisplayValues[0]<>''then
str:=str+' and v_sea.<2E><><EFBFBD><EFBFBD>Ա='+''''+RxDBLookupCombo1.DisplayValues[0]+'''';
if RxDBLookupCombo3.DisplayValues[1]<>''then
str:=str+' and t_ch_fee_truck.<2E>շѿͻ<D1BF>='+''''+RxDBLookupCombo3.DisplayValues[1]+'''';
if RxDBLookupCombo4.DisplayValues[1]<>''then
str:=str+' and t_ch_fee_truck.<2E><><EFBFBD>ѿͻ<D1BF>='+''''+RxDBLookupCombo4.DisplayValues[1]+'''';
if RxDBLookupCombo5.DisplayValues[1]<>''then
str:=str+' and t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>='+''''+RxDBLookupCombo5.DisplayValues[1]+'''';
if str<>''then
str:=' where '+copy(str,5,length(str)-4);
t_op_truck_detail.Close;
t_op_truck_detail.Parameters.ParamByName('SQLStr').value:=Memo1.text+str
+'order by ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD> desc';
t_op_truck_detail.open;
t_op_truck_accept.Close;
t_op_truck_accept.Parameters.ParamByName('SQLStr').value:=Memo2.text
+'t_ch_fee_truck.<2E>շѿͻ<D1BF>,t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E>շѽ<D5B7><D1BD><EFBFBD>) as <20>շѽ<D5B7><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>) as <20><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD><EFBFBD>) as <20><><EFBFBD><EFBFBD> '
+'FROM v_sea INNER JOIN t_ch_fee_truck ON v_sea.<2E><><EFBFBD><EFBFBD>=t_ch_fee_truck.<2E><><EFBFBD><EFBFBD> '
+str+' '
+Memo3.text
+'t_ch_fee_truck.<2E>շѿͻ<D1BF>,t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> order by v_sea.ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD> desc';
t_op_truck_accept.open;
t_op_truck_pay.Close;
t_op_truck_pay.Parameters.ParamByName('SQLStr').value:=Memo2.text
+'t_ch_fee_truck.<2E><><EFBFBD>ѿͻ<D1BF>,t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E>շѽ<D5B7><D1BD><EFBFBD>) as <20>շѽ<D5B7><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>) as <20><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD><EFBFBD>) as <20><><EFBFBD><EFBFBD> '
+'FROM v_sea INNER JOIN t_ch_fee_truck ON v_sea.<2E><><EFBFBD><EFBFBD>=t_ch_fee_truck.<2E><><EFBFBD><EFBFBD> '
+str+' '
+Memo3.text
+'t_ch_fee_truck.<2E><><EFBFBD>ѿͻ<D1BF>,t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> order by v_sea.ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD> desc';
t_op_truck_pay.open;
t_op_truck_fukuan.Close;
t_op_truck_fukuan.Parameters.ParamByName('SQLStr').value:=Memo2.text
+'t_ch_fee_truck.<2E>շѿͻ<D1BF>,t_ch_fee_truck.<2E><><EFBFBD>ѿͻ<D1BF>,t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E>շѽ<D5B7><D1BD><EFBFBD>) as <20>շѽ<D5B7><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>) as <20><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD><EFBFBD>) as <20><><EFBFBD><EFBFBD> '
+'FROM v_sea INNER JOIN t_ch_fee_truck ON v_sea.<2E><><EFBFBD><EFBFBD>=t_ch_fee_truck.<2E><><EFBFBD><EFBFBD> '
+str+' '
+Memo3.text
+'t_ch_fee_truck.<2E>շѿͻ<D1BF>,t_ch_fee_truck.<2E><><EFBFBD>ѿͻ<D1BF>,t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> order by v_sea.ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD> desc';
t_op_truck_fukuan.open;
t_op_truck_sum_accept.Close;
t_op_truck_sum_accept.Parameters.ParamByName('SQLStr').value:=
'select t_ch_fee_truck.<2E>շѿͻ<D1BF>,'
+'sum(t_ch_fee_truck.<2E>շѽ<D5B7><D1BD><EFBFBD>) as <20>շѽ<D5B7><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>) as <20><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD><EFBFBD>) as <20><><EFBFBD><EFBFBD> '
+'FROM v_sea INNER JOIN t_ch_fee_truck ON v_sea.<2E><><EFBFBD><EFBFBD>=t_ch_fee_truck.<2E><><EFBFBD><EFBFBD> '
+str
+' group by t_ch_fee_truck.<2E>շѿͻ<D1BF> order by t_ch_fee_truck.<2E>շѿͻ<D1BF>';
t_op_truck_sum_accept.open;
t_op_truck_sum_pay.Close;
t_op_truck_sum_pay.Parameters.ParamByName('SQLStr').value:=
'select t_ch_fee_truck.<2E><><EFBFBD>ѿͻ<D1BF>,'
+'sum(t_ch_fee_truck.<2E>շѽ<D5B7><D1BD><EFBFBD>) as <20>շѽ<D5B7><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>) as <20><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD><EFBFBD>) as <20><><EFBFBD><EFBFBD> '
+'FROM v_sea INNER JOIN t_ch_fee_truck ON v_sea.<2E><><EFBFBD><EFBFBD>=t_ch_fee_truck.<2E><><EFBFBD><EFBFBD> '
+str
+' group by t_ch_fee_truck.<2E><><EFBFBD>ѿͻ<D1BF> order by t_ch_fee_truck.<2E><><EFBFBD>ѿͻ<D1BF>';
t_op_truck_sum_pay.open;
t_op_truck_sum_fukuan.Close;
t_op_truck_sum_fukuan.Parameters.ParamByName('SQLStr').value:=
'select t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E>շѽ<D5B7><D1BD><EFBFBD>) as <20>շѽ<D5B7><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>) as <20><><EFBFBD>ѽ<EFBFBD><D1BD><EFBFBD>,'
+'sum(t_ch_fee_truck.<2E><><EFBFBD><EFBFBD>) as <20><><EFBFBD><EFBFBD> '
+'FROM v_sea INNER JOIN t_ch_fee_truck ON v_sea.<2E><><EFBFBD><EFBFBD>=t_ch_fee_truck.<2E><><EFBFBD><EFBFBD> '
+str
+' group by t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> order by t_ch_fee_truck.<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>';
t_op_truck_sum_fukuan.open;
end;
procedure Tfrm_rp_truck_du.bsSkinButton6Click(Sender: TObject);
begin
Edit1.text:='';
Edit4.text:='';
Edit2.text:='';
Edit3.text:='';
wwDBDateTimePicker1.text:='';
wwDBDateTimePicker2.text:='';
RxDBLookupCombo2.ClearValue;
wwDBDateTimePicker3.text:='';
wwDBDateTimePicker4.text:='';
wwDBLookupCombo49.text:='';
Edit7.text:='';
RxDBLookupCombo1.ClearValue;
RxDBLookupCombo6.ClearValue;
RxDBLookupCombo3.ClearValue;
RxDBLookupCombo4.ClearValue;
RxDBLookupCombo5.ClearValue;
end;
procedure Tfrm_rp_truck_du.dxDBGrid1ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
begin
Column_sort_pro(Column,t_op_truck_detail,'ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
end;
procedure Tfrm_rp_truck_du.N10Click(Sender: TObject);
begin
if bsSkinTabSheet1.Showing then
update_grid_view_no(dxdbgrid1)
else if bsSkinTabSheet2.Showing then
update_grid_view_no(dxdbgrid3)
else if bsSkinTabSheet3.Showing then
update_grid_view_no(dxdbgrid5)
else if bsSkinTabSheet4.Showing then
update_grid_view_no(dxdbgrid7);
end;
procedure Tfrm_rp_truck_du.N14Click(Sender: TObject);
begin
if bsSkinTabSheet1.Showing then
update_grid_view_all(dxdbgrid1)
else if bsSkinTabSheet2.Showing then
update_grid_view_all(dxdbgrid3)
else if bsSkinTabSheet3.Showing then
update_grid_view_all(dxdbgrid5)
else if bsSkinTabSheet4.Showing then
update_grid_view_all(dxdbgrid7);
end;
procedure Tfrm_rp_truck_du.N12Click(Sender: TObject);
begin
if bsSkinTabSheet1.Showing then
update_grid(dxdbgrid1,24)
else if bsSkinTabSheet2.Showing then
update_grid(dxdbgrid3,107)
else if bsSkinTabSheet3.Showing then
update_grid(dxdbgrid5,108)
else if bsSkinTabSheet4.Showing then
update_grid(dxdbgrid7,109);
end;
procedure Tfrm_rp_truck_du.N16Click(Sender: TObject);
begin
if bsSkinTabSheet1.Showing then
grid_save_xls(dxdbgrid1)
else if bsSkinTabSheet2.Showing then
grid_save_xls(dxdbgrid3)
else if bsSkinTabSheet3.Showing then
grid_save_xls(dxdbgrid5)
else if bsSkinTabSheet4.Showing then
grid_save_xls(dxdbgrid7);
end;
procedure Tfrm_rp_truck_du.FormShow(Sender: TObject);
begin
loadreggrid(dxdbgrid1,true,caption+'1');
loadreggrid(dxdbgrid3,true,caption+'2');
loadreggrid(dxdbgrid5,true,caption+'3');
loadreggrid(dxdbgrid7,true,caption+'4');
end;
procedure Tfrm_rp_truck_du.bsSkinButton9Click(Sender: TObject);
begin
sys_print('<27><><EFBFBD>˳<EFBFBD><CBB3><EFBFBD><EFBFBD>ɳ<EFBFBD>ͳ<EFBFBD><CDB3>',2,nil,nil,nil,nil,t_op_truck_detail1,
t_op_truck_accept1,t_op_truck_pay1,t_op_truck_fukuan1,
t_op_truck_sum_accept1,t_op_truck_sum_pay1,t_op_truck_sum_fukuan1);
end;
procedure Tfrm_rp_truck_du.dxDBGrid3ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
begin
Column_sort_pro(Column,t_op_truck_accept,'ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
end;
procedure Tfrm_rp_truck_du.dxDBGrid5ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
begin
Column_sort_pro(Column,t_op_truck_pay,'ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
end;
procedure Tfrm_rp_truck_du.dxDBGrid7ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
begin
Column_sort_pro(Column,t_op_truck_fukuan,'ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
end;
end.