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.

900 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_info_price_release;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, dxExEdtr, DB, ADODB, DBCtrls, StdCtrls, Mask, wwdbedit,
Wwdotdot, Wwdbcomb, bsSkinCtrls, wwdblook, RxLookup, dxDBTLCl, dxGrClms,
dxDBCtrl, dxDBGrid, dxTL, dxCntner, ExtCtrls, wwdbdatetimepicker,
bsdbctrls;
type
Tfrm_info_price_release = class(TForm)
Panel1: TPanel;
bsSkinButton7: TbsSkinButton;
bsSkinButton6: TbsSkinButton;
bsSkinButton1: TbsSkinButton;
bsSkinButton2: TbsSkinButton;
bsSkinButton3: TbsSkinButton;
bsSkinButton4: TbsSkinButton;
bsSkinButton8: TbsSkinButton;
bsSkinButton9: TbsSkinButton;
bsSkinButton11: TbsSkinButton;
bsSkinButton5: TbsSkinButton;
bsSkinButton10: TbsSkinButton;
Notebook1: TNotebook;
bsSkinGroupBox2: TbsSkinGroupBox;
Label14: TLabel;
Label3: TLabel;
Label4: TLabel;
Label5: TLabel;
DBEdit31: TDBEdit;
DBEdit1: TDBEdit;
DBEdit2: TDBEdit;
DBEdit3: TDBEdit;
t_price_release: TADOQuery;
t_price_release1: TDataSource;
t_price_ship: TADOQuery;
t_price_ship1: TDataSource;
t_price_release_port: TADOQuery;
t_price_release_port1: TDataSource;
Label1: TLabel;
DBEdit11: TDBEdit;
bsSkinGroupBox3: TbsSkinGroupBox;
dxDBGrid1: TdxDBGrid;
dxDBGrid1Column4: TdxDBGridColumn;
dxDBGrid1Column3: TdxDBGridColumn;
dxDBGrid1Column2: TdxDBGridColumn;
dxDBGrid1Column5: TdxDBGridColumn;
dxDBGrid120GP: TdxDBGridColumn;
dxDBGrid140GP: TdxDBGridColumn;
dxDBGrid140HQ: TdxDBGridColumn;
dxDBGrid140RF: TdxDBGridColumn;
dxDBGrid140RH: TdxDBGridColumn;
dxDBGrid145HQ: TdxDBGridColumn;
dxDBGrid1Column20: TdxDBGridColumn;
dxDBGrid1Column21: TdxDBGridColumn;
dxDBGrid1Column37: TdxDBGridColumn;
dxDBGrid1Column38: TdxDBGridColumn;
dxDBGrid1Column39: TdxDBGridColumn;
dxDBGrid1Column22: TdxDBGridColumn;
bsSkinButton14: TbsSkinButton;
bsSkinButton15: TbsSkinButton;
dxDBGrid3: TdxDBGrid;
dxDBGrid3Column1: TdxDBGridMaskColumn;
dxDBGrid3Column2: TdxDBGridMaskColumn;
dxDBGrid3Column3: TdxDBGridDateColumn;
dxDBGrid3Column4: TdxDBGridMaskColumn;
dxDBGrid3Column5: TdxDBGridMaskColumn;
bsSkinButton16: TbsSkinButton;
Label6: TLabel;
wwDBDateTimePicker2: TwwDBDateTimePicker;
Label9: TLabel;
wwDBDateTimePicker1: TwwDBDateTimePicker;
dxDBGrid1Column36: TdxDBGridColumn;
dxDBGrid1Column41: TdxDBGridColumn;
dxDBGrid1Column42: TdxDBGridColumn;
dxDBGrid3Column6: TdxDBGridColumn;
bsSkinGroupBox4: TbsSkinGroupBox;
bsSkinDBCheckRadioBox2: TbsSkinDBCheckRadioBox;
bsSkinDBCheckRadioBox3: TbsSkinDBCheckRadioBox;
bsSkinDBCheckRadioBox4: TbsSkinDBCheckRadioBox;
bsSkinDBCheckRadioBox11: TbsSkinDBCheckRadioBox;
bsSkinDBCheckRadioBox9: TbsSkinDBCheckRadioBox;
bsSkinDBCheckRadioBox1: TbsSkinDBCheckRadioBox;
v_price_release_port: TADOQuery;
v_price_release_port1: TDataSource;
spl1: TSplitter;
bsSkinGroupBox1: TbsSkinGroupBox;
dxDBGrid2: TdxDBGrid;
dxDBGridMaskColumn1: TdxDBGridMaskColumn;
dxDBGridMaskColumn2: TdxDBGridMaskColumn;
dxDBGridMaskColumn3: TdxDBGridMaskColumn;
dxDBGridMaskColumn4: TdxDBGridMaskColumn;
dxDBGridMaskColumn5: TdxDBGridMaskColumn;
dxDBGridMaskColumn6: TdxDBGridMaskColumn;
dxDBGridMaskColumn7: TdxDBGridMaskColumn;
dxDBGridMaskColumn8: TdxDBGridMaskColumn;
dxDBGridMaskColumn9: TdxDBGridMaskColumn;
dxDBGridMaskColumn10: TdxDBGridMaskColumn;
dxDBGridMaskColumn11: TdxDBGridMaskColumn;
dxDBGrid1Column12: TdxDBGridMaskColumn;
dxDBGrid1Column13: TdxDBGridMaskColumn;
dxDBGrid1Column14: TdxDBGridMaskColumn;
dxDBGrid1Column15: TdxDBGridMaskColumn;
dxDBGrid1Column16: TdxDBGridMaskColumn;
dxDBGrid1Column17: TdxDBGridMaskColumn;
dxDBGrid1Column18: TdxDBGridMaskColumn;
dxDBGrid1Column19: TdxDBGridMaskColumn;
dxDBGridMaskColumn12: TdxDBGridMaskColumn;
dxDBGridMaskColumn13: TdxDBGridMaskColumn;
dxDBGridMaskColumn14: TdxDBGridMaskColumn;
dxDBGrid1Column23: TdxDBGridMaskColumn;
dxDBGrid1Column24: TdxDBGridMaskColumn;
dxDBGrid1Column25: TdxDBGridMaskColumn;
dxDBGrid1Column26: TdxDBGridMaskColumn;
dxDBGrid1Column27: TdxDBGridMaskColumn;
dxDBGrid1Column28: TdxDBGridMaskColumn;
dxDBGrid1Column29: TdxDBGridMaskColumn;
dxDBGrid1Column30: TdxDBGridMaskColumn;
dxDBGrid1Column31: TdxDBGridMaskColumn;
dxDBGrid1Column32: TdxDBGridMaskColumn;
dxDBGrid1Column33: TdxDBGridMaskColumn;
dxDBGrid1Column34: TdxDBGridMaskColumn;
dxDBGrid1Column35: TdxDBGridMaskColumn;
dxDBGridMaskColumn15: TdxDBGridMaskColumn;
dxDBGridMaskColumn16: TdxDBGridMaskColumn;
dxDBGridMaskColumn17: TdxDBGridMaskColumn;
dxDBGridMaskColumn18: TdxDBGridMaskColumn;
dxDBGrid1Column40: TdxDBGridMaskColumn;
dxDBGridDateColumn1: TdxDBGridDateColumn;
dxDBGridDateColumn2: TdxDBGridDateColumn;
dxDBGridMaskColumn19: TdxDBGridMaskColumn;
dxDBGridDateColumn3: TdxDBGridDateColumn;
dxDBGrid1Column45: TdxDBGridColumn;
dxDBGrid1Column46: TdxDBGridColumn;
dxDBGrid1Column47: TdxDBGridColumn;
dxDBGrid1Column48: TdxDBGridColumn;
dxDBGrid1Column49: TdxDBGridColumn;
dxDBGrid1Column50: TdxDBGridColumn;
dxDBGrid1Column51: TdxDBGridColumn;
dxDBGrid1Column52: TdxDBGridColumn;
dxDBGrid1Column53: TdxDBGridColumn;
dxDBGrid1Column54: TdxDBGridColumn;
dxDBGrid2Column55: TdxDBGridColumn;
dxDBGrid2Column56: TdxDBGridColumn;
dxDBGrid2Column57: TdxDBGridColumn;
bsSkinPanel1: TbsSkinPanel;
Label8: TLabel;
Label10: TLabel;
Label2: TLabel;
Label7: TLabel;
Label27: TLabel;
Label30: TLabel;
Label12: TLabel;
RxDBLookupCombo3: TRxDBLookupCombo;
wwDBLookupCombo2: TwwDBLookupCombo;
bsSkinButton12: TbsSkinButton;
bsSkinButton13: TbsSkinButton;
wwDBComboBox3: TwwDBComboBox;
RxDBLookupCombo4: TRxDBLookupCombo;
RxDBLookupCombo8: TRxDBLookupCombo;
Edit7: TEdit;
wwDBLookupCombo5: TwwDBLookupCombo;
procedure bsSkinButton9Click(Sender: TObject);
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure bsSkinButton11Click(Sender: TObject);
procedure bsSkinButton8Click(Sender: TObject);
procedure bsSkinButton4Click(Sender: TObject);
procedure bsSkinButton10Click(Sender: TObject);
procedure bsSkinButton2Click(Sender: TObject);
procedure bsSkinButton3Click(Sender: TObject);
procedure bsSkinButton5Click(Sender: TObject);
procedure t_price_releaseAfterInsert(DataSet: TDataSet);
procedure FormShow(Sender: TObject);
procedure Panel1Resize(Sender: TObject);
procedure t_price_releaseBeforeEdit(DataSet: TDataSet);
procedure bsSkinButton12Click(Sender: TObject);
procedure bsSkinButton13Click(Sender: TObject);
procedure FormCloseQuery(Sender: TObject; var CanClose: Boolean);
procedure bsSkinButton14Click(Sender: TObject);
procedure bsSkinButton15Click(Sender: TObject);
procedure t_price_release_portAfterInsert(DataSet: TDataSet);
procedure bsSkinButton16Click(Sender: TObject);
procedure bsSkinButton1Click(Sender: TObject);
procedure DBEdit31KeyPress(Sender: TObject; var Key: Char);
procedure DBEdit11KeyPress(Sender: TObject; var Key: Char);
procedure DBEdit1KeyPress(Sender: TObject; var Key: Char);
procedure DBEdit2KeyPress(Sender: TObject; var Key: Char);
procedure dxDBGrid3ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
procedure dxDBGrid3Column6CustomDraw(Sender: TObject; ACanvas: TCanvas;
ARect: TRect; ANode: TdxTreeListNode; AColumn: TdxDBTreeListColumn;
const AText: String; AFont: TFont; var AColor: TColor; ASelected,
AFocused: Boolean; var ADone: Boolean);
procedure bsSkinButton7Click(Sender: TObject);
procedure bsSkinButton6Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
frm_info_price_release: Tfrm_info_price_release;
implementation
uses u_main, u_data_share, my_sys_function, u_info_price_release_query;
{$R *.dfm}
procedure Tfrm_info_price_release.bsSkinButton9Click(Sender: TObject);
begin
close;
end;
procedure Tfrm_info_price_release.FormClose(Sender: TObject;
var Action: TCloseAction);
begin
frm_info_price_release.Hide;
frm_info_price_release.ManualFloat(frm_info_price_release.BoundsRect );
frm_main.freeTabs('frm_info_price_release');
action:=cafree;
frm_info_price_release:=nil;
end;
procedure Tfrm_info_price_release.bsSkinButton11Click(Sender: TObject);
begin
table_post(t_price_release);
end;
procedure Tfrm_info_price_release.bsSkinButton8Click(Sender: TObject);
begin
table_cancel(t_price_release);
end;
procedure Tfrm_info_price_release.bsSkinButton4Click(Sender: TObject);
begin
table_delete(t_price_release);
end;
procedure Tfrm_info_price_release.bsSkinButton10Click(Sender: TObject);
var
answer:TModalResult;
begin
if bsSkinButton10.Caption='<27><EFBFBD>޸<EFBFBD>' then
begin
Notebook1.PageIndex:=1;
bsSkinButton10.Caption:='<27><><EFBFBD><EFBFBD><EFBFBD>б<EFBFBD>';
end
else
begin
if (t_price_release.State=dsinsert)or(t_price_release.State=dsedit) then
BEGIN
answer:=messagedlg( '<27><><EFBFBD><EFBFBD><EFBFBD>Ѿ<EFBFBD><D1BE>޸ģ<DEB8><C4A3>Ƿ񱣴棿',mtWarning,mbYesNoCancel,0);
if answer=mrYes then
begin
t_price_release.post;
end;
if answer=mrNo then
begin
t_price_release.cancel;
end;
if answer=mrCancel then
begin
exit;
end;
END;
Notebook1.PageIndex:=0;
bsSkinButton10.Caption:='<27><EFBFBD>޸<EFBFBD>';
end;
end;
procedure Tfrm_info_price_release.bsSkinButton2Click(Sender: TObject);
begin
t_price_release.insert;
Notebook1.PageIndex:=1;
bsSkinButton10.Caption:='<27><><EFBFBD><EFBFBD><EFBFBD>б<EFBFBD>';
end;
procedure Tfrm_info_price_release.bsSkinButton3Click(Sender: TObject);
var
afield : variant;
i: Integer;
begin
if t_price_release.IsEmpty then
exit;
afield := vararraycreate([0,t_price_release.fieldcount-1],varvariant);
for i := 0 to (t_price_release.fieldcount-1) do
begin
afield[i] :=t_price_release.fields[i].value ;
end;
t_price_release.append;
for i := 1 to (t_price_release.fieldcount-1) do
begin
if t_price_release.fields[i].FieldName<>'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>' then
t_price_release.fields[i].value := afield[i] ;
end;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=employee;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=date;
t_price_release['<27><><EFBFBD><EFBFBD>״̬']:='<27><><EFBFBD>ӷ<EFBFBD><D3B7><EFBFBD>';
Notebook1.PageIndex:=1;
bsSkinButton10.Caption:='<27><><EFBFBD><EFBFBD><EFBFBD>б<EFBFBD>';
showmessage('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ӳɹ<D3B3><C9B9><EFBFBD><EFBFBD><EFBFBD>');
end;
procedure Tfrm_info_price_release.bsSkinButton5Click(Sender: TObject);
begin
sys_print('<27>˼۷<CBBC><DBB7><EFBFBD><EFBFBD><EFBFBD>ӡ',2,t_price_release1,frm_data_share.t_code_price_ctn1,nil,nil,t_price_release_port1,nil,nil,nil,nil,nil,nil);
end;
procedure Tfrm_info_price_release.t_price_releaseAfterInsert(
DataSet: TDataSet);
begin
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=employee;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=date;
t_price_release['<27><><EFBFBD><EFBFBD>״̬']:='<27><><EFBFBD>ӷ<EFBFBD><D3B7><EFBFBD>';
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾']:=0;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾']:=0;
t_price_release['<27><><EFBFBD><EFBFBD>Ŀ<EFBFBD>ĸ<EFBFBD>']:=0;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=0;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=0;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=0;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=0;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>۲<EFBFBD><DBB2><EFBFBD>']:=0;
t_price_release['<27><><EFBFBD><EFBFBD>ί<EFBFBD>е<EFBFBD>λ']:=0;
t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ص<EFBFBD>']:=0;
end;
procedure Tfrm_info_price_release.FormShow(Sender: TObject);
begin
t_price_release.sql.Clear;
t_price_release.sql.add('SELECT top 100 * FROM t_price_release ');
t_price_release.sql.add('where '+open_data('3007','<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>','no','no','no','no'));
t_price_release.sql.add(' order by <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
t_price_release.open;
t_price_release_port.open;
frm_data_share.t_code_price_ctn.requery;
if frm_data_share.t_code_price_ctn.IsEmpty then
exit;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>1').asstring)<>'' then
begin
dxDBGrid120GP.Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>1').asstring);
dxDBGrid120GP.Visible:=true;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>2').asstring)<>'' then
begin
dxDBGrid140GP.Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>2').asstring);
dxDBGrid140GP.Visible:=true;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>3').asstring)<>'' then
begin
dxDBGrid140HQ.Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>3').asstring);
dxDBGrid140HQ.Visible:=true;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>4').asstring)<>'' then
begin
dxDBGrid140RF.Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>4').asstring);
dxDBGrid140RF.Visible:=true;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>5').asstring)<>'' then
begin
dxDBGrid140RH.Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>5').asstring);
dxDBGrid140RH.Visible:=true;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>6').asstring)<>'' then
begin
dxDBGrid145HQ.Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>6').asstring);
dxDBGrid145HQ.Visible:=true;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>7').asstring)<>'' then
begin
dxDBGrid1Column20.Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>7').asstring);
dxDBGrid1Column20.Visible:=true;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>8').asstring)<>'' then
begin
dxDBGrid1Column21.Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>8').asstring);
dxDBGrid1Column21.Visible:=true;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>1').asstring)<>'' then
begin
dxDBGrid2.Bands[1].Visible:=true;
dxDBGrid2.Bands[1].Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>1').asstring);
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>2').asstring)<>'' then
begin
dxDBGrid2.Bands[2].Visible:=true;
dxDBGrid2.Bands[2].Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>2').asstring);
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>3').asstring)<>'' then
begin
dxDBGrid2.Bands[3].Visible:=true;
dxDBGrid2.Bands[3].Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>3').asstring);
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>4').asstring)<>'' then
begin
dxDBGrid2.Bands[4].Visible:=true;
dxDBGrid2.Bands[4].Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>4').asstring);
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>5').asstring)<>'' then
begin
dxDBGrid2.Bands[5].Visible:=true;
dxDBGrid2.Bands[5].Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>5').asstring);
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>6').asstring)<>'' then
begin
dxDBGrid2.Bands[6].Visible:=true;
dxDBGrid2.Bands[6].Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>6').asstring);
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>7').asstring)<>'' then
begin
dxDBGrid2.Bands[7].Visible:=true;
dxDBGrid2.Bands[7].Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>7').asstring);
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>8').asstring)<>'' then
begin
dxDBGrid2.Bands[8].Visible:=true;
dxDBGrid2.Bands[8].Caption:=trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>8').asstring);
end;
wwDBComboBox3.Items.Clear;
frm_data_share.t_sys_code_data.Filtered:=false;
frm_data_share.t_sys_code_data.Filter:='<27><><EFBFBD><EFBFBD>='+''''+'3006'+'''';
frm_data_share.t_sys_code_data.Filtered:=true;
if frm_data_share.t_sys_code_data.IsEmpty then
exit;
if frm_data_share.t_sys_code_data.Locate('ְԱ','ȫ<><C8AB><EFBFBD>׼<EFBFBD>',[])then
begin
if frm_data_share.t_sys_code_data.fieldbyname('<27>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>').asboolean then
begin
dxDBGridMaskColumn6.Visible:=true;
dxDBGridMaskColumn7.Visible:=true;
dxDBGridMaskColumn8.Visible:=true;
dxDBGridMaskColumn9.Visible:=true;
dxDBGridMaskColumn10.Visible:=true;
dxDBGridMaskColumn11.Visible:=true;
dxDBGrid1Column45.Visible:=true;
dxDBGrid1Column50.Visible:=true;
wwDBComboBox3.Items.Add('ȫ<><C8AB><EFBFBD>׼<EFBFBD>');
end;
end;
if frm_data_share.t_sys_code_data.Locate('ְԱ','<27>׼۹<D7BC><DBB9><EFBFBD>',[])then
begin
if frm_data_share.t_sys_code_data.fieldbyname('<27>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>').asboolean then
begin
dxDBGrid1Column12.Visible:=true;
dxDBGrid1Column13.Visible:=true;
dxDBGrid1Column14.Visible:=true;
dxDBGrid1Column15.Visible:=true;
dxDBGrid1Column16.Visible:=true;
dxDBGrid1Column17.Visible:=true;
dxDBGrid1Column46.Visible:=true;
dxDBGrid1Column51.Visible:=true;
end;
end;
if frm_data_share.t_sys_code_data.Locate('ְԱ','һ<><D2BB><EFBFBD>ۼ<EFBFBD>',[])then
begin
if frm_data_share.t_sys_code_data.fieldbyname('<27>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>').asboolean then
begin
dxDBGrid1Column18.Visible:=true;
dxDBGrid1Column19.Visible:=true;
dxDBGridMaskColumn12.Visible:=true;
dxDBGridMaskColumn13.Visible:=true;
dxDBGridMaskColumn14.Visible:=true;
dxDBGrid1Column23.Visible:=true;
dxDBGrid1Column47.Visible:=true;
dxDBGrid1Column52.Visible:=true;
wwDBComboBox3.Items.Add('һ<><D2BB><EFBFBD>ۼ<EFBFBD>');
end;
end;
if frm_data_share.t_sys_code_data.Locate('ְԱ','<27><><EFBFBD><EFBFBD><EFBFBD>ۼ<EFBFBD>',[])then
begin
if frm_data_share.t_sys_code_data.fieldbyname('<27>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>').asboolean then
begin
dxDBGrid1Column24.Visible:=true;
dxDBGrid1Column25.Visible:=true;
dxDBGrid1Column26.Visible:=true;
dxDBGrid1Column27.Visible:=true;
dxDBGrid1Column28.Visible:=true;
dxDBGrid1Column29.Visible:=true;
dxDBGrid1Column48.Visible:=true;
dxDBGrid1Column53.Visible:=true;
wwDBComboBox3.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD>ۼ<EFBFBD>');
end;
end;
if frm_data_share.t_sys_code_data.Locate('ְԱ','<27><><EFBFBD><EFBFBD><EFBFBD>ۼ<EFBFBD>',[])then
begin
if frm_data_share.t_sys_code_data.fieldbyname('<27>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>').asboolean then
begin
dxDBGrid1Column30.Visible:=true;
dxDBGrid1Column31.Visible:=true;
dxDBGrid1Column32.Visible:=true;
dxDBGrid1Column33.Visible:=true;
dxDBGrid1Column34.Visible:=true;
dxDBGrid1Column35.Visible:=true;
dxDBGrid1Column49.Visible:=true;
dxDBGrid1Column54.Visible:=true;
wwDBComboBox3.Items.Add('<27><><EFBFBD><EFBFBD><EFBFBD>ۼ<EFBFBD>');
end;
end;
end;
procedure Tfrm_info_price_release.Panel1Resize(Sender: TObject);
var
i:integer;
begin
i:=round(Panel1.Width/11);
bsSkinButton5.Width:=i;
bsSkinButton7.Width:=i;
bsSkinButton6.Width:=i;
bsSkinButton2.Width:=i;
bsSkinButton3.Width:=i;
bsSkinButton10.Width:=i;
bsSkinButton11.Width:=i;
bsSkinButton4.Width:=i;
bsSkinButton8.Width:=i;
bsSkinButton1.Width:=i;
end;
procedure Tfrm_info_price_release.t_price_releaseBeforeEdit(
DataSet: TDataSet);
begin
if do_data('3007',t_price_release.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').asstring,'','','','','')=false then
begin
showmessage('<27>Բ<EFBFBD><D4B2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȩ<EFBFBD>޸Ĵ<DEB8><C4B4><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
abort;
end;
if t_price_release.fieldbyname('<27><><EFBFBD><EFBFBD>״̬').asstring='ȷ<>Ϸ<EFBFBD><CFB7><EFBFBD>' then begin
showmessage('<27>˼<EFBFBD><CBBC>ѷ<EFBFBD><D1B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>޸Ĵ<DEB8><C4B4><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
abort;
end;
end;
procedure Tfrm_info_price_release.bsSkinButton12Click(Sender: TObject);
begin
t_price_ship.close;
t_price_ship.sql.clear;
t_price_ship.sql.add('SELECT * FROM t_price_ship where <20><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>>=getdate()');
if wwDBLookupCombo2.text<>''then
t_price_ship.sql.add(' and Ŀ<>ĸ<EFBFBD> like '+''''+'%'+wwDBLookupCombo2.text+'%'+'''');
if RxDBLookupCombo3.DisplayValue<>''then
t_price_ship.sql.add(' and <20><><EFBFBD><EFBFBD>˾='+''''+RxDBLookupCombo3.DisplayValueS[1]+'''');
if RxDBLookupCombo4.DisplayValue<>''then
t_price_ship.sql.add(' and <20><><EFBFBD><EFBFBD>='+''''+RxDBLookupCombo4.DisplayValueS[1]+'''');
if wwDBLookupCombo5.Text<>''then
t_price_ship.sql.add(' and <20><><EFBFBD><EFBFBD>='+''''+wwDBLookupCombo5.Text+'''');
if RxDBLookupCombo8.DisplayValue<>''then
t_price_ship.sql.add(' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾='+''''+RxDBLookupCombo8.DisplayValues[1]+'''');
if Edit7.text<>''then
t_price_ship.sql.add(' and Ŀ<>ĸ<EFBFBD> like '+''''+'%'+Edit7.text+'%'+'''');
t_price_ship.sql.add('order by <20>˼۱<CBBC><DBB1><EFBFBD>');
t_price_ship.open;
end;
procedure Tfrm_info_price_release.bsSkinButton13Click(Sender: TObject);
var
i:integer;
begin
if wwDBComboBox3.ItemIndex=-1 then
begin
showmessage('<27><>ѡ<EFBFBD><D1A1>Ҫ<EFBFBD><D2AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ۼۼ<DBBC><DBBC>𣡣<EFBFBD>');
exit;
end;
if t_price_ship.Active=false then
exit;
if t_price_ship.IsEmpty then
exit;
if t_price_release.IsEmpty then
exit;
if t_price_release.state=dsinsert then
t_price_release.post;
if dxDBGrid2.SelectedCount>=1 then
begin
for i:=0 to dxDBGrid2.SelectedCount-1 do
begin
t_price_ship.GotoBookmark(pointer(dxDBGrid2.selectedrows[i]));
t_price_release_port.insert;
t_price_release_port['<27><><EFBFBD><EFBFBD>1']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'1').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>2']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'2').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>3']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'3').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>4']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'4').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>5']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'5').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>6']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'6').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>7']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'7').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>8']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'8').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>˾']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>˾').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
t_price_release_port['<27><><EFBFBD>˸<EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD>˸<EFBFBD>').asstring;
t_price_release_port['Ŀ<>ĸ<EFBFBD>']:=t_price_ship.fieldbyname('Ŀ<>ĸ<EFBFBD>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').asstring;
t_price_release_port['<27>˼۱<CBBC><DBB1><EFBFBD>']:=t_price_ship.fieldbyname('<27>˼۱<CBBC><DBB1><EFBFBD>').asinteger;
t_price_release_port.post;
end;
exit;
end;
t_price_release_port.insert;
t_price_release_port['<27><><EFBFBD><EFBFBD>1']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'1').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>2']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'2').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>3']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'3').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>4']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'4').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>5']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'5').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>6']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'6').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>7']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'7').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>8']:=t_price_ship.fieldbyname(wwDBComboBox3.text+'8').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>˾']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>˾').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
t_price_release_port['<27><><EFBFBD>˸<EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD>˸<EFBFBD>').asstring;
t_price_release_port['Ŀ<>ĸ<EFBFBD>']:=t_price_ship.fieldbyname('Ŀ<>ĸ<EFBFBD>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1>').asstring;
t_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=t_price_ship.fieldbyname('<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>').asstring;
t_price_release_port['<27>˼۱<CBBC><DBB1><EFBFBD>']:=t_price_ship.fieldbyname('<27>˼۱<CBBC><DBB1><EFBFBD>').asinteger;
t_price_release_port.post;
end;
procedure Tfrm_info_price_release.FormCloseQuery(Sender: TObject;
var CanClose: Boolean);
begin
CanClose:=frm_close_query(t_price_release);
end;
procedure Tfrm_info_price_release.bsSkinButton14Click(Sender: TObject);
begin
if t_price_release_port.state=dsedit then
t_price_release_port.post;
end;
procedure Tfrm_info_price_release.bsSkinButton15Click(Sender: TObject);
begin
table_delete(t_price_release_port);
end;
procedure Tfrm_info_price_release.t_price_release_portAfterInsert(
DataSet: TDataSet);
begin
t_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=t_price_release['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'];
t_price_release_port['<27><><EFBFBD><EFBFBD>1']:=0;
t_price_release_port['<27><><EFBFBD><EFBFBD>2']:=0;
t_price_release_port['<27><><EFBFBD><EFBFBD>3']:=0;
t_price_release_port['<27><><EFBFBD><EFBFBD>4']:=0;
t_price_release_port['<27><><EFBFBD><EFBFBD>5']:=0;
t_price_release_port['<27><><EFBFBD><EFBFBD>6']:=0;
t_price_release_port['<27><><EFBFBD><EFBFBD>7']:=0;
t_price_release_port['<27><><EFBFBD><EFBFBD>8']:=0;
end;
procedure Tfrm_info_price_release.bsSkinButton16Click(Sender: TObject);
begin
table_cancel(t_price_release_port);
end;
procedure Tfrm_info_price_release.bsSkinButton1Click(Sender: TObject);
begin
try
frm_info_price_release_query:=tfrm_info_price_release_query.Create (self);
frm_info_price_release_query.ShowModal;
finally
frm_info_price_release_query.Free;
end;
end;
procedure Tfrm_info_price_release.DBEdit31KeyPress(Sender: TObject;
var Key: Char);
begin
key_DBEdit(Key,DBEdit11);
end;
procedure Tfrm_info_price_release.DBEdit11KeyPress(Sender: TObject;
var Key: Char);
begin
key_DBEdit(Key,DBEdit1);
end;
procedure Tfrm_info_price_release.DBEdit1KeyPress(Sender: TObject;
var Key: Char);
begin
key_DBEdit(Key,DBEdit2);
end;
procedure Tfrm_info_price_release.DBEdit2KeyPress(Sender: TObject;
var Key: Char);
begin
key_DBEdit(Key,DBEdit3);
end;
procedure Tfrm_info_price_release.dxDBGrid3ColumnSorting(Sender: TObject;
Column: TdxDBTreeListColumn; var Allow: Boolean);
begin
Column_sort(Column,t_price_release,'<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
end;
procedure Tfrm_info_price_release.dxDBGrid3Column6CustomDraw(
Sender: TObject; ACanvas: TCanvas; ARect: TRect; ANode: TdxTreeListNode;
AColumn: TdxDBTreeListColumn; const AText: String; AFont: TFont;
var AColor: TColor; ASelected, AFocused: Boolean; var ADone: Boolean);
begin
if ANode.Strings[dxDBGrid3Column6.Index]='ȷ<>Ϸ<EFBFBD><CFB7><EFBFBD>' then
AColor:=clRed
else if ANode.Strings[dxDBGrid3Column6.Index]='ȡ<><C8A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>' then
AColor:=clGreen
else
AColor:=clWhite;
AFont.Color:=clblack;
end;
procedure Tfrm_info_price_release.bsSkinButton7Click(Sender: TObject);
var
aQuery:TADOQuery;
subStr,Str,cntrstr:String;
sl:tStrings;
begin
v_price_release_port.Close;
v_price_release_port.Open;
v_price_release_port.First;
if MessageDlg('<27><><EFBFBD><EFBFBD><EFBFBD>˼ۣ<CBBC>ϵͳ<CFB5><CDB3><EFBFBD>Զ<EFBFBD><D4B6><EFBFBD><EFBFBD><EFBFBD>ϵͳ<CFB5>з<EFBFBD><D0B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˷<EFBFBD><CBB7><EFBFBD>Ϣ<EFBFBD><CFA2>ȷʵҪ<CAB5><D2AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD>?',mtConfirmation,[mbYes,mbNo],0)=mrYes then begin
frm_main.db.BeginTrans;
try
try
aQuery:=CreateAdoQuery;
with aQuery do begin
while not v_price_release_port.Eof do begin
subStr:='';
if (v_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾']=1) and (v_price_release_port['<27><><EFBFBD><EFBFBD>˾'].asString<>'') then begin
subStr:=subStr+' and <20><><EFBFBD><EFBFBD>˾='+''''+v_price_release_port['<27><><EFBFBD><EFBFBD>˾'].asString+'''';
end;
if (v_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾']=1) and (v_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾'].asString<>'') then begin
subStr:=subStr+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾='+''''+v_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˾'].asString+'''';
end;
if (v_price_release_port['<27><><EFBFBD><EFBFBD>Ŀ<EFBFBD>ĸ<EFBFBD>']=1) and (v_price_release_port['Ŀ<>ĸ<EFBFBD>'].asString<>'') then begin
subStr:=subStr+' and Ŀ<>ĸ<EFBFBD> like '+''''+'%'+v_price_release_port['Ŀ<>ĸ<EFBFBD>'].asString+'%'+'''';
end;
if (v_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ص<EFBFBD>']=1) and (v_price_release_port['Ŀ<>ĸ<EFBFBD>'].asString<>'') then begin
subStr:=subStr+' and <20><><EFBFBD><EFBFBD><EFBFBD>ص<EFBFBD> like '+''''+'%'+v_price_release_port['Ŀ<>ĸ<EFBFBD>'].asString+'%'+'''';
end;
if (v_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']=1) and (v_price_release_port['<27><><EFBFBD><EFBFBD>'].asString<>'') then begin
subStr:=subStr+' and <20><><EFBFBD><EFBFBD>='+''''+v_price_release_port['Ŀ<>ĸ<EFBFBD>'].asString+'''';
end;
if (v_price_release_port['<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']=1) and (v_price_release_port['<27><><EFBFBD><EFBFBD>'].asString<>'') then begin
subStr:=subStr+' and <20><><EFBFBD><EFBFBD> like '+''''+'%'+v_price_release_port['<27><><EFBFBD><EFBFBD>'].asString+'%'+'''';
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>1').asstring)<>'' then
begin
if StrToFloatDef(v_price_release_port['<27><><EFBFBD><EFBFBD>1'],0)<>0 then begin
cntrstr:=frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>1').asstring;
CntrStr:=StringReplace(CntrStr,'''','''''',[rfReplaceAll]);
Str:='Update t_ch_fee set <20><><EFBFBD><EFBFBD>='+v_price_release_port['<27><><EFBFBD><EFBFBD>1']+' where ϵͳ<CFB5><CDB3><EFBFBD><EFBFBD>=1 and <20><><EFBFBD><EFBFBD>״̬=''¼<><C2BC>״̬'' and <20><>׼='+''''+trim(CntrStr)+''''
+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>>='+''''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'])+''''+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><='''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>ֹ'])+''''
+subStr+')';
Close;
SQL.Text:=Str;
ExecSQL;
end;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>2').asstring)<>'' then
begin
if StrToFloatDef(v_price_release_port['<27><><EFBFBD><EFBFBD>2'],0)<>0 then begin
cntrstr:=frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>2').asstring;
CntrStr:=StringReplace(CntrStr,'''','''''',[rfReplaceAll]);
Str:='Update t_ch_fee set <20><><EFBFBD><EFBFBD>='+v_price_release_port['<27><><EFBFBD><EFBFBD>2']+' where ϵͳ<CFB5><CDB3><EFBFBD><EFBFBD>=1 and <20><><EFBFBD><EFBFBD>״̬=''¼<><C2BC>״̬'' and <20><>׼='+''''+trim(cntrstr)+''''
+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>>='+''''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'])+''''+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><='''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>ֹ'])+''''
+subStr+')';
Close;
SQL.Text:=Str;
ExecSQL;
end;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>3').asstring)<>'' then
begin
if StrToFloatDef(v_price_release_port['<27><><EFBFBD><EFBFBD>3'],0)<>0 then begin
cntrstr:=frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>3').asstring;
CntrStr:=StringReplace(CntrStr,'''','''''',[rfReplaceAll]);
Str:='Update t_ch_fee set <20><><EFBFBD><EFBFBD>='+v_price_release_port['<27><><EFBFBD><EFBFBD>3']+' where ϵͳ<CFB5><CDB3><EFBFBD><EFBFBD>=1 and <20><><EFBFBD><EFBFBD>״̬=''¼<><C2BC>״̬'' and <20><>׼='+''''+trim(cntrstr)+''''
+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>>='+''''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'])+''''+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><='''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>ֹ'])+''''
+subStr+')';
Close;
SQL.Text:=Str;
ExecSQL;
end;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>4').asstring)<>'' then
begin
if StrToFloatDef(v_price_release_port['<27><><EFBFBD><EFBFBD>4'],0)<>0 then begin
cntrstr:=frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>4').asstring;
CntrStr:=StringReplace(CntrStr,'''','''''',[rfReplaceAll]);
Str:='Update t_ch_fee set <20><><EFBFBD><EFBFBD>='+v_price_release_port['<27><><EFBFBD><EFBFBD>4']+' where ϵͳ<CFB5><CDB3><EFBFBD><EFBFBD>=1 and <20><><EFBFBD><EFBFBD>״̬=''¼<><C2BC>״̬'' and <20><>׼='+''''+trim(cntrstr)+''''
+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>>='+''''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'])+''''+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><='''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>ֹ'])+''''
+subStr+')';
Close;
SQL.Text:=Str;
ExecSQL;
end;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>5').asstring)<>'' then
begin
cntrstr:=frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>5').asstring;
CntrStr:=StringReplace(CntrStr,'''','''''',[rfReplaceAll]);
if StrToFloatDef(v_price_release_port['<27><><EFBFBD><EFBFBD>5'],0)<>0 then begin
Str:='Update t_ch_fee set <20><><EFBFBD><EFBFBD>='+v_price_release_port['<27><><EFBFBD><EFBFBD>5']+' where ϵͳ<CFB5><CDB3><EFBFBD><EFBFBD>=1 and <20><><EFBFBD><EFBFBD>״̬=''¼<><C2BC>״̬'' and <20><>׼='+''''+trim(cntrstr)+''''
+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>>='+''''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'])+''''+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><='''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>ֹ'])+''''
+subStr+')';
Close;
SQL.Text:=Str;
ExecSQL;
end;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>6').asstring)<>'' then
begin
if StrToFloatDef(v_price_release_port['<27><><EFBFBD><EFBFBD>6'],0)<>0 then begin
cntrstr:=frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>6').asstring;
CntrStr:=StringReplace(CntrStr,'''','''''',[rfReplaceAll]);
Str:='Update t_ch_fee set <20><><EFBFBD><EFBFBD>='+v_price_release_port['<27><><EFBFBD><EFBFBD>6']+' where ϵͳ<CFB5><CDB3><EFBFBD><EFBFBD>=1 and <20><><EFBFBD><EFBFBD>״̬=''¼<><C2BC>״̬'' and <20><>׼='+''''+trim(cntrstr)+''''
+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>>='+''''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'])+''''+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><='''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>ֹ'])+''''
+subStr+')';
Close;
SQL.Text:=Str;
ExecSQL;
end;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>7').asstring)<>'' then
begin
if StrToFloatDef(v_price_release_port['<27><><EFBFBD><EFBFBD>7'],0)<>0 then begin
cntrstr:=frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>7').asstring;
CntrStr:=StringReplace(CntrStr,'''','''''',[rfReplaceAll]);
Str:='Update t_ch_fee set <20><><EFBFBD><EFBFBD>='+v_price_release_port['<27><><EFBFBD><EFBFBD>7']+' where ϵͳ<CFB5><CDB3><EFBFBD><EFBFBD>=1 and <20><><EFBFBD><EFBFBD>״̬=''¼<><C2BC>״̬'' and <20><>׼='+''''+trim(cntrstr)+''''
+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>>='+''''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'])+''''+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><='''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>ֹ'])+''''
+subStr+')';
Close;
SQL.Text:=Str;
ExecSQL;
end;
end;
if trim(frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>8').asstring)<>'' then
begin
if StrToFloatDef(v_price_release_port['<27><><EFBFBD><EFBFBD>8'],0)<>0 then begin
cntrstr:=frm_data_share.t_code_price_ctn.fieldbyname('<27>˼<EFBFBD><CBBC><EFBFBD><EFBFBD><EFBFBD>8').asstring;
CntrStr:=StringReplace(CntrStr,'''','''''',[rfReplaceAll]);
Str:='Update t_ch_fee set <20><><EFBFBD><EFBFBD>='+v_price_release_port['<27><><EFBFBD><EFBFBD>8']+' where ϵͳ<CFB5><CDB3><EFBFBD><EFBFBD>=1 and <20><><EFBFBD><EFBFBD>״̬=''¼<><C2BC>״̬'' and <20><>׼='+''''+trim(cntrstr)+''''
+' and <20><><EFBFBD><EFBFBD> in (select <20><><EFBFBD><EFBFBD> from t_op_seae where <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>>='+''''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>'])+''''+' and <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><='''+formatDatetime('yyyy-mm-dd',v_price_release_port['<27><>Ч<EFBFBD><D0A7><EFBFBD><EFBFBD>ֹ'])+''''
+subStr+')';
Close;
SQL.Text:=Str;
ExecSQL;
end;
end;
v_price_release_port.Next;
end;
end;
finally
FreeAndNil(aQuery);
end;
t_price_release.Edit;
t_price_release['<27><><EFBFBD><EFBFBD>״̬']:='ȷ<>Ϸ<EFBFBD><CFB7><EFBFBD>';
t_price_release.Post;
showmessage('<27>˼۳ɹ<DBB3><C9B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>');
frm_main.db.CommitTrans;
except
frm_main.db.RollbackTrans;
end;
end;
end;
procedure Tfrm_info_price_release.bsSkinButton6Click(Sender: TObject);
begin
t_price_release.Edit;
t_price_release['<27><><EFBFBD><EFBFBD>״̬']:='ȡ<><C8A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>';
t_price_release.Post;
end;
end.