|
|
|
|
unit u_info_price_person_view;
|
|
|
|
|
|
|
|
|
|
interface
|
|
|
|
|
|
|
|
|
|
uses
|
|
|
|
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
|
|
|
|
Dialogs, dxExEdtr, DB, ADODB, StdCtrls, ComCtrls, DBCtrls, bsSkinCtrls,
|
|
|
|
|
wwdblook, RxLookup, Mask, wwdbedit, Wwdotdot, Wwdbcomb, dxDBTLCl,
|
|
|
|
|
dxGrClms, dxTL, dxDBCtrl, dxDBGrid, dxCntner, ExtCtrls, BusinessSkinForm,
|
|
|
|
|
wwdbdatetimepicker;
|
|
|
|
|
|
|
|
|
|
type
|
|
|
|
|
Tfrm_info_price_person_view = class(TForm)
|
|
|
|
|
t_price_prerson: TADOQuery;
|
|
|
|
|
t_price_prerson1: TDataSource;
|
|
|
|
|
bsBusinessSkinForm1: TbsBusinessSkinForm;
|
|
|
|
|
Panel1: TPanel;
|
|
|
|
|
bsSkinButton2: TbsSkinButton;
|
|
|
|
|
bsSkinButton4: TbsSkinButton;
|
|
|
|
|
bsSkinButton8: TbsSkinButton;
|
|
|
|
|
bsSkinButton9: TbsSkinButton;
|
|
|
|
|
bsSkinButton11: TbsSkinButton;
|
|
|
|
|
bsSkinButton3: TbsSkinButton;
|
|
|
|
|
Panel2: TPanel;
|
|
|
|
|
dxDBGrid1: TdxDBGrid;
|
|
|
|
|
dxDBGrid1Column1: TdxDBGridMaskColumn;
|
|
|
|
|
dxDBGrid1Column2: TdxDBGridMaskColumn;
|
|
|
|
|
dxDBGrid1Column3: TdxDBGridMaskColumn;
|
|
|
|
|
bsSkinPanel1: TbsSkinPanel;
|
|
|
|
|
bsSkinPanel2: TbsSkinPanel;
|
|
|
|
|
Label1: TLabel;
|
|
|
|
|
Label2: TLabel;
|
|
|
|
|
Label3: TLabel;
|
|
|
|
|
Label4: TLabel;
|
|
|
|
|
wwDBComboBox1: TwwDBComboBox;
|
|
|
|
|
RxDBLookupCombo2: TRxDBLookupCombo;
|
|
|
|
|
wwDBLookupCombo52: TwwDBLookupCombo;
|
|
|
|
|
bsSkinGroupBox1: TbsSkinGroupBox;
|
|
|
|
|
DBRichEdit1: TDBRichEdit;
|
|
|
|
|
wwDBDateTimePicker1: TwwDBDateTimePicker;
|
|
|
|
|
dxDBGrid1Column4: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column5: TdxDBGridColumn;
|
|
|
|
|
dxDBGrid1Column6: TdxDBGridColumn;
|
|
|
|
|
procedure t_price_prersonAfterInsert(DataSet: TDataSet);
|
|
|
|
|
procedure t_price_prersonBeforePost(DataSet: TDataSet);
|
|
|
|
|
procedure bsSkinButton9Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton2Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton11Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton8Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton4Click(Sender: TObject);
|
|
|
|
|
procedure bsSkinButton3Click(Sender: TObject);
|
|
|
|
|
procedure t_price_prersonBeforeEdit(DataSet: TDataSet);
|
|
|
|
|
private
|
|
|
|
|
{ Private declarations }
|
|
|
|
|
public
|
|
|
|
|
{ Public declarations }
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
var
|
|
|
|
|
frm_info_price_person_view: Tfrm_info_price_person_view;
|
|
|
|
|
|
|
|
|
|
implementation
|
|
|
|
|
|
|
|
|
|
uses u_main, my_sys_function;
|
|
|
|
|
|
|
|
|
|
{$R *.dfm}
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.t_price_prersonAfterInsert(
|
|
|
|
|
DataSet: TDataSet);
|
|
|
|
|
begin
|
|
|
|
|
t_price_prerson['¼<><C2BC><EFBFBD><EFBFBD>']:=employee;
|
|
|
|
|
t_price_prerson['¼<><C2BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>']:=date;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.t_price_prersonBeforePost(
|
|
|
|
|
DataSet: TDataSet);
|
|
|
|
|
begin
|
|
|
|
|
table_before_post(t_price_prerson,'<27>ո<EFBFBD><D5B8><EFBFBD><EFBFBD><EFBFBD>');
|
|
|
|
|
table_before_post(t_price_prerson,'<27>ͻ<EFBFBD><CDBB><EFBFBD><EFBFBD><EFBFBD>');
|
|
|
|
|
table_before_post(t_price_prerson,'<27>˼<EFBFBD>˵<EFBFBD><CBB5>');
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.bsSkinButton9Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
close;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.bsSkinButton2Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
t_price_prerson.insert;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.bsSkinButton11Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
table_post(t_price_prerson);
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.bsSkinButton8Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
table_cancel(t_price_prerson);
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.bsSkinButton4Click(Sender: TObject);
|
|
|
|
|
begin
|
|
|
|
|
table_delete(t_price_prerson);
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.bsSkinButton3Click(Sender: TObject);
|
|
|
|
|
var
|
|
|
|
|
afield : variant;
|
|
|
|
|
i: Integer;
|
|
|
|
|
begin
|
|
|
|
|
if t_price_prerson.IsEmpty then
|
|
|
|
|
begin
|
|
|
|
|
showmessage('û<>и<EFBFBD><D0B8><EFBFBD>ĸ<EFBFBD>壬<EFBFBD><E5A3AC><EFBFBD>ܸ<EFBFBD><DCB8><EFBFBD><EFBFBD>½<EFBFBD><C2BD><EFBFBD>');
|
|
|
|
|
exit;
|
|
|
|
|
end;
|
|
|
|
|
afield := vararraycreate([0,t_price_prerson.fieldcount-1],varvariant);
|
|
|
|
|
for i := 1 to (t_price_prerson.fieldcount-1) do
|
|
|
|
|
begin
|
|
|
|
|
afield[i] :=t_price_prerson.fields[i].value ;
|
|
|
|
|
end;
|
|
|
|
|
t_price_prerson.append;
|
|
|
|
|
for i := 1 to (t_price_prerson.fieldcount-1) do
|
|
|
|
|
begin
|
|
|
|
|
t_price_prerson.fields[i].value := afield[i] ;
|
|
|
|
|
end;
|
|
|
|
|
showmessage('<27><><EFBFBD>Ƴɹ<C6B3><C9B9><EFBFBD><EFBFBD><EFBFBD>');
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure Tfrm_info_price_person_view.t_price_prersonBeforeEdit(
|
|
|
|
|
DataSet: TDataSet);
|
|
|
|
|
begin
|
|
|
|
|
if not do_data('3008',t_price_prerson.fieldbyname('¼<><C2BC><EFBFBD><EFBFBD>').asstring
|
|
|
|
|
,'','','','','') then
|
|
|
|
|
begin
|
|
|
|
|
showmessage('<27>Բ<EFBFBD><D4B2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȩ<EFBFBD><EFBFBD><DEB8><EFBFBD><EFBFBD>ݣ<EFBFBD><DDA3><EFBFBD>');
|
|
|
|
|
abort;
|
|
|
|
|
end;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
end.
|